Show (driving) speed

So currently I have the following working:

type: entity
entity: device_tracker.fold5
name: ' '
icon: mdi:car-speed-limiter
attribute: speed
unit: km/h
state_color: true

This will give me the speed I’m going in (i believe) meters per second, however I would like it to be converted into kilometers per hour.

To achieve this I will need to multiply that number by 3.6.
I also get this error:
Configuration errors detected:

  • Illegal invocation

Can someone point me in the right direction? :slight_smile:

If it is in meters per second, you could create something like a template helper sensor with this as the template:

{{state_attr('device_tracker.fold5', 'speed')|float*3.6}}

As for the Error, do you have more Information or Logs? Is it setup in configuration.yaml or a subfile, or in an automation, dashboard etc.?
Which Integration is this and does it have a way to configure it from UI etc.?

Because just by this I’d assume it is internally and not because of configuration error.
Also, why is the name key empty, this should I think also throw a warning, albeit a different one.

Wow thanks for that, I wasn’t even aware of that function in HA.
Did some googling, and will check if it works tomorrow morning :slight_smile:
As for the error, I deleted that card anyway, so no further need to investigate.

It works :slight_smile:
Only thing i need to figure out now is how to update more frequently.
I’ts between 20 seconds to a minute to update.

Template Sensors will update either if the state changes (device_tracker) or every minute. So it should update as soon as your speed sensor updates.