Context
RuntimeConfig parsing exists, but the firmware does not yet subscribe to any MQTT config topic or apply received config.
Scope
Subscribe to a per-device config topic and parse config messages.
Suggested topic:
repacss/devices/<mac>/config
Implementation notes
- Add
mqttClient.setCallback(...) in TelemetrySender.cpp.
- Subscribe after successful MQTT connect.
- Convert the callback payload into a
String or bounded buffer safely.
- Pass config JSON into
parseRuntimeConfigJson(...).
- Store accepted config somewhere the main firmware can use.
Acceptance criteria
- Firmware subscribes to the config topic after MQTT connect/reconnect.
- Retained config messages are received after reconnect.
- Valid config JSON is parsed into
RuntimeConfig.
- Invalid config JSON is rejected with a useful serial log message.
- Telemetry publishing continues even if config is invalid or missing.
Context
RuntimeConfigparsing exists, but the firmware does not yet subscribe to any MQTT config topic or apply received config.Scope
Subscribe to a per-device config topic and parse config messages.
Suggested topic:
repacss/devices/<mac>/configImplementation notes
mqttClient.setCallback(...)inTelemetrySender.cpp.Stringor bounded buffer safely.parseRuntimeConfigJson(...).Acceptance criteria
RuntimeConfig.