set waypoints(Lat-Lon)using Gps and Serial

Discussion in 'Questions (Windows Mobile)' started by wm.chatman, Apr 16, 2009.

  1. wm.chatman

    wm.chatman Well-Known Member Licensed User

    :)Hi forum,

    Working with Lat and Lon, I have been trying to set Waypoints. Seems like nothing wants to work correct.:(
    Can somebody :sign0085: me with this?
    I would like to set waypoints(lat-Lon)using Gps and Serial. Then have the Compass Arrow show the way back to the waypoint I select. If at all possible please with Example Code.If anyone can help me here, I'd be very very thankful.
    I sincerely appreciate the time and effort of everyone who responded to my question.

    best Regards to all,
    WmC

    PC: Laptop CoreDUo, Windows XP SP2 E
    PPC: MDA Pro/WM5
    OS: 5.1.195
    Prozessor: PXA-520 Mhz
    Display: 480x640 TFT
    Periphery: GPS Receiver (ext module)
    Bayern/Germany
     
  2. wm.chatman

    wm.chatman Well-Known Member Licensed User

    :)Hi folks,
    Still working with Lat and Lon and waypoints using Compass for Direction to Waypoint but i need assistance on this!

    I'd be very thankful if somebody could :sign0085:me.

    best Regards,
    WmC
     
  3. derez

    derez Expert Licensed User

    the accurate way of calculating the bearing and distance between two points (your location and the waypoint) is this (found here http://www.ac6v.com/greatcircle.htm):

    From the 1982 ARRL antenna book.

    1. cos(D) = (sin(A) * sin(B)) + (cos(A) * cos(B) * cos(L))

    2. cos(C) = (sin(B) - (sin(A) * cos(D))) / (cos(A) * sin(D))

    WHERE:

    A = YOUR latitude in degrees.
    B = latitude of the other location in degrees.
    L = YOUR longitude minus that of the other location. (Algebraic difference.)
    D = Distance along path in degrees of arc.
    C = True bearing from north if the value for sin(L) is positive. If
    sin(L) is negative, true bearing is 360 - C.

    To convert degrees of arc to statute miles, multiply by 69.041.
    To convert degrees of arc to kilometers, multiply by 111.111.

    If you want simpler calculation, use arctan for the bearing and pythagoras for the distance.

    don't forget to change degrees to radians for b4ppc trig operations.
     
  4. wm.chatman

    wm.chatman Well-Known Member Licensed User

    :)Hi Mr.Derez

    This is a hardcore situation. I am working on that. Upuntil now nothing but bad Luck. The Link does not seem to work for me, but we have a few sites that I am checking on this matter.

    take care and best regards,
    William
     
  5. klaus

    klaus Expert Licensed User

    Last edited: Apr 19, 2009
  6. derez

    derez Expert Licensed User

    I put the algorithm above in code
     

    Attached Files:

  7. wm.chatman

    wm.chatman Well-Known Member Licensed User

    :)Hi Mr. Derez and Klaus


    :sign0085:How do I integrate AZ and Distance to use with the Compass bmp enclosed, so it will show me the way back to the waypoint that is selected? GPS.dll and Serial.dll are on board. It is extremely hard for me, to code this. A save waypoint and also goto waypoint is needed, this much I know.
    I added Sub Rotate(course), seems a helpless mess.
    O.K. maybe someone could help me and or help with the further coding of this.
    Na ja, vielleicht kann mir doch noch jemand weiter helfen oder mit entwickeln.
    If anyone can help me here, I'd be very very thankful. I sincerely appreciate the time and effort of everyone who responded to my question.

    P.S. I been working on a database App for close to 15 yrs. now using Visual basic 5.0/6.0. Its looking and working great. But working with the GPS algorithm, I must admit, that this is not simple!:BangHead:

    best Regards to all,
    WmC

    PC: Laptop CoreDUo, Windows XP SP2 E
    PPC: MDA Pro/WM5
    OS: 5.1.195
    Prozessor: PXA-520 Mhz
    Display: 480x640 TFT
    Periphery: GPS Receiver (ext module)
    Bayern/Germany
     
    Last edited: May 19, 2009
  8. klaus

    klaus Expert Licensed User

    Hello William,

    Here you have an example of a rotating needle, rotating bitmap using the ImageLibEx.
    You can adapt it to your needs.

    Best regards.
     
  9. wm.chatman

    wm.chatman Well-Known Member Licensed User

    :)Lieber Klaus und Derez

    Sometimes I feel like hiding under a Rock.:sign0148:

    >Ich Danke Sehr<

    P.S. Mein Gedanke fuer eine Waypoint App I will UPLOAD Tommorow.
    My thoughts for a waypoint App I will UPLOAD Tommorow.
    Maybe we can make this to a Forum Projekt, if that is O.K. with Mr. Erel.

    mit freundliche Gruesse an alle,:sign0089:

    William
     
  10. wm.chatman

    wm.chatman Well-Known Member Licensed User

    frage bitte Klaus?
    wie setze ich nun diese sache mit dem GPS in verbindung?

    kanst du mir dass doch maletwas naeher erklaeren?
     
  11. wm.chatman

    wm.chatman Well-Known Member Licensed User

    :)Hi all,

    this is what the App needs to do.
    Screen shows all the available waypoints that have been saved with az_dist_demo_Update.
    Select one waypoint and use the Waypoint menu to:
    • Add a new waypoint, either manually, or from the current GPS position.
    • Go to that waypoint, entering track back function, let the Compass function take you to selected waypoint.
    • Import
    o All waypoints from KML, or other format. If these files contain more than 1 waypoint, GPS asks you to import a specific waypoint.
    • Export
    o All waypoints to KML, or other format.
    • A sound (A Warning half Hour before Sunset. This is Important)
    • Delete selected, to delete the selected waypoints.
    • Save the selected waypoints.

    P.S. I am working on this. Well I am giving it my best.:sign0137:

    best regards,
    William
     
    Last edited: May 19, 2009
  12. wm.chatman

    wm.chatman Well-Known Member Licensed User

    [ The App does not use Google Earth or KML Generator ]
    :)Hi all,

    this is what the App needs to do.
    Screen shows all the available waypoints that have been saved with az_dist_demo_Update.
    Select one waypoint and use the Waypoint menu to:
    • Add a new waypoint, either manually, or from the current GPS position.
    • Go to that waypoint, entering track back function, let the Compass function take you to selected waypoint.
    • Import
    o All waypoints from a given format. If these files contain more than 1 waypoint, GPS asks you to import a specific waypoint.
    • Export
    o All waypoints to KML, or other format. Question: Is KML not used for the Internet?
    • A sound (A Warning half Hour before Sunset. This is Important)
    • Delete selected, to delete the selected waypoints.
    • Save the selected waypoints.

    Edit: It does not use Google Earth or KML Generator

    P.S. I am working on this. Well I am giving it my best.:sign0137:

    best regards,
    William
     
    Last edited: Apr 21, 2009
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice