Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Temperature in integer #17

Open
landaisbenj opened this issue Jun 28, 2021 · 5 comments
Open

Temperature in integer #17

landaisbenj opened this issue Jun 28, 2021 · 5 comments

Comments

@landaisbenj
Copy link

Hello, i would do that :

binary_sensor:
  - platform: template
    sensors:
      temp_zone_vie:
            unique_id: 4cbf0f03-2f7e-4697-ad20-098a1288f4c9
            friendly_name: "Zone Vie"
            device_class: temperature
            value_template:  "{{state_attr('climate.domicile_zone_vie', 'current_temperature')}}"

It work, but binary_sensor.temp_zone_vie make me a state with "." and no ",".
So i think, some trouble bring me bug.
Look history :
image
isn't a graph like this:
image
And, i can't try to use the stat in node red or other..
I think it's because the value uploaded by airzone need a new format !?

@gabrio79
Copy link

gabrio79 commented Jun 28, 2021

I'm not sure that is a bug (separator is depending on your settings)... but you could try to apply

{{ states('binary_sensor. temp_zone_vie').replace(',','.') }}

@landaisbenj
Copy link
Author

I try but it's break the entity:

image

You talk about what settings ? Aircloud or Home assistant ? Because Home assistant look like be good..

@landaisbenj
Copy link
Author

landaisbenj commented Jun 28, 2021

    temp_zone_vie:
      unique_id: 4cbf0f03-2f7e-4697-ad20-098a1288f4c9
      friendly_name: "Zone Vie"
      device_class: temperature
      value_template:  "{{state_attr('climate.domicile_zone_vie', 'current_temperature').replace(',','.')}}"

image

@gabrio79
Copy link

gabrio79 commented Jun 28, 2021

i think that .replace() doesn't works on state_attr, you need to creata another binary_sensor (ie: temp_zone_vie_wit_point)
something like

temp_zone_vie_wit_point:
      unique_id: 4cbf0f03-2f7e-4697-ad20-098a12s88f4c9
      device_class: temperature
      value_template:  "{{ states('binary_sensor.temp_zone_vie_wit_point').replace(',','\.') }}"

@max13fr
Copy link
Owner

max13fr commented Dec 19, 2021

Hello,

Can you retry with the new version (v1.1.1) ?

@max13fr max13fr closed this as completed Dec 19, 2021
@max13fr max13fr reopened this Dec 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants