View Single Post
  #17   Spotlight this post!  
Unread 28-01-2006, 21:31
yoyodyne yoyodyne is offline
Registered User
AKA: Greg Smith
FRC #0116 (Epsilon Delta)
Team Role: Engineer
 
Join Date: Jan 2006
Rookie Year: 2004
Location: Reston, VA
Posts: 61
yoyodyne is a splendid one to beholdyoyodyne is a splendid one to beholdyoyodyne is a splendid one to beholdyoyodyne is a splendid one to beholdyoyodyne is a splendid one to beholdyoyodyne is a splendid one to beholdyoyodyne is a splendid one to behold
Smile Re: Has anyone gotten useful data from the accelerometer?

Quote:
Originally Posted by Chriszuma
I was playing around with the accelerometer the other day, trying to use its sum to determine velocity. However, I fiddled with my algorithm for a couple of hours and couldn't get it to give me anything close to an accurate reading. Has anyone actually gotten this to work? I think they're just way too sensitive to use for tracking. I'll probably end up just using the gear tooth sensor to measure distance, which makes more sense anyway.
Maybe I need to upgrade to kevin watson's oversampling uart?
This is my frist Chief Delphi post! Hope this information helps someone.

I agree it can be difficult to get reasonable data from the accelerometer. We designed a little test where we mounted the 2006 Gyro and X,Y accelerometer (plan attached) to a roll around cart and recorded the outputs using the NI data logger we got. Our plan for navigation is basically to use the gyro to set a heading and then use shaft encoders or gear tooth counters to drive straight to the next point in the waypoint list, stop, turn and then go straight again so I didn’t really think we would actually use the accelerometers for navigation. I did think that they may come in handy to tell us if we have started up a corner goal ramp and I was curious what I could get out of them. Well, after the data was put in an excel spread sheet, it looks like using only the accelerometer that is in the direction of the robot heading and the gyro and a little trig you can navigate through a few waypoints, travel over 50feet with an X,Y error when you are done of about a foot. See attached spread sheet if you are curious. We will still count wheel rotations but at least for now our controls group will use the gyro and accelerometers for navigation.

The excel files list the raw readings for 5v, Gyro, Temperature, Acc X, Acc Y. The sample rate was slow, 100 s/s but that seems to be fast enough. The actual path and the estimated path using the gyro and accelerometer are shown for two test cases.

The spread sheets basically take the raw gyro and Y accelerometer outputs, remove bias, let you set different dead band widths and gains. The final output is the X,Y position of the robot for each time tick. The heading from the gyro is used to update the robot position every sample. That is probably too much processing for the real application but if you assume the robot drives straight from waypoint to waypoint then you can save processing cycles and only calculate the distance traveled in the heading direction from the last waypoint in order to know when to stop and turn. If you look at the data carefully, you will see that the Y accelerometer output is zeroed while the robot is turning (for question mark that is from 6.93 to 9.23 and 15.33 to 18.74 seconds) this can be done because while turning the robot only uses the feedback from the gyro for our application.


http://members.cox.net/gnsmith/Just%...e1_results.xls

http://members.cox.net/gnsmith/Just%...stion_mark.xls

http://members.cox.net/gnsmith/Team%..._test_plan.pdf

Last edited by yoyodyne : 28-01-2006 at 22:45. Reason: Add more information on the calculations