Quote:
Originally Posted by BitTwiddler
Nope. It will continue past 360 degrees on the second time around as the documentation you provided indicates.
|
You might find
this post and posts
1 and
36 in
this thread of interest.
Quote:
|
the gyro sees a leftward turn and reports a process variable toward 360 degrees ... I don't think I've seen the gyro vi report angles less than zero.
|
Given the rationale stated in the WPILib documentation, it's hard to imagine the gyro would report anything other than angles less than zero when that occurs.
The post and thread I linked above shows how to turn any angle into +/-180 degrees.
If you compute the angle error ( = target-gyro ) and feed that error into the computation, it will give you the setpoint you should use to go the shortest angle to get to your target (or just see below).
Quote:
Originally Posted by apm4242
Is it possible that this -180 to +180 feature is built into the gyro Get Angle vi?
|
I
think it is built into WPILib PID. See "set continuous".