I am looking for some advice regarding my control setup for an ROV and how to make it as smooth as possible. Currently, I have two arcade style joysticks with standard micro switches inside. How I envision the system working is like this: Joystick outputs 3.3V or logic 1 equiavalent to a GPIO input on the BBB. I have a script setup to run on boot for the BBB that immediately sets up the input pins, and sets the output pins to low (temporarily) to avoid any floating high. A series of while loops or equivalent designate what input on which pin will correspond to the BBB outputing a HIGH value on another pin, which then goes to a 16-channel relay board, which in turn feeds out to 8 (maximum) 12V bilge pump motors.
Now here is my issue: How do I go about getting the joystick to output a signal that is of the proper voltage/amperage so as to not harm the BBB by damaging the substrate by having a GPIO sink too much current. I have seen some 3.3V regulators out there, and I assume with a proper current limiting resistor the system would function correctly without harming the Beaglebone. However, I am not sure if this would even work and how it would be setup for optimal function. For example, should I have a regulator feed 3.3V to the microswitches and have the joystick switch 3.3V? Seems like this would work in theory, but I would really like to be sure before I do any damage to the board.
If you are still not sure what my question is, let me put it to you this way: What would be the optimal setup utlizing the components above to produce a system that is both safe for the BBB and functional for the purpose intended (controlling 12V bilge pump motors by driving a relay board). To be clear, I'm not asking for anyone to design this for me, more just looking for constructive feedback and criticism to see if there is anything I can improve. Let me know if any clarifications are needed.