One of my pet projects is building a robot car, yes I'm that original 😉. For this, I bought a motor shield from SeeedStudio which makes the Pulse-Width Modulation, PWM, very simple: You connect three cables to the oulets in the shield, program your Arduino sketch (no more than 5 lines) and use the SeeedStudio's library and you will get your motor working. Just that easy!
However, I faced one problem that I was able to manage. In the library, the specified pins are
- Motor A: 8, 11, 9. Pin 9 is used as PWM.
- Motor B: 12, 13, 10. Pin 10 is used as PWM.
- Motor A: 5, 6, 9. Pin 9 is used as PWM.
- Motor B: 7, 8, 10. Pin 10 is used as PWM.