mirror of
https://github.com/meshtastic/Meshtastic-Android.git
synced 2026-04-20 22:23:37 +00:00
add new configs
This commit is contained in:
parent
5a6b5a7202
commit
807337ca9b
4 changed files with 57 additions and 0 deletions
|
|
@ -367,6 +367,11 @@ class UIViewModel @Inject constructor(
|
|||
setModuleConfig(moduleConfig { audio = data })
|
||||
}
|
||||
|
||||
inline fun updateRemoteHardwareConfig(crossinline body: (ModuleConfig.RemoteHardwareConfig) -> ModuleConfig.RemoteHardwareConfig) {
|
||||
val data = body(module.remoteHardware)
|
||||
setModuleConfig(moduleConfig { remoteHardware = data })
|
||||
}
|
||||
|
||||
fun setModuleConfig(config: ModuleConfig) {
|
||||
meshService?.setModuleConfig(config.toByteArray())
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue