mirror of
https://github.com/meshtastic/Meshtastic-Android.git
synced 2026-06-14 00:45:24 -04:00
feat(settings): implement set_ham_mode HamParameters admin message
When the licensed amateur radio toggle is on for the locally connected node, the User config screen repurposes the long-name field as the callsign (max 8 chars, iOS parity) and saving sends AdminMessage(set_ham_mode) instead of set_owner. Current LoRa tx_power/override_frequency are echoed into the HamParameters so a re-send while already licensed never wipes the node's overrides (firmware applies them verbatim). The node entry is optimistically updated pending the device's authoritative NodeInfo. Closes #5759 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -25,6 +25,7 @@ import org.meshtastic.core.repository.RadioController
|
||||
import org.meshtastic.proto.Channel
|
||||
import org.meshtastic.proto.ClientNotification
|
||||
import org.meshtastic.proto.Config
|
||||
import org.meshtastic.proto.HamParameters
|
||||
import org.meshtastic.proto.ModuleConfig
|
||||
import org.meshtastic.proto.User
|
||||
|
||||
@@ -99,6 +100,8 @@ class FakeRadioController :
|
||||
|
||||
override suspend fun setOwner(destNum: Int, user: User, packetId: Int) {}
|
||||
|
||||
override suspend fun setHamMode(destNum: Int, hamParameters: HamParameters, packetId: Int) {}
|
||||
|
||||
override suspend fun setConfig(destNum: Int, config: Config, packetId: Int) {}
|
||||
|
||||
override suspend fun setModuleConfig(destNum: Int, config: ModuleConfig, packetId: Int) {}
|
||||
|
||||
Reference in New Issue
Block a user