Skip to content

Commit

Permalink
Update osd.c - RSSI Display Code
Browse files Browse the repository at this point in the history
The current way the RSSI is displayed is such that the RSSI takes up two characters. Whilst this is OK for most OSD systems, it causes alignement issues with regards to the values when used with LQ, which hovers around 100 most of the time. 

I think that the MAX symbol should not be used, but instead the value should be shown as 100 when it is 100 same as the LQ. This way both the LQ and the RSSI, which are most frequently used together will both be showing with the same total number of characters, i.e. 4 in total, 1 for the signal bars icon and 3 for the value. This way users can correclty align the two signal icons one under the other and the values can lign up to the right. 

The only thing that would need to be done would be to adjust the lenght in the configurator as well.
  • Loading branch information
dzaro-dev authored Dec 25, 2024
1 parent 8ac5703 commit ff2fb02
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 @@ -1723,9 +1723,9 @@ static bool osdDrawSingleElement(uint8_t item)
uint8_t osdRssi = osdConvertRSSI();
buff[0] = SYM_RSSI;
if (osdRssi < 100)
tfp_sprintf(buff + 1, "%2d", osdRssi);
tfp_sprintf(buff + 1, " %2d", osdRssi);
else
tfp_sprintf(buff + 1, "%c ", SYM_MAX);
tfp_sprintf(buff + 1, "100");

if (osdRssi < osdConfig()->rssi_alarm) {
TEXT_ATTRIBUTES_ADD_BLINK(elemAttr);
Expand Down

0 comments on commit ff2fb02

Please sign in to comment.