Maybe that's not the right term. I have built a tricycle with steering on both ends, connected to a single motor. It is driven by the front wheel. How do I consistantly return the front wheel (and therefore the back ones) to"straight?"
Mike
best:
drive motor to left max until a certain touch sensor is hit.
in that moment stop motor and set encoder to -45 or what ever.
(This is how my chess robot is doing more or less - good if torque is strong)
next best:
drive motor slowly to left max and wait enough time to be sure that it finally will have reached the outmost left max. (motor will be stalling!!).
then stop motor and set encoder to -45 or what ever.
(This is how Mindcuber is doing - sufficient for weak torque)
A vehicle like that may be different from doc's robots, because you may not want to drive to the end of travel to reset, and you may want to be able to keep resetting (to compensate for drift, while it's driving)
My suggestion would be to put a cam on the motor, and have it hit a touch sensor when the motor is centered. When it's first started, you may use doc's second method (drive to end at low power) to make sure it knows which direction the touch sensor (center) is. Then, drive until you reach the touch sensor.
Steve
---> Link to lots of MINDSTORMS stuff under my picture --->
To enhance that a slight gear reduction could help. If your steering has a total of 90 degrees of swing than using say a 2:1 ratio between the steering servo with touch sensor cam and the front wheel will give you more resolution and a more precise "center".
JimmyJam
"The more you know, the more you know, the less you know."