Go to Post The greatest lesson we can teach our kids is how to win. - AdamHeard [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 08-03-2006, 21:55
hello1990ab hello1990ab is offline
Registered User
no team
 
Join Date: Mar 2006
Location: MA
Posts: 4
hello1990ab is an unknown quantity at this point
Accelerometer Readings

I'm a rookie this year and playing with my teams accelerometer since we didnt use this year on the robot.

The IFI Site says that it returns 290 milivolts per g when supplied with 5volts (what I think the RC has).



How do the RC values 0-1023 reflect the g changes?
Also, when it says 2g, is that the same as 19.6 m/s^2?


THANK YOU!

Last edited by Joe Johnson : 09-03-2006 at 12:18.
  #2   Spotlight this post!  
Unread 08-03-2006, 22:11
DonRotolo's Avatar
DonRotolo DonRotolo is offline
Back to humble
FRC #0832
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Atlanta GA
Posts: 7,011
DonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond repute
Re: Aaccelerometer Readings

Quote:
Originally Posted by hello1990ab
I'm a rookie this year and playing with my teams accelerometer since we didnt use this year on the robot.

The IFI Site says that it returns 290 milivolts per g when supplied with 5volts (what I think the RC has).

How do the RC values 0-1023 reflect the g changes?
Also, when it says 2g, is that the same as 19.6 m/s^2?
First of all, it's great that you are playing with the accelerometer, that's the best way to learn!

The RC measures between 0 and 5 volts at the Analog Inputs, returning values between 0 and 1023 (10 bits). So, a voltage of 2.5 volts would return 512. There is some tolerance there, plus or minus a few percent.

Also, the RC does have a +5v output, at the digital input pins.

Yes, 2g is the same as twice the acceleration due to gravity at sea level, or about 19.6 m/sec^2.

Please review the specifications and data sheet carefully, and remember the range is +/- 2g, so the bias voltage (a constant voltage when the device is measuring 0 g) is about 1/2 the supply voltage, or perhaps 2.5 volts. That means, you'll measure 2.5 volts (512 on the RC) when both axes are perpendicular to the earth's gravity vector.

Luckily, you have a calibrated gravity field - point the sensor down to measure 1 g, up to measure -1 g, on both axes. Calibrate your RC that way, for + and - 1g in both the X and Y axes.

Good luck

Don
__________________

I am N2IRZ - What's your callsign?
  #3   Spotlight this post!  
Unread 09-03-2006, 11:14
hello1990ab hello1990ab is offline
Registered User
no team
 
Join Date: Mar 2006
Location: MA
Posts: 4
hello1990ab is an unknown quantity at this point
Re: Aaccelerometer Readings

Thanks for such a great reply, it really helps.

I was just hoping you could expand one thing:
Quote:
Originally Posted by Don Rotolo
The RC measures between 0 and 5 volts at the Analog Inputs, returning values between 0 and 1023 (10 bits). So, a voltage of 2.5 volts would return 512. There is some tolerance there, plus or minus a few percent.
Why is this? I understand why "no" acceleration would register at 2.5v which in turn would be somewhere near 512 depending on the bias. So then if that's 2500 mV = 512, then wouldn't 2g at 3080 mV = 631?

What if I was working with a different sensor that returned 350 mV / unit (random number don't know if it exists), would I still be dealing with the full range of 0-1023 or would I have to figure something out like I just did above?



Thanks
  #4   Spotlight this post!  
Unread 12-03-2006, 20:35
bush's Avatar
bush bush is offline
Registered User
AKA: Aaron
FRC #0710 (Pine Crest School)
Team Role: Programmer
 
Join Date: Jan 2006
Rookie Year: 2005
Location: Fort Lauderdale, Florida
Posts: 42
bush has a spectacular aura aboutbush has a spectacular aura about
Send a message via AIM to bush
Re: Accelerometer Readings

I'll bump this because I am also interested in a descriptive answer to the above question.
  #5   Spotlight this post!  
Unread 04-04-2006, 02:00
BillyJ BillyJ is offline
Registered User
no team
 
Join Date: Feb 2005
Rookie Year: 2003
Location: Texas
Posts: 13
BillyJ is an unknown quantity at this point
Re: Accelerometer Readings

I hate to bump threads but I just got an accelerometer and had similar questions.
  #6   Spotlight this post!  
Unread 04-04-2006, 11:00
Mike Bortfeldt Mike Bortfeldt is offline
Registered User
FRC #1126 (& 1511)
Team Role: Mentor
 
Join Date: Oct 2004
Rookie Year: 2004
Location: Rochester, NY
Posts: 119
Mike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud of
Re: Accelerometer Readings

The answer to your questions are in the data sheet on the web page that Don pointed you to. The typical supply voltage to this part is 3V however it can be operated at any voltage from 2.4 to 5.25 volts. At a 3 volt supply, the sensitivity is around 174 mv/g, however when the supply is bumped up to 5 volts, the sensitivity increases to 290 mv/g as indicated in the IFI document. Manufacturing variances cause each part to be slightly different from each other. However, the specifications indicate that at a 3 volt supply, the center (0 g) value will be between 1.2 volts and 1.8 volts - basically +- 20% of the center voltage. Assuming this holds true at a 5 volt supply, the 0 g value would be between 2.0 volts and 3.0 volts which gives you quite a big potential range for analog values for 0g. Typically, the parts will be very near 2.5 volts, but the specifications indicate that it is possible for them to vary significantly, but will never be outside the specified maximum and minimum values. Also the specification indicates that there could be up to a +-15% variation in sensitivity from part to part. So one part may be as low as 247 mv/g to as high as 333 mv/g. A perfect part would give you 3080 mv or an analog value of 631, but all parts are not perfect. Thus the suggestion by Don to calibrate the accelerometer by using gravity.

Mike
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Accelerometer Timer Question psquared Programming 3 12-02-2005 01:34
URGENT! We need help with the accelerometer lkdjm Electrical 5 11-02-2005 16:42
Accelerometer Wiring/Input DAN THE MAN Control System 1 06-02-2005 20:02
Accelerometer vs Gear Tooth Sensors zdeswarte Electrical 4 22-01-2005 15:35
Example accelerometer code released. Kevin Watson Programming 0 20-01-2005 03:45


All times are GMT -5. The time now is 23:01.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi