Auto-reconnect with RPi secondary mcu

Following the method detailed here: Auto-reconnect
This worked well until I added the RPi secondary mcu.
I added

SUBSYSTEM=="usb", ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="7523", ACTION=="add", RUN+="/bin/sh -c '/bin/echo RESTART > /tmp/klipper_host_mcu'"

as a new line to “/etc/udev/rules.d/98-klipper.rules”. The event triggers but the mcu ‘rpi’ doesn’t comes back from the shutdown state. Sending a move command errors:

Can not update MCU 'rpi' config as it is shutdown

Sending a FIRMWARE_RESET from octoprint successfully restores the connection.

apparently all I had to do was change the one line from RESTART to FIRMWARE_RESTART
SUBSYSTEM=="usb", ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="7523", ACTION=="add", RUN+="/bin/sh -c '/bin/echo FIRMWARE_RESTART > /tmp/printer"

1 Like