Using Arduino with Air ManagerDrive an RPM gauge for B58 or C172 with ULN driver and stepper motorBelow you find a video of a stepper motor example with ULN driver that controls a RPM gauge.The script was made to work with B58 but of course it can be used with other planes as well.The stepper is connected via the driver to 4 digital ports on the arduino.The calibration switch is connected directly to a port on Arduino.The date comes from XPlane via AirManager, the script does not take more than a few lines.Need more info, feel free to ask
Driver connectionsStepper motor plugged into white connectorIN1 goes to Arduino port 2IN3 goes to Arduino port 3IN2 goes to Arduino port 4IN4 goes to Arduino port 5
1
Calibration switchGoes to Arduino port 7 and GNDCan be replaced by a photo sensorto handle calibration automatically
How to use the sensor as a calibration toolFor calibration the best is to use a photo sensorThat is simply a IR led that shines on a photo sensor (transistor)In Air Manager add the following code to test…function input_change(state) print("state = " .. tostring(state)) endinput = hw_input_add("ZeroStop", input_change)Blocking the light from the LED will trigger astate changed and you will see that in Air Manager
How to do it practically with an instrument and behind the dial plate