Author: Yael Ben Shalom
Final project, MS in Robotics at Northwestern, 2021.
To control the motor, I used a 2 layer control system - feedback current and position control. The current was controlled by the ODrive's controller, and the position was controlled by a feedback PID controller (with an optional feedforward component).
The control system diagram:
The PID position control diagram:
An example of motor position control using the PID controller. The blue plot is the input angles, the red plot is the controlled output angles, and the second graph is the error changing with time: