kia_uvo
kia_uvo copied to clipboard
Tucson PHEV scheduled charging
Hi, It would be nice to have the charging schedule for a (Tucson) PHEV . reservChargeInfos --> Next departure time (1) offpeakPowerInfo --> Off-peak setting reserveChargeInfo2 --> Next departure time (2)
Full response of Tucson PHEV (EU)
{ "retCode": "S", "resCode": "0000", "resMsg": { "vehicleStatusInfo": { "vehicleLocation": { "coord": { "lat": XX.XXXXX, "lon": X.XXXXX, "alt": 0, "type": 0 }, "head": 189, "speed": { "value": 0, "unit": 0 }, "accuracy": { "hdop": 0, "pdop": 0 }, "time": "20220203155212" }, "vehicleStatus": { "airCtrlOn": False, "engine": False, "doorLock": True, "doorOpen": { "frontLeft": 0, "frontRight": 0, "backLeft": 0, "backRight": 0 }, "trunkOpen": False, "airTemp": { "value": "00H", "unit": 0, "hvacTempType": 1 }, "defrost": False, "lowFuelLight": False, "acc": False, "evStatus": { "batteryCharge": False, "batteryStatus": 100, "batteryPlugin": 2, "remainTime2": { "etc2": { "value": 50, "unit": 1 }, "etc3": { "value": 20, "unit": 1 }, "atc": { "value": 0, "unit": 1 } }, "drvDistance": [{ "rangeByFuel": { "gasModeRange": { "value": 0, "unit": 1 }, "evModeRange": { "value": 0, "unit": 1 }, "totalAvailableRange": { "value": 0, "unit": 1 } }, "type": 2 }], "reservChargeInfos": { "reservChargeInfo": { "reservChargeInfoDetail": { "reservInfo": { "day": [0, 1, 2, 3, 4, 5, 6], "time": { "time": "0900", "timeSection": 0 } }, "reservChargeSet": True } }, "offpeakPowerInfo": { "offPeakPowerTime1": { "starttime": { "time": "0100", "timeSection": 0 }, "endtime": { "time": "0700", "timeSection": 0 } }, "offPeakPowerFlag": 2 }, "reserveChargeInfo2": { "reservChargeInfoDetail": { "reservInfo": { "day": [0, 1, 2, 3, 4, 5, 6], "time": { "time": "1200", "timeSection": 0 } }, "reservChargeSet": False } }, "reservFlag": 1, "ect": { "start": { "day": 0, "time": { "time": "0000", "timeSection": 0 } }, "end": { "day": 0, "time": { "time": "0000", "timeSection": 0 } } } } }, "ign3": False, "hoodOpen": False, "transCond": True, "steerWheelHeat": 0, "sideBackWindowHeat": 0, "tirePressureLamp": { "tirePressureLampAll": 0, "tirePressureLampFL": 0, "tirePressureLampFR": 0, "tirePressureLampRL": 0, "tirePressureLampRR": 0 }, "seatHeaterVentState": { "frSeatHeatState": 2, "flSeatHeatState": 2, "rlSeatHeatState": 2, "rrSeatHeatState": 2 }, "battery": { "batSoc": 89, "batState": 0, "sjbDeliveryMode": 1, "batSignalReferenceValue": { "batWarning": 65 }, "powerAutoCutMode": 2 }, "lampWireStatus": { "stopLamp": { "stopLampStatus": False, "leftLamp": False, "rightLamp": False }, "headLamp": { "headLampStatus": False, "leftLowLamp": False, "rightLowLamp": False, "leftHighLamp": False, "rightHighLamp": False, "leftBifuncLamp": False, "rightBifuncLamp": False }, "turnSignalLamp": { "turnSignalLampStatus": False, "leftFrontLamp": False, "rightFrontLamp": False, "leftRearLamp": False, "rightRearLamp": False } }, "windowOpen": { "frontLeft": 0, "frontRight": 0, "backLeft": 0, "backRight": 0 }, "smartKeyBatteryWarning": False, "fuelLevel": 100, "washerFluidStatus": False, "breakOilStatus": False, "sleepModeCheck": False, "time": "20220203155214", "remoteWaitingTimeAlert": { "remoteControlAvailable": 1, "remoteControlWaitingTime": 168, "elapsedTime": "04:43:02" }, "systemCutOffAlert": 0, "tailLampStatus": 0, "hazardStatus": 0 }, "odometer": { "value": 1801.8, "unit": 1 } } }, "msgId": "XXXXXX-XXXXX-XXXXXX-XXXXXX-XXXXXXXX" }
Are you looking to set this or display?
Are you looking to set this or display?
Both would be nice, since it's constantly changing (resetting itself) without any reason
wow, just found this and realllyyy would like this Scheduled Charging feature. Stupid car is always disabling this.
pm me if testing is needed.
I am interested to hear how people would want this displayed based on the raw data? If possible think about other data types you have seen in HACS as I don't think a string is helpful here. Also interested to see what you would do with the data in automations so that I make it useful.
Could I get screenshots of how you this is shown in the app? May give me clues on how to show it in HACS.
please find below some screenshots from the app
I have done the initial work of mapping this data from the API. https://github.com/Hyundai-Kia-Connect/hyundai_kia_connect_api/pull/204
I don't know how we set though and would need someone to sniff the traffic to figure that out. I am still unsure how to display this in home assistant.
Some items will just be binary sensors (on off) for now and could turn to a switch if we learn to set the schedule. For times I am thinking just text, same with days of the week. Would that help you?
Could you update in hacs and select the version of "master"? It should show 6 new sensors. I haven't added day of the week yet. To start I want to confirm these 6 work and get any feedback you may have on this.
With the master version I get 2 new sensors EV First Scheduled Departure & EV First Scheduled Departure Time (and they are correct)
Could I get the attribute contents of your data sensor? I'm interested to see why the second departure didn't show up.
Could I get the attribute contents of your data sensor? I'm interested to see why the second departure didn't show up.
vehicleLocation: coord: lat: XX.XXXXX lon: XX.XXXXX alt: 0 type: 0 head: 0 speed: value: 0 unit: 0 accuracy: hdop: 0 pdop: 0 time: '20221224143639' vehicleStatus: airCtrlOn: false engine: false doorLock: true doorOpen: frontLeft: 0 frontRight: 0 backLeft: 0 backRight: 0 trunkOpen: false airTemp: value: 00H unit: 0 hvacTempType: 1 defrost: false lowFuelLight: false acc: false evStatus: batteryCharge: false batteryStatus: 99 batteryPlugin: 2 remainTime2: etc2: value: 1 unit: 1 etc3: value: 1 unit: 1 atc: value: 1 unit: 1 drvDistance:
- rangeByFuel: gasModeRange: value: 249 unit: 1 evModeRange: value: 59 unit: 1 totalAvailableRange: value: 308 unit: 1 type: 2 reservChargeInfos: reservChargeInfo: reservChargeInfoDetail: reservInfo: day:
- 0
- 2
- 3
- 4 time: time: '0700' timeSection: 0 reservChargeSet: true offpeakPowerInfo: offPeakPowerTime1: starttime: time: '0200' timeSection: 0 endtime: time: '0500' timeSection: 0 offPeakPowerFlag: 2 reserveChargeInfo2: reservChargeInfoDetail: reservInfo: day:
- 0
- 1
- 2
- 3
- 4
- 5
- 6 time: time: '0100' timeSection: 1 reservChargeSet: true reservFlag: 0 ect: start: day: 0 time: time: '0000' timeSection: 0 end: day: 0 time: time: '0000' timeSection: 0 ign3: true hoodOpen: false transCond: true steerWheelHeat: 0 sideBackWindowHeat: 0 tirePressureLamp: tirePressureLampAll: 0 tirePressureLampFL: 0 tirePressureLampFR: 0 tirePressureLampRL: 0 tirePressureLampRR: 0 seatHeaterVentState: frSeatHeatState: 2 flSeatHeatState: 2 rlSeatHeatState: 2 rrSeatHeatState: 2 battery: batSoc: 82 batState: 0 sjbDeliveryMode: 1 batSignalReferenceValue: batWarning: 65 powerAutoCutMode: 2 lampWireStatus: stopLamp: stopLampStatus: false leftLamp: false rightLamp: false headLamp: headLampStatus: false leftLowLamp: false rightLowLamp: false leftHighLamp: false rightHighLamp: false leftBifuncLamp: false rightBifuncLamp: false turnSignalLamp: turnSignalLampStatus: false leftFrontLamp: false rightFrontLamp: false leftRearLamp: false rightRearLamp: false windowOpen: frontLeft: 0 frontRight: 0 backLeft: 0 backRight: 0 smartKeyBatteryWarning: false fuelLevel: 50 washerFluidStatus: false breakOilStatus: false sleepModeCheck: false time: '20221224143639' remoteWaitingTimeAlert: remoteControlAvailable: 1 remoteControlWaitingTime: 168 elapsedTime: '48:42:08' systemCutOffAlert: 0 tailLampStatus: 0 hazardStatus: 0 odometer: value: 7241.9 unit: 1 Vehicle name TUCSON
Please update to the latest release and let me know results. I found one issue that may have impacted other sensors not showing.
Please update to the latest release and let me know results. I found one issue that may have impacted other sensors not showing.
Updated to 2.3.0, but sensors are the same
vehicleLocation: coord: lat: XX.XXXXX lon: XX.XXXX alt: 0 type: 0 head: 0 speed: value: 0 unit: 0 accuracy: hdop: 0 pdop: 0 time: '20221224165052' vehicleStatus: airCtrlOn: false engine: false doorLock: true doorOpen: frontLeft: 0 frontRight: 0 backLeft: 0 backRight: 0 trunkOpen: false airTemp: value: 00H unit: 0 hvacTempType: 1 defrost: false lowFuelLight: false acc: false evStatus: batteryCharge: false batteryStatus: 99 batteryPlugin: 2 remainTime2: etc2: value: 1 unit: 1 etc3: value: 1 unit: 1 atc: value: 1 unit: 1 drvDistance:
- rangeByFuel: gasModeRange: value: 249 unit: 1 evModeRange: value: 59 unit: 1 totalAvailableRange: value: 308 unit: 1 type: 2 reservChargeInfos: reservChargeInfo: reservChargeInfoDetail: reservInfo: day:
- 0
- 2
- 3
- 4 time: time: '0700' timeSection: 0 reservChargeSet: true offpeakPowerInfo: offPeakPowerTime1: starttime: time: '0200' timeSection: 0 endtime: time: '0500' timeSection: 0 offPeakPowerFlag: 2 reserveChargeInfo2: reservChargeInfoDetail: reservInfo: day:
- 0
- 1
- 2
- 3
- 4
- 5
- 6 time: time: '0100' timeSection: 1 reservChargeSet: true reservFlag: 0 ect: start: day: 0 time: time: '0000' timeSection: 0 end: day: 0 time: time: '0000' timeSection: 0 ign3: true hoodOpen: false transCond: true steerWheelHeat: 0 sideBackWindowHeat: 0 tirePressureLamp: tirePressureLampAll: 0 tirePressureLampFL: 0 tirePressureLampFR: 0 tirePressureLampRL: 0 tirePressureLampRR: 0 seatHeaterVentState: frSeatHeatState: 2 flSeatHeatState: 2 rlSeatHeatState: 2 rrSeatHeatState: 2 battery: batSoc: 82 batState: 0 sjbDeliveryMode: 1 batSignalReferenceValue: batWarning: 65 powerAutoCutMode: 2 lampWireStatus: stopLamp: stopLampStatus: false leftLamp: false rightLamp: false headLamp: headLampStatus: false leftLowLamp: false rightLowLamp: false leftHighLamp: false rightHighLamp: false leftBifuncLamp: false rightBifuncLamp: false turnSignalLamp: turnSignalLampStatus: false leftFrontLamp: false rightFrontLamp: false leftRearLamp: false rightRearLamp: false windowOpen: frontLeft: 0 frontRight: 0 backLeft: 0 backRight: 0 smartKeyBatteryWarning: false fuelLevel: 50 washerFluidStatus: false breakOilStatus: false sleepModeCheck: false time: '20221224165050' remoteWaitingTimeAlert: remoteControlAvailable: 1 remoteControlWaitingTime: 168 elapsedTime: '50:56:20' systemCutOffAlert: 0 tailLampStatus: 0 hazardStatus: 0 odometer: value: 7241.9 unit: 1 Vehicle name TUCSON
Found some of the issues. They spell words different for the second charge and also I had a mistake on off peak. https://github.com/Hyundai-Kia-Connect/hyundai_kia_connect_api/pull/211 Please try again with the latest from "master"
I can confirm, I have the new sensors now
Could you test out data from the afternoon and see what it does? I may need logs or you to roll back. Have another issue opened where the data is 1270 for time in the api but the app shows 1:10 so almost looks like they handle pm times strangely.
My "EV Second Scheduled Depature Time" shows 01:00:00, this should be 13:00:00 Will test some more pm times later today
Also the other sensors are incorrect, the show for example 03:00:00 instead of 15:00:00
https://github.com/Hyundai-Kia-Connect/hyundai_kia_connect_api/pull/214
If you update from "Master" in HACS the PM issue should be solved.
Tested with master and can confirm the PM issue is solved.