Hello, I'm converting an old lab instrument to a 3D printer and need some help with my firmware. The z-axis has a solenoid configured, that when powered, opens a release mechanism to allow the z-axis to move. The z-axis drops without the stop when unpowered. I want to modify the firware so that the solenoid/servo will be powered when the z-axis motor is powered, but shuts off when z-axis shuts off. How can I do this and what pins would I use on RAMPs board? Thank you for help!