I’m a new user of Arduino and for my project I have to build a robot car, and control the motors with an arduino (Due) with a motor shield (Adafruit v2).
Right now, the arduino is powered by USB, and the motor shield is powered by 5 AA battery. I have changed the logic jumper from 5V to 3.3V as they said on the motor shield pdf.
I have made a really simple code which change the speed of the wheels.
The motors turn at the right speed, but after a random times, the motors turn at a constant speed and they don’t follow the program anymore.
Does anyone have a suggestion of what is the problem?
MotorTest.ino (1.89 KB)