0
mirror of https://github.com/OneOfEleven/uv-k5-firmware-custom.git synced 2025-06-19 14:48:03 +03:00

Clean up DTMF decoder code (now menu item)

This commit is contained in:
OneOfEleven
2023-09-19 10:41:31 +01:00
parent 609e50f034
commit 797fc0729f
8 changed files with 14 additions and 24 deletions

View File

@ -2068,14 +2068,12 @@ static void APP_ProcessKey(KEY_Code_t Key, bool bKeyPressed, bool bKeyHeld)
if (gEeprom.AUTO_KEYPAD_LOCK)
gKeyLockCountdown = 30; // 15 seconds
#ifdef ENABLE_DTMF_DECODER
if (Key == KEY_EXIT && bKeyPressed && bKeyHeld && gDTMF_ReceivedSaved[0] > 0)
{ // clear the live DTMF decoder if the EXIT key is held
gDTMF_RecvTimeoutSaved = 0;
gDTMF_ReceivedSaved[0] = '\0';
gUpdateDisplay = true;
}
#endif
if (Key == KEY_EXIT && bKeyPressed && bKeyHeld && gDTMF_ReceivedSaved[0] > 0)
{ // clear the live DTMF decoder if the EXIT key is held
gDTMF_RecvTimeoutSaved = 0;
gDTMF_ReceivedSaved[0] = '\0';
gUpdateDisplay = true;
}
if (!bKeyPressed)
{