Hi, can you share the new card with the liquid range and days until service? Thanks
sure. here you go.
elements:
- entity: sensor.g_646_lz_fuel_level
prefix: ''
style:
transform: 'translate(-50%, -50%) scale(1.3, 1.3)'
color: lightgrey
left: 15%
top: 17%
type: state-label
- entity: sensor.car_rangeliquid
prefix: ''
style:
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
color: lightgrey
left: 17%
top: 6%
type: state-label
- entity: sensor.g_646_lz_odometer
prefix: ' '
style:
transform: 'translate(-50%, -50%) scale(1.3, 1.3)'
color: lightgrey
left: 39%
top: 17%
type: state-label
- entity: sensor.car_service_days
prefix: ' '
style:
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
color: lightgrey
left: 45%
top: 6%
type: state-label
- entity: sensor.car_window_sunroof
style:
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
'--paper-item-icon-color': null
left: 57%
top: 17.5%
type: state-icon
- entity: binary_sensor.g_646_lz_tire_warning
prefix: ''
style:
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
color: '#FFFFFF'
left: 66.5%
top: 17.5%
type: state-icon
- entity: binary_sensor.g_646_lz_low_brake_fluid_warning
prefix: ''
style:
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
color: '#FFFFFF'
left: 76%
top: 17.5%
type: state-icon
- entity: binary_sensor.g_646_lz_low_coolant_level_warning
prefix: ''
style:
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
color: '#FFFFFF'
left: 85.5%
top: 17.5%
type: state-icon
- entity: binary_sensor.g_646_lz_low_wash_water_warning
prefix: ''
style:
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
color: '#FFFFFF'
left: 95%
top: 17.5%
type: state-icon
- entity: sensor.car_tire_pressure_front_right
style:
transform: 'translate(-50%, -50%) scale(0.8, 0.8)'
color: lightgrey
left: 38%
top: 32%
type: state-label
- entity: sensor.car_tire_pressure_rear_right
style:
transform: 'translate(-50%, -50%) scale(0.8, 0.8)'
color: lightgrey
left: 84%
top: 32%
type: state-label
- entity: sensor.car_tire_pressure_front_left
style:
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
color: lightgrey
left: 38%
top: 90%
type: state-label
- entity: sensor.car_tire_pressure_rear_left
style:
transform: 'translate(-50%, -50%) scale(0.8, 0.8)'
color: lightgrey
left: 84%
top: 90%
type: state-label
- entity: sensor.car_lock_front_right
style:
'--paper-item-icon-color': white
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
left: 61%
top: 38%
type: state-icon
- entity: sensor.car_lock_rear_right
style:
'--paper-item-icon-color': white
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
left: 68%
top: 38%
type: state-icon
- entity: sensor.car_lock_front_left
style:
'--paper-item-icon-color': white
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
left: 61%
top: 83%
type: state-icon
- entity: sensor.car_lock_rear_left
style:
'--paper-item-icon-color': white
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
left: 68%
top: 83%
type: state-icon
- entity: sensor.car_lock_trunk
style:
'--paper-item-icon-color': white
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
left: 95%
top: 60%
type: state-icon
- entity: sensor.car_window_front_right
style:
'--paper-item-icon-color': lightgrey
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
left: 56%
top: 31%
type: state-icon
- entity: sensor.car_window_rear_right
style:
'--paper-item-icon-color': lightgrey
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
left: 73%
top: 31%
type: state-icon
- entity: sensor.car_window_front_left
style:
'--paper-item-icon-color': lightgrey
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
left: 56%
top: 90%
type: state-icon
- entity: sensor.car_window_rear_left
style:
'--paper-item-icon-color': lightgrey
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
left: 73%
top: 90%
type: state-icon
- entity: binary_sensor.g_646_lz_park_brake_status
prefix: ''
style:
transform: 'translate(-50%, -50%) scale(0.6, 0.6)'
color: '#FFFFFF'
left: 9%
top: 42%
type: state-icon
- entity: binary_sensor.g_646_lz_windows_closed
prefix: ''
style:
transform: 'translate(-50%, -50%) scale(0.6, 0.6)'
color: '#FFFFFF'
left: 9%
top: 52%
type: state-icon
- entity: sensor.my_car_lock_status
prefix: ''
style:
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
color: lightgrey
left: 16.5%
top: 64%
type: state-label
- entity: device_tracker.g_646_lz_device_tracker
prefix: ''
style:
transform: 'translate(-50%, -50%) scale(0.7, 0.7)'
color: lightgrey
left: 10.5%
top: 77%
type: state-label
image: /local/mercnew.png
type: picture-elements
Can you share this card? I’m specially interested in the charging information. Thanks
Hi.
I have a strange behavior with device tracker. I always see my car at home. Yesterday I’ve moved it outside of my garage… but the position was indicating home… (I moved about 15 km)…
With Mercedes me application I saw the right position.
Any idea? Thanks…
Hi,
this is a problem with the underlaying websocket connection. The connection is not very stable currently. Restart HA and then it should work again. I will rework this part over the weekend.
BR
Rene
Here we go, it is picture-elements of course. Since the sensor names contain the registration number, the names have been altered. German labels.
- type: picture-elements
image: "/local/lovelace/mercedes.jpg"
elements:
- type: icon
icon: mdi:gas-station
style:
# Positioning of the element
left: 73%
top: 5%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_liquid_range_critical
prefix: "Warnung Benzinreserve: "
style:
# Positioning of the element
left: 75%
top: 5%
color: black
max-width: 1px
- type: icon
icon: mdi:car-brake-alert
style:
# Positioning of the element
left: 73%
top: 10%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_low_brake_fluid_warning
prefix: "Warnung Bremsflüssigkeit: "
style:
# Positioning of the element
left: 75%
top: 10%
color: black
max-width: 1px
- type: icon
icon: mdi:car-coolant-level
style:
# Positioning of the element
left: 73%
top: 15%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_low_coolant_level_warning
prefix: "Warnung Kühlflüssigkeit: "
style:
# Positioning of the element
left: 75%
top: 15%
color: black
max-width: 1px
- type: icon
icon: mdi:wiper-wash
style:
# Positioning of the element
left: 73%
top: 20%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_low_wash_water_warning
prefix: "Warnung Wischwasser: "
style:
# Positioning of the element
left: 75%
top: 20%
color: black
max-width: 1px
- type: icon
icon: mdi:car-tire-alert
style:
# Positioning of the element
left: 73%
top: 25%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_tire_warning
prefix: "Warnung Reifendruck: "
style:
# Positioning of the element
left: 75%
top: 25%
color: black
max-width: 1px
- type: icon
icon: mdi:car-cog
style:
# Positioning of the element
left: 73%
top: 30%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_odometer
prefix: "Service in "
attribute: serviceintervaldays
suffix: " Tagen"
style:
# Positioning of the element
left: 75%
top: 30%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_tire_warning
suffix: " kPa"
attribute: tirepressureFrontLeft
style:
# Positioning of the element
left: 34%
top: 20%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_tire_warning
suffix: " kPa"
attribute: tirepressureFrontRight
style:
# Positioning of the element
left: 60%
top: 20%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_tire_warning
suffix: " kPa"
attribute: tirepressureRearLeft
style:
# Positioning of the element
left: 34%
top: 75%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_tire_warning
suffix: " kPa"
attribute: tirepressureRearRight
style:
# Positioning of the element
left: 60%
top: 75%
color: black
max-width: 1px
- type: icon
icon: mdi:car-door-lock
style:
# Positioning of the element
left: 3%
top: 5%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_lock2
prefix: "Zentralverriegelung: "
style:
# Positioning of the element
left: 5%
top: 5%
color: black
max-width: 1px
- type: icon
icon: mdi:car-door
style:
# Positioning of the element
left: 3%
top: 10%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_windows_closed
prefix: "Fenster geschlossen: "
style:
# Positioning of the element
left: 5%
top: 10%
color: black
max-width: 1px
- type: icon
icon: mdi:car-brake-parking
style:
# Positioning of the element
left: 3%
top: 15%
color: black
max-width: 1px
- type: state-label
entity: binary_sensor.aa_a_1234e_park_brake_status
prefix: "Parkbremse: "
style:
# Positioning of the element
left: 5%
top: 15%
color: black
max-width: 1px
- type: icon
icon: mdi:battery-medium
style:
# Positioning of the element
left: 3%
top: 75%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_range_electric
prefix: "Elektrische Reichweite: "
style:
# Positioning of the element
left: 5%
top: 75%
color: black
max-width: 1px
- type: icon
icon: mdi:battery-medium
style:
# Positioning of the element
left: 3%
top: 80%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_range_electric
prefix: "Batteriefüllstand: "
attribute: soc
suffix: "%"
style:
# Positioning of the element
left: 5%
top: 80%
color: black
max-width: 1px
- type: icon
icon: mdi:water
style:
# Positioning of the element
left: 3%
top: 85%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_odometer
prefix: "Diesel Reichweite: "
attribute: rangeliquid
suffix: " km"
style:
# Positioning of the element
left: 5%
top: 85%
color: black
max-width: 1px
- type: icon
icon: mdi:water-percent
style:
# Positioning of the element
left: 3%
top: 90%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_odometer
prefix: "Diesel Tank: "
attribute: tanklevelpercent
suffix: "%"
style:
# Positioning of the element
left: 5%
top: 90%
color: black
max-width: 1px
- type: icon
icon: mdi:water-percent
style:
# Positioning of the element
left: 3%
top: 95%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_odometer
prefix: "AdBlue Tank: "
attribute: tankLevelAdBlue
suffix: "%"
style:
# Positioning of the element
left: 5%
top: 95%
color: black
max-width: 1px
- type: icon
icon: mdi:counter
style:
# Positioning of the element
left: 73%
top: 80%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_odometer
prefix: "Gesamt: "
style:
# Positioning of the element
left: 75%
top: 80%
color: black
max-width: 1px
- type: icon
icon: mdi:car-electric
style:
# Positioning of the element
left: 73%
top: 85%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_odometer
prefix: "Elektrisch: "
attribute: distanceZEReset
suffix: " km"
style:
# Positioning of the element
left: 75%
top: 85%
color: black
max-width: 1px
- type: icon
icon: mdi:water
style:
# Positioning of the element
left: 73%
top: 90%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_odometer
prefix: "Diesel: "
attribute: liquidconsumptionreset
suffix: " l/100km"
style:
# Positioning of the element
left: 75%
top: 90%
color: black
max-width: 1px
- type: icon
icon: mdi:battery-medium
style:
# Positioning of the element
left: 73%
top: 95%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_range_electric
prefix: "Elektrisch: "
attribute: electricconsumptionreset
suffix: " kWh/100km"
style:
# Positioning of the element
left: 75%
top: 95%
color: black
max-width: 1px
# Start of Charging switch / sensors
- type: state-icon
entity: switch.c300de
icon: mdi:ev-station
tap_action:
action: toggle
style:
# Positioning of the element
left: 3%
top: 45%
color: black
max-width: 1px
height: 60px
width: 60px
--mdc-icon-size: 100px
- type: conditional
conditions:
- entity: switch.c300de
state: 'on'
elements:
- type: state-badge
entity: sensor.c300de_remaining
style:
# Positioning of the element
left: 9%
top: 50%
max-width: 1px
- type: state-badge
entity: sensor.c300de_energy
style:
# Positioning of the element
left: 15%
top: 50%
max-width: 1px
- type: state-badge
entity: sensor.c300de_temperature
style:
# Positioning of the element
left: 21%
top: 50%
max-width: 1px
- type: conditional
conditions:
- entity: sensor.c300de_energy
state_not: '0'
- entity: sensor.c300de_energy
state_not: '2'
elements:
- type: icon
icon: mdi:ev-station
style:
# Positioning of the element
left: 3%
top: 70%
color: black
max-width: 1px
- type: state-label
entity: sensor.aa_a_1234e_charging
style:
# Positioning of the element
left: 5%
top: 70%
color: black
max-width: 1px
- type: state-label
entity: sensor.c300de_lastupdated
prefix: "Letzte Aktualisierung: "
style:
# Positioning of the element
left: 50%
top: 2%
color: black
font-size: 50%
Nodered flow that calculates the charging end time (updates every 15 seconds):
[{"id":"7b313be7.3a45a4","type":"poll-state","z":"ba901ebf.b2a9a","name":"","server":"2b393d9c.07d642","version":1,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"updateinterval":"15","updateIntervalUnits":"seconds","outputinitially":true,"outputonchanged":false,"entity_id":"sensor.aa_a_1234e_range_electric","state_type":"str","halt_if":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"x":310,"y":80,"wires":[["8b5e6096.72eba"]]},{"id":"8b5e6096.72eba","type":"function","z":"ba901ebf.b2a9a","name":"","func":"var charge = parseInt(msg.data.attributes.soc);\n\nvar remaining = 100 - charge;\nif(remaining == 0) {\n msg.payload = \"--:--\";\n return msg;\n}\n\nvar millis = parseInt(msg.data.attributes.endofchargetime) * 1000;\nvar t = new Date(msg.data.last_updated);\nvar end = new Date(t.getTime()+millis);\n\nvar datetext = end.toTimeString().split(' ')[0].substring(0,5);\nmsg.payload = datetext;\n\nreturn msg;\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","x":680,"y":120,"wires":[["b277e884.7f1fd8"]]},{"id":"b277e884.7f1fd8","type":"mqtt out","z":"ba901ebf.b2a9a","name":"","topic":"mercedes/remaining","qos":"","retain":"","broker":"abbee078.98f9f","x":1020,"y":180,"wires":[]},{"id":"2b393d9c.07d642","type":"server","name":"Home Assistant","legacy":false,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":false,"cacheJson":true},{"id":"abbee078.98f9f","type":"mqtt-broker","name":"","broker":"192.168.a.b","port":"1883","clientid":"","usetls":false,"compatmode":false,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","closeTopic":"","closeQos":"0","closePayload":"","willTopic":"","willQos":"0","willPayload":""}]
Dear all,
great stuff this updated Integration!
Does anyone know how to use / start the components
- Lock
- Remote Start Switch
- Aux Heat Switch
???
Thanks a lot for your help!
Hi @jjmkimera,
these functions are not available currently. However I’m working on it, but first I have to fix the websocket stability.
BR
Rene
Hello Rene,
I ran the provided image curl (after restarting) and the image.zip file threw an unzip error “End-of-central-directory signature not found”. Thoughts?
Randy
What do you see, when you open the zip file in a text editor?
Ahhhh. So simple
{“code”:401,“message”:“invalid token”}
I’m fairly certain I have the pathway correct. Just fyi. I’m still using the original component as it still works in the US. At least for me.
The image code works with the new component and in europe only. For the US the URL could be https://vhs.meapp-an.secure.mercedes-benz.com/v1/vehicle/XXX-VIN-XXX/topviewimage … I have not tested this.
Thank you for looking at it. I tried that URL just for kicks with similar results. It doesn’t like the access token.
I ended up using the screenshot method.
Hi,
I have updated the component and hopefully the websocket connection is much more stable now. Feeback is very welcome. Based on my test the server closes the connection after ~200 minutes. Now the component reconnects automatically.
As a small consolation, I added the first service “Unlock_Car”. Please setup your PIN in the Android/IOS app first and then add the Pin in the options dialog of the component (under Home Assistant/Config/Integrations). Please keep in mind that this will work only if the unlock option is available in your Android/IOS app too.
here a button card configuration to integrate the service call in your frontend:
Not sure on how to get the vin? Click on one of your sensors. The vin is visible in the attributes.
First of all, thanks for updating, I am sure the connection will be more stable.
But the unlocking of the doors doesn’t work for me. To rule out, that something with my car is wrong, I tried unlocking it with the MB-App and that worked of course. If you need more details, just ask and I hope I can deliver.
Edit: I am an idiot! Sorry! I forgot to restart HA after putting the PIN into the Integration.
thank you for your great work Rene … all is working but i don’t have the attribute liquidconsumptionstart in odometer sensor. What i’m wrong!? in the app i see the value…i have w177.
I just had a problem getting a doorstatusoverall sensor to work. My problem was, that I wrote DoorStatusOverall and not doorStatusOverall. The way I found this out was that I looked in the messages folder and saw, that I need to make it a lowercase “d”. I now saw, that you have the correct names in your documentation. I took the spelling of the attributes from the lock sensor.
Is it possible for you to have 1 way of writing the attributes in the sensor? Because some only have the first letter uppercase and 2 have every words first letter uppercase. I think the best way to write it, would be like in the messages folder, but any other way is fine too, if it is consistent.
But as I already said in a different post, thank you so much for all your hard work!!!
Hi,
I’m not sure if I understand it right. Here some comments
- I use the same naming style like the delivered data (the naming is not consistent)
- Please do not use the sensor card to get naming. HA is changing the first letter of an attribute from lower to upper-case in this view
- Please use the developer-tools/state page to get the real names of an attribute
BR
Rene
Thanks for the update. Opening the car seems to work as well. However, I do not like to have this PIN in the integration set-up options. Currently the button is on my Dashboard without any check. So disabling for now until someone has a nice way of doing this. great work!
You can take a look on https://github.com/iantrich/restriction-card for now.
I’ll try to implement a lock. Here we should have the option to enter a pin on unlock.
BR
Rene