RobotC Quadrature Encoders On XDrive? Autonomous


I am trying to find out how to program the quadrature encoders on my x-drive chassis for our autonomous but have not been able to find any resources. I was wondering if anyone had an example of such program.


I did a little searching and found this thread:

X-Drive with Encoders

Rotate your frame of reference. Treat the NE/SW as the X direction and the NW/SE as the Y direction. Use each encoder direction independently and count the ticks to go one way and the ticks to go the other way. Each will hone in on their target independently in your control loop.