inmcm / micropyGPS

A Full Featured GPS NMEA-0183 sentence parser for use with Micropython and the PyBoard embedded platform
MIT License
346 stars 119 forks source link

Replace dependency on pyb with more portable machine. #13

Closed peterhinch closed 6 years ago

peterhinch commented 6 years ago

This pathch should enable it to run on generic MicroPython targets. Also tested on CPython 3.4.

inmcm commented 6 years ago

Thanks for the improvement!

peterhinch commented 6 years ago

Thanks for the excellent parser! A very nice piece of code.

Just FYI I've nearly completed an asynchronous device driver for those GPS modules which use a UART to communicate. The driver uses an adapted version of your parser. Significantly uasyncio's StreamReader can return a complete line. Hence the update method is substantially simplified (taking as input a sentence rather than a character) consequently the class does not need to store state associated with the update process.