Build a Real Robot – Episode 11 – Motor Coding
In todays episode of the Build a Real Robot Series I will give you an update on the code for the motor controller.
Article coming soon! Full series at https://dronebotworkshop.com/build-a-real-robot/
Just a brief update today.
The code for the motor controller is still in development, and as I program it I’m also writing some test routines to exercise the controller and the motors.
Right now the controller runs a test routine that runs a sequence:
Move the motors at a speed of 200 for a couple of seconds.
Reverses and moves again at the same speed.
Stops for two seconds.
Accelerates forward to a speed of 255
Runs for four seconds and then decelerates to zero
Waits fours seconds
Repeats the acceleration and deceleration, but in reverse
Stops
I’ll go over some of the code today, specifically the code that does the acceleration and deceleration and also the code that determines the specific I2C address used by the Arduino Nano.
I’ll also go over some of the considerations you need to pay attention to when connecting a USB cable to the Nano while the robot is powered up.
source