mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-23 16:25:31 +03:00
GPS - handle data loss occurs in the start of a UBLOX frame
This commit is contained in:
parent
20f32d632c
commit
1c8416db2c
2 changed files with 7 additions and 1 deletions
3
Makefile
3
Makefile
|
@ -266,7 +266,7 @@ EUSTM32F103RC_SRC = startup_stm32f10x_hd_gcc.S \
|
|||
drivers/bus_i2c_stm32f10x.c \
|
||||
drivers/bus_spi.c \
|
||||
drivers/compass_hmc5883l.c \
|
||||
drivers/display_ug2864hsweg01.h \
|
||||
drivers/display_ug2864hsweg01.c \
|
||||
drivers/gpio_stm32f10x.c \
|
||||
drivers/inverter.c \
|
||||
drivers/light_led_stm32f10x.c \
|
||||
|
@ -424,6 +424,7 @@ MASSIVEF3_SRC = $(STM32F3DISCOVERY_SRC) \
|
|||
$(COMMON_SRC)
|
||||
|
||||
SPARKY_SRC = $(STM32F30x_COMMON_SRC) \
|
||||
drivers/display_ug2864hsweg01.c \
|
||||
drivers/accgyro_mpu9150.c \
|
||||
drivers/barometer_ms5611.c \
|
||||
$(HIGHEND_SRC) \
|
||||
|
|
|
@ -24,6 +24,8 @@
|
|||
|
||||
#include "platform.h"
|
||||
|
||||
#include "build_config.h"
|
||||
|
||||
#include "common/maths.h"
|
||||
|
||||
#include "drivers/system.h"
|
||||
|
@ -908,6 +910,9 @@ static bool gpsNewFrameUBLOX(uint8_t data)
|
|||
_skip_packet = true;
|
||||
}
|
||||
_payload_counter = 0; // prepare to receive payload
|
||||
if (_payload_length == 0) {
|
||||
_step = 7;
|
||||
}
|
||||
break;
|
||||
case 6:
|
||||
_ck_b += (_ck_a += data); // checksum byte
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue