Interesting, I’d done this using MQTT Sensors via the template’s.
Anyway, in the interest of sharing things I can’t see in the thread at the moment;
payload_on: '{"system":{"sequence_id":"2003","command":"ledctrl","led_node":"chamber_light","led_mode":"on","led_on_time": 500,"led_off_time": 500,"loop_times": 0,"interval_time":0},"user_id":"123456789"}'
payload_off: '{"system":{"sequence_id":"2003","command":"ledctrl","led_node":"chamber_light","led_mode":"off","led_on_time": 500,"led_off_time": 500,"loop_times": 0,"interval_time":0},"user_id":"123456789"}'
Sent to device/DEVICEID/request
will toggle the chamber lights. User ID seems to not matter.
I also have the ones for starting prints from files off the SD card, though I’m not sure how useful that would be for this setup. If your interested in prodding that tho, there is some bad Python here darkorb/bambu-ftp-and-print: A Python script to upload 3mf’s to X1 printers and trigger a print start via MQTT (github.com) which has the start print command in.
I can log the MQTT requests for cancelling/stopping prints though if there is interest, I’ve been intercepting the traffic from Handy to get the “Do things” commands. I’ll note I’ve reached out to Bambu as well to a) ask they don’t remove MQTT from local mode and b) see if they can provide some actual docs around what is what for things that are more obscure. I’ll post if/when I hear back.
Edit: Actually, the stop command might not be accurate, so snipped it. However, here’s some other fun ones for you instead. Or least I think they are fun/interesting.
Set Filament Type for a slot in the AMS
ABS: {"print":{"sequence_id":"2010","command":"ams_filament_setting","ams_id":0,"tray_id":3,"tray_info_idx":"GFB99","tray_color":"161616FF","nozzle_temp_min":240,"nozzle_temp_max":270,"tray_type":"ABS"},"user_id":"1234567890"}
ASA: {"print":{"sequence_id":"2006","command":"ams_filament_setting","ams_id":0,"tray_id":3,"tray_info_idx":"GFB98","tray_color":"161616FF","nozzle_temp_min":240,"nozzle_temp_max":270,"tray_type":"ASA"},"user_id":"1234567890"}
PA: {"print":{"sequence_id":"2016","command":"ams_filament_setting","ams_id":0,"tray_id":3,"tray_info_idx":"GFN99","tray_color":"161616FF","nozzle_temp_min":270,"nozzle_temp_max":300,"tray_type":"PA"},"user_id":"1234567890"}
PA-CF: {"print":{"sequence_id":"2017","command":"ams_filament_setting","ams_id":0,"tray_id":3,"tray_info_idx":"GFN98","tray_color":"161616FF","nozzle_temp_min":270,"nozzle_temp_max":300,"tray_type":"PA-CF"},"user_id":"1234567890"}
PC: {"print":{"sequence_id":"2019","command":"ams_filament_setting","ams_id":0,"tray_id":3,"tray_info_idx":"GFC99","tray_color":"161616FF","nozzle_temp_min":260,"nozzle_temp_max":280,"tray_type":"PC"},"user_id":"1234567890"}
PETG: {"print":{"sequence_id":"2020","command":"ams_filament_setting","ams_id":0,"tray_id":3,"tray_info_idx":"GFG99","tray_color":"161616FF","nozzle_temp_min":220,"nozzle_temp_max":260,"tray_type":"PETG"},"user_id":"1234567890"}
PLA: {"print":{"sequence_id":"2003","command":"ams_filament_setting","ams_id":0,"tray_id":3,"tray_info_idx":"GFL99","tray_color":"F72323FF","nozzle_temp_min":190,"nozzle_temp_max":250,"tray_type":"PLA"},"user_id":"1234567890"}
PLA-CF: {"print":{"sequence_id":"2021","command":"ams_filament_setting","ams_id":0,"tray_id":3,"tray_info_idx":"GFL98","tray_color":"161616FF","nozzle_temp_min":190,"nozzle_temp_max":250,"tray_type":"PLA-CF"},"user_id":"1234567890"}
PVA: {"print":{"sequence_id":"2022","command":"ams_filament_setting","ams_id":0,"tray_id":3,"tray_info_idx":"GFS99","tray_color":"161616FF","nozzle_temp_min":190,"nozzle_temp_max":250,"tray_type":"PVA"},"user_id":"1234567890"}
TPU: {"print":{"sequence_id":"2023","command":"ams_filament_setting","ams_id":0,"tray_id":3,"tray_info_idx":"GFU99","tray_color":"161616FF","nozzle_temp_min":200,"nozzle_temp_max":250,"tray_type":"TPU"},"user_id":"1234567890"}
Change Spool. Very much untested, just what I snaffled on some tests a second ago.
{"print":{"sequence_id":"2026","command":"gcode_line","param":"M620 P3 \n"},"user_id":"1234567890"}
{"print":{"sequence_id":"2027","command":"gcode_line","param":"M620 S3\nM104 S250\nG28 X\nG91\nG1 Z3.0 F1200\nG90\n\nG1 X70 F12000\nG1 Y245\nG1 Y265 F3000\nM109 S250\nG1 X120 F12000\n\nG1 X20 Y50 F12000\nG1 Y-3\n\nT3\n\nG1 X54 F12000\nG1 Y265\nM400\nM106 P1 S0\nG92 E0\nG1 E40 F200\nM400\nM109 S220\nM400\nM106 P1 S255\nG92 E0\nG1 E5 F300\nM400\nM106 P1 S0\nG1 X70 F9000\nG1 X76 F15000\nG1 X65 F15000\nG1 X76 F15000\nG1 X65 F15000\n\nG1 X70 F6000\nG1 X100 F5000\nG1 X70 F15000\nG1 X100 F5000\nG1 X70 F15000\nG1 X165 F5000\nG1 Y245\n\nG91\nG1 Z-3.0 F1200\nG90\nM621 S3"},"user_id":"1234567890"}
All those are sent to the /request
part of the topic as per above.