Skip to content

Commit

Permalink
Increase OSD_EFFICIENCY_WH_PER_KM max displayed value
Browse files Browse the repository at this point in the history
  • Loading branch information
shellixyz committed May 19, 2018
1 parent 0dce190 commit 87f7051
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/io/osd.c
Original file line number Diff line number Diff line change
Expand Up @@ -1674,7 +1674,7 @@ static bool osdDrawSingleElement(uint8_t item)
case OSD_EFFICIENCY_WH_PER_KM:
{
// amperage is in centi amps, speed is in cms/s. We want
// mah/km. Values over 999 are considered useless and
// mWh/km. Values over 999Wh/km are considered useless and
// displayed as "---""
static pt1Filter_t eFilterState;
static timeUs_t efficiencyUpdated = 0;
Expand All @@ -1691,7 +1691,7 @@ static bool osdDrawSingleElement(uint8_t item)
value = eFilterState.state;
}
}
if (value > 0 && value <= 999) {
if (value > 0 && value <= 999999) {
osdFormatCentiNumber(buff, value / 10, 0, 2, 0, 3);
} else {
buff[0] = buff[1] = buff[2] = '-';
Expand Down

0 comments on commit 87f7051

Please sign in to comment.