Added Macro functionality, updated readme

This commit is contained in:
2026-03-29 22:19:27 +02:00
parent b49984b9c0
commit 59b3cb4dd1
9 changed files with 354 additions and 33 deletions
+12 -6
View File
@@ -12,6 +12,7 @@
#include "hal/usb_hid.h"
#include "hal/usb_serial.h"
#include "config/action.h"
#include "config/macro_config.h"
class CMainController
{
@@ -41,10 +42,15 @@ private:
void updateLEDs(); // Dirty-LEDs in WS2812-Buffer schreiben
// ── Config-Empfangspuffer ─────────────────────────────────────────────────
// Mehrteilige Übertragung: BEGIN setzt receiving=true, DATA füllt den Buffer,
// COMMIT validiert und schreibt in den NVM.
// Puffergröße = sizeof(SDeviceConfig) = 163 Bytes.
uint8_t m_cfg_buf[163]; // Empfangspuffer für eingehende Config-Daten
uint8_t m_cfg_chunks_expected; // Anzahl erwarteter Chunks (aus BEGIN-Paket)
bool m_cfg_receiving; // true wenn Übertragung läuft
uint8_t m_cfg_buf[223]; // sizeof(SDeviceConfig) = 223 Bytes
uint8_t m_cfg_chunks_expected;
bool m_cfg_receiving;
// ── Makro-Empfangspuffer ──────────────────────────────────────────────────
uint8_t m_macro_buf[256]; // sizeof(SMacroTable) = 256 Bytes
uint8_t m_macro_chunks_expected;
bool m_macro_receiving;
// Geladene Makro-Tabelle (im RAM wird beim Start aus NVM geladen)
SMacroTable m_macros;
};