Kia Uvo Integration

Fixed it, data must be lower case. 1 and 0 must be used, not “1” and “0”; UI is misleading.

Hi all,

Was very happy to discover this integration! I’ve only installed it an hour ago and I have a question about the data retrieved. I see there are a lot of interesting data values that don’t get a sensor automatically created for them.

Can I request that this integration automatically create a few additional sensors? I’m in Canada and have a Hyundai Tucson PHEV. I’ve attached the value from my sensor.tucson_data below.

The extra sensors I’m hoping to get are:

  • SeatHeaterVentInfo
  • WindowOpen {}
  • rangeByFuel:gasModeRange
  • FuelLevel
  • smartKeyBatteryWarning

I’m also wondering about the air_temp value. It shows as 14 in my data, but I’ve set my default climate control to 24C and the current outdoor temperature is -4C - so where is the 14 C coming from?

vehicle_data:
  status:
    lastStatusDate: '20230303051828'
    airCtrlOn: false
    engine: false
    doorLock: false
    doorOpen:
      frontLeft: 0
      frontRight: 0
      backLeft: 0
      backRight: 0
    trunkOpen: false
    airTempUnit: C
    airTemp:
      value: 14
      unit: 0
    defrost: false
    lowFuelLight: false
    acc: false
    evStatus:
      batteryCharge: false
      batteryStatus: 78
      batteryPlugin: 3
      remainTime2:
        etc1:
          value: 65535
          unit: 1
        etc2:
          value: 0
          unit: 1
        etc3:
          value: 0
          unit: 1
        atc:
          value: 0
          unit: 1
      drvDistance:
        - rangeByFuel:
            gasModeRange:
              value: 322
              unit: 1
            evModeRange:
              value: 37
              unit: 1
            totalAvailableRange:
              value: 359
              unit: 1
          type: 2
    hoodOpen: false
    transCond: true
    steerWheelHeat: 0
    sideBackWindowHeat: 0
    dte: {}
    tirePressureLamp:
      tirePressureLampAll: 0
    battery:
      batSoc: 96
      sjbDeliveryMode: 1
      batSignalReferenceValue: {}
    remoteIgnition: true
    seatHeaterVentInfo:
      drvSeatHeatState: 2
      astSeatHeatState: 2
      rlSeatHeatState: 2
      rrSeatHeatState: 2
    sleepModeCheck: true
    lampWireStatus:
      headLamp:
        headLampStatus: false
        leftLowLamp: false
        rightLowLamp: false
        leftHighLamp: false
        rightHighLamp: false
        leftBifuncLamp: false
        rightBifuncLamp: false
      stopLamp:
        leftLamp: false
        rightLamp: false
      turnSignalLamp:
        leftFrontLamp: false
        rightFrontLamp: false
        leftRearLamp: false
        rightRearLamp: false
    windowOpen: {}
    smartKeyBatteryWarning: false
    fuelLevel: 68
    washerFluidStatus: false
    breakOilStatus: false
    vehicleMovementHis: true
    engineRuntime:
      value: 267
      unit: 3
  vehicleLocation:
    head: 264
    coord:
      lat: 43.99999
      lon: -79.99999
      alt: 315
      type: 0
    accuracy:
      hdop: 8
      pdop: 11
    time: '20230303063645'
    speed:
      value: 0
      unit: 0
  service:
    msopServiceOdometer: 5133
    msopServiceOdometerUnit: 1
    mtspServiceDate: '20221011'
    imatServiceOdometer: 13133
    imatServiceOdometerUnit: 1
    mtitServiceDate: '20230411'
    currentOdometer: 6688.3
    currentOdometerUnit: 1
    serviceOdometerDuration: 8000
    serviceDaysDuration: 182
    serviceMonthsThreshold: 6
vehicle_name: Tucson
friendly_name: Tucson Data

If there is a way I can create a sensor myself that displays some of the data points, I’d be very grateful if someone could explain how using the:
drvDistance: - rangeByFuel: gasModeRange: value: 322
from the sensor data above.

Thanks.

So I tried the TOP-post function to Force an update and couldn’t get it to work.

Isn’t it easier to just do:

alias: Update Car info when BT is lost
description: ""
trigger:
  - platform: state
    entity_id:
      - sensor.pixel_6a_bluetooth_connection
      - sensor.sm_g950f_bluetooth_connection
    attribute: connected_paired_devices
    from: KIA
    for:
      hours: 0
      minutes: 0
      seconds: 30
condition: []
action:
  - service: kia_uvo.force_update
    data:
      device_id: <id>
mode: single

Started out with the card from Cromolex, above, and modified it to use the entities I could see for my EV6 Wind w/ Tech Package. Located in the USA so that might change what I can see. I added an “A/C” button, which calls the “start climate” service. However, the air_conditioner state doesn’t change.
Questions:

  • Anybody know where to get a state for the climate?
  • In the USA, can I only get status for the tires as a whole, not individual pressures?
  • Can I get the charging door open/closed status?
  • I would love to have a temp field to modify to set the climate temp.
  • Clicking the icon when the climate is on should make a service call to turn it off. I’ll have to figure out how to get the climate status, first.

Any and all help, suggestions, and criticisms are appreciated.

  - type: state-icon
    tap_action:
      action: call-service
      service: kia_uvo.start_climate
      data:
        duration: 10
        climate: true
        temperature: 72
        defrost: false
        heating: false
    entity: binary_sensor.kevin_ev6_air_conditioner
    style:
      right: 0
      top: 24px
      margin-top: 0px
      transform: initial
      font-size: 1em
      line-height: 2em
      '--paper-item-icon-color': black
  - type: state-label
    entity: binary_sensor.kevin_ev6_air_conditioner
    title: binary_sensor.kevin_ev6_air_conditioner
    style:
      transform: initial
      font-size: 1em
      line-height: 2em
      top: 24px
      right: 30px
      margin-top: 0px
      color: black

kia_uvo_card

Thanks!

Must be related to location API. Most of those seem to work fine in Europe.

  • Anybody know where to get a state for the climate? In Europe I’m getting a working binary_sensor.ev6_air_conditioner
  • In the USA, can I only get status for the tires as a whole, not individual pressures? Working in Europe, 1 sensor for all tires + 1 separate sensor for each.
  • Can I get the charging door open/closed status? I have a working binary_sensor.ev6_ev_charge_port sensor
  • I would love to have a temp field to modify to set the climate temp. A bit more complex, but you could create an helper input_number for the temperature and have the climate action taking the state of the helper as the temperature value.

I haven’t added this integration yet, but I have a question.

I own Kia Niro 2020 HEV (hybrid), European model.

Last year, I went overseas for about a month, and I left my car at home.

From time to time, I checked my car using the Android app “KIA Connect”. It worked for about two weeks and then the app kinda stopped, and told me “it’s to preserve the battery”.

Have you experienced this behavior?

Can we read the battery status of the car using this integration?

Is it going to be the same behavior, refusing to update the entities to preserve car battery?

Honestly, I only want some kind of status update, probably daily to send to my phone that the car is “okay” :joy:

Been running this integration since Tuesday last week and now I can’t refresh my Kia Connect account.
The App just says Network Error and my HA-sessions doesn’t update.

I used the standard intervall of updating and force refreshed maybe twice a day.
Is Kia Connect down or have I been blocked?

Unexpected error fetching kia_uvo data:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 239, in _async_refresh
    self.data = await self._async_update_data()
  File "/config/custom_components/kia_uvo/coordinator.py", line 107, in _async_update_data
    await self.async_check_and_refresh_token()
  File "/config/custom_components/kia_uvo/coordinator.py", line 166, in async_check_and_refresh_token
    await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.10/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.10/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 118, in check_and_refresh_token
    self.initialize()
  File "/usr/local/lib/python3.10/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 62, in initialize
    self.token: Token = self.api.login(self.username, self.password)
  File "/usr/local/lib/python3.10/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 198, in login
    device_id = self._get_device_id(stamp)
  File "/usr/local/lib/python3.10/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 1103, in _get_device_id
    _check_response_for_errors(response)
  File "/usr/local/lib/python3.10/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 104, in _check_response_for_errors
    raise InvalidAPIResponseError()
hyundai_kia_connect_api.exceptions.InvalidAPIResponseError

Mine has been disconnected some of today, maybe Kia are having an issue. It isn’t the first time it’s been down for me.

1 Like

Thanks.
I’m seeing binary_sensor.ev6_air_conditioner, but it doesn’t update when I see that the climate is going in the Kia Access app.
As for the missing sensors, I just don’t see them.
I have no idea how to find any specs for the app API. I will have to leave that to others.

Hi, thanks @anon63427907 to have make this custom integration. It works like a charm for my Kia Niro EV in Canada. I’m relatively new to home assistant, but I was using a similar integration directly in Node red before using this one. In Node-red, I was able to set myself a notification if the command failed for whatever reason. I have not found a way yet for this. Is it possible to do?

Hi, the same happened to me when I left my Soul EV in a parking lot at the airport. It stopped working sooner, after 8-9 days. It makes no sense in an EV where you have plenty of kWh in the traction battery and the DC-DC converter topping up the 12V battery when needed…

1 Like

Since a few days the integration is not working anymore (neither with 2023-03,6 nor with 2023-04.0) .

I see the following:

image

I tried all the troubleshooting tips from the repo, but no success.

I updated to HA 2023.04 a few days ago and I noticed that my Kia UVO integration, which has been working for the past month (since initial installation), suddenly showed entities being unavailable. In Settings, I saw the same dialog as shown in previous post, ie Config Not Ready: “intUserId”.

Eventually I gave up and deleted the integration completely, I even went back and removed the Downloaded integration, then re-downloaded, latest v2.6.1.

On adding the integration, I now get an “Unexpected Exception” when trying to login. I can login to my Kia Account via browser, I can also login via Kia Connect App on my mobile.

  • When I deliberately provide wrong credentials, I see a specific error-message in HA log file (I have enabled DEBUG) saying: hyundai_kia_connect_api.exceptions.AuthenticationError: Login Failed

  • When I provide correct credentials, I see this instead:
    2023-04-06 21:33:44.638 ERROR (MainThread) [custom_components.kia_uvo.config_flow] Unexpected exception
    File “/usr/local/lib/python3.10/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py”, line 203, in login
    File “/usr/local/lib/python3.10/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py”, line 1146, in _get_authorization_code_with_redirect_url
    File “/config/custom_components/kia_uvo/config_flow.py”, line 159, in async_step_user
    File “/config/custom_components/kia_uvo/config_flow.py”, line 63, in validate_input
    File “/usr/local/lib/python3.10/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py”, line 208, in login
    File “/usr/local/lib/python3.10/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py”, line 1239, in _get_authorization_code_with_form

I’m in EU and connect to European Server. I have tried adding PIN as well as not adding PIN. No difference…

Any guidance greatly appreciated.

1 Like

It’s a know issue and reported in the api component repo: https://github.com/Hyundai-Kia-Connect/hyundai_kia_connect_api/issues/309#issuecomment-1496509407

No solution yet unfortunately.

1 Like

Many thanks for the link. I’ll be patient :wink:

Am I the only one having this error. If it can help I am in Canada.

Logger: homeassistant.config_entries
Source: config_entries.py:425
First occurred: 2:42:08 PM (1 occurrences)
Last logged: 2:42:08 PM

Config entry 'Kia Canada [email protected]' for kia_uvo integration not ready yet: Config Not Ready: HTTPSConnectionPool(host='kiaconnect.ca', port=443): Max retries exceeded with url: /tods/api/lgn (Caused by SSLError(SSLError(1, '[SSL: WRONG_SIGNATURE_TYPE] wrong signature type (_ssl.c:997)'))); Retrying in background

It was working fine since a week up to this night.

The EU issue is fixed. The API changed. Canada now has a new issue that is unrelated. I hope to work on that in the next few days.

2 Likes

Anybody use this with Node Red? I can’t seem to get heating/defrost and the other options working correctly.

When they were a simple true/false option it was working, but since it has changed to, I think, 1/2/3/etc I can’t seem to send the data in the right format.

Greetings,
Ioniq 5 Canada here, Integration reporting the 12V car battery is 75% continuously. I have measured the voltage and it is sitting at 12.85V which seems to be much healthier than 75% would indicate.

Earlier today I had the Eco mode throttle mapping update done. Prior to the update the battery was reporting 85%, but after this update it reports 75% continuously.

Any ideas ? Your thoughts appreciated.

Update: it appears the data for the “EV Battery” and the “12V Car Battery” are one and the same.

If you have an I5, would you please verify that you have the correct 12V battery percentage shown.

Today things look normal and battery is reading 99%. I would be very nice to have a numeric value rather than a percentage.

image

type: picture-elements
elements:
  - type: state-icon
    entity: sensor.e_niro_last_updated_at
    style:
      right: 0
      bottom: 0px
      margin-bottom: 0px
      transform: initial
      font-size: 1em
      line-height: 1em
      '--paper-item-icon-color': BLACK
  - type: state-label
    entity: sensor.e_niro_last_updated_at
    style:
      transform: initial
      font-size: 1em
      line-height: 2em
      bottom: 0px
      right: 30px
      margin-bottom: 0px
      color: black
  - type: state-icon
    entity: device_tracker.e_niro_location
    style:
      right: 0
      bottom: 0px
      margin-bottom: 40px
      transform: initial
      font-size: 1em
      line-height: 2em
      '--paper-item-icon-color': black
  - type: state-label
    entity: device_tracker.e_niro_location
    style:
      transform: initial
      font-size: 1em
      line-height: 2em
      bottom: 0px
      right: 30px
      margin-bottom: 40px
      color: black
  - type: state-icon
    entity: sensor.e_niro_odometer
    style:
      right: 0
      bottom: 0px
      margin-bottom: 20px
      transform: initial
      font-size: 1em
      line-height: 2em
      '--paper-item-icon-color': black
  - type: state-label
    entity: sensor.e_niro_odometer
    style:
      transform: initial
      font-size: 1em
      line-height: 2em
      bottom: 0px
      right: 30px
      margin-bottom: 20px
      color: black
  - type: state-icon
    entity: lock.e_niro_door_lock
    style:
      left: 0
      top: 0px
      margin-top: 0px
      transform: initial
      font-size: 1em
      line-height: 2em
      '--paper-item-icon-color': black
  - type: state-label
    entity: lock.e_niro_door_lock
    title: lock.e_niro_door_lock
    style:
      transform: initial
      font-size: 1em
      line-height: 2em
      top: 0px
      left: 30px
      margin-top: 0px
      color: black
  - type: state-icon
    entity: binary_sensor.e_niro_front_left_door
    title: binary_sensor.e_niro_front_left_door
    style:
      left: 0
      top: 0px
      margin-top: 20px
      transform: initial
      font-size: 1em
      line-height: 2em
      '--paper-item-icon-color': black
  - type: state-label
    entity: binary_sensor.e_niro_front_left_door
    title: binary_sensor.e_niro_front_left_door
    style:
      transform: initial
      font-size: 1em
      line-height: 2em
      top: 0px
      left: 30px
      margin-top: 20px
      color: black
  - type: state-icon
    entity: binary_sensor.e_niro_trunk
    style:
      left: 0
      top: 0px
      margin-top: 40px
      transform: initial
      font-size: 1em
      line-height: 2em
      '--paper-item-icon-color': black
  - type: state-label
    entity: binary_sensor.e_niro_trunk
    title: binary_sensor.e_niro_trunk
    style:
      transform: initial
      font-size: 1em
      line-height: 2em
      top: 0px
      left: 30px
      margin-top: 40px
      color: black
  - type: state-icon
    entity: sensor.e_niro_total_driving_range
    style:
      left: 0
      bottom: 0px
      margin-bottom: 0px
      transform: initial
      font-size: 1em
      line-height: 2em
      '--paper-item-icon-color': black
  - type: state-label
    entity: sensor.e_niro_total_driving_range
    title: sensor.e_niro_total_driving_range
    prefix: 'Range: '
    style:
      transform: initial
      font-size: 1em
      line-height: 2em
      bottom: 0px
      left: 30px
      margin-bottom: 0px
      color: black
  - type: state-icon
    entity: sensor.e_niro_ev_battery_level
    style:
      bottom: 20px
      left: 0px
      margin-top: 0px
      transform: initial
      font-size: 1em
      line-height: 2em
      '--paper-item-icon-color': black
  - type: state-label
    entity: sensor.e_niro_ev_battery_level
    style:
      transform: initial
      font-size: 1em
      line-height: 2em
      bottom: 20px
      left: 30px
      margin-top: 0px
      color: black
  - type: state-icon
    entity: binary_sensor.e_niro_ev_battery_plug
    style:
      right: 0
      top: 0px
      margin-top: 0px
      transform: initial
      font-size: 1em
      line-height: 2em
      '--paper-item-icon-color': black
  - type: state-label
    entity: binary_sensor.e_niro_ev_battery_plug
    style:
      transform: initial
      font-size: 1em
      line-height: 2em
      top: 0px
      right: 30px
      margin-top: 0px
      color: black
image: https://pbs.twimg.com/media/EVe-9BhWoAMcfPt.jpg
4 Likes