Skip to content

Commit

Permalink
Add status bar separator line,
Browse files Browse the repository at this point in the history
and change orange battery threshold
  • Loading branch information
LCiccio authored and reppad committed Mar 8, 2024
1 parent 2faa7a9 commit 2b636e6
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 3 deletions.
5 changes: 5 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ UART_DEBUG ?= 0
MOTO_STARTUP_TONE ?= 1
ENABLE_AM_FIX ?= 1
ENABLE_ALT_SQUELCH ?= 1
ENABLE_STATUS_BAR_LINE ?= 1
ENABLE_NOAA ?= 1
ENABLE_RX_BAR ?= 1
ENABLE_TX_BAR ?= 1
Expand Down Expand Up @@ -242,6 +243,10 @@ endif
ifeq ($(ENABLE_KEEP_MONITOR_MODE_UP_DN), 1)
CFLAGS += -DENABLE_KEEP_MONITOR_MODE_UP_DN
endif
ifeq ($(ENABLE_STATUS_BAR_LINE), 1)
CFLAGS += -DENABLE_STATUS_BAR_LINE
endif


all: $(TARGET)
$(OBJCOPY) -O binary $< $<.bin
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ UART_DEBUG => UART debug output
MOTO_STARTUP_TONE => Moto XPS startup beeps
ENABLE_AM_FIX => Experimental port of the great UV-K5 AM fix from OneOfEleven
ENABLE_ALT_SQUELCH => Port of optimized UV-K5 squelch system from various firmwares
ENABLE_STATUS_BAR_LINE => Display status bar separator line
ENABLE_NOAA => NOAA weather channels (always re-set the sidekeys actions from menu after modifying the available actions)
ENABLE_SPECTRUM => Spectrum frequency view (assign to a shortcut key to access)
ENABLE_SPECTRUM_PRESETS => Band presets for Spectrum mode (ENABLE_SPECTRUM required to be enabled)
Expand Down
8 changes: 6 additions & 2 deletions ui/helper.c
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,9 @@ void UI_DrawFM(void)
{
gColorForeground = COLOR_GREY;
DISPLAY_Fill(0, 159, 1, 81, COLOR_BACKGROUND);
DISPLAY_DrawRectangle0(0, 81, 160, 1, gSettings.BorderColor);
#ifndef ENABLE_STATUS_BAR_LINE
DISPLAY_DrawRectangle0(0, 81, 160, 1, gSettings.BorderColor);
#endif
UI_DrawFrame(12, 150, 6, 74, 2, gColorForeground);
UI_DrawFrame(72, 144, 36, 64, 2, gColorForeground);
DISPLAY_Fill( 72, 88, 16, 22, gColorForeground);
Expand Down Expand Up @@ -946,7 +948,9 @@ void UI_DrawStringSwitchType(void)
void UI_DrawRadar(void)
{
DISPLAY_Fill(0, 159, 1, 81, COLOR_BACKGROUND);
DISPLAY_DrawRectangle0(0, 81, 160, 1, gSettings.BorderColor);
#ifndef ENABLE_STATUS_BAR_LINE
DISPLAY_DrawRectangle0(0, 81, 160, 1, gSettings.BorderColor);
#endif
gColorForeground = COLOR_BLUE;
UI_DrawBitmap(4, 12, 8, 64, BitmapRadar);
}
Expand Down
6 changes: 5 additions & 1 deletion ui/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ void DrawStatusBar(void)
DISPLAY_Fill(0, 159, 0, 96, COLOR_BACKGROUND);
// DISPLAY_DrawRectangle0(0, 41, 160, 1, gSettings.BorderColor);

#ifdef ENABLE_STATUS_BAR_LINE
DISPLAY_DrawRectangle0(0, 83, 160, 1, gSettings.BorderColor);
#endif

if (gSettings.DtmfState == DTMF_STATE_STUNNED) {
UI_DrawStatusIcon(4, ICON_LOCK, true, COLOR_RED);
} else {
Expand Down Expand Up @@ -101,7 +105,7 @@ void UI_DrawBattery(bool bDisplayVoltage)
}
if (i < 6) {
Color = COLOR_RED;
} else if (i < 11) {
} else if (i < 7) {
Color = COLOR_RGB(31, 41, 0);
} else {
Color = COLOR_GREEN;
Expand Down

0 comments on commit 2b636e6

Please sign in to comment.