diff --git a/Meshtastic.xcodeproj/project.pbxproj b/Meshtastic.xcodeproj/project.pbxproj index cb1f6722..ad215f33 100644 --- a/Meshtastic.xcodeproj/project.pbxproj +++ b/Meshtastic.xcodeproj/project.pbxproj @@ -1595,7 +1595,7 @@ "$(inherited)", "@executable_path/Frameworks", ); - MARKETING_VERSION = 2.3.10; + MARKETING_VERSION = 2.3.11; PRODUCT_BUNDLE_IDENTIFIER = gvh.MeshtasticClient; PRODUCT_NAME = "$(TARGET_NAME)"; SUPPORTS_MACCATALYST = YES; @@ -1629,7 +1629,7 @@ "$(inherited)", "@executable_path/Frameworks", ); - MARKETING_VERSION = 2.3.10; + MARKETING_VERSION = 2.3.11; PRODUCT_BUNDLE_IDENTIFIER = gvh.MeshtasticClient; PRODUCT_NAME = "$(TARGET_NAME)"; SUPPORTS_MACCATALYST = YES; diff --git a/Meshtastic/Helpers/BLEManager.swift b/Meshtastic/Helpers/BLEManager.swift index caab235d..5885e375 100644 --- a/Meshtastic/Helpers/BLEManager.swift +++ b/Meshtastic/Helpers/BLEManager.swift @@ -452,7 +452,7 @@ class BLEManager: NSObject, CBPeripheralDelegate, MqttClientProxyManagerDelegate } catch { context!.rollback() let nsError = error as NSError - Logger.data.error("Error Updating Core Data BluetoothConfigEntity: \(nsError)") + Logger.data.error("💥 Error Updating Core Data BluetoothConfigEntity: \(nsError)") } let logString = String.localizedStringWithFormat("mesh.log.traceroute.sent %@".localized, String(destNum)) @@ -492,7 +492,7 @@ class BLEManager: NSObject, CBPeripheralDelegate, MqttClientProxyManagerDelegate } func peripheral(_ peripheral: CBPeripheral, didUpdateNotificationStateFor characteristic: CBCharacteristic, error: Error?) { - Logger.services.error("didUpdateNotificationStateFor error: \(error?.localizedDescription ?? "Unknown")") + Logger.services.error("💥 didUpdateNotificationStateFor error: \(error?.localizedDescription ?? "Unknown")") } // MARK: Data Read / Update Characteristic Event @@ -507,7 +507,7 @@ class BLEManager: NSObject, CBPeripheralDelegate, MqttClientProxyManagerDelegate // 5 CBATTErrorDomain Code=5 "Authentication is insufficient." // 15 CBATTErrorDomain Code=15 "Encryption is insufficient." lastConnectionError = "🚨" + String.localizedStringWithFormat("ble.errorcode.pin %@".localized, error.localizedDescription) - Logger.services.error("\(error.localizedDescription) Please try connecting again and check the PIN carefully.") + Logger.services.error("💥 \(error.localizedDescription) Please try connecting again and check the PIN carefully.") self.disconnectPeripheral(reconnect: false) } return diff --git a/Meshtastic/Helpers/Map/OfflineTileManager.swift b/Meshtastic/Helpers/Map/OfflineTileManager.swift index 89e9bc16..12b159ba 100644 --- a/Meshtastic/Helpers/Map/OfflineTileManager.swift +++ b/Meshtastic/Helpers/Map/OfflineTileManager.swift @@ -21,7 +21,7 @@ class OfflineTileManager: ObservableObject { } init() { - Logger.services.debug("Documents Directory = \(self.documentsDirectory.absoluteString)") + Logger.services.debug("🗄️ Documents Directory = \(self.documentsDirectory.absoluteString)") createDirectoriesIfNecessary() } diff --git a/Meshtastic/Helpers/Mqtt/MqttClientProxyManager.swift b/Meshtastic/Helpers/Mqtt/MqttClientProxyManager.swift index a2e363d0..29a3548a 100644 --- a/Meshtastic/Helpers/Mqtt/MqttClientProxyManager.swift +++ b/Meshtastic/Helpers/Mqtt/MqttClientProxyManager.swift @@ -130,8 +130,7 @@ extension MqttClientProxyManager: CocoaMQTTDelegate { } } func mqttDidDisconnect(_ mqtt: CocoaMQTT, withError err: Error?) { - Logger.services.debug("mqttDidDisconnect: \(err?.localizedDescription ?? "")") - + Logger.services.debug("📲 MQTT Client Proxy mqttDidDisconnect: \(err?.localizedDescription ?? "")") if let error = err { delegate?.onMqttError(message: error.localizedDescription) } @@ -152,7 +151,7 @@ extension MqttClientProxyManager: CocoaMQTTDelegate { Logger.services.info("📲 MQTT Client Proxy didSubscribeTopics: \(success.allKeys.count) topics. failed: \(failed.count) topics") } func mqtt(_ mqtt: CocoaMQTT, didUnsubscribeTopics topics: [String]) { - Logger.services.info("didUnsubscribeTopics: \(topics.joined(separator: ", "))") + Logger.services.info("📲 MQTT Client Proxy didUnsubscribeTopics: \(topics.joined(separator: ", "))") } func mqttDidPing(_ mqtt: CocoaMQTT) { Logger.services.info("📲 MQTT Client Proxy mqttDidPing") diff --git a/Meshtastic/MeshtasticApp.swift b/Meshtastic/MeshtasticApp.swift index da3383d2..b6cb96c1 100644 --- a/Meshtastic/MeshtasticApp.swift +++ b/Meshtastic/MeshtasticApp.swift @@ -48,7 +48,7 @@ struct MeshtasticAppleApp: App { Logger.services.debug("Add Channel \(self.addChannels)") } self.saveChannels = true - Logger.mesh.debug("User wants to open a Channel Settings URL: \(self.incomingUrl?.absoluteString ?? "No QR Code Link")") + Logger.mesh.debug("User wants to open a Channel Settings URL: \(self.incomingUrl?.absoluteString ?? "No QR Code Link", privacy: .private)") } if self.saveChannels { Logger.mesh.debug("User wants to open Channel Settings URL: \(String(describing: self.incomingUrl!.relativeString))") @@ -56,14 +56,14 @@ struct MeshtasticAppleApp: App { } .onOpenURL(perform: { (url) in - Logger.mesh.debug("Some sort of URL was received \(url)") + Logger.mesh.debug("Some sort of URL was received \(url, privacy: .private)") self.incomingUrl = url if url.absoluteString.lowercased().contains("meshtastic.org/e/#") { if let components = self.incomingUrl?.absoluteString.components(separatedBy: "#") { self.channelSettings = components.last! } self.saveChannels = true - Logger.mesh.debug("User wants to open a Channel Settings URL: \(self.incomingUrl?.absoluteString ?? "No QR Code Link")") + Logger.mesh.debug("User wants to open a Channel Settings URL: \(self.incomingUrl?.absoluteString ?? "No QR Code Link", privacy: .private)") } else if url.absoluteString.lowercased().contains("meshtastic://") { appState.navigationPath = url.absoluteString let path = appState.navigationPath ?? "" @@ -140,7 +140,7 @@ struct MeshtasticAppleApp: App { .onChange(of: scenePhase) { (newScenePhase) in switch newScenePhase { case .background: - Logger.services.info("🍏 Scene is in the background") + Logger.services.info("🎬 Scene is in the background") do { try persistenceController.container.viewContext.save() @@ -151,9 +151,9 @@ struct MeshtasticAppleApp: App { Logger.services.error("💥 Failed to save viewContext when the app goes to the background.") } case .inactive: - Logger.services.info("🍏 Scene is inactive") + Logger.services.info("🎬 Scene is inactive") case .active: - Logger.services.info("🍏 Scene is active") + Logger.services.info("🎬 Scene is active") @unknown default: Logger.services.error("🍎 Apple must have changed something") } diff --git a/Meshtastic/Views/Nodes/Helpers/Map/PositionPopover.swift b/Meshtastic/Views/Nodes/Helpers/Map/PositionPopover.swift index 221bf24f..8cfcb612 100644 --- a/Meshtastic/Views/Nodes/Helpers/Map/PositionPopover.swift +++ b/Meshtastic/Views/Nodes/Helpers/Map/PositionPopover.swift @@ -193,7 +193,9 @@ struct PositionPopover: View { } BatteryGauge(node: position.nodePosition!) } - LoRaSignalStrengthMeter(snr: position.nodePosition?.snr ?? 0.0, rssi: position.nodePosition?.rssi ?? 0, preset: ModemPresets(rawValue: UserDefaults.modemPreset) ?? ModemPresets.longFast, compact: false) + if !(position.nodePosition?.viaMqtt ?? true) && position.nodePosition?.hopsAway == 0 { + LoRaSignalStrengthMeter(snr: position.nodePosition?.snr ?? 0.0, rssi: position.nodePosition?.rssi ?? 0, preset: ModemPresets(rawValue: UserDefaults.modemPreset) ?? ModemPresets.longFast, compact: false) + } Spacer() } }