Shop OBEX P1 Docs P2 Docs Learn Events
HM55B Help — Parallax Forums

HM55B Help

souplogicsouplogic Posts: 8
edited 2009-01-12 23:08 in Propeller 1
I have the HM55B, It works with the propeller, but I don't know how to calibrate it.

I have calibrated in with the BS2, and copied the data. I see where there is a lookup table in the prop object I have (Beau Schwabe's), but I do not know how to translate from one to another.

I need to reconcile data between the compass and GPS coods, so I need accurate NSEW, though not necessarily precise thereafter.

please help ASAP

TIA

Adam

Post Edited (souplogic) : 5/2/2008 5:02:45 PM GMT

Comments

  • StefanL38StefanL38 Posts: 2,292
    edited 2008-05-02 09:58
    Hello Souplogic,

    first of all welcome to the forum.

    as i post this the viewcounter is on 70.

    70 views ands still no single reply

    in my opinion this has to reasons:

    1.) lack of information from you
    2.) you are "commanding" the members answer as soon as possible.

    I'm afraid if your project has to be finished tomorrow you had a very bad time-planning about
    unexpected problems.

    So now what is to do

    post your COMPLETE sourcecode of the working basicstamp example

    post your COMPLETE sourcecode of the propeller-example and your propellersourcecode

    post DETAILED information (datasheets electronical circuits etc.) about the HM55B and all other hardware that you are using

    if you do not serve these informations easily by attaching it to a posting the forum-members are forced to search for these information before they can even START
    THINKING about your problem.

    best regards

    Stefan
  • Beau SchwabeBeau Schwabe Posts: 6,562
    edited 2008-05-02 16:01
    souplogic,

    The Propeller compass demonstration object only provides raw X and Y values as well as the Angle derived from a coordic expression using the X and Y raw values.

    I don't have the resources at the moment to add a calibration routine to this object, but by looking at the existing documentation for the BS2 you should be able to derive the correct calibration procedure that you need.· I'll see if I can look into something in the way of calibration this weekend.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • inserviinservi Posts: 113
    edited 2008-05-02 16:17
    Hello,

    Wonderful, I thing that Parallax is providing the best support in the world !

    Souplogic, i hope you are aware about that ?

    Best regards,
    dro

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    in medio virtus
  • souplogicsouplogic Posts: 8
    edited 2008-05-02 16:59
    Thank you for your help,

    I will have to look into alternate options, as I have this project due today. Originally I thought that the calibration program saved data to the compass, not the BS2 EEPROM.

    To StefanL38: Thank you for your tips, I was actually looking for help from someone with intimate enough knowledge of the module that they would know what I was talking about immediately. To this end my post title should have been a bit more detailed as to not waste people's time. I apologize.

    It would be nice to see a propeller calibration routine for this compass just the same, I may work on one myself.

    Two questions: how is the angle encoded (float32?) and what is the number format for the data table in the propeller compass object?

    Thanks again,
    Adam
  • Chuck RiceChuck Rice Posts: 210
    edited 2008-12-09 21:58
    Beau Schwabe (Parallax) said...
    souplogic,

    The Propeller compass demonstration object only provides raw X and Y values as well as the Angle derived from a coordic expression using the X and Y raw values.

    I don't have the resources at the moment to add a calibration routine to this object, but by looking at the existing documentation for the BS2 you should be able to derive the correct calibration procedure that you need. I'll see if I can look into something in the way of calibration this weekend.

    Was this calibration object ever written?

    .
  • Beau SchwabeBeau Schwabe Posts: 6,562
    edited 2009-01-12 21:49
    UPDATE:


    The OBEX has been updated with a Propeller calibration technique...

    http://obex.parallax.com/objects/48/

    This demo shows the RAW heading with a "RED" compass arrow, along with the Correct heading after calibration with a "YELLOW" arrow.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.

    Post Edited (Beau Schwabe (Parallax)) : 1/12/2009 10:46:32 PM GMT
  • Chuck RiceChuck Rice Posts: 210
    edited 2009-01-12 22:50
    Thanks. I will give it a try!
  • Beau SchwabeBeau Schwabe Posts: 6,562
    edited 2009-01-12 23:08
    Chuck Rice,
    Yes, please let me know what you think.· The calibration technique uses only 8 Longs to hold the calibration data required and applies a simple interpolation technique to produce the correct heading.


    Exert from program:
    Compass Calibration for Linear interpolation Theory:
     
    Calibrate:
    Read RAW compass values at 22.5 Deg intervals and Store these values in the DAT section below.
    
    Calculating the correct heading from stored calibration values:
     
    1) Read RAW compass value into RAWheading variable
     
    2) Look where RAWheading value is within stored Calibration values.
       Determine LowCalibration value and HighCalibration value based on RAWheading
       Set HeadingIndex value from lookup table (<-- 22.5 Deg Increments indicating
       where heading should be) 
    3) CalibrationDelta = HighCalibration - LowCalibration
     
    4) HeadingError = 22.5 / CalibrationDelta
     
    5) CorrectHeading = [noparse][[/noparse] ( RAWheading - LowCalibration ) * HeadingError ] + HeadingIndex
    
    



    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
Sign In or Register to comment.