Shop OBEX P1 Docs P2 Docs Learn Events
Accelerometer — Parallax Forums

Accelerometer

Mike15Mike15 Posts: 109
edited 2006-08-03 00:11 in Learn with BlocklyProp
· I am trying to use the Analog Devices AD7706 accelerometer to give me the altitude of a rocket.

·I know I have to use an ADC but I am not sure how to wire the AD7706.

·The rest of the circut I have figured out.· I have a pair of Cds cells opposite of each other to give me the roll rate.· All of this information is stored in an external EEPROM.

·If anyone could let me know how·I should·wire this it would be great.

·Mike

Comments

  • Ken GraceyKen Gracey Posts: 7,392
    edited 2006-02-01 21:21
    Mike,

    This sounds difficult to me. Relating acceleration to distance of travel and matching periods of zero acceleration to distance could also be pretty difficult. I wonder about using a barometric altimeter sensor. But I'd sure like to learn how this could be done with an accelerometer. When a rocket is travelling at a consistent velocity, there is no acceleration (right?) so how will you know if you are going 1 m/s or 5 m/s? Using the g-force vector instead? I assume you are using a high-g accelerometer, and not the Memsic 2125.

    Reason I'm interested is that I'm supporting one customer who is authoriing a model rocketry / electronic sensor book for McGraw Hill.

    I'll follow this thread closely. Tell me more!

    Ken Gracey
    Parallax, Inc.

    Post Edited (Ken Gracey (Parallax)) : 2/1/2006 9:28:34 PM GMT
  • Paul BakerPaul Baker Posts: 6,351
    edited 2006-02-01 21:32
    Here's a link you may find useful: http://www.geocities.com/SiliconValley/Orchard/6633/altimeter.html

    With respect to your confusion on the AD7706, are you confused about the connection to the stamp, or the connection to the sensor?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·1+1=10

    Post Edited (Paul Baker) : 2/1/2006 9:40:19 PM GMT
  • Ken GraceyKen Gracey Posts: 7,392
    edited 2006-02-01 21:59
    Mike,

    One project we did at Parallax is to mount a BASIC Stamp/accelerometer on top of one of those RadioShack X-Mod R/C cars. We stored the X/Y acceleration data in the BASIC Stamp EEPROM and ran the car around the office. We pasted the data from DEBUG into Excel and made some really neat graphs showing the different forces experienced by the imaginary driver. I think accelerometers are neat no matter what you're doing with them. I'd like to see the same data collected from a rocket flight, especially considering it would probably show rocket rolls.

    By the way, since we're on the subject of accelerometers I should let you know that Parallax is about to release a 3-axis <3g accelerometer module (based on a Hitachi MEMS sensor).

    Ken Gracey
    Parallax, Inc.
  • John R.John R. Posts: 1,376
    edited 2006-02-01 22:31
    In a concept only, with an accelerometer and RTC (Real Time Clock), you should be able to calculate altitude.

    Basically, you know you start at rest. Then you can calc speed based on accelleration time, and from there distance. When accelleration is zero, you know you have constant speed from where you left off.

    This isn't too bad to calculate if you go straight up, and straight down. In my limited experience, this isn't normally the path model rockets take smile.gif

    Looking at Ryan's R/C car example, he should be able to take the data (assuming some type of real time recording) and not only plot the g's, but also be able to map out the path the car took. Not simple, probably not something that the STAMP could do "on board", but doable. I vaguely remember doing this in Physics class, long ago, and far away (with a caculator, pencil and paper).

    Adding the third dimension (4 if you count roll) would make things really "interesting". This is the type of stuff that gives the phrase "Rocket Scientist" its meaning. Keep in mind most of this was done with slide rules to get to the moon and back, so we should be able to do it too, given the computing power we have at our disposal.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    John R.

    8 + 8 = 10
  • edited 2006-02-01 23:11
    Yeah, I remember that from first semester physics too (finding position given initial position and velocity).· It was a fun experiment.· It would take two more columns in the spreadsheet that generated Figure 6-2 in the attached manuscript excerpt to plot velocity and position.· What do you think about adding that to the Projects section at the end of the chatper?

    Post Edited (Andy Lindsay (Parallax)) : 2/1/2006 11:28:12 PM GMT
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2006-02-01 23:29
    Heck, I'd love to see that! Being a fan of racing, I've seen a system called "Pi" that is used in high performance cars (e.g., Indy and F1 cars) that plots track position based on measured speed and measured g-forces. I always wanted to build something like that for my go-kart. Sadly, I sold the go-kart.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
  • John R.John R. Posts: 1,376
    edited 2006-02-01 23:34
    It would certainly make sense, and show another aspect of what an accelerometer can be used for.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    John R.

    8 + 8 = 10
  • edited 2006-02-02 01:08
    Oh, man that is just too fun!· I did, in fact, drive the car forward about three and a half meters.· Then, I backed up and slightly overshoot where I started.·I'll try plotting in 2-d next.· I'm pretty sure I can reconstruct a figure-eight, but not until I dig the car back up and put the board on it.· I'll probably post the supplementary activity this weekend.


    Post Edited (Andy Lindsay (Parallax)) : 2/2/2006 1:37:45 AM GMT
  • bubbleheadbubblehead Posts: 36
    edited 2006-02-02 05:58
    A trick to know when to start logging the acceleration data is to use a conductive ink pen to run trackes down to the bottom of the fins where they rest on the metal launch pad to complete a circuit. The CPU loops checking the continuity of the circuit. When the rocket begins to leave the launch pad the circuit opens. The CPU detects this and begins logging the various sensors.

    If the rocket has multiple stages, then the same kind of trick can be used to sense the stage separations.

    You can detect parachute deployment and fill fromthe accelerometer data.

    Another sensor I've seen in model rocket telemetry units is a photosensor that looks out the side of the rocket. As the rocket spins, the sensor alternately faces toward and away from the sun, so the sensor can be used to measure spin rate.
  • Mike15Mike15 Posts: 109
    edited 2006-02-02 08:04
    Yes it is true a barometric altimeter would be more accurate but it has to be "exposed" wich means port holes and turbulance.
    The accelerometer isn't as accurate because even if the thrust doesn’t go totally into vertical movement, then neither does the pull of gravity subtract totally from forward motion. This means that as the rocket arcs over, the accelerometer will calculate 0 for airspeed at the top of the arc, even though the rocket doesn’t stop. This does mean the calculated altitude is incorrect (short) though. So obviously, the accelerometer isn’t the best way to determine altitude, but still a way.
    The advantages are that other aspects of flight are recorded also. Liftoff, engine burnout and apogee. At liftoff there will be an increase in acceleration that will closely follow the engines thrust curve. When the measured acceleration goes from positive to negative, burn out has occurred. This is usefull when stagging motors for the ignition of the second motor. Apogee(highest point of flight) can be detected when velocity goes from positive to negitive. This information can be used to trigger the recovery system.
    The goal here is not just to record data but have a system that can react accordingly to different aspects of the flight.
  • Mike15Mike15 Posts: 109
    edited 2006-02-02 08:17
    I already use the Cds cell circut for roll rate. I have two Cds cells facing opposite eachother. When plotted in Excell the two cells form peaks opposite each other.
    I have also seen the Cds cells used to "seek" the sun with the aid of moveable fins.
    Another use would be to use the Cds cells to eliminate roll for better video from an onboard cammera.
  • Bruce BatesBruce Bates Posts: 3,045
    edited 2006-02-02 09:25
    Mike15 -

    Excuse me for butting in here, but I do find this somewhat humorous from a purely mathermatical point of view. You seem to want to trust velocity like the Holy Grail, but don't trust acceleration as though it weren't worth a dose of salt.

    Please keep in mind that the first derivative of position is velocity, and the second derivative is acceleration. If you trust one, you can surely trust the other! Accelerometers can measure either or both, and tilt as well, given a functioning set of accelerometers, the proper alignment, and an appropriate working set of equations. In fact, most accelerometer data sheets will show you how to do all that and more.

    Regards,

    Bruce Bates

    Post Edited (Bruce Bates) : 2/2/2006 9:43:03 AM GMT
  • Mike15Mike15 Posts: 109
    edited 2006-02-02 10:37
    I geuss I don't totally understand what you mean.

    I know Velocity = change of position and Acceleration = change of velocity.

    Where did I trust one over the other?
  • Bruce BatesBruce Bates Posts: 3,045
    edited 2006-02-02 11:55
    Mike -

    I suppose it was an extrapolation of what you said below, but upon re-reading it, that's not quite what you were proposing:

    quote

    The accelerometer isn't as accurate because even if the thrust doesn't go totally into vertical movement, then neither does the pull of gravity subtract totally from forward motion. This means that as the rocket arcs over, the accelerometer will calculate 0 for airspeed at the top of the arc, even though the rocket doesn't stop.

    end quote

    Sorrry if I misread your intent there.

    Perhaps a better way to interpret that is that when the arc over occurs, the acceleration goes from positive to zero to negative, and the velocity remains reasonably unchanged, over that arc over period.

    My own point was merely that speed, velocity and acceleration are all inexorably interrelated, due to their mathematical relationships, and any one is just a valid as the others, for a given set of motion related circumstances.

    Regards,

    Bruce Bates

    Post Edited (Bruce Bates) : 2/2/2006 2:01:21 PM GMT
  • John R.John R. Posts: 1,376
    edited 2006-02-02 12:16
    As further clarification for Mike, this wouldn't work with just one axis to measure acceleration. You would need the measure all three axis for this to work.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    John R.

    8 + 8 = 10
  • knucklesknuckles Posts: 1
    edited 2006-08-01 22:10
    Actually a much more accurate (and simple) way to calculate altitude is by using a PRESSURE SENSOR. As you go higher into the atmosphere, the pressure decreases and you can establish a very linear relationship between height and pressure without worrying about time at all.

    Hope this helps.
  • JavaPaulJavaPaul Posts: 9
    edited 2006-08-03 00:11
    I agree with Ken Gracey, Paul Baker and Knuckles that a pressure sensor is the right way to go.

    But altitude as a function of pressure is NOT a linear relationship, as pointed out in Paul Baker's post and link:

    http://www.geocities.com/SiliconValley/Orchard/6633/altimeter.html

    As that article points out,

    Altitude = (10^(log(P/P_0)/5.2558797)-1)/-6.8755856*10^-6.

    I'm using a Freescale MPX4115A Precision Temperature Compensated Pressure Sensor ($15 Digikey) connected to a Javelin Stamp to measure and compute altitude for my quad prop helicopter. I'm also using the Memsic 2125 Dual-axis Accelerometer ($29 @ Parallax) to measure tilt, and the Analog Devices ADXRS15 Angular Rate Sensor ($50) as a yaw sensor. Everything is not entirely integrated, but I'll let you know the performance once things are running.

    ----
    Paul
Sign In or Register to comment.