I need help with writing a code for a limit switch buttons that controls a DC motor.
The limit switch looks like this:
The DC motor controlled by H-Bridge (L298N) that connected to the Arduino (nano).
I want that the motor will turn right as I push on one button, turn left as I push on the other button and stops as I push on two buttons.
I’m a nooby in this, so I don’t understand much with writing to Arduino.
Thanks a lot!