mirror of
https://github.com/meshtastic/Meshtastic-Apple.git
synced 2026-04-20 22:13:56 +00:00
Zero hops, defaults for node info broadcast
This commit is contained in:
parent
8d6aa9e88b
commit
e4284d9741
2 changed files with 6 additions and 6 deletions
|
|
@ -176,9 +176,6 @@ struct DeviceConfig: View {
|
|||
dc.buttonGpio = UInt32(buttonGPIO)
|
||||
dc.buzzerGpio = UInt32(buzzerGPIO)
|
||||
dc.rebroadcastMode = RebroadcastModes(rawValue: rebroadcastMode)?.protoEnumValue() ?? RebroadcastModes.all.protoEnumValue()
|
||||
if nodeInfoBroadcastSecs < 0 {
|
||||
nodeInfoBroadcastSecs = 10800
|
||||
}
|
||||
dc.nodeInfoBroadcastSecs = UInt32(nodeInfoBroadcastSecs)
|
||||
dc.doubleTapAsButtonPress = doubleTapAsButtonPress
|
||||
dc.isManaged = isManaged
|
||||
|
|
@ -271,6 +268,9 @@ struct DeviceConfig: View {
|
|||
self.buzzerGPIO = Int(node?.deviceConfig?.buzzerGpio ?? 0)
|
||||
self.rebroadcastMode = Int(node?.deviceConfig?.rebroadcastMode ?? 0)
|
||||
self.nodeInfoBroadcastSecs = Int(node?.deviceConfig?.nodeInfoBroadcastSecs ?? 900)
|
||||
if nodeInfoBroadcastSecs < 3600 {
|
||||
nodeInfoBroadcastSecs = 3600
|
||||
}
|
||||
self.doubleTapAsButtonPress = node?.deviceConfig?.doubleTapAsButtonPress ?? false
|
||||
self.isManaged = node?.deviceConfig?.isManaged ?? false
|
||||
self.hasChanges = false
|
||||
|
|
|
|||
|
|
@ -130,12 +130,12 @@ struct LoRaConfig: View {
|
|||
}
|
||||
VStack(alignment: .leading) {
|
||||
Picker("Number of hops", selection: $hopLimit) {
|
||||
ForEach(1..<8) {
|
||||
ForEach(0..<8) {
|
||||
Text("\($0)")
|
||||
.tag($0 == 0 ? 3 : $0)
|
||||
.tag($0)
|
||||
}
|
||||
}
|
||||
Text("Sets the maximum number of hops, default is 3. Increasing hops also increases congestion and should be used carefully.")
|
||||
Text("Sets the maximum number of hops, default is 3. Increasing hops also increases congestion and should be used carefully. O hop broadcast messages will not get ACKs.")
|
||||
.foregroundColor(.gray)
|
||||
.font(.callout)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue