As a disclaimer... the devices I monitor are mobile and I need to be able to derive the GPS coordinates from an onboard system.

My Question: I have a custom sensor that can give me the Latitude and Longitude, but the onboard system only provides it in the degrees decimal minutes format, and I need it in the decimal degrees format. Using the Regular Expression coding, I can only get the degrees, as the message has spaces and other non-numerical data. Example: 41 19' 42.465"

Is there any way to derive this data that includes the spaces and tic marks? Eventually I will take that data and push it to the parent group's location information via API.


Article Comments

In the case you have a problem with the correct regex here is a link

http://regexr.com/?32vj8

to a regex that extracts degrees minutes and seconds from a string.


Aug, 2015 - Permalink