View Single Post
  #2   Spotlight this post!  
Unread 20-01-2015, 23:31
cjl2625's Avatar
cjl2625 cjl2625 is offline
apel py
AKA: Cory Lynch
FRC #2067 (Apple Pi)
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2013
Location: Guilford, CT
Posts: 412
cjl2625 is a splendid one to beholdcjl2625 is a splendid one to beholdcjl2625 is a splendid one to beholdcjl2625 is a splendid one to beholdcjl2625 is a splendid one to beholdcjl2625 is a splendid one to beholdcjl2625 is a splendid one to beholdcjl2625 is a splendid one to behold
Re: ANNOUNCING: navX MXP Robotics Navigation Sensor

Quote:
Originally Posted by bmammen View Post
We started playing with the example code tonight, trying to use the navX to Auto-Rotate to an angle but we're having an issue where no matter what values we use for PID, the bot rotates to the angle and constantly shakes back and forth trying to reach the exact angle.

I can post our code if that helps, we're using C++ and have a 4 motor/4 transmission tank drive configuration on our test chassis. Hoping someone might have some ideas for us. Thx.
I once had a similar problem with rotating swerve modules with PID.
The problem ended up being that the loop time was really long, like 300 ms.
Since it took so long to update, it repeatedly overshot the target and shook back and forth.
In my case, it turned out that this was being caused by an error, because I didn't configure something correctly in the drive encoders. So the code seemed to be quietly throwing errors which drastically slowed down the iteration time.
__________________
Head Programmer / Driver

Last edited by cjl2625 : 20-01-2015 at 23:37.
Reply With Quote