BRN-POCSAG: 171 channels, 26 x 40 char messages, make toggles

EEPROM layout (settings.h), replacing the broken 24 byte layout from
85fb527 (200 x 24 B channels overran the VFOs, attributes and settings;
names were saved at ch*24 but read at ch*20):
- 32 byte channel records with the 10 char name and the 16 bit scrambler
  inside, 171 channels in two areas (0x0000, 0x11E0); VFOs at 0x1020 with
  the same record; attributes moved to 0x0F50.
- Message store from 0x1900: 26 messages of 40 characters.
- Reset VFO no longer wipes the memory channels and messages.
- Static asserts that no area overlaps another or the calibration.

Identity: reports "BRN-POCSAG v4.0" to CHIRP and in the packed image, so
stock / egzumer / F4HWN drivers do not accept the new layout; the name is
shown on the welcome screen.

Make toggles: ENABLE_POCSAG, ENABLE_POCSAG_DEBUG, ENABLE_POCSAG_DEV_TUNING,
ENABLE_OOK_SENDER (POCSAG code and the OOK sender compile out completely).

Fonts: removed the unused big font, big digits and small digits; the 3x5
font is only built with the spectrum.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-15 01:43:05 +01:00
co-authored by Claude Opus 5.5
parent c5a2b41fdb
commit aabd0f4956
20 changed files with 159 additions and 312 deletions

No files matched your search

+4
View File
@@ -87,7 +87,9 @@ const t_menu_item MenuList[] =
{"ChDisp", MENU_MDF}, // was "MDF"
{"FSKMod", MENU_FSKMOD},
{"FSKSRC", MENU_FSKSRC}, // was "AUTOLk"
#ifdef ENABLE_POCSAG
{"PocMon", MENU_PMON}, // POCSAG monitor: receive all RICs
#endif
{"BLTime", MENU_ABR}, // was "ABR"
{"BLMin", MENU_ABR_MIN},
{"BLMax", MENU_ABR_MAX},
@@ -235,9 +237,11 @@ const char gSubMenu_FSKMod[][8] =
"A1200",
"A2400",
"NOAA",
#ifdef ENABLE_POCSAG
"PCS1200",
"PCS512",
"PCS2400"
#endif
};
const char gSubMenu_ROGER[][6] =
+4
View File
@@ -145,7 +145,11 @@ extern const char gSubMenu_SET_PTT[2][4];
#endif
extern const char *const gSubMenu_PTT_ID[5];
#ifdef ENABLE_POCSAG
extern const char gSubMenu_FSKMod[10][8];
#else
extern const char gSubMenu_FSKMod[7][8];
#endif
extern const char gSubMenu_ROGER[3][6];
extern const char gSubMenu_RESET[2][4];
extern const char *const gSubMenu_F_LOCK[F_LOCK_LEN];
+7 -3
View File
@@ -37,7 +37,7 @@ static void UI_PrintWrapped(const char *text, const uint8_t line, const uint8_t
}
void UI_DisplayMessages(void) {
char String[19];
char String[24];
UI_DisplayClear();
if (gEnteringSMS != SMS_NOT_ENTERING) {
if (gEnteringSMS == SMS_ENTERING_DEST) {
@@ -76,8 +76,12 @@ void UI_DisplayMessages(void) {
MESSAGES_GET();
// header: sender (POCSAG: "P:" + RIC), sequence, position in the list, EEPROM slot
sprintf(String, (loadedPacket.flags & MESSAGE_FLAG_POCSAG) ? "P:%07lu -%03u-%X-%X" : "%010lu-%03u-%X-%X",
(unsigned long) loadedPacket.src, loadedPacket.seq, ixa + pageOffset, gActiveMessage);
// header (max 18 chars): POCSAG "P:<RIC> #nn", SMS "<address> s<seq> #nn"
if (loadedPacket.flags & MESSAGE_FLAG_POCSAG)
sprintf(String, "P:%07lu #%02u", (unsigned long) loadedPacket.src, ixa + pageOffset + 1U);
else
sprintf(String, "%08lu s%03u #%02u", (unsigned long) (loadedPacket.src % 100000000UL),
loadedPacket.seq, ixa + pageOffset + 1U);
// header line, then the text wrapped over MESSAGES_TEXT_LINES lines
const uint8_t line = ixa * (1U + MESSAGES_TEXT_LINES);
+4
View File
@@ -40,7 +40,9 @@
#include "ui/ui.h"
#include "../misc.h"
#include "messages.h"
#ifdef ENABLE_OOK_SENDER
#include "ooksender.h"
#endif
GUI_DisplayType_t gScreenToDisplay;
GUI_DisplayType_t gRequestDisplayScreen = DISPLAY_INVALID;
@@ -55,7 +57,9 @@ void (*UI_DisplayFunctions[])(void) = {
[DISPLAY_MENU] = &UI_DisplayMenu,
[DISPLAY_SCANNER] = &UI_DisplayScanner,
[DISPLAY_MESSAGES] = &UI_DisplayMessages,
#ifdef ENABLE_OOK_SENDER
[DISPLAY_OOKSENDER] = &OOKSENDER_Display,
#endif
#ifdef ENABLE_FMRADIO
[DISPLAY_FM] = &UI_DisplayFM,
+3 -1
View File
@@ -55,7 +55,9 @@ void UI_DisplayWelcome(void) {
UI_DrawLineBuffer(gFrameBuffer, 0, 31, 127, 31, 1); // Be ware, status zone = 8 lines, the rest = 56 ->total 64
for (uint8_t i = 18; i < 110; i++) {
// firmware name in an inverted bar
UI_PrintStringSmallNormal(Version, 0, 127, 4);
for (uint8_t i = 0; i < 128; i++) {
gFrameBuffer[4][i] ^= 0xFF;
}