stanfordroboticsclub / StanfordQuadruped

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

IMU use / not use

SteveMacenski opened this issue · comments

Hi,

I see IMU code in here but you mentioned you didn't seem to think it helped much. Can you detail that here (publicly for others in the future)? It seems as pupper and derivatives of work of it, an IMU would be necessary for feedback on achieving target poses in the absence of other external sensing. Maybe also for future work in stabilization.

If you enable the IMU, the controller will gimbal the legs in space to cancel out the body's orientation. Imagine how a chicken stabilizes it's head as you move the body around, except here, replace the chicken head with the robot feet. In other words, if you pick up the robot and tilt it around, the robot feet will still be walking on the horizontal plane.

The goal with this method was to make the robot always put the feet down perfectly on the ground, even if the body was rotated. However, the downside is that there was essentially no restoring force on the body to bring it back to level, it would just stay tilted and walk tilted. We didn't really like this behavior, even though it walked a little bit better with this method, so we have the IMU turned off by default.

This is as of commit 8a71:

(roll, pitch, yaw) = quat2euler(state.quat_orientation)