From ff2fb02a907c30f8b31b77cf849812417a23cfd3 Mon Sep 17 00:00:00 2001 From: dzaro-dev <23706061+dzaro-dev@users.noreply.github.com> Date: Wed, 25 Dec 2024 14:11:22 +0100 Subject: [PATCH] Update osd.c - RSSI Display Code 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. --- src/main/io/osd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/io/osd.c b/src/main/io/osd.c index 77e5f8a583b..e1ea4eab5a0 100644 --- a/src/main/io/osd.c +++ b/src/main/io/osd.c @@ -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);