Actions
For all actions, you can specify a target property to specify the device to send the action to.
target:
device_id: a1b2c3d4e5f6g7h8i9j0
Send Command
actionbambu_lab.extrude_retractrequiredSends arbitrary GCODE to the printer. Be careful as it does not check if the printer is running a job or not so before invoking this action, you should check the printer state to ensure it is not running a job.
action: bambu_lab.send_command
target:
device_id: a1b2c3d4e5f6g7h8i9j0
data:
command: M104 S200
The data object should contain the following properties:
commandstringrequiredThe command to perform, e.g. M104 S200
Print 3MF project file
actionbambu_lab.print_project_filerequiredPrints 3MF file stored on SD card. 3MF file must be stored on SD card root and it must contain gcode (e.g., "Export sliced file" from slicer)
action: bambu_lab.print_project_file
target:
device_id: a1b2c3d4e5f6g7h8i9j0
data:
type: Extrude
force: false
The data object should contain the following properties:
filepathstringrequiredFilename on SD card (e.g. test.3mf)
platenumberoptionalPlate number to print
timelapsebooleanoptionalRecord timelapse of the print
bed_levelingbooleanoptionalPerform bed leveling before print
flow_calibooleanoptionalPerform flow calibration before print
vibration_calibooleanoptionalPerform vibration calibration (aka XY Mech Sweep) before print
layer_inspectbooleanoptionalPerform first layer inspection during print
use_amsbooleanoptionalUse AMS for print. Uses external spool otherwise
ams_mappingbooleanoptionalExtrude or Retract Filament
actionbambu_lab.extrude_retractrequiredExtude or retract filament.
action: bambu_lab.extrude_retract
target:
device_id: a1b2c3d4e5f6g7h8i9j0
data:
type: Extrude
force: false
The data object should contain the following properties:
typestringrequiredThe type of action to perform. Can be Extrude or Retract.
forcebooleanoptionalPerform extrusion or retraction if nozzle temperature is below 170ºC.
Load Filament
actionbambu_lab.load_filamentrequiredExtude or retract filament.
action: bambu_lab.load_filament
target:
device_id: a1b2c3d4e5f6g7h8i9j0
data:
tray: 1
external_spool: 1
temperature: 220
The data object should contain the following properties:
traynumberrequiredThe tray number to load filament from.
external_spoolnumberoptionalLoad filament from the external spool. Enabling the external spool will override the AMS tray value if also set.
temperaturenumberoptionalTarget nozzle temperature once the filament is loaded. By default uses the midpoint between min and max temperature of the chosen filament.
Unload Filament
actionbambu_lab.load_filamentrequiredUnload filament from the nozzle.
action: bambu_lab.unload_filament
target:
device_id: a1b2c3d4e5f6g7h8i9j0
Move Axis
actionbambu_lab.move_axisrequiredMove the printer axis.
action: bambu_lab.move_axis
target:
device_id: a1b2c3d4e5f6g7h8i9j0
data:
axis: X
distance: 10
The data object should contain the following properties:
axisstringrequiredThe axis to move. X1 and P1 devices, X and Y move the printhead, Z moves the bed. A1, Z moves the gantry, Y the bed, X the printhead.
distancenumberrequiredThe distance (in mm) to move the axis A negative distance moves Z up, X left, Y forward.
Skip Objects
actionbambu_lab.move_axisrequiredMove the printer axis.
action: bambu_lab.skip_objects
target:
device_id: a1b2c3d4e5f6g7h8i9j0
data:
objects: 409,1463
The data object should contain the following properties:
objectsstringrequiredObject IDs are available from printable objects entity attributes