Shop OBEX P1 Docs P2 Docs Learn Events
troubles with altimeter MS5607 #29124 — Parallax Forums

troubles with altimeter MS5607 #29124

nomadnomad Posts: 276
edited 2012-08-02 22:05 in Accessories
hi
today i make first tests with the altimeter

1) Luckily, i have a PropellerDemoBoard here
i connected the device as per 29124_altimeter.spin object
its running but i think the output is verry wrong
on pst: altitude: -2086.08 m
-6844.09 ft

i living in winterthur near zurich in switzerland
and i think the altitude should be around 450 m

what going wrong ?

2) on the 29124_altimeter.spin object i can see
only that altimeter working on propeller-demo-board
and other boards
see: default Module setting:

it's possible to work with the altimeter on
- PPDB (propellerProfessionalDemoBoard)
or
with the propellerProtoBoard or
the new C3
- it's possible that, on ppb:
- 29124 pin gnd -> bdb:VSS -> my ppb: gnd
vin -> P7 P7 or +3.3V
ps -> P6 -
SCL -> P5 P5
SDA -> P4 P4
SDO -> P3 -
CS -> P2 -

have somebody ideas for this ??


i am working on a quadcopter with the ppb or C3-
and cant working with the demoboard

thanks for hints and help
regards nomad

Comments

  • TymkrsTymkrs Posts: 539
    edited 2012-06-27 18:19
    I don't know your main code that you're working with that's calling the OBJ, but in your main code, did you set the START_ALT as your starting altitude? Here's how I got mine working:

    http://tymkrs.tumblr.com/post/21916124555/parallax-altimeter-module-29124-rev-a-ms5607-part-1-2
    http://tymkrs.tumblr.com/post/21982704463/parallax-altimeter-module-29124-rev-a-ms5607-part-2-2

    And I believe you can set the pins to whatever you want in the OBJ file.
  • nomadnomad Posts: 276
    edited 2012-06-28 00:48
    hi Tymkrs,
    thanks for your answer.
    i work with the 29124_simple_altimeter_demo.spin
    my Start_Alt := 200

    today i am testing your code....
    thanks for the hints on tymksr.tumblr.com
    regards nomad
  • TymkrsTymkrs Posts: 539
    edited 2012-06-28 00:57
    nomad wrote: »
    hi Tymkrs,
    thanks for your answer.
    i work with the 29124_simple_altimeter_demo.spin
    my Start_Alt := 200

    today i am testing your code....
    thanks for the hints on tymksr.tumblr.com
    regards nomad

    Good luck - let me know if it works or if there's anything on there I haven't addressed!
  • nomadnomad Posts: 276
    edited 2012-06-29 00:24
    hi Tymkrs,
    thanks for your reply.
    yesterday i have testing the stuff with your code with PropellerProfessionalDemoBoard.
    Pins are: SDA: P4
    SCL: P6
    Results:
    altitude: -2086.08m
    -6844.o9ft
    Barometric Pressure: 7864.43 mb
    232.24 in
    Temperature: 20.01° C
    68.01° F

    START_ALT := 1317

    i dont know what i should done??
    ev. is the chip defect, i dont now

    thanks for hints and tips
    regards nomad
  • TymkrsTymkrs Posts: 539
    edited 2012-06-29 01:34
    Hmm. I seem to remember having those same measurements for Altitude when I FIRST used the demo code. (ie 2086 and 6844). That's why I wanted to write my own code, because I knew that wasn't correct! And I just wanted to confirm that for the OBJ (in your proptool library), you have 29129_Altimeter.spin and for the main code you just copy pasted what's here: http://pastebin.com/7XwDtLW5

    I don't think, however, that it's a chip defect since your temperature looks pretty reasonable.

    Oh and try setting your starting altitude closer to your actual starting altitude.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2012-06-29 08:34
    The object, 29124_altimeter is designed for use with both the 5607 and 5611 sensors, which use different math formulae for computing altitude. You have to specify which sensor to use when calling start. So, if your call to start looks something like this:
    alt.start(alt#QUICKSTART | [b]alt#MS5611[/b], alt#BACKGROUND)
    

    change it to this:
    alt.start(alt#QUICKSTART | [b]alt#MS5607[/b], alt#BACKGROUND)
    

    -Phil
  • nomadnomad Posts: 276
    edited 2012-06-30 00:34
    hi tymkrs:
    thanks for your answer:
    i confirm i taken this with OBJ 29129_Altimeter.spin
    i set Start_Alt: 1_387 ft (423meter) to 1 meter = 3.2808399 feet (3 feet 3⅜ inches)

    on the weekend i test this with your pastebin-code with the changing of source from phil (look next post)
    after test i make a reply
    thanks for help
    regards nomad
  • nomadnomad Posts: 276
    edited 2012-06-30 00:34
    hi phil,
    thanks for your answer and your help:
    on the weekend i test this and make reply
    regards nomad
  • nomadnomad Posts: 276
    edited 2012-07-01 00:18
    hi,
    @ tymkr, @phil,

    on sunday morning i make some Tests:
    i have make the changes as per your postings:
    - testing with C3 :
    - Pin gem. 29124_altimeter.spin -> (PropDemoBoard)
    - Pins P4 = SDA (black)
    P5 = SCL (red)

    - 1.OnlineTest:
    pst.output: - with alti-1.spin -> -2086.08m
    - with alti-2.spin -> -2086.08m, -6844.09 ft
    Temperature are the same as my early postings.

    its possible that i working with wrong pins???
    Now :-(

    as per attachment i posting the alti-1.spin and alti-2.spin
    thanks for help and tip hints and tricks
    regards nomad
  • TymkrsTymkrs Posts: 539
    edited 2012-08-02 18:55
    Hey nomad,

    I just tested my code and though it should be working, I too got the -2086 and -6844 results. So I'm going to try and see whether or not it's my code. (Most likely is).
  • TymkrsTymkrs Posts: 539
    edited 2012-08-02 19:26
    Oh gosh nomad. I realized I'm pretty dumb most of the time.but MAKE SURE you're not plugging in the gyroscope module. I had the gyroscope module plugged in and it gave me those EXACT numbers no matter what I did. But as soon as I plugged in the altimeter module (white chip on the top), it worked. *facepalm* Let me know if that was the case for you?
  • nomadnomad Posts: 276
    edited 2012-08-02 22:05
    hi tymkrs,
    thanks for your answer
    in the moment i dont use the altimeter
    i am working on a quadcopter,,
    and i must use the L3G4200D 3Axes-Gyroscope , its essential for the whole stuff.
    but i have my GPS-System and on the GPS-System i have a correct Altitude.
    thanks for your help
    regards nomad
Sign In or Register to comment.