ConnectedCar Binding myAudi, Volkswagen, VW ID, Skoda, Enyaq, Seat, Ford, WeCharge

Please try again the updated build, there was a bug

0.1 to low or to high?

Do you have a log from the previous version showing a working setup?

Please try updated build and set API Level Climatisation to 1 in the account thing config (save, disable/enable)

I renamed control#maxcurrent to control#setMaxCurrent, please delete thing and re-discover
Then try to 5 / 10 / 13 to the channel

The temperature is correct.

New build with ā€œAPI Level Climatisation to 1ā€ fixes the switch again.

Somehow I still only have:
ā€œSet Max Currentā€

and no
ā€œmaxcurrentā€

Now DoorLock channel works for me after your last fix.

However, I still only get the DoorLock channel detected. I still get the pairing warning that I don’t understand why I get since I have paired it when I bought the car and everythings works in the app.

The debug log contains:

2021-05-20 22:45:33.965 [DEBUG] [nternal.handler.CarNetVehicleHandler] - WVGZZZ5NZLW805555: Adding channel definition for channel control#lock
2021-05-20 22:45:33.965 [DEBUG] [carnet.internal.api.CarNetHttpClient] - HTTP GET https://msg.volkswagen.de/fs-car/bs/rlu/v1/VW/DE/vehicles/WVGZZZ5NZLW805555/actions, data=
2021-05-20 22:45:34.276 [DEBUG] [nternal.handler.CarNetVehicleHandler] - WVGZZZ5NZLW805555: Service rlu_v1 is not available, disable

So the control#lock channel is first created, but then the API returns that my car does not support rlu action? But the channel is still created and I can use it to lock/unlock my Tiguan.
Strange???

Updated binding works well on reading values for VW Passat 2021.

  • Translation to location/parking address responds with NULL
  • status#tempOutside is always xx,95°C; xx changing, but ,95 constant. E.g. 13,95°C from "value":"2871","unit":"dK","textId":"temperature_outside_valid"
    correct calculation, but maybe bad rounding on their reported value.
    If you could deduct only 2731 instead of 2731,5 for conversion, before dividing by ten?
    (alternatively I could show %d in sitemap)
  • lock/unlock not working, although it does in We Connect app, DEBUG log (yes, it stops after the VIN):
2021-05-21 00:39:26.034 [DEBUG] [ng.carnet.internal.api.CarNetApiBase] - WVWZZZ3CZME0xxxxx: Sending action request for rlu_v1.LOCK, reqSecToken=true, contentType=application/vnd.vwg.mbb.RemoteLockUnlock_v1_0_0+xml
2021-05-21 00:39:26.037 [DEBUG] [carnet.internal.api.CarNetHttpClient] - HTTP GET https://mal-1a.prd.ece.vwg-connect.com/api/rolesrights/authorization/v2/vehicles/WVWZZZ3CZME0xxxxx/services/rlu_v1/operations/LOCK/security-pin-auth-requested, data=
2021-05-21 00:39:26.501 [DEBUG] [rnet.internal.api.CarNetTokenManager] - Authenticating SPIN, retires=null
2021-05-21 00:39:26.504 [DEBUG] [carnet.internal.api.CarNetHttpClient] - HTTP POST https://mal-1a.prd.ece.vwg-connect.com/api/rolesrights/authorization/v2/security-pin-auth-completed, data={"securityPinAuthentication":{"securityPin":{"challenge":"ABCDE42350FB65A174976C77B492F9DFFD111299546D4266A0FFE93CB9E49137","securityPinHash":"ABCDE0CAFAC7F2E1619473ABD5A88DAD58B043C761FCDF85164C5E791FA5472F4428F349A91DCF9FA2518D37B011377CC0CACEDE81EE48416B1A2D91B14A2A00"},"securityToken":"abcde3n1fJEsoj57HqgcYwJF5H0oJY4olotpQP2P1a1BThM69HhI7LcFVq054I0gGvN/5+MuY0MkjfGGHLmUCMRdbr1thDxw1C+s37Gs3dLUs9rCXYC3J5wa4kp2D8hfVdzheu5ZKGZLWkUmjuaHCW0cZyM53qPcmNPOtxTTccrKPzkMA+JpYsH2u8F5J2OQSxgtTX1WTh49Gl0Qz00P77oS+GZMlDSdnD7T7kZj6/IEego7lK8vxRAi1rxSAssDYGPgQFsE5ICVE7rbhC6IC6R5QJxv+w/r/EucnbJNs2z+3pdb0p7CGJqAOpFGS2Xzp3Y9rCaFzSmmzSHu3VEuU7yUnu47QatXQWGw1gHSUCXO66GCd7oqFKJr1XBabOszCLF5alNUU+9GDIXZwP4UzWm8hk+4ynSwn4qH/ljipXn5+3QxUkG6OJLUQJU07G1SeNJabk54d1VmLc00MBOYLOVxvNSf7dj1OI5xhrf1RaFiNlszdqPZJ8PCBXwkMgjrYf3J8AaaLj5gJ1AvWPygtLpyMFibxmh9Jh0s8Pygyocdu83upjC8CG7/IZXF3VcS4FjGYISCP6kfOYSqItVCSQ\u003d\u003d"}}
2021-05-21 00:39:26.812 [DEBUG] [rnet.internal.api.CarNetTokenManager] - securityToken granted successful!
2021-05-21 00:39:26.817 [DEBUG] [carnet.internal.api.CarNetHttpClient] - HTTP POST https://fal-3a.prd.eu.dp.vwg-connect.com/fs-car/bs/rlu/v1/VW/DE/vehicles/WVWZZZ3CZME0xxxxx/actions, data=<?xml version="1.0" encoding= "UTF-8" ?><rluAction xmlns="http://audi.de/connect/rlu"><action>lock</action></rluAction>
2021-05-21 00:39:27.143 [INFO ] [nternal.handler.CarNetVehicleHandler] - WVWZZZ3CZME0xxxxx: API Service is not available: 
2021-05-21 00:39:27.146 [WARN ] [nternal.handler.CarNetVehicleHandler] - WVWZZZ3CZME0xxxxx:

repeated with TRACE log, last section here:

2021-05-21 00:48:14.160 [DEBUG] [rnet.internal.api.CarNetTokenManager] - securityToken granted successful!
2021-05-21 00:48:14.162 [DEBUG] [carnet.internal.api.CarNetHttpClient] - HTTP POST https://fal-3a.prd.eu.dp.vwg-connect.com/fs-car/bs/rlu/v1/VW/DE/vehicles/WVWZZZ3CZME0xxxx/actions, data=<?xml version="1.0" encoding= "UTF-8" ?><rluAction xmlns="http://audi.de/connect/rlu"><action>unlock</action></rluAction>
2021-05-21 00:48:14.163 [TRACE] [carnet.internal.api.CarNetHttpClient] -   Headers: 
Accept-Encoding: gzip
User-Agent: okhttp/3.10.0
Accept-Charset: UTF-8
Authorization: Bearer xxxxWQiOiJNQkIwMSIsImFsZyI6IlJTMjU2In0.eyJzY3AiOlsiZmFsIl0sInN1YiI6IlRad0JLcE5KZ2hsWjlKaVpyblowUkk5WmFKNjEiLCJ2ZXIiOiIxIiwiY29yIjoiREUiLCJpc3MiOiJWV0dNQkIwMURFTElWMSIsImNudCI6IjM4NzYxMTM0LTM0ZDAtNDFmMy05YTczLWM0YmU4OGQ3ZDMzNyIsImNjaCI6ImFwcCIsInR5cCI6IkFUIiwic3lzIjoiWElEX0FQUF9WVyIsInN0eXAiOiJUMiIsImF1ZCI6Im1hbC5wcmQuZWNlLnZ3Zy1jb25uZWN0LmNvbSIsInRudCI6IlZXLERFRkFVTFQiLCJleHAiOjE2MjE1NTQ0OTMsImlhdCI6MTYyMTU1MDg5MywicnQtaWQiOiI3MjBmNjIyNS1lZWYyLTQ4MTAtYTYwMS05OTM3ZGJmMjc0ODgiLCJqdGkiOiI5YzNjMmQyYy1kMzNlLTQyZGQtYmRlNy1lYTNlYmI0MzkzYTkifQ.Zdstrn1nzX4nYD0A8cQkMPNkG5c_iRpBmhXs-6cbkEoRil8Z398vqoEcz5GPUjn5PgTWGIc-xmS81ZjEKuDt3larreYdMFcwkjRIAGbdtEl8MAU5yGuyW_ODoDnJ7_6UGY5JHGFEibL1Z_SXAPtedPRZi-XlYDWMblaXrJpFMi6Agyy-GhxWW1JunW4ZeyMvPqOvzZ2yD-imdWJmd_r8ZypSFlRaa6Nw65k6eGA8DXZ42IMidzhJVfYvN3NoOhYuD3Yqg-RHCOJm_-aY15tWsy3RnjuaNIOQunYqDqu0c0fJ7QfOcFJTuTF-sYS9GfUdRFmnraFG_adh996hIH-dOQ
Accept: application/json, application/vnd.vwg.mbb.ChargerAction_v1_0_0+xml,application/vnd.volkswagenag.com-error-v1+xml,application/vnd.vwg.mbb.genericError_v1_0_2+xml,application/vnd.vwg.mbb.RemoteStandheizung_v2_0_0+xml,application/vnd.vwg.mbb.genericError_v1_0_2+xml,application/vnd.vwg.mbb.RemoteLockUnlock_v1_0_0+xml,application/vnd.vwg.mbb.operationList_v3_0_2+xml,application/vnd.vwg.mbb.genericError_v1_0_2+xml,*/*
X-App-Name: eRemote
Host: msg.volkswagen.de
X-App-Version: 5.1.2
Content-Type: application/vnd.vwg.mbb.RemoteLockUnlock_v1_0_0+xml
x-mbbSecToken: xxxxxdn3hetY+h2az1UY2o8vZjz4vv0CY6ssxSxKrdaLolPCDleEDfiI+eNccE6a3HYKeF0c3nI0oj65zrAW+McZKkfTNE6gy9VT01Oa8oI2BJAu/hNli9458qvL2gy4nCvpb9N4X7W8FuazUWy9desx/E5oU5ghz5gzqgcxDwxIP0iYTI/etXeGCMZLdkAFoUHWF7fGDbJjIA1OXhv+oiGpHOpQ9rm/pvhWkRkOqpERw4g56jLFl9/42+JrwvoeOwojE423Kk8jcfdlGQTHs4r6cigmo16HUn24iRnmjqqTIC3fNHHhXTlxajFbtzpwG2nJeItpThFYAvUNANDIj8oZRFhHsLzSeOsZesKKJCVFkma7Ln6uJKk+/K3CxE0RyP10nNrDSMkTYUnn0+uhwMaDCBFj9UYASF/l0p8uQfsn8y2KDwa8RzwpSYJ55K4/v57cEFSiBNxzOof1TQKLzwW/zRoatdTJHLRbydJfbwlyNImlDf4J2ZlO1c01nMGDBeqE9qZBQrPZmDoOSWX38k+n9CEvj/VJCuk/bB6kfA6C8bVGlORF6lcZKG39xr3nRkMQbDkv1VFlNGZxtl0iw==
Content-Length: 121
2021-05-21 00:48:14.552 [TRACE] [carnet.internal.api.CarNetHttpClient] - HTTP Response: {"error":{"errorCode":"RLU.security.9007","description":"MBB Roles and Rights responded: 403 - Forbidden"}}
2021-05-21 00:48:14.554 [TRACE] [carnet.internal.api.CarNetHttpClient] -   Headers: 
x-fault-id: 9fa47afd-f4ae-4d8b-a077-db00fb212964
X-FS-Tracking-ID: efcdfb35-62f9-44c2-9b6b-6ad421e0186c
X-FS-Error-Code: GW403
Content-Type: application/json
Content-Length: 107
Date: Thu, 20 May 2021 22:48:14 GMT
Server: www
2021-05-21 00:48:14.556 [INFO ] [nternal.handler.CarNetVehicleHandler] - WVWZZZ3CZME0xxxx: API Service is not available: 
2021-05-21 00:48:14.557 [WARN ] [nternal.handler.CarNetVehicleHandler] - WVWZZZ3CZME0xxxx: 

Interestingly, VW suddenly reports a decent mileage of 4.2 billion km for my car, while trips still flag correct 4701 km:

2021-05-21 00:59:46.475 [TRACE] [carnet.internal.api.CarNetHttpClient] - HTTP Response: {"StoredVehicleDataResponse":{"vin":"WVWZZZ3CZME0xxxx","vehicleData":{"data": [{"id":"0x0101010001","field": 
----
{"id":"0x0101010002","field": [{"id":"0x0101010002","tsCarSentUtc":"2021-05-20T22:58:46Z","tsCarSent":"2021-05-21T00:58:44","tsCarCaptured":"2021-05-21T00:58:44","tsTssReceivedUtc":"2021-05-20T22:58:46Z","milCarCaptured":0,"milCarSent":0,"value":"4294967295"}]}]}}}
2021-05-21 00:59:46.648 [DEBUG] [.services.CarNetVehicleServiceStatus] - WVWZZZ3CZME0xxxx: KILOMETER_STATUS=4294967295 (channel status#kilometerStatus)
2021-05-21 00:59:46.649 [DEBUG] [.services.CarNetVehicleServiceStatus] - Updading channel carnet:vehicle:VW-weconnect:WVWZZZ3CZME0xxxx:status#kilometerStatus with value 4294967295
2021-05-21 00:59:46.650 [DEBUG] [.services.CarNetVehicleServiceStatus] - WVWZZZ3CZME0xxxx: Updating channel status#kilometerStatus with 4294967295 km

Hi Markus,

links in fine the Audi and shows data. i cant seem to get an update on lock status and is there anyway to implement Miles as and option as the uk doesnt use Kilometers.

thanks again for the good work.

no changes for me. API Level is set to one. App locks/unlocks the car.

carnet.log (12.6 KB)

What does that mean vs. your next statement?

This is what the API returns. Obviously pairing is complete, therefore it might be that it works only for Audi, a different base API endpoint has to be used or sthg like that. Please provide TRACE log extract.

Please provide a full TRACE log of the initialization. Creation of channels is handled dynamically based on API access. If this is rejected (HTTP 403) the channel should not be created. E.g. for my A6 even the App doesn’t show trip statistics and clima control (even the car has it). In other cases the App shows those features, but current implementation of the API call fails.
Keep in mind: !There is NO documentation of the API! All of that is the extract of various other implementations, tril & error etc. Please help with testing or research, this allows to improve the implementation.

Please include the log. In general this requires that the vehicle was reported correctly and requires access to https://nominatim.openstreetmap.org. I added a log entry if the requests fails. Check the log for request url and respnse.

In fact I use the conversion provided by the framework as requested by the review process.

Double temp = getDouble(cs.settings.targetTemperature.content).doubleValue();
BigDecimal bd = new BigDecimal(
     DKELVIN.getConverterToAny(SIUnits.CELSIUS).convert(temp).doubleValue() + 0.1);

However, obviosly this is not exaclt. Maybe I need to replace this by a formula.

This message is shiown on http status 403 (Forbidden). This is also supported by the error message ā€œMBB Roles and Rights responded: 403ā€. As I said, there might be other options, but so far I don’t found more information. Send me a PM with the credentials and I could verify some options. If the Audi App works there must be some other API endpoint, other http header, other XML content for the SOAP request, but we have to find that…

Did you manupulated your odometer? Applied for an award for the longest car distance? :slight_smile:
Maybe the unit is missing? Sometimes I saw that distance was returned in inch (2,54cm). At the end I map the values to the channel, which are returned by the API.

The binding uses UOM (Units of Measurement) and the framework handles conversions. This also means that units and conversions are derived from OH’s Region and langusage settings (see OH system settings). Try to select UK English there, this you bring up values in correct units.

I see that still version 2 format is used. Please try to restart OH, maybe the change in the account config is not applied dynamically (need to check).
We could try several options

  • Use version 1 format
  • Try heaterSource=automatic instead of electric
  • Try the call using the security token (currently without)

It would be best if you could provide me the credendials so I could debug it (send PM).


In general: Please include brand+car model and extract of TRACE log in your posts, I can’t keep in mind who has which car. These things are brand/model specific and I try to a) make it working and then b) find the criteriads to switch between different options. :crazy_face:

Please help with testing or research, this allows to improve the implementation.

Of course we will try to help you out as much as possible, by the way super job that you have done so far in making one binding to rule them all!!! :slight_smile:

I will during the week-end explore more why I only get the DoorLock channel detected, I suspect that it is due to VW using other EP for checking availability, but I will try to investigate that further.

VW Tiguan Petrol 2020

1 Like

updated build (2nd one)

  • changes to the account thing config should now work dynamically
  • I found a syntax error in the payload for startClimatisation
  • Enable Address Lookup moved to thing config and works now

Please delete things and re-discover

Blockquote

updated build

  • Fix: Lock/Unlock for VW - use home region url for security token (could also pos. impacts other actions)
  • Change: Timeout for actions increased to 2min
  • Fix: display correct number of SPIN retries (currently log only)

Hi Markus,

in the newest Build the channel status#parkingBrake is missing at my Audi Q3.

Ralph

@markus7017 I’m getting the same error as @MathiasK with the latest build:

2021-05-23 13:02:48.289 [WARN ] [org.apache.felix.fileinstall ] - Error while starting bundle: file:/usr/share/openhab/addons/org.openhab.binding.carnet-3.1.0-SNAPSHOT.jar
org.osgi.framework.BundleException: Could not resolve module: org.openhab.binding.carnet [287]
Unresolved requirement: Import-Package: javax.measure; version=ā€œ[1.0.0,2.0.0)ā€

    at org.eclipse.osgi.container.Module.start(Module.java:463) ~[org.eclipse.osgi-3.16.200.jar:?]
    at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:440) [org.eclipse.osgi-3.16.200.jar:?]
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1260) [bundleFile:3.6.8]
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1233) [bundleFile:3.6.8]
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520) [bundleFile:3.6.8]
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365) [bundleFile:3.6.8]
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316) [bundleFile:3.6.8]

Openhab version: 3.1.0~S2399-1

crap, there is something wrong when the build system gets its updates. This results in a jar, which has the upcoming 3.1 dependencies, which are not available on a prod inst.

Please try the updated build

Check updated build
Does anybody sees STATE1_SERVICE_FLAP != 0 in the raw data (data point 0x030105000F)

Hi Markus,

Sorry for not replying earlier, after I installed the jar file last week my openhab started to behave weird. Since i’m rather new to openhab i decided to build it up from scratch again, and last night I installed your new CarNet build. Last week i didn’t want to report anything without ruling out I myself screwed up something else, but as soon as I install the CarNet jar file I’m noticing strange behaviour in OpenHab. That strange behavior consists of me losing all the decimal places in other things, i.e. mqtt room temperature 16 instead of 16.256 in the Overview page in the UI. I am also seeing fluctuating readings: 48.0 % charge becomes 0.48 for no clear reason, as well as km range becoming meters. Openhab 3 on Openhabian, 2021 VW e-up! move E 61 E1F (DE-BL33F1).

Parking brake Channel is back again but the value is UNDEF

@RalphSester If I remember correctly the symptom @fregger65 is referring to was exactly the reason why I did the regular ā€œforce vehicle updateā€. Do you see consistent updates?

Yes my data is the same as showed in the audi-app

Yes - but the value is UNDEF

UNDEF means ā€œdata point not availableā€, therefore I want to check if this data point returns meaningful data or can be ignored