The things I missed is to check the ENMA sentence, if the checksum is valid or not.
b'$GPGSA,A,1,,,,,,,,,,,,,99.99,99.99,99.99*30\r\n'
b'$GPGSV,6,1,21,01,,,24,02,,,26,03,,,28,04,,,24*77\r\n'
b'$GPGSV,6,2,21,06,,,25,07,,,26,09,,,25,10,,,25*74\r\n'
b'$GPGSV,6,3,21,11,,,25,14,,,36,22,,,25,23,,,24*78\r\n'
b'$GPGSV,6,4,21,24,,,25,25,,,24,26,,,24,27,,,23*7E\r\n'
b'$GPGSV,6,5,21,28,,,24,30,,,25,31,,,37,32,,,40*72\r\n'
b'$GPGSV,6,6,21,50,,,26*7B\r\n'
b'$GPGLL,,,,,214908.00,V,N*4C\r\n'
b'$GPRMC,214909.00,V,,,,,,,210420,,,N*7F\r\n'
b'$GPVTG,,,,,,,,,N*30\r\n'
b'$GPGGA,214909.00,,,,,0,00,99.99,,,,,,*61\r\n'
b'$GPGSA,A,1,,,,,,,,,,,,,99.99,99.99,99.99*30\r\n'
b'$GPGSV,6,1,21,01,,,23,02,,,24,03,,,26,04,,,24*7C\r\n'
b'$GPGSV,6,2,21,06,,,24,07,,,25,09,,,24,10,,,24*76\r\n'
b'$GPGSV,6,3,21,11,,,24,14,,,36,22,,,24,23,,,23*7F\r\n'
b'$GPGSV,6,4,21,24,,,24,25,,,23,26,,,23,27,,,23*7F\r\n'
b'$GPGSV,6,5,21,28,,,23,30,,,24,31,,,37,32,,,40*74\r\n'
b'$GPGSV,6,6,21,50,,,27*7A\r\n'
b'$GPGLL,,,,,214909.00,V,N*4D\r\n'
b'$GPRMC,214910.00,V,,,,,,,210420,,,N*77\r\n'
b'$GPVTG,,,,,,,,,N*30\r\n'
b'$GPGGA,214910.00,,,,,0,00,99.99,,,,,,*69\r\n'
b'$GPGSA,A,1,,,,,,,,,,,,,99.99,99.99,99.99*30\r\n'
b'$GPGSV,5,1,20,01,,,23,02,,,24,03,,,24,04,,,23*7B\r\n'
b'$GPGSV,5,2,20,06,,,24,07,,,24,09,,,24,10,,,23*72\r\n'
b'$GPGSV,5,3,20,11,,,24,14,,,35,22,,,23,23,,,22*78\r\n'
b'$GPGSV,5,4,20,24,,,23,25,,,28,26,,,24,27,,,22*77\r\n'
b'$GPGSV,5,5,20,28,,,22,30,,,23,31,,,36,32,,,39*7F\r\n'
b'$GPGLL,,,,,214910.00,V,N*45\r\n'
b'$GPRMC,214911.00,V,,,,,,,210420,,,N*76\r\n'
And I read it, I would like to loop a bit longer, or to return a warning.
My GPS (GP-735) has a PWR_CTRL pin. If I leave it disconnected, I read valid sentence, but when it pull HIGH (poweron), I go thos bad sentence. This I do not undertand why, but it any case, if I can find a solution to flag when the sentence is like this