forked from zellneralex/klipper_config
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcaselight.cfg
29 lines (26 loc) · 968 Bytes
/
caselight.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#####################################################################
# Caselight pin Definition
#####################################################################
## Caselight - XYE board, HB Connector
[output_pin caselight]
pin: P2.5
pwm: true
hardware_pwm: true
shutdown_value: 0
cycle_time: 0.0001
#####################################################################
# Macros
#####################################################################
[gcode_macro _CASELIGHT_ON]
description: Helper: Light on
gcode:
SET_PIN PIN=caselight VALUE={printer['gcode_macro _USER_VARIABLE'].peripheral.caselight.on_val}
{action_respond_info("Caselight on")}
[gcode_macro _CASELIGHT_OFF]
description: Helper: Light off
gcode:
SET_PIN PIN=caselight VALUE=0.0
{action_respond_info("Caselight off")}
[gcode_macro CASELIGHT]
description: Toggle light
gcode: {% if printer['output_pin caselight'].value == 0 %} _CASELIGHT_ON {% else %} _CASELIGHT_OFF {% endif %}