====== DRAWBOT ======
there are three repos needed to get this going
* GRBL [[https://git.telavivmakers.space/yair/grbl|git]] - the firmware running on the arduino+grbl shield
* drawbot_LY [[https://git.telavivmakers.space/yair/drawbot_LY|git]] - the Inkscape extension that converts vector to gcode
* Universal gcode sender- this [[https://universalgcodesender.com/|java app]] loads the gcode above and sends the gcode commands one by one to the Arduino over serial.
the above fork of GRBL has been adapted to make servo handling easier (check commits). \\
there are also EEPROM kept states that need to be adapted to our machine. \\
- enabling of homing sequence (the [[https://he.aliexpress.com/item/1005005888174412.html|machine]] did not come with limit switches)
- adapting the number of steps per millimeter for x/y
- keeping steppers motorized ''$1=255'' (thanks paul)
the drawbot Inkscape extension also got some love, with a few fixes. notably, disregarding hidden layers, addition of x/y offset control.
{{tamiwiki:projects:video_2025-12-16_12-08-06.mp4 }}
{{tamiwiki:projects:photo_2025-12-16_00-37-06.jpg?700}}
==== links and more info ====
* https://sameer.github.io/svg2gcode/
* https://www.generativehut.com/post/ly-drawbot-a-70-pen-plotter
* https://hannahilea.com/blog/ly-drawbot-setup/#fn4
* https://he.aliexpress.com/item/1005005888174412.html
==== llm lols ====
{{tamiwiki:projects:tami_draw.gcode}}
cat drawbot_skeleton.gcode | llm -m openrouter/anthropic/claude-3.7-sonnet -x - | tee drawbot_claude37.gcode
{{:tamiwiki:projects:pxl_20251019_225657827.jpg?400|}}
{{tamiwiki:projects:drawbot_skeleton.gcode}}
; drawbot_skeleton.gcode
;extend the following gcode to draw an orthographic view of a rubic cube
; speed is F2200
; limits are y:60 x:200
; only one color
; do not draw occlude lines
G21 ; Set units to millimeters
G90 ; Set to absolute positioning
M5 ; Pen up
G4 P1 ; always Wait 1 second after pen up
M3 S1000 ; Pen down
we came a long way
cat drawbot_skeleton.gcode | llm -m 3.5 -x - | tee drawbot_gpt35-turbo.gcode
G1 X0 Y0 F2200 ; Move to starting position
G1 X60 Y0 ; Draw first square of the rubic cube
G1 X0 Y60 ; Draw second square of the rubic cube
G1 X60 Y60 ; Draw third square of the rubic cube
G1 X60 Y20 ; Draw fourth square of the rubic cube
G1 X60 Y40 ; Draw fifth square of the rubic cube
G1 X20 Y60 ; Draw sixth square of the rubic cube
G1 X40 Y60 ; Draw seventh square of the rubic cube
G1 X20 Y0 ; Draw eighth square of the rubic cube
G1 X40 Y0 ; Draw ninth square of the rubic cube
M5 ; Pen up
G4 P1 ; Wait 1 second
M2 ; End of program