Shop OBEX P1 Docs P2 Docs Learn Events
Gyro and degrees of rotation — Parallax Forums

Gyro and degrees of rotation

TGTG Posts: 36
edited 2006-11-28 21:01 in BASIC Stamp
I am looking at using a gyro to calculate degrees of rotation. The Analog Devices gyro gives a deg/sec output. I will need to integrate this to know degrees of rotation. Does the STAMP handle this?
Thanks in advance for the input
Toby

Comments

  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2006-11-28 18:34
    Toby,

    What's the part number of the gyro?

    -Phil
  • TGTG Posts: 36
    edited 2006-11-28 18:45
    Analog Devices ADXRS401
    It is a analog output. I would rather do a PVM gyro if you have any in mind.
    Thanks again
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2006-11-28 19:31
    That one uses a ball-grid-array package. Are you able to solder something like that? Also, you will need an A/D converter to get useful data to the Stamp.

    That said, in order to integrate output from such a device, you need to sample it at a constant rate, and frequently enough to account for the range of angular accelerations encountered by your system. Still, there will always be accumulated errors which you will have to find a way to calibrate out. Even the Mars rovers, which use rate gyros and wheel odometry for dead-reckoning navigation, need to obtain a sun sight periodically to correct for accumulated errors.

    Sampling anything at a fixed, constant, rapid rate can be a challenge with the Stamp -- especially if it's also engaged in other activities. It might be better to assign the sampling and integration tasks to a small micro with an A/D converter, which the Stamp can poll at its convenience. Parallax's BASIC Stamp 2pe Motherboard (the MoBoStamp-pe, p/n 28300), includes a couple AVR (ATTiny13) micros as coprocessors. These have 10-bit A/Ds built-in and can operate independently of the Stamp. However, you will have to determine if 10 bits of resolution is adequate for your app. Also, these micros run with an internal 9.6MHz RC clock, whose frequency is somewhat temperature dependent. To get a guaranteed constant sampling rate, you would have to provide the AVR with a constant-frequency clock from an external source.

    -Phil
  • Paul BakerPaul Baker Posts: 6,351
    edited 2006-11-28 21:01
    Sparkfun has premounted boards: http://www.sparkfun.com/commerce/product_info.php?products_id=394·No reflow nessesary.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Paul Baker
    Propeller Applications Engineer

    Parallax, Inc.
Sign In or Register to comment.