issue with 0.5 degrees jumps
Closed this issue ยท 6 comments
HI,
thank you so much for this great great script!!!
I just have 1 issue - one of my ACs has 0.5 degrees jumps. how can I solve this??? I tried to put "0.5" in the "precision" but nothing helps....
pleaseeeee advise :)
Yep, you're right. The code is currently assuming natural numbers for the temperature. You will need to change the code on learn.py
to handle 0.5 increments. Perhaps the proper way would be to read the precision from the json file.
I do not plan to implement that myself. I don't need it, and I just shared this code in case it was useful for someone. If you want to give it a try and manage to make it work I would happily accept a PR.
Can you please elaborate regarding if I would want to give it a try? Is it
something to open the py script and just change the text or something
"deeper"? (sorry for the quotation, I'm not familiar with code AT ALL ๐ )
Well, in a nutshell, yes, it's about changing the python script. But if you have no coding knowledge at all it won't be an easy task. But it's nonetheless a perfect starting point to learn!
Using some LLM like ChatGPT to help you with that might work, but I guess you might need some basic understanding about what's happening.
No idea about Alexa, I've never used any of those assistants / smart speakers.
My suggestion would be to reach to the Home Assistant forum (https://community.home-assistant.io/). There's plenty of excellent people on there who might help or even have the solution.
Thank you very much sir, will do! :)
min_temperature = data['minTemperature']
max_temperature = data['maxTemperature']
temp_range = [round(x * 0.5, 1) for x in range(int(min_temperature * 2), int((max_temperature + 0.5) * 2))]
It works with this minor amendment :>
Haven't tested it in HA yet, but it works for learning the IR commands.
Alternatively, you can simply double the min/max range and then halve the units in labeling after the fact.