I have OctoPi on all my 3D printers, and they are running MQTT.
I have OctoPi set to send MQTT event messages either if it disconnects from the printer or there is an error.
In Home Assistant, I have this set up in /config/automations.yaml
Which tells the Sonoff switch to turn the power off, thus shutting down the printer.
However, when Home Assistant Boots up, I’m getting these events in the LogBook, even when the printer and OctoPi is OFF:
And the BAD part is, if that printer actually is ON and printing, this ‘fake’ event happen anyway when Home Assistant restarts and it shuts down the power to the printer in the middle of a print job!
Any ideas how to fix this and/or why its happening?
Thanks!
P.S. I think this may be happening because the last trigger was a ‘Disconnect’ topic from the printer. So maybe MQTT is still holding that topic and resending it at startup? If so, how do I clear that out after my ‘action:’ ?