Skip to content

Commit

Permalink
AP_GPS: have AP_GPS_UBLOX use boolean uart read
Browse files Browse the repository at this point in the history
  • Loading branch information
peterbarker committed Oct 6, 2023
1 parent 49d7d0b commit 53115c7
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions libraries/AP_GPS/AP_GPS_UBLOX.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -594,11 +594,10 @@ AP_GPS_UBLOX::read(void)
for (uint16_t i = 0; i < numc; i++) { // Process bytes received

// read the next byte
const int16_t rdata = port->read();
if (rdata < 0) {
uint8_t data;
if (!port->read(data)) {
break;
}
const uint8_t data = rdata;
#if AP_GPS_DEBUG_LOGGING_ENABLED
log_data(&data, 1);
#endif
Expand Down

0 comments on commit 53115c7

Please sign in to comment.