fix(bumblebee): customisable switches display issue, audio mute not working (#5722)

This commit is contained in:
3djc
2024-12-20 08:12:52 +10:00
committed by GitHub
parent 689dbb23db
commit 91a961f7fb
2 changed files with 5 additions and 1 deletions
+4
View File
@@ -885,7 +885,11 @@ void menuModelSetup(event_t event)
case ITEM_MODEL_SETUP_SW5:
case ITEM_MODEL_SETUP_SW6:
{
#if defined(FUNCTION_SWITCHES_RGB_LEDS)
int index = (k - ITEM_MODEL_SETUP_SW1) / 2;
#else
int index = (k - ITEM_MODEL_SETUP_SW1);
#endif
lcdDrawSizedText(INDENT_WIDTH, y, STR_CHAR_SWITCH, 2, menuHorizontalPosition < 0 ? attr : 0);
// TODO: restore following line when switchGetName(index+switchGetMaxSwitches()) doesn't crash anymore
+1 -1
View File
@@ -2725,7 +2725,7 @@
#define JACK_DETECT_GPIO GPIO_PIN(GPIOC, 13) // PC.13
#define AUDIO_SPEAKER_ENABLE_GPIO GPIO_PIN(GPIOD, 14) // PD.14
#define HEADPHONE_TRAINER_SWITCH_GPIO GPIO_PIN(GPIOD, 9) // PD.09
#elif defined(RADIO_FAMILY_T20)
#elif defined(RADIO_FAMILY_T20) || defined(RADIO_BUMBLEBEE)
#define AUDIO_MUTE_GPIO GPIO_PIN(GPIOG, 4) // PG.04
#define AUDIO_MUTE_DELAY 500 // ms
#define AUDIO_UNMUTE_DELAY 150 // ms