WeConnect-python
WeConnect-python copied to clipboard
PreHeater integration
Hi there! :)
i want to control, start and stop my preHeater(German: Standheizung). I can control the preHeater with "We Connect" so i think it should be possible to integrate in your code?
If you need me or my car for debugging or testing send me a pm.
Thanks!!
WeConnect uses a different backend. It needs to be controllable through WeConnect ID App
Could you be so kind and install WeConnect-cli and do a weconnect-cli -vv --selective all get /
for me? I would be interested in the cars capabilities and if you see any warnings in the output already.
Sure, here is the output. I added only the errors. Yesterday my License expiered, i only upgraded the "Security & Service Plus" License today.
Capabilities: 33 items [access] disabling: False (expires 2025-03-14T12:50:00+00:00) [automation] disabling: False (expires 2025-03-14T12:50:00+00:00) [charging] disabling: False (expires 2025-03-14T12:50:00+00:00) [climatisation] disabling: False (expires 2025-03-14T12:50:00+00:00) [dealerAppointment] disabling: True (expires 2030-03-13T10:16:00+00:00) [departureProfiles] disabling: False (expires 2025-03-14T12:50:00+00:00) [departureTimers] disabling: False (expires 2025-03-14T12:50:00+00:00) [destinations] Status: MISSING_LICENSE disabling: False (expires 2023-03-13T10:16:00+00:00) [emergencyCalling] disabling: False (expires 2030-03-13T10:16:00+00:00) [fuelStatus] disabling: False (expires 2025-03-14T12:50:00+00:00) [honkAndFlash] disabling: False (expires 2025-03-14T12:50:00+00:00) [measurements] disabling: False (expires 2025-03-14T12:50:00+00:00) [news] Status: MISSING_LICENSE disabling: False (expires 2023-03-13T10:16:00+00:00) [oilLevelStatus] disabling: False (expires 2025-03-14T12:50:00+00:00) [parkingInformation] Status: MISSING_LICENSE disabling: False (expires 2023-03-13T10:16:00+00:00) [parkingPosition] disabling: False (expires 2025-03-14T12:50:00+00:00) [roadsideAssistant] disabling: False (expires 2030-03-13T10:16:00+00:00) [state] disabling: False (expires 2025-03-14T12:50:00+00:00) [transactionHistoryAntiTheftAlert] disabling: False (expires 2025-03-14T12:50:00+00:00) [transactionHistoryAntiTheftAlertDelete] disabling: False (expires 2025-03-14T12:50:00+00:00) [transactionHistoryHonkFlash] disabling: False (expires 2025-03-14T12:50:00+00:00) [transactionHistoryLockUnlock] disabling: False (expires 2025-03-14T12:50:00+00:00) [tripStatistics] disabling: False (expires 2025-03-14T12:50:00+00:00) [vehicleHealth] disabling: False (expires 2030-03-13T10:16:00+00:00) [vehicleHealthArchive] disabling: False (expires 2030-03-13T10:16:00+00:00) [vehicleHealthInspection] disabling: False (expires 2025-03-14T12:50:00+00:00) [vehicleHealthSettings] disabling: False (expires 2030-03-13T10:16:00+00:00) [vehicleHealthTrigger] disabling: False (expires 2030-03-13T10:16:00+00:00) [vehicleHealthWakeUp] disabling: False (expires 2025-03-14T12:50:00+00:00) [vehicleHealthWarnings] disabling: False (expires 2030-03-13T10:16:00+00:00) [vehicleLights] disabling: False (expires 2025-03-14T12:50:00+00:00) [vehicleWakeUp] disabling: False (expires 2025-03-14T12:50:00+00:00) [vehicleWakeUpTrigger] disabling: False (expires 2025-03-14T12:50:00+00:00)
[automation] Elements: 2 items [climatisationTimer] Error: Error 4104: Bad Gateway info: Looks like your service has expired. Please update your service subscription. timestamp: 2023-03-14 12:58:12+00:00 Timers: 0 items [chargingProfiles] Error: Error 4104: Bad Gateway info: Looks like your service has expired. Please update your service subscription. timestamp: 2023-03-14 12:58:12+00:00 Profiles: 0 items [chargeMode] Error: Error 4105: Bad Gateway info: Upstream service responded with an unexpected status. If the problem persists, please contact our support. timestamp: 2023-03-14 12:58:12+00:00 [vehicleHealthWarnings] Elements: 1 items [warningLights] Error: Error 4103: Not Found info: Upstream service responded with an unexpected status. If the problem persists, please contact our support. timestamp: 2023-03-14 12:58:12+00:00 [oilLevel] Elements: 1 items [oilLevelStatus] Error: Error 4004: Bad Gateway info: Something went wrong. Please try to re-login. If the problem persists, please contact our support. timestamp: 2023-03-14 12:58:12+00:00
Hmmm, unfortunately nothing about preheater
i installed the WeConnect ID App temporary. With this App i can not control my preHeater.
Only with the "We Connect" App i can choose between Climatisation and PreHeater.
is it planned to support the "We Connect Backend" ?
No. I expect the normal WeConnect App to be replaced by the new App some time in the future. I don’t see a reason for VW to maintain two apps.
I have a simualar problem with my tiguan 2018. I guess it's a problem over all platforms :-( I follow and install the weconnect-cli but in every cass of my tries to collect the list data I still run into errors.
like you wrote here (I add only user password) : sudo weconnect-cli -u xxxxxx -p yyyyyy -vv --selective all get
usage: weconnect-cli get [-h] [--format {string,json}] ID weconnect-cli get: error: the following arguments are required: ID
If I add a slash to the command
2023-04-13T13:00:16+0200:INFO:Could not use token from file /tmp/weconnect.token ([Errno 2] No such file or directory: '/tmp/weconnect.token')
2023-04-13T13:00:16+0200:WARNING:Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0xb5856950>: Failed to establish a new connection: [Errno -2] Name or service not known')': /authorize?redirect_uri=weconnect%3A%2F%2Fauthenticated&nonce=91836789237180176351681383616
2023-04-13T13:00:16+0200:WARNING:Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0xb5856ab0>: Failed to establish a new connection: [Errno -2] Name or service not known')': /authorize?redirect_uri=weconnect%3A%2F%2Fauthenticated&nonce=91836789237180176351681383616
Can you share the correct syntax or some other hints for the usage please. A normal login looks like it works.
Many thanks, Christian
Is that the latest version? Can you check with —version
Hi Till, it's weconnect-cli 0.33.4 (using WeConnect-python 0.49.0)
I used the described standardway to install (pip3 install)
Update: I‘m now more than confident that it is possible to make the auxiliary Heater (Standheizung) work. But: I would need someone to give me remote access to his car for testing.
@tillsteinbach i can give you access to my car. when do you want to test?
That is a nice offer, let me prepare everything and then Inlet you know. I need probably an hour where I am allowed to turn things on and off :)
Ok, preparaion is done, I would be ready to test if we can make it work. If you would still be able to share your account please send me an email
can you check again if the preheater is working now?
only got this channels. which should i use to control the preheater?
/vehicles/VV/controls/charging /vehicles/VV/controls/climatisation /vehicles/VV/controls/windowheating /vehicles/VV/controls/honkAndFlash /vehicles/VV/controls/wakeup
caps: [userCapabilities] Elements: 1 items [capabilitiesStatus] Capabilities: 36 items [access] disabling: False (expires 2025-03-14T12:50:00+00:00) [automation] disabling: False (expires 2025-03-14T12:50:00+00:00) [charging] disabling: False (expires 2025-03-14T12:50:00+00:00) [climatisation] disabling: False (expires 2025-03-14T12:50:00+00:00) [dealerAppointment] disabling: True (expires 2030-03-13T10:16:00+00:00) [departureProfiles] disabling: False (expires 2025-03-14T12:50:00+00:00) [destinations] Status: MISSING_LICENSE, LICENSE_EXPIRED disabling: False (expires 2023-03-13T10:16:00+00:00) [destinationsTours] Status: MISSING_LICENSE, LICENSE_EXPIRED disabling: False (expires 2023-03-13T10:16:00+00:00) [emergencyCalling] disabling: False (expires 2030-03-13T10:16:00+00:00) [fuelStatus] disabling: False (expires 2025-03-14T12:50:00+00:00) [honkAndFlash] disabling: False (expires 2025-03-14T12:50:00+00:00) [hybridCarAuxiliaryHeating] disabling: False (expires 2025-03-14T12:50:00+00:00) [hybridCarAuxiliaryHeatingTimers] Status: MISSING_OPERATION disabling: False (expires 2025-03-14T12:50:00+00:00) [measurements] disabling: False (expires 2025-03-14T12:50:00+00:00) [news] Status: MISSING_LICENSE, LICENSE_EXPIRED disabling: False (expires 2023-03-13T10:16:00+00:00) [oilLevelStatus] disabling: False (expires 2025-03-14T12:50:00+00:00) [parkingInformation] Status: MISSING_LICENSE, LICENSE_EXPIRED disabling: False (expires 2023-03-13T10:16:00+00:00) [parkingPosition] disabling: False (expires 2025-03-14T12:50:00+00:00) [roadsideAssistant] disabling: False (expires 2030-03-13T10:16:00+00:00) [state] disabling: False (expires 2025-03-14T12:50:00+00:00) [theftWarning] disabling: False (expires 2025-03-14T12:50:00+00:00) [transactionHistoryAntiTheftAlert] disabling: False (expires 2025-03-14T12:50:00+00:00) [transactionHistoryAntiTheftAlertDelete] disabling: False (expires 2025-03-14T12:50:00+00:00) [transactionHistoryHonkFlash] disabling: False (expires 2025-03-14T12:50:00+00:00) [transactionHistoryLockUnlock] disabling: False (expires 2025-03-14T12:50:00+00:00) [tripStatistics] disabling: False (expires 2025-03-14T12:50:00+00:00) [vehicleHealth] disabling: False (expires 2030-03-13T10:16:00+00:00) [vehicleHealthArchive] disabling: False (expires 2030-03-13T10:16:00+00:00) [vehicleHealthInspection] disabling: False (expires 2025-03-14T12:50:00+00:00) [vehicleHealthSettings] disabling: False (expires 2030-03-13T10:16:00+00:00) [vehicleHealthTrigger] disabling: False (expires 2030-03-13T10:16:00+00:00) [vehicleHealthWakeUp] disabling: False (expires 2025-03-14T12:50:00+00:00) [vehicleHealthWarnings] disabling: False (expires 2030-03-13T10:16:00+00:00) [vehicleLights] disabling: False (expires 2025-03-14T12:50:00+00:00) [vehicleWakeUp] disabling: False (expires 2025-03-14T12:50:00+00:00) [vehicleWakeUpTrigger] disabling: False (expires 2025-03-14T12:50:00+00:00)
VW disabled the "We Conncted" App and i now switched to the "Volkswagen" App. With the "Volkswagen" app i can control now my preHeater like before with "We Connected" App. I installed your Docker Container "weconnect-mqtt" and enabled my preHeater with "Volkswagen" App. Topic: climatisationState change to "unknown climatization state" and heaterSource change to "unknown heater source". If you need my Account to debug the preHeater Messages write me a message. I didnt find any debug logs to send
Found the Debug Logging Option here the Warnings:
WARNING:weconnect:/vehicles/WVWZZZ/domains/climatisation/climatisationSettings: Unknown attribute heaterSource with value automatic
WARNING:weconnect:/vehicles/WVWZZZ/domains/measurements/rangeStatus: Unknown attribute totalRange_km with value 438
WARNING:weconnect:/vehicles/WVWZZZ: Unknown attribute fuelLevelStatus with value {'value': {'carCapturedTimestamp': '2023-11-21T16:14:58Z', 'currentFuelLevel_pct': 79, 'currentSOC_pct': 37, 'primaryEngineType': 'gasoline', 'secondaryEngineType': 'electric', 'carType': 'hybrid'}} in domain measurements
WARNING:weconnect:/vehicles/WVWZZZ/domains/climatisation/climatisationSettings: Unknown attribute heaterSource with value automatic