hillaliy / homebridge-midea-air

Homebridge plugin for Midea units
MIT License
71 stars 23 forks source link

Setting keeps reverting to Celsius #53

Closed ryannowlin closed 2 years ago

ryannowlin commented 2 years ago

After changing setting from Celsius to Farenheit in Homekit app, anytime you adjust the temperature or go to the settings screen, it reverts back to Celsius.

Could we add a config setting for preferred temperature type (C or F)?

hillaliy commented 2 years ago

Hi! Which of this plugin version are you using? The target temperature setter always expects a celsius temperature so i can't preferred temperature type on config.

ryannowlin commented 2 years ago

I am using the latest 1.4.4 build. Also it changes the LED display on the AC unit from F to C anytime I adjust the temp in homekit.

rcenik commented 2 years ago

I am also on 1.4.4 and can confirm I have the same issue as ryannowlin. Other than that this plugin works great.

ctvw commented 2 years ago

Second this, keeps reverting back to C.

taylorwilsdon commented 2 years ago

Another +1 for this, when I modify the setting in the Homekit device preferences it briefly looks like it's going to hold, then reverts. It also changes the temp display in the Midea app and on the device to celsius any time the temperature is changed. This is definitely fixable, I've hacked around it by writing a cron job that periodically fires the command to change back to Fahrenheit on the device so the issue seems to be that either the useFahrenheit hook isn't properly getting passed from the Homekit settings back to the object state, or we need to bake in a call to set Fahrenheit to the Midea API right after the temperature payload (in C) is sent.

This is for OSK-103 Midea U Inverter AC units in my case. I will enable debug mode and dump the output from the Fahrenheit setting calls shortly!

hillaliy commented 2 years ago

I'm using OSK-102 with two units and it's work perfect. I think that the commands is a little bit different with the new models.

taylorwilsdon commented 2 years ago

@hillaliy - here's the debug mode output when I try to update from "Celsius" to "Fahrenheit" in the Hardware Display -> Unit Home config option. No matter what I do, useFahrenheit is always set to: false, so that seems to be the crux of the issue.

[5/12/2022, 3:47:15 PM] [homebridge-midea-air] useFahrenheit is set to: false
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] Target Temperature: 21.5˚C
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] Indoor Temperature is: 20.5˚C
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] Outdoor Temperature is: 23.5˚C
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] Power State is set to: 1
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] Operational Mode is set to: 2
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] Fan Speed is set to: 102
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] Swing Mode is set to: 12
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] Eco Mode is set to: true
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] Turbo Mode is set to: false
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] Full data is: 11000000,1,1010101,1100110,0,0,0,111100,0,10000,100,1011011,1100001,100000,1110000,0,0,0,0,0,0,0,0,11,11101010,100110,0,0,0,0,0,0,0,0,0,0,0,0,0,0
[5/12/2022, 3:47:15 PM] [homebridge-midea-air] [updateValues] Sent update command to: Master Bedroom (30786325803404)

---

[5/12/2022, 3:47:53 PM] [homebridge-midea-air] Updating accessory: Master Bedroom (30786325803404)
[5/12/2022, 3:47:53 PM] [homebridge-midea-air] [updateValues] Header + Command: 90,90,1,16,89,0,32,0,80,0,0,0,169,65,48,9,14,5,20,20,213,50,1,0,0,17,0,0,0,4,2,0,0,1,0,0,0,0,0,0,170,32,172,0,0,0,0,0,0,3,65,129,0,255,3,255,0,2,0,0,0,0,0,0,0,0,0,0,0,0,3,205,156,16,184,113,186,162,129,39,12,160,157,100,102,118,15,154,166
jmluxem commented 2 years ago

This is for OSK-103 Midea U Inverter AC units in my case.

+1 for all the same. I have the OSK-103 Midea U Inverter AC as well, showing this same Celsius-only display. Still troubleshooting my horizontal oscillate also not working.

taylorwilsdon commented 2 years ago

This is for OSK-103 Midea U Inverter AC units in my case.

+1 for all the same. I have the OSK-103 Midea U Inverter AC as well, showing this same Celsius-only display. Still troubleshooting my horizontal oscillate also not working.

Good news is that I can help you with the second problem, the Midea U oscillates vertically (up and down), not horizontally, so you just need to enable the other in the config and disable horizontal to resolve the issue. I wrote a quick fork that sends the “change to f” command after a temp change call is made, but I’d love to get it working without the additional call!

jmluxem commented 2 years ago

+1 for all the same. I have the OSK-103 Midea U Inverter AC as well, showing this same Celsius-only display. Still troubleshooting my horizontal oscillate also not working.

Good news is that I can help you with the second problem, the Midea U oscillates vertically (up and down), not horizontally, so you just need to enable the other in the config and disable horizontal to resolve the issue. I wrote a quick fork that sends the “change to f” command after a temp change call is made, but I’d love to get it working without the additional call!

I thought the same and have tried both, but neither are working from my HomeKit app control. The Midea App GUI states "horizontal swing" so I figured that would be the terminology, but yeah I tried both and neither are working at this point. I'm also trying to find out how to have Eco Mode turned OFF when first powering on the unit.

Also, is the "Change to F" command something easy to implement? I'm interested in trying that. Thanks for the help already!

noltondyer commented 2 years ago

@taylorwilsdon how could I install that fork to get my plug-in to work?

LampeMW commented 2 years ago

@taylorwilsdon how could I install that fork to get my plug-in to work?

I installed it by cloning the repository to my Homebridge server and then using npm to install it.

git clone https://github.com/taylorwilsdon/homebridge-midea-air-osk103

npm install ./homebridge-midea-air-osk103

noltondyer commented 2 years ago

@LampeMW Did you already have the Midea-air plug-in installed? If so, how did you configure it to pull from the osk103 fork? (Sorry if these are stupid questions, I’m brand new to this and trying to learn)

hillaliy commented 2 years ago

Hi i add default use Fahrenheit to config. Version 1.5.0