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

Celcius to Fahrenheit #19

Open
mjackmtl opened this issue Aug 20, 2024 · 1 comment
Open

Celcius to Fahrenheit #19

mjackmtl opened this issue Aug 20, 2024 · 1 comment

Comments

@mjackmtl
Copy link

Hi,

I got this working in HA, thank you!, Just wondering if the temperature could be set into Fahrenheit?

I've tried changing the code but I would assume the data is set to receive in celsius only, would there be any easy way to change it?

image

Mike

@sle118
Copy link

sle118 commented Aug 25, 2024

You could possibly try to change this :

But you would also need to change precision, precision step, etc and provide conversion from F to C here

if (temp >= MIN_TEMP && temp <= MAX_TEMP)

And C to F here

jsonData += "\"temp_in\":\"" + String(currentTempIn) + "\",";

Alternatively, you could also create a helper template that provides temperature in F, but it wouldn't be integrated to the lovelace thermostat

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

2 participants