Files
mangavalkandClaude Opus 5.5 e5be65834e LEDs: nozzle light follows the motion sensor, new logo status macro
The motion timeout switched the nozzle LEDs off during prints, motion
switched them off when idle or paused, the timeout counted from the first
movement, and every _status_* macro stopped the nozzle light.

- _LIGHTS sets case light and nozzle LEDs from presence, print state and
  CASELIGHT MODE=AUTO|ON|OFF; the timeout (60 s) starts at the sensor
  release
- _STATUS STATE=... replaces the _status_* macros; logo effects only
  cover the logo LEDs and use REPLACE=1
- heater gauge while heating, print progress, paused, error flash from
  _ERROR, part ready once the bed is cool, dim night mode when idle and
  nobody near, cleaning during BLOBIFIER_CLEAN
- removed unused effects and macros, 12 fps for the toolhead effects

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 19:32:42 +02:00

36 lines
1.5 KiB
INI

# Errors and warnings that also show on the display (M117: the status line in
# Mainsail and KlipperScreen, display_status.message)
#
# action_raise_error aborts while the macro is rendered, before any of its
# G-code runs, so an M117 in the same macro never shows. _ERROR sends the
# M117 first and raises the error in a separate macro: the display keeps the
# text and the calling macros are aborted as with action_raise_error.
#
# _ERROR MSG="full text for the console" DISPLAY="short text"
# _WARN MSG="full text for the console" DISPLAY="short text"
#
# DISPLAY defaults to MSG. No double quotes in either (they end the
# parameter). Nothing after an _ERROR in the calling macro runs, but
# anything that macro does while rendering (action_respond_info, ...) has
# already happened: put the rest in an else branch.
[gcode_macro _ERROR]
description: Show DISPLAY (default MSG) on the display, then raise MSG as an error (aborts the calling macros)
gcode:
M117 {params.DISPLAY|default(params.MSG)}
{% if 'gcode_macro _STATUS_FLASH' in printer %}
_STATUS_FLASH STATE=error
{% endif %}
_RAISE_ERROR MSG="{params.MSG}"
[gcode_macro _RAISE_ERROR]
description: Helper for _ERROR: raise MSG as an error
gcode:
{action_raise_error(params.MSG)}
[gcode_macro _WARN]
description: Show MSG as an error line in the console and DISPLAY (default MSG) on the display, without stopping
gcode:
RESPOND TYPE=error MSG="{params.MSG}"
M117 {params.DISPLAY|default(params.MSG)}