LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

GMAP: FromLocalToLatLng returns inaccurate coordinates.

Hi

I have managed to successfully integrate the GMAP.net control with my Labview application, however, when I use the FromLocalToLatLng function to get the coordinates back, the resultant coordinates are slightly offset. Has anybody else encountered this issue? 

Kind regards.

0 Kudos
Message 1 of 6
(4,477 Views)
How slight? How do ypu know that they are offset? Could it be rounding error?

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 2 of 6
(4,456 Views)

Hi Mike

 

Thank you for your quick responce!

 

I compared the coordinates I received with coordinates I got back from Google Maps for the same spot. I did a similar excercise, but used C# instead, and got the correct values (compared to Google Maps) back. 

 

So I don't think the problem lies in the GMAP.net dll set. I'm kinda wondering about the coordinates that the mouse event is returning.

 

Kind regards

Werner

0 Kudos
Message 3 of 6
(4,446 Views)

Hi werner vs1,


I would like you to give more information about how LabVIEW is getting data. Maybe you can specify more detailed information in order to understand why are you getting this offset

0 Kudos
Message 4 of 6
(4,427 Views)

Hi Supertramp

 

I think I might have found a fix for this problem. I printed out the mouse coordinate in the C# app I did and found that at the top left corner of the control box, it was 0,0. I then had a look at the top left corner coordinates of the control box on the LABVIEW app, and found that it was much higher numbers for both horizontal and vertical. I created a reference of the activeX control and then subracted it's size from the mouse coordinates. The resultant coordinates now translates to the correct physical lat long coordinates.

 

I took some screenshots of the test point on my map and the same point on Google Maps before and after the fix.

 

 

0 Kudos
Message 5 of 6
(4,412 Views)

That should probably be that the application is obtaining a constant value from somewhere, as yous said before, it would be like an offset in the obtained signal. Your solution was ingenious.
Thanks for sharing wernervs1. 

Message 6 of 6
(4,397 Views)