buncha messing around

This commit is contained in:
Mitchell Hansen
2026-06-21 13:31:15 -07:00
parent e88ac8d16b
commit f4704916fc
16 changed files with 847368 additions and 18 deletions

179
config.yaml Normal file
View File

@@ -0,0 +1,179 @@
name: "TMC2209 XY Servo Laser"
board: "FluidNC Pen/Laser 2209 V2"
junction_deviation_mm: 0.05
stepping:
engine: RMT
idle_ms: 255
dir_delay_us: 1
pulse_us: 2
disable_delay_us: 0
start:
must_home: false
deactivate_parking: false
check_limits: true
#Stepper Driver UART
uart1:
txd_pin: gpio.17
rxd_pin: gpio.16
rts_pin: NO_PIN
cts_pin: NO_PIN
baud: 115200
mode: 8N1
# Pendant UART
uart2:
txd_pin: gpio.4
rxd_pin: gpio.15
rts_pin: NO_PIN
cts_pin: NO_PIN
baud: 5000000
mode: 8N1
# Pendant
uart_channel2:
uart_num: 2
report_interval_ms: 75
axes:
shared_stepper_disable_pin: gpio.13:high
x:
steps_per_mm: 82
max_rate_mm_per_min: 5000
acceleration_mm_per_sec2: 500
max_travel_mm: 220
soft_limits: false
homing:
cycle: 2
positive_direction: false
mpos_mm: 0
feed_mm_per_min: 200.000
seek_mm_per_min: 1000.000
settle_ms: 500
seek_scaler: 1.100
feed_scaler: 1.100
motor0:
limit_neg_pin: NO_PIN
limit_pos_pin: NO_PIN
limit_all_pin: gpio.36:low
hard_limits: true
pulloff_mm: 1
tmc_2209:
uart_num: 1
addr: 0
r_sense_ohms: 0.110
run_amps: 1.000
hold_amps: 0.200
homing_amps: 1.000
microsteps: 16
stallguard: 0
stallguard_debug: false
toff_disable: 0
toff_stealthchop: 5
toff_coolstep: 3
run_mode: StealthChop
homing_mode: StealthChop
homing_amps: 0.80
use_enable: false
direction_pin: gpio.12:low
step_pin: gpio.14
motor1:
null_motor:
y:
steps_per_mm: 76
max_rate_mm_per_min: 5000
acceleration_mm_per_sec2: 500
max_travel_mm: 320
soft_limits: false
homing:
cycle: 2
positive_direction: false
mpos_mm: 0.000
feed_mm_per_min: 200.000
seek_mm_per_min: 1000.000
settle_ms: 500
seek_scaler: 1.100
feed_scaler: 1.100
motor0:
limit_neg_pin: NO_PIN
limit_pos_pin: NO_PIN
limit_all_pin: gpio.39:low
hard_limits: true
pulloff_mm: 1
tmc_2209:
uart_num: 1
addr: 1
r_sense_ohms: 0.110
run_amps: 0.800
hold_amps: 0.200
homing_amps: 1.000
microsteps: 16
stallguard: 0
stallguard_debug: false
toff_disable: 0
toff_stealthchop: 5
toff_coolstep: 3
run_mode: StealthChop
homing_mode: StealthChop
homing_amps: 0.80
use_enable: false
direction_pin: gpio.26
step_pin: gpio.25
motor1:
null_motor:
z:
steps_per_mm: 100
max_rate_mm_per_min: 10000
acceleration_mm_per_sec2: 500
max_travel_mm: 5.00
soft_limits: false
homing:
cycle: 0
positive_direction: false
mpos_mm: 0
motor0:
rc_servo:
pwm_hz: 50
output_pin: gpio.21
min_pulse_us: 2000
max_pulse_us: 1000
spi:
miso_pin: gpio.19
mosi_pin: gpio.23
sck_pin: gpio.18
sdcard:
cs_pin: gpio.5
card_detect_pin: NO_PIN
coolant:
flood_pin: NO_PIN
mist_pin: gpio.22
probe:
pin: gpio.32:low
control:
feed_hold_pin: gpio.35:low
cycle_start_pin: gpio.34:low
safety_door_pin: gpio.33:low
Laser:
pwm_hz: 5000
output_pin: gpio.27
enable_pin: gpio.2
disable_with_s0: false
s0_with_disable: true
tool_num: 0
speed_map: 0=0.000% 255=100.000%

View File

@@ -1,7 +1,7 @@
{
"version": 1,
"app": "trac3r",
"saved_at": "2026-06-16T07:32:05.632Z",
"saved_at": "2026-06-18T06:06:21.491Z",
"image_path": null,
"node_width": 450,
"graph": {
@@ -38,7 +38,7 @@
"kind": "Text",
"x": 1023.771108140191,
"y": 1395.6709349290113,
"text": "Hansen Family\n2710 Timberline Dr.\nWest Richland, WA 99353",
"text": "Emily Hansen\n609 Kirkham St.\nSan Francisco, CA 94122",
"font": "futural",
"font_size_mm": 3,
"line_spacing_mm": 10,

Binary file not shown.

View File

@@ -0,0 +1,222 @@
{
"version": 1,
"app": "trac3r",
"saved_at": "2026-06-21T20:27:01.442Z",
"image_path": null,
"node_width": 450,
"graph": {
"nodes": [
{
"id": "source",
"kind": "Source",
"file_path": "/Users/mitchellhansen/source/Trac3r-rust/resources/images/angine-de-poitrine-vol-ii-3003991_1024x1024.jpg",
"x": 60,
"y": 60,
"file_w_px": 1024,
"file_h_px": 1024
},
{
"id": "kernel_61295",
"kind": "Kernel",
"kernel": "Luminance",
"weight": 1.6,
"invert": true,
"blur_radius": 0,
"sat_min_value": 0.1,
"canny_low": 50,
"canny_high": 150,
"xdog_sigma2": 1.6,
"xdog_tau": 0.4,
"xdog_phi": 100,
"color_filter": {
"enabled": true,
"hue_min": 335.49132947976886,
"hue_max": 15.491329479768808,
"sat_min": 0.2,
"sat_max": 1,
"val_min": 0.15,
"val_max": 1
},
"ci_color": "#e63946",
"ci_hue_tolerance": 20,
"ci_sat_min": 0.2,
"ci_val_min": 0.15,
"x": 580,
"y": 60
},
{
"id": "hull",
"kind": "Hull",
"threshold": 128,
"min_area": 13,
"connectivity": "eight",
"color_filter": {
"enabled": false,
"hue_min": 0,
"hue_max": 360,
"sat_min": 0,
"sat_max": 1,
"val_min": 0,
"val_max": 1
},
"x": 1100,
"y": 60
},
{
"id": "fill",
"kind": "Fill",
"strategy": "outline",
"spacing": 0.1,
"angle": 0,
"param": 1,
"smooth_rdp": 0,
"smooth_iters": 0,
"dpi": 425,
"x": 1620,
"y": 60
},
{
"id": "pen1",
"kind": "PenOutput",
"pen_color": [
20,
20,
20
],
"pen_label": "Pen 1",
"pen_order": 0,
"x": 2140,
"y": 60
},
{
"id": "kernel_62688",
"kind": "Kernel",
"x": 576.4968553459119,
"y": -587.7551806947721,
"kernel": "XDoG",
"weight": 1,
"invert": false,
"blur_radius": 0,
"sat_min_value": 0.1,
"canny_low": 50,
"canny_high": 150,
"xdog_sigma2": 7.5,
"xdog_tau": 0.98,
"xdog_phi": 10,
"color_filter": {
"enabled": true,
"hue_min": 335.49132947976886,
"hue_max": 15.491329479768808,
"sat_min": 0.2,
"sat_max": 1,
"val_min": 0.15,
"val_max": 1
},
"ci_color": "#e63946",
"ci_hue_tolerance": 20,
"ci_sat_min": 0.2,
"ci_val_min": 0.15
},
{
"id": "hull_62857",
"kind": "Hull",
"x": 1105.1667721409349,
"y": -745.8331740836204,
"threshold": 128,
"min_area": 4,
"connectivity": "four",
"color_filter": {
"enabled": false,
"hue_min": 0,
"hue_max": 360,
"sat_min": 0,
"sat_max": 1,
"val_min": 0,
"val_max": 1
}
},
{
"id": "fill_63032",
"kind": "Fill",
"x": 1646.1119846155493,
"y": -847.2923694079702,
"strategy": "outline",
"spacing": 3.9,
"angle": 0,
"param": 1,
"smooth_rdp": 0,
"smooth_iters": 0,
"dpi": 254
},
{
"id": "penoutput_63145",
"kind": "PenOutput",
"x": 2165.8563215965705,
"y": -813.3008573323875,
"pen_color": [
20,
20,
20
],
"pen_label": "Pen 1",
"pen_order": 0
}
],
"edges": [
{
"from": "source",
"to": "kernel_61295",
"port": 0
},
{
"from": "kernel_61295",
"to": "hull",
"port": 0
},
{
"from": "hull",
"to": "fill",
"port": 0
},
{
"from": "source",
"to": "kernel_62688",
"port": 0
},
{
"from": "kernel_62688",
"to": "hull_62857",
"port": 0
},
{
"from": "hull_62857",
"to": "fill_63032",
"port": 0
},
{
"from": "fill_63032",
"to": "penoutput_63145",
"port": 0
}
]
},
"gcode": {
"bed_w_mm": 220,
"bed_h_mm": 320,
"paper_offset_x_mm": 5.418060200668896,
"paper_offset_y_mm": 11.918060200668897,
"paper_w_mm": 210,
"paper_h_mm": 297,
"img_w_mm": 198.48921671658832,
"offset_x_mm": 6.62450034934923,
"offset_y_mm": 46.88099386613955,
"feed_draw": 1700,
"feed_travel": 5000,
"pen_down": "G1 Z0.4 F1000",
"pen_up_z_mm": 2,
"pen_dwell_ms": 70,
"pen_tip_mm": 0.5,
"printer_url": "http://192.168.2.80",
"rotate_quarter_turns": 1
}
}

View File

@@ -0,0 +1,227 @@
{
"version": 1,
"app": "trac3r",
"saved_at": "2026-06-20T03:04:40.560Z",
"image_path": null,
"node_width": 450,
"graph": {
"nodes": [
{
"id": "source",
"kind": "Source",
"file_path": "/Users/mitchellhansen/source/Trac3r-rust/resources/images/Pasted image (3).png",
"x": 60,
"y": 60,
"file_w_px": 1000,
"file_h_px": 1198
},
{
"id": "kernel_50598",
"kind": "Kernel",
"kernel": "Luminance",
"weight": 0.8,
"invert": false,
"blur_radius": 0,
"sat_min_value": 0.1,
"canny_low": 50,
"canny_high": 150,
"xdog_sigma2": 1.6,
"xdog_tau": 0.98,
"xdog_phi": 10,
"color_filter": {
"enabled": true,
"hue_min": 335.49132947976886,
"hue_max": 15.491329479768808,
"sat_min": 0.2,
"sat_max": 1,
"val_min": 0.15,
"val_max": 1
},
"ci_color": "#e63946",
"ci_hue_tolerance": 20,
"ci_sat_min": 0.2,
"ci_val_min": 0.15,
"x": 580,
"y": 60
},
{
"id": "hull",
"kind": "Hull",
"threshold": 128,
"min_area": 4,
"connectivity": "four",
"color_filter": {
"enabled": false,
"hue_min": 0,
"hue_max": 360,
"sat_min": 0,
"sat_max": 1,
"val_min": 0,
"val_max": 1
},
"x": 1100,
"y": 60
},
{
"id": "fill",
"kind": "Fill",
"strategy": "outline",
"spacing": 2.5,
"angle": 0,
"param": 1,
"smooth_rdp": 0,
"smooth_iters": 0,
"dpi": 254,
"x": 1620,
"y": 60
},
{
"id": "pen1",
"kind": "PenOutput",
"pen_color": [
20,
20,
20
],
"pen_label": "Pen 1",
"pen_order": 0,
"x": 2140,
"y": 60
},
{
"id": "kernel_51645",
"kind": "Kernel",
"x": 583.267085404842,
"y": -642.92954131517,
"kernel": "Luminance",
"weight": 1,
"invert": false,
"blur_radius": 0,
"sat_min_value": 0.1,
"canny_low": 50,
"canny_high": 150,
"xdog_sigma2": 1.6,
"xdog_tau": 0.98,
"xdog_phi": 10,
"color_filter": {
"enabled": true,
"hue_min": 335.49132947976886,
"hue_max": 15.491329479768808,
"sat_min": 0.2,
"sat_max": 1,
"val_min": 0.15,
"val_max": 1
},
"ci_color": "#e63946",
"ci_hue_tolerance": 20,
"ci_sat_min": 0.2,
"ci_val_min": 0.15
},
{
"id": "hull_51768",
"kind": "Hull",
"x": 1094.381836784237,
"y": -707.8017982210164,
"threshold": 104,
"min_area": 5000,
"connectivity": "four",
"color_filter": {
"enabled": false,
"hue_min": 0,
"hue_max": 360,
"sat_min": 0,
"sat_max": 1,
"val_min": 0,
"val_max": 1
}
},
{
"id": "fill_51841",
"kind": "Fill",
"x": 1613.3598920310076,
"y": -793.3152277787229,
"strategy": "voronoi",
"spacing": 3.1,
"angle": 0,
"param": 1,
"smooth_rdp": 0,
"smooth_iters": 0,
"dpi": 375
},
{
"id": "penoutput_51966",
"kind": "PenOutput",
"x": 2149.0474679959507,
"y": -807.0760095466296,
"pen_color": [
20,
20,
20
],
"pen_label": "Pen 1",
"pen_order": 0
}
],
"edges": [
{
"from": "source",
"to": "kernel_50598",
"port": 0
},
{
"from": "kernel_50598",
"to": "hull",
"port": 0
},
{
"from": "hull",
"to": "fill",
"port": 0
},
{
"from": "fill",
"to": "pen1",
"port": 0
},
{
"from": "fill_51841",
"to": "penoutput_51966",
"port": 0
},
{
"from": "hull_51768",
"to": "fill_51841",
"port": 0
},
{
"from": "kernel_51645",
"to": "hull_51768",
"port": 0
},
{
"from": "source",
"to": "kernel_51645",
"port": 0
}
]
},
"gcode": {
"bed_w_mm": 220,
"bed_h_mm": 320,
"paper_offset_x_mm": 5,
"paper_offset_y_mm": 11.5,
"paper_w_mm": 210,
"paper_h_mm": 297,
"img_w_mm": 203.75087006080153,
"offset_x_mm": 2.58146229312114,
"offset_y_mm": 11.432441441524595,
"feed_draw": 1000,
"feed_travel": 5000,
"pen_down": "G1 Z0.4 F1000",
"pen_up_z_mm": 2,
"pen_dwell_ms": 250,
"pen_tip_mm": 0.5,
"printer_url": "http://192.168.2.80",
"rotate_quarter_turns": 0
}
}

View File

@@ -0,0 +1,134 @@
{
"version": 1,
"app": "trac3r",
"saved_at": "2026-06-18T06:02:49.905Z",
"image_path": null,
"node_width": 450,
"graph": {
"nodes": [
{
"id": "source",
"kind": "Source",
"file_path": "/Users/mitchellhansen/source/Trac3r-rust/resources/images/set-ripe-corn-hand-drawn-illustration_37827-1054_jpg.png",
"x": 60,
"y": 60,
"file_w_px": 740,
"file_h_px": 740
},
{
"id": "kernel_11401",
"kind": "Kernel",
"kernel": "XDoG",
"weight": 1.8,
"invert": false,
"blur_radius": 0,
"sat_min_value": 0.1,
"canny_low": 50,
"canny_high": 150,
"xdog_sigma2": 1.6,
"xdog_tau": 0.98,
"xdog_phi": 10,
"color_filter": {
"enabled": true,
"hue_min": 335.49132947976886,
"hue_max": 15.491329479768808,
"sat_min": 0.2,
"sat_max": 1,
"val_min": 0.15,
"val_max": 1
},
"ci_color": "#e63946",
"ci_hue_tolerance": 20,
"ci_sat_min": 0.2,
"ci_val_min": 0.15,
"x": 580,
"y": 60
},
{
"id": "hull",
"kind": "Hull",
"threshold": 215,
"min_area": 4,
"connectivity": "four",
"color_filter": {
"enabled": false,
"hue_min": 0,
"hue_max": 360,
"sat_min": 0,
"sat_max": 1,
"val_min": 0,
"val_max": 1
},
"x": 1100,
"y": 60
},
{
"id": "fill",
"kind": "Fill",
"strategy": "outline",
"spacing": 2,
"angle": 0,
"param": 1,
"smooth_rdp": 0,
"smooth_iters": 0,
"dpi": 425,
"x": 1620,
"y": 60
},
{
"id": "pen1",
"kind": "PenOutput",
"pen_color": [
20,
20,
20
],
"pen_label": "Pen 1",
"pen_order": 0,
"x": 2140,
"y": 60
}
],
"edges": [
{
"from": "source",
"to": "kernel_11401",
"port": 0
},
{
"from": "kernel_11401",
"to": "hull",
"port": 0
},
{
"from": "hull",
"to": "fill",
"port": 0
},
{
"from": "fill",
"to": "pen1",
"port": 0
}
]
},
"gcode": {
"bed_w_mm": 220,
"bed_h_mm": 320,
"paper_offset_x_mm": 5,
"paper_offset_y_mm": 11.5,
"paper_w_mm": 210,
"paper_h_mm": 297,
"img_w_mm": 200.5969387174046,
"offset_x_mm": 6.128677126555029,
"offset_y_mm": 43.41427329494073,
"feed_draw": 1400,
"feed_travel": 5000,
"pen_down": "G1 Z0.4 F1000",
"pen_up_z_mm": 2,
"pen_dwell_ms": 160,
"pen_tip_mm": 0.5,
"printer_url": "http://192.168.2.80",
"rotate_quarter_turns": 0
}
}

BIN
resources/images/hhpzoawhg2k61.jpg (Stored with Git LFS) Normal file

Binary file not shown.

BIN
resources/images/sabateur.png (Stored with Git LFS) Normal file

Binary file not shown.

BIN
resources/images/sabateur.webp (Stored with Git LFS) Normal file

Binary file not shown.

View File

@@ -0,0 +1,64 @@
{
"version": 1,
"app": "trac3r",
"saved_at": "2026-06-18T05:31:57.297Z",
"image_path": null,
"node_width": 450,
"graph": {
"nodes": [
{
"id": "pen1",
"kind": "PenOutput",
"pen_color": [
20,
20,
20
],
"pen_label": "Pen 1",
"pen_order": 0,
"x": 1484.6746376285246,
"y": -376.88357491431697
},
{
"id": "text_6963",
"kind": "Text",
"x": 533.6610878661088,
"y": -379.8598326359835,
"text": "What the fuck did you just fucking say about \nme, you little bitch? I'll have you know I \ngraduated top of my class in the Navy Seals, \nand I've been involved in numerous secret \nraids on Al-Quaeda, and I have over 300 \nconfirmed kills. I am trained in gorilla warfare\n and I'm the top sniper in the entire US \narmed forces. You are nothing to me but \njust another target. I will wipe you the fuck \nout with precision the likes of which has \nnever been seen before on this Earth, mark \nmy fucking words. You think you can get away \nwith saying that shit to me over the Internet? \nThink again, fucker. As we speak I am \ncontacting my secret network of spies across \nthe USA and your IP is being traced right \nnow so you better prepare for the storm, \nmaggot. The storm that wipes out the \npathetic little thing you call your life. You're \nfucking dead, kid. I can be anywhere, anytime, \nand I can kill you in over seven hundred ways, \nand that's just with my bare hands. Not only \nam I extensively trained in unarmed combat, \nbut I have access to the entire arsenal of the \nUnited States Marine Corps and I will use it \nto its full extent to wipe your miserable ass \noff the face of the continent, you little shit. \nIf only you could have known what unholy \nretribution your little \"clever\" comment was \nabout to bring down upon you, maybe you \nwould have held your fucking tongue. But \nyou couldn't, you didn't, and now you're \npaying the price, you goddamn idiot. I will \nshit fury all over you and you will drown in it. \n\nYou're fucking dead, kiddo.",
"font": "futural",
"font_size_mm": 2.5,
"line_spacing_mm": 6.5,
"x_mm": 10,
"y_mm": 20,
"align": "center",
"underline": false
}
],
"edges": [
{
"from": "text_6963",
"to": "pen1",
"port": 0
}
]
},
"gcode": {
"bed_w_mm": 220,
"bed_h_mm": 320,
"paper_offset_x_mm": 5,
"paper_offset_y_mm": 11.5,
"paper_w_mm": 210,
"paper_h_mm": 297,
"img_w_mm": 232.78757416890963,
"offset_x_mm": 31.2122891666888,
"offset_y_mm": 6.6593644590361,
"feed_draw": 1400,
"feed_travel": 5000,
"pen_down": "G1 Z0.4 F1000",
"pen_up_z_mm": 2,
"pen_dwell_ms": 160,
"pen_tip_mm": 0.5,
"printer_url": "http://192.168.2.80",
"rotate_quarter_turns": 0
}
}

Binary file not shown.

View File

@@ -0,0 +1,150 @@
{
"version": 1,
"app": "trac3r",
"saved_at": "2026-06-20T04:12:46.151Z",
"image_path": null,
"node_width": 450,
"graph": {
"nodes": [
{
"id": "source",
"kind": "Source",
"file_path": "/Users/mitchellhansen/source/Trac3r-rust/resources/images/hhpzoawhg2k61.jpg",
"x": 60,
"y": 60,
"file_w_px": 625,
"file_h_px": 471
},
{
"id": "kernel_58314",
"kind": "Kernel",
"kernel": "XDoG",
"weight": 0.7,
"invert": false,
"blur_radius": 0,
"sat_min_value": 0.1,
"canny_low": 50,
"canny_high": 150,
"xdog_sigma2": 1.6,
"xdog_tau": 0.98,
"xdog_phi": 28,
"color_filter": {
"enabled": true,
"hue_min": 335.49132947976886,
"hue_max": 15.491329479768808,
"sat_min": 0.2,
"sat_max": 1,
"val_min": 0.15,
"val_max": 1
},
"ci_color": "#e63946",
"ci_hue_tolerance": 20,
"ci_sat_min": 0.2,
"ci_val_min": 0.15,
"x": 580,
"y": 60
},
{
"id": "hull",
"kind": "Hull",
"threshold": 163,
"min_area": 22,
"connectivity": "four",
"color_filter": {
"enabled": false,
"hue_min": 0,
"hue_max": 360,
"sat_min": 0,
"sat_max": 1,
"val_min": 0,
"val_max": 1
},
"x": 1100,
"y": 60
},
{
"id": "fill",
"kind": "Fill",
"strategy": "outline",
"spacing": 2,
"angle": 0,
"param": 1,
"smooth_rdp": 0,
"smooth_iters": 0,
"dpi": 525,
"x": 1620,
"y": 60
},
{
"id": "pen1",
"kind": "PenOutput",
"pen_color": [
20,
20,
20
],
"pen_label": "Pen 1",
"pen_order": 0,
"x": 2140,
"y": 60
},
{
"id": "mask_59839",
"kind": "Mask",
"x": 528.3856159138845,
"y": -530.9329209034938,
"mask_x": 0.82,
"mask_y": 0.945,
"mask_w": 0.23,
"mask_h": 0.15,
"invert": false
}
],
"edges": [
{
"from": "hull",
"to": "fill",
"port": 0
},
{
"from": "fill",
"to": "pen1",
"port": 0
},
{
"from": "source",
"to": "kernel_58314",
"port": 0
},
{
"from": "kernel_58314",
"to": "mask_59839",
"port": 0
},
{
"from": "mask_59839",
"to": "hull",
"port": 0
}
]
},
"gcode": {
"bed_w_mm": 220,
"bed_h_mm": 320,
"paper_offset_x_mm": 5.418060200668896,
"paper_offset_y_mm": 11.918060200668897,
"paper_w_mm": 210,
"paper_h_mm": 297,
"img_w_mm": 264.36959915779147,
"offset_x_mm": 5.507883697803414,
"offset_y_mm": 13.940802645537975,
"feed_draw": 1700,
"feed_travel": 5000,
"pen_down": "G1 Z0.4 F1000",
"pen_up_z_mm": 2,
"pen_dwell_ms": 70,
"pen_tip_mm": 0.5,
"printer_url": "http://192.168.2.80",
"rotate_quarter_turns": 1
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,132 @@
{
"version": 1,
"app": "trac3r",
"saved_at": "2026-06-21T18:20:47.949Z",
"image_path": null,
"node_width": 450,
"graph": {
"nodes": [
{
"id": "source",
"kind": "Source",
"file_path": null,
"x": 60,
"y": 60
},
{
"id": "kernel_65432",
"kind": "Kernel",
"kernel": "Luminance",
"weight": 1,
"invert": false,
"blur_radius": 0,
"sat_min_value": 0.1,
"canny_low": 50,
"canny_high": 150,
"xdog_sigma2": 1.6,
"xdog_tau": 0.98,
"xdog_phi": 10,
"color_filter": {
"enabled": true,
"hue_min": 335.49132947976886,
"hue_max": 15.491329479768808,
"sat_min": 0.2,
"sat_max": 1,
"val_min": 0.15,
"val_max": 1
},
"ci_color": "#e63946",
"ci_hue_tolerance": 20,
"ci_sat_min": 0.2,
"ci_val_min": 0.15,
"x": 580,
"y": 60
},
{
"id": "hull",
"kind": "Hull",
"threshold": 128,
"min_area": 4,
"connectivity": "four",
"color_filter": {
"enabled": false,
"hue_min": 0,
"hue_max": 360,
"sat_min": 0,
"sat_max": 1,
"val_min": 0,
"val_max": 1
},
"x": 1100,
"y": 60
},
{
"id": "fill",
"kind": "Fill",
"strategy": "hatch",
"spacing": 2,
"angle": 0,
"param": 1,
"smooth_rdp": 1,
"smooth_iters": 2,
"dpi": 254,
"x": 1620,
"y": 60
},
{
"id": "pen1",
"kind": "PenOutput",
"pen_color": [
20,
20,
20
],
"pen_label": "Pen 1",
"pen_order": 0,
"x": 2140,
"y": 60
}
],
"edges": [
{
"from": "source",
"to": "kernel_65432",
"port": 0
},
{
"from": "kernel_65432",
"to": "hull",
"port": 0
},
{
"from": "hull",
"to": "fill",
"port": 0
},
{
"from": "fill",
"to": "pen1",
"port": 0
}
]
},
"gcode": {
"bed_w_mm": 220,
"bed_h_mm": 320,
"paper_offset_x_mm": 64.71952341137123,
"paper_offset_y_mm": 36.84163879598661,
"paper_w_mm": 104.775,
"paper_h_mm": 241.3,
"img_w_mm": 241.98489858362532,
"offset_x_mm": -138.93821250555197,
"offset_y_mm": 5.823244057698307,
"feed_draw": 1400,
"feed_travel": 5000,
"pen_down": "G1 Z0.4 F1000",
"pen_up_z_mm": 2,
"pen_dwell_ms": 160,
"pen_tip_mm": 0.5,
"printer_url": "http://192.168.2.80",
"rotate_quarter_turns": 1
}
}

BIN
resources/images/zodiac_border.png (Stored with Git LFS) Normal file

Binary file not shown.

View File

@@ -1350,26 +1350,28 @@ fn build_all_gcode(st: &AppState, cfg: &gcode::GcodeConfig) -> Vec<(String, Stri
// `image_rgb` so the standard image pipeline (Source → Kernel → Hull →
// Fill) renders the text like any other image.
let mut out = Vec::new();
// The plotter has no auto pen-changer, so every pen's strokes are packed
// into a SINGLE gcode file and run as one continuous job (ordered by each
// pen's `order`). `to_gcode` already emits one home/return around the whole
// slice, so we just hand it every pen's fill at once. Image dims come from
// the pass the pens belong to (in practice there is a single pass).
let mut fills: Vec<(u32, fill::FillResult)> = Vec::new();
let mut dims: Option<(u32, u32)> = None;
for ps in st.passes.iter() {
let (iw, ih) = (ps.img_w.max(1), ps.img_h.max(1));
let mut pens = ps.pen_results.clone();
pens.sort_by_key(|pr| pr.order);
for pr in &pens {
for pr in &ps.pen_results {
if pr.fill.strokes.is_empty() { continue; }
let code = gcode::to_gcode(&[pr.fill.clone()], iw, ih, cfg);
let slug = if pr.label.is_empty() {
format!("{:02x}{:02x}{:02x}", pr.color[0], pr.color[1], pr.color[2])
} else {
pr.label.chars()
.map(|c| if c.is_alphanumeric() || c == '-' || c == '_' { c } else { '_' })
.collect()
};
let fname = format!("{:02}_{slug}.gcode", pr.order + 1);
out.push((fname, code));
if dims.is_none() { dims = Some((ps.img_w.max(1), ps.img_h.max(1))); }
fills.push((pr.order, pr.fill.clone()));
}
}
out
let (iw, ih) = match dims {
Some(d) => d,
None => return Vec::new(),
};
fills.sort_by_key(|(order, _)| *order);
let ordered: Vec<fill::FillResult> = fills.into_iter().map(|(_, f)| f).collect();
let code = gcode::to_gcode(&ordered, iw, ih, cfg);
vec![("trac3r.gcode".to_string(), code)]
}
#[tauri::command]