another attempt

This commit is contained in:
2026-11-15 00:58:12 +01:00
parent e7ae3d3ee8
commit 7832c1968e
14 changed files with 332 additions and 126 deletions

No files matched your search

+4 -1
View File
@@ -137,7 +137,7 @@ void SETTINGS_InitEEPROM(void) {
gEeprom.KEY_2_LONG_PRESS_ACTION = (Data[4] < ACTION_OPT_LEN) ? Data[4] : ACTION_OPT_NONE;
gEeprom.SCAN_RESUME_MODE = (Data[5] < 105) ? Data[5] : 14;
gEeprom.AUTO_KEYPAD_LOCK = (Data[6] < 41) ? Data[6] : 0;
gEeprom.FSKMode = (Data[7] <= MOD_POCSAG_1200) ? Data[7] : MOD_FSK_1200;
gEeprom.FSKMode = (Data[7] <= MOD_POCSAG_2400) ? Data[7] : MOD_FSK_1200;
// 0E98..0E9F
#ifdef ENABLE_PWRON_PASSWORD
EEPROM_ReadBuffer(0x0E98, Data, 8);
@@ -234,6 +234,8 @@ void SETTINGS_InitEEPROM(void) {
gEeprom.FSKSRCAddress |= Data[1] << 8;
gEeprom.FSKSRCAddress |= Data[2] << 16;
gEeprom.FSKSRCAddress |= Data[3] << 24;
// 0x0F25 held leftover scan list bytes before, so ON is a magic value
gEeprom.POCSAG_MONITOR = Data[5] == 0x5A;
#ifdef ENABLE_FMRADIO
gEeprom.BK1080_AGC_ENABLED = Data[4] & 0x01;
gEeprom.BK1080_BLEND_CONFIG = (Data[4] >> 1) & 0x03;
@@ -646,6 +648,7 @@ void SETTINGS_SaveSettings(void) {
((gEeprom.BK1080_BLEND_CONFIG & 0x03) << 1) |
((gEeprom.BK1080_DEEMPHASIS_CONFIG & 0x03) << 3));
#endif
State[5] = gEeprom.POCSAG_MONITOR ? 0x5A : 0x00;
EEPROM_WriteBuffer(0x0F20, State);