diff --git a/Meshtastic/Helpers/MeshPackets.swift b/Meshtastic/Helpers/MeshPackets.swift index bf47bc0f..9b720845 100644 --- a/Meshtastic/Helpers/MeshPackets.swift +++ b/Meshtastic/Helpers/MeshPackets.swift @@ -796,7 +796,7 @@ func textMessageAppPacket(packet: MeshPacket, blockRangeTest: Bool, connectedNod subtitle: "AKA \(newMessage.fromUser?.shortName ?? "?")", content: messageText, target: "message", - path: "meshtastic://messages/dm/user/\(newMessage.fromUser?.num ?? 0)/message/\(newMessage.messageId)" + path: "meshtastic://open-dm?userid=\(newMessage.fromUser?.num ?? 0)&id=\(newMessage.messageId)" ) ] manager.schedule() diff --git a/Meshtastic/Views/Settings/Config/DeviceConfig.swift b/Meshtastic/Views/Settings/Config/DeviceConfig.swift index 674c951f..5572c330 100644 --- a/Meshtastic/Views/Settings/Config/DeviceConfig.swift +++ b/Meshtastic/Views/Settings/Config/DeviceConfig.swift @@ -103,7 +103,7 @@ struct DeviceConfig: View { } Section(header: Text("GPIO")) { Picker("Button GPIO", selection: $buttonGPIO) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { @@ -113,7 +113,7 @@ struct DeviceConfig: View { } .pickerStyle(DefaultPickerStyle()) Picker("Buzzer GPIO", selection: $buzzerGPIO) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { diff --git a/Meshtastic/Views/Settings/Config/Module/CannedMessagesConfig.swift b/Meshtastic/Views/Settings/Config/Module/CannedMessagesConfig.swift index ded4f262..cb5585d2 100644 --- a/Meshtastic/Views/Settings/Config/Module/CannedMessagesConfig.swift +++ b/Meshtastic/Views/Settings/Config/Module/CannedMessagesConfig.swift @@ -124,7 +124,7 @@ struct CannedMessagesConfig: View { .disabled(configPreset > 0) Section(header: Text("Inputs")) { Picker("Pin A", selection: $inputbrokerPinA) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { @@ -136,7 +136,7 @@ struct CannedMessagesConfig: View { Text("GPIO pin for rotary encoder A port.") .font(.caption) Picker("Pin B", selection: $inputbrokerPinB) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { @@ -148,7 +148,7 @@ struct CannedMessagesConfig: View { Text("GPIO pin for rotary encoder B port.") .font(.caption) Picker("Press Pin", selection: $inputbrokerPinPress) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { diff --git a/Meshtastic/Views/Settings/Config/Module/DetectionSensorConfig.swift b/Meshtastic/Views/Settings/Config/Module/DetectionSensorConfig.swift index 7b874aa0..23b33a90 100644 --- a/Meshtastic/Views/Settings/Config/Module/DetectionSensorConfig.swift +++ b/Meshtastic/Views/Settings/Config/Module/DetectionSensorConfig.swift @@ -139,7 +139,7 @@ struct DetectionSensorConfig: View { .listRowSeparator(.visible) .offset(y: -10) Picker("GPIO Pin to monitor", selection: $monitorPin) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { diff --git a/Meshtastic/Views/Settings/Config/Module/ExternalNotificationConfig.swift b/Meshtastic/Views/Settings/Config/Module/ExternalNotificationConfig.swift index 512f09ae..511385d8 100644 --- a/Meshtastic/Views/Settings/Config/Module/ExternalNotificationConfig.swift +++ b/Meshtastic/Views/Settings/Config/Module/ExternalNotificationConfig.swift @@ -99,7 +99,7 @@ struct ExternalNotificationConfig: View { Text("If enabled, the 'output' Pin will be pulled active high, disabled means active low.") .font(.caption) Picker("Output pin GPIO", selection: $output) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { @@ -147,7 +147,7 @@ struct ExternalNotificationConfig: View { } .toggleStyle(SwitchToggleStyle(tint: .accentColor)) Picker("Output pin buzzer GPIO ", selection: $outputBuzzer) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { @@ -157,7 +157,7 @@ struct ExternalNotificationConfig: View { } .pickerStyle(DefaultPickerStyle()) Picker("Output pin vibra GPIO", selection: $outputVibra) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { diff --git a/Meshtastic/Views/Settings/Config/Module/SerialConfig.swift b/Meshtastic/Views/Settings/Config/Module/SerialConfig.swift index 0e36460e..c3fa234d 100644 --- a/Meshtastic/Views/Settings/Config/Module/SerialConfig.swift +++ b/Meshtastic/Views/Settings/Config/Module/SerialConfig.swift @@ -99,7 +99,7 @@ struct SerialConfig: View { Section(header: Text("GPIO")) { Picker("Receive data (rxd) GPIO pin", selection: $rxd) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { @@ -110,7 +110,7 @@ struct SerialConfig: View { .pickerStyle(DefaultPickerStyle()) Picker("Transmit data (txd) GPIO pin", selection: $txd) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { diff --git a/Meshtastic/Views/Settings/Config/PositionConfig.swift b/Meshtastic/Views/Settings/Config/PositionConfig.swift index c70e5c89..a92f06ef 100644 --- a/Meshtastic/Views/Settings/Config/PositionConfig.swift +++ b/Meshtastic/Views/Settings/Config/PositionConfig.swift @@ -213,7 +213,7 @@ struct PositionConfig: View { if deviceGpsEnabled { Picker("GPS Receive GPIO", selection: $rxGpio) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { @@ -223,7 +223,7 @@ struct PositionConfig: View { } .pickerStyle(DefaultPickerStyle()) Picker("GPS Transmit GPIO", selection: $txGpio) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { @@ -233,7 +233,7 @@ struct PositionConfig: View { } .pickerStyle(DefaultPickerStyle()) Picker("GPS EN GPIO", selection: $gpsEnGpio) { - ForEach(0..<48) { + ForEach(0..<49) { if $0 == 0 { Text("unset") } else { diff --git a/Meshtastic/Views/Settings/RouteRecorder.swift b/Meshtastic/Views/Settings/RouteRecorder.swift index 601f2a49..88c4a44e 100644 --- a/Meshtastic/Views/Settings/RouteRecorder.swift +++ b/Meshtastic/Views/Settings/RouteRecorder.swift @@ -257,6 +257,12 @@ struct RouteRecorder: View { .presentationDetents([.fraction(0.30), .fraction(0.65)]) .presentationDragIndicator(.hidden) .interactiveDismissDisabled(false) + .onAppear { + UIApplication.shared.isIdleTimerDisabled = true + } + .onDisappear(perform: { + UIApplication.shared.isIdleTimerDisabled = false + }) .onChange(of: locationsHandler.locationsArray.last) { newLoc in if locationsHandler.isRecording { if let loc = newLoc {