fix(admin): persist TAK module config (team color / member role) (#11216)

Setting TAK team/role ACKed and rebooted but stored nothing:
handleSetModuleConfig had no tak case, saveToDisk never set has_tak,
and handleGetModuleConfig had no TAK_CONFIG case. Add all three, plus
a native suite sweeping every ModuleConfig submessage through
set -> save -> load -> get and a TAK value-fidelity suite.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
James Rich
2026-07-25 23:03:06 +00:00
committed by GitHub
co-authored by GitHub Claude Fable 5
parent 6d944e44d0
commit 8e104a909b
7 changed files with 365 additions and 1 deletions
+10
View File
@@ -1299,6 +1299,11 @@ bool AdminModule::handleSetModuleConfig(const meshtastic_ModuleConfig &c)
moduleConfig.has_traffic_management = true;
moduleConfig.traffic_management = c.payload_variant.traffic_management;
break;
case meshtastic_ModuleConfig_tak_tag:
LOG_INFO("Set module config: TAK");
moduleConfig.has_tak = true;
moduleConfig.tak = c.payload_variant.tak;
break;
#if !MESHTASTIC_EXCLUDE_BEACON
case meshtastic_ModuleConfig_mesh_beacon_tag: {
LOG_INFO("Set module config: MeshBeacon");
@@ -1617,6 +1622,11 @@ void AdminModule::handleGetModuleConfig(const meshtastic_MeshPacket &req, const
res.get_module_config_response.which_payload_variant = meshtastic_ModuleConfig_traffic_management_tag;
res.get_module_config_response.payload_variant.traffic_management = moduleConfig.traffic_management;
break;
case meshtastic_AdminMessage_ModuleConfigType_TAK_CONFIG:
configName = "TAK";
res.get_module_config_response.which_payload_variant = meshtastic_ModuleConfig_tak_tag;
res.get_module_config_response.payload_variant.tak = moduleConfig.tak;
break;
#if !MESHTASTIC_EXCLUDE_BEACON
case meshtastic_AdminMessage_ModuleConfigType_MESHBEACON_CONFIG:
configName = "MeshBeacon";