forked from fritob/Camper-Monitor
Solar-Integration und dev_watch-Geräte zusammenführen
solar-integration (aus dem separaten VanAligneiOS-Repo) und dev_watch haben unabhängige Git-Historien, decken aber überlappende und sich ergänzende Funktionen ab. Übernommen aus solar-integration: Votronic- Solar-ESP-Anbindung samt Geräterolle, die Live-Activity/Widget-Extension fürs Sperrbildschirm/Dynamic-Island/CarPlay, das Querformat-Layout für Libelle/Fahrzeug-Ansicht und Ausrichtungs-Assistent, sowie die mehreren Fahrzeuggrafik-Stile (Vanster/California). Beibehalten aus dev_watch: alle zusätzlichen Geräteprotokolle (Daly-/JBD-BMS, Alpicool- Kühlbox, WattCycle, Victron), die dort zwischenzeitlich entstanden. Die Xcode-Projektdatei wurde von Hand um die neue Widget-Extension samt SharedActivity-Gruppe erweitert (Datei-synchronisierte Gruppen, kein App-Group-Entitlement nötig). Build für App, Watch und Widget-Extension geprüft (Debug und Release). Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 5
parent
812874baef
commit
e9b9c5bcd5
@@ -59,8 +59,13 @@ enum DemoData {
|
||||
name: "Nivellierung", role: .leveling, profileID: Profile.defaultID,
|
||||
peripheralID: UUID(uuidString: "00000000-0000-0000-0000-0000000000E1")!)
|
||||
|
||||
static let votronicSolar = ConfiguredDevice(
|
||||
id: UUID(uuidString: "00000000-0000-0000-0000-0000000000D0")!,
|
||||
name: "VotronicSolarESP", role: .solar, profileID: Profile.defaultID,
|
||||
peripheralID: UUID(uuidString: "00000000-0000-0000-0000-0000000000D1")!)
|
||||
|
||||
static var devices: [ConfiguredDevice] {
|
||||
[solar, booster, battery, fridge, level, caravanSolar]
|
||||
[solar, booster, battery, fridge, level, votronicSolar, caravanSolar]
|
||||
}
|
||||
|
||||
/// Leicht schräg stehend, damit die Libelle etwas zu zeigen hat.
|
||||
@@ -83,6 +88,20 @@ enum DemoData {
|
||||
return state
|
||||
}
|
||||
|
||||
/// Mittags, gute Sonne.
|
||||
static var votronicSolarESPState: VotronicSolarESPState {
|
||||
var state = VotronicSolarESPState()
|
||||
state.batteryVoltage = 13.9
|
||||
state.pvVoltage = 19.4
|
||||
state.pvCurrent = 6.2
|
||||
state.pvPower = 120
|
||||
state.controllerTemperature = 34
|
||||
state.isBatteryCharging = true
|
||||
state.isControllerActive = true
|
||||
state.isCurrentLimited = false
|
||||
return state
|
||||
}
|
||||
|
||||
static func snapshots() -> [DeviceSnapshot] {
|
||||
var solarSnapshot = DeviceSnapshot(deviceID: solar.id, timestamp: Date(), rssi: -58)
|
||||
solarSnapshot.state = "Konstantspannung (Absorption)"
|
||||
@@ -131,6 +150,7 @@ enum DemoData {
|
||||
return [solarSnapshot, boosterSnapshot, batterySnapshot,
|
||||
fridgeState.snapshot(deviceID: fridge.id, rssi: -66),
|
||||
levelState.snapshot(deviceID: level.id, rssi: -70),
|
||||
votronicSolarESPState.snapshot(deviceID: votronicSolar.id, rssi: -58),
|
||||
caravanSnapshot]
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user