FAQ and Troubleshooting - iangohy/SUTDoggo GitHub Wiki
FAQ
Some questions and answers adapted from Stanford Doggo README FAQ.
How are the legs numbered?
Leg0 is the front left, leg1 is the back left, leg2 is the back right, and leg3 is the front right.
How do I calibrate the legs?
This is a sore spot for the robot right now. When you power on the robot, all the driven linkages (ie top links) need to be as horizontal as possible. If everything is set up correctly, the motors will then begin their calibration routine which involves them rotating about 120 degrees to one side and then back. After this, the robot is ready.
Can it turn?
Yes and no. It turns very slowly with the 'Y' command. The turning speed is set by 's [desired step difference]' where the step difference should be around -0.1 to 0.1 at the most.
Which way should the IMU point?
There are little markings on the BNO080 board which indicate which way x is positive. Align that direction with the forward direction of the robot. The forward direction is towards the motors connected to ODrives 0 and 3.
Troubleshooting
ODrive
- Install
odrivetool
by following this guide. - If the ODrive is not connecting, try changing the power source. A dim light on the ODrive indicates insufficient power.
- Always calibrate when the ODrive is first started.
odrv0.axis0.requested_state = AXIS_STATE_FULL_CALIBRATION_SEQUENCE
- Set recommended P gain.
drv0.axis0.controller.config.pos_gain = 0.05
- Enable closed loop control as manual control is only enabled when closed loop control is enabled.
odrv0.axis0.requested_state = AXIS_STATE_CLOSED_LOOP_CONTROL
- Try moving the motor.
odrv0.axis0.controller.pos_setpoint = 1000