mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-26 01:35:41 +03:00
Add guard for GPS in OSD
This commit is contained in:
parent
84b79b1789
commit
44d249f054
1 changed files with 3 additions and 2 deletions
|
@ -508,9 +508,10 @@ static void osdResetStats(void)
|
||||||
|
|
||||||
static void osdUpdateStats(void)
|
static void osdUpdateStats(void)
|
||||||
{
|
{
|
||||||
int16_t value;
|
int16_t value = 0;
|
||||||
|
#ifdef GPS
|
||||||
value = GPS_speed * 36 / 1000;
|
value = GPS_speed * 36 / 1000;
|
||||||
|
#endif
|
||||||
if (stats.max_speed < value)
|
if (stats.max_speed < value)
|
||||||
stats.max_speed = value;
|
stats.max_speed = value;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue