Digital Gyroscopes

26
Digital Gyroscopes Brian Margosian Connor Donker Nick Tountasakis Tuesday, November 5th, 2013 https://learn.sparkfun.com/tutorials/gyroscope

description

czzczc

Transcript of Digital Gyroscopes

  • Digital GyroscopesBrian Margosian Connor Donker

    Nick Tountasakis

    Tuesday, November 5th, 2013

    https://learn.sparkfun.com/tutorials/gyroscope

  • Agenda

    What is a gyroscope? Why are they useful? Project usage Error compensation Types of gyroscopes / interfacing Question / Answer

    1

  • What is a Gyroscope?

    Device used to measure rotational velocity

    https://learn.sparkfun.com/tutorials/accelerometer-basics/all

    2

  • Mechanical Gyro Spinning wheel with fixed axle

    Mounted in 2 or 3 gimbals to allow rotation

    Resists external torque

    http://en.wikipedia.org/wiki/File:Gyroscope_operation.gifDetailed explanation of the physics involved in a mechanical gyroscope can be found at.. http://www.real-world-physics-problems.com/gyroscope-physics.html

    3

  • MEMS Gyro

    Small oscillating mass http://sensorwiki.org/doku.php/sensors/gyroscope

    Low-current electric signals produced

    One mass per axis

    Utilize Coriolis force

    4http://electroiq.com/blog/2010/11/introduction-to-mems-gyroscopes/

  • MEMS Gyro Cont.

    5

    http://sensorwiki.org/doku.php/sensors/gyroscope

  • Why are they useful?

    Measure angular velocity Projects

    Aviation Stability control Image on spinning disc Motion detection

    6

    http://www.eecs.umich.edu

  • Sources of ErrorGyro Drift:

    Defined as gyro at resting state producing non-zero values

    Drift seen at all rotational velocities, on all axes

    Caused by heating up of gyroscope during operation

    Unsteady input power source voltages contributes

    7

  • Visualization of Gyro Drift

    http://nxttime.wordpress.com/category/sensors/gyro-sensor/

    8

  • How to CompensateMultiple Options:

    More expensive (+$5 - $10) premium on-chip temperature compensation

    Wait until sensor reaches maximum temperature, calculate offset Drift not exactly constant, high accuracy requires moving

    average calculation

    Run gyroscope off of quality power supply Can get by with batteries and voltage regulator

    9

  • Gyros vs. Accelerometers

    GyroscopesRotational motion

    AccelerometersLinear motion

    10

    https://learn.sparkfun.com/tutorials/accelerometer-basics/all https://learn.sparkfun.com/tutorials/accelerometer-basics/all

  • Gyros vs. Accelerometers cont.Gyros: Integrate rotational velocity to determine angular displacement Susceptible to gyro drift More resistant to external noise than accelerometers

    Accelerometers: Integrate linear acceleration to determine linear displacement Measures linear motion with inertial resistive forces Must continually compensate for gravity

    IMU (Inertial Measurement Unit) - combination plus magnetometer

    Detailed explanation how to combine data to determine full orientation:http://www.instructables.com/id/Accelerometer-Gyro-Tutorial/#step1

    11

  • So you want to add a gyroscope?

    Range Interface Number of axes Power Bonus features

    Interrupts Temperature sensing Internal LPF

    https://www.sparkfun.com/products/9446

    12

  • Device comparisonDevice Range Interface Price Axes Power Bonus Features

    LPY503AL 30/s (4x output) or 120/s

    Analog $30 2 2.7-3.6V6.8mA or1-5uA

    Self-test, power-down, 1x and 4x outputs

    L3G4200D 250/s, 500/s or 2000/s

    SPI and I2C

    $50 3 2.4-3.6V6.1mA or5uA

    Power-down and sleep mode, temperature sensor, High shock survivability

    ITG-3200 2000/s I2C $20 3 2.1-3.6V6.5mA or5uA

    Programmable low pass filter, optional external clock input for better clock accuracy, 1 interrupt output, temperature sensor

    Images and data courtsey of sparkfun.com 13

  • Analog Interfacing

    Analog Gyro

    Z axis ADC

    X axis ADC

    Y axis ADC Microcontroller

    Pros:CheaperEasier to interpret dataPrecision

    Cons:More partsMore pin usage (dependant on ADCs)Often higher power

    14

  • Digital Interfacing

    Digital Gyro Microcontroller

    Pros:Smaller packageLess power use (fewer running components)Fewer pins

    Cons:Often marginally more expensiveCan be harder to interface

    X axis ADCY axis ADCZ axis ADC

    15

  • Sample I2C Transaction

    16

    X data Y data Z data

    0x28

    0x2A 0x2B 0x2C 0x2D0x290x28L L LH H H

  • Sample I2C Transaction

    16

    X data Y data Z data

    0x28

    0x2A 0x2B 0x2C 0x2D0x290x28L L LH H H

  • Sample I2C Transaction

    16

    X data Y data Z data

    0x28

    0x2A 0x2B 0x2C 0x2D0x290x28L L LH H H

  • Sample I2C Transaction

    16

    X data Y data Z data

    0x28

    0x2A 0x2B 0x2C 0x2D0x290x28L L LH H H

  • Sample I2C Transaction

    16

    X data Y data Z data

    0x28

    0x2A 0x2B 0x2C 0x2D0x290x28L L LH H H

  • Sample I2C Transaction

    16

    X data Y data Z data

    0x28

    0x2A 0x2B 0x2C 0x2D0x290x28L L LH H H

  • IMUs

    http://www.pololu.com/product/1268/

    Gyro, accelerometer, magnetometer on board

    Always digital Degrees of freedom Some come with onboard

    processors Can be pricey ($50-$125)

    17

  • Summary

    Gyroscope basics What is a gyro? Mechanical vs MEMS

    Uses of Gyroscopes in projects Gyro drawbacks

    Gyro drift Compensation

    Interfacing Analog Digital

    18Image from: http://www.eeherald.com/section/design-guide/mems_application.html

  • But wait, theres more! (References)High-level gyro usage/description:https://learn.sparkfun.com/tutorials/gyroscope

    Low-level description of MEMS Gyro:http://en.wikipedia.org/wiki/Vibrating_structure_gyroscope#MEMS_gyroscope

    Explanation of gyro drift and how to compensate:http://nxttime.wordpress.com/category/sensors/gyro-sensor/

    Detailed explanation how to combine data to determine full orientation:http://www.instructables.com/id/Accelerometer-Gyro-Tutorial/#step1

    19

  • Digital GyroscopesBrian Margosian Connor Donker

    Nick Tountasakis

    Tuseday, November 5th, 2013

    https://learn.sparkfun.com/tutorials/gyroscope