Pyrofer wrote:Why does it need to be called? Why not parse each incoming line and see if its nmea or not?
Its easy to identify each type of data and react accordingly.
There is no reason it has to "choose" one of the other, both can be supported at the same time based on the incoming data.
This is also how I see the way to share the same UART.
With the new protocol, there is a header.
So it's easy to detect either a NMEA header or a MSP header without the need to sense the presence of a GPS at the init.
just one inconvenient: the Serial speed must be the same between GUI and GPS device