#Invert Toggle case light

1 messages · Page 1 of 1 (latest)

normal epoch
#

This is my gcode macro

[output_pin caselight1]
pin: mcu:gpio5
[gcode_macro TOGGLE_CASELIGHT1]
gcode:
SET_PIN PIN=caselight1 VALUE={(not printer['output_pin caselight1'].value)|int}

At start up the pin is low and when I toggle the pin is high. I want to invert that. So that at start up the pin is high and by toggle the pin is low. Can anyone help

Thank you for your help

tardy jolt
#

put ! in front of you pin in your config