Need to find an old script to turn on/off my printer by rpi->relay


I have a really old installation of octopi that's been living under my Ultimaker 2 since forever. Running reliably so haven't touched :smiley:

I made this setup back in 2017 I think, I have an old blog post: OctoPi,

So there's a RPI3 mounted under my UM2 and it piggybacks on the PSU and can turn on the printer:

The thing right now is that since this is so old, there's issues with the Linux distribution so I'm currently unable to install tailscale which I need with a new network setup. The certs in the distro is too old or something something. Short story - I want to re-install octopi entirely.

However - I have this custom script for turning on the pi and I can't seem to find any notes or repo on any of my machines on how I exactly did that or where it is. It's just these menu entires to turn on/off

So if I remember correctly - it's just a python script that sets some pin high/low on the host pi. But I have now idea how to redo this in a new install.

Any help highly appreciated!

The menu items are under the power button:


Finally found it under /home/pi/.octoprint/config.yaml:

  - action: printer on
    command: gpio -g write 18 1
    name: Turn on the printer
  - action: printer off
    command: gpio -g write 18 0
    confirm: You are about to turn off the printer.
    name: Turn off the printer
1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.