In this Post: https://forum.peplink.com/t/accessing-gps-info-from-pepwave-max-routers/8262/3
@Guido_Biosca wanted to access the GPS data from a MAX over the LAN using python to open the NEMA socket on.60660. I tried knocking out a Python 3 script to do just that but didn't have a MAX to hand with an active GPS so couldn't test it.
Well I tested it and it didn't work as expected. I managed to grab the positioning data from the socket:
but assumed incorrectly that the positioning data just needed to be pulled out of that string eg:
Of course in hindsight I should have easily spotted that it wasn't valid lat longs. So what is it? Well its a decimal-decimal value, so it needs to be converted to degrees and minutes before its useful to us eg:
5141.058053 (ddmm.mmmmmm) = 51 41.058053 = 51 + 41.058053/60 = 51.684301 degrees
The following code does exactly that and now finally works hooray!