xiaomi_fan icon indicating copy to clipboard operation
xiaomi_fan copied to clipboard

Add dmaker.fan.p45 support

Open VikeDragon opened this issue 1 year ago • 15 comments

Just tried adding my fan in Home Assistant, getting: "Unsupported device found! dmaker.fan.p45". Are there any plans on implementing it, or some generic way of controlling it, seems that others has got it to work, although not officially supported by your integration, but there are little info on how to.

Thanks in advance.

VikeDragon avatar May 10 '23 16:05 VikeDragon

Today has got same fan and surprised it is a not supported. Please add.

Here is specs: https://home.miot-spec.com/spec?type=urn:miot-spec-v2:device:fan:0000A005:dmaker-p45:1

slakouz avatar Jun 03 '23 15:06 slakouz

тоже жду dmaker.fan.p45 . Добавьте, пожалуйста

saraykina avatar Jun 17 '23 18:06 saraykina

Please add support for this device. It's new, apparently.

nevizhon avatar Jun 26 '23 11:06 nevizhon

Please add device support. This model is becoming popular.

aaastafyev avatar Aug 01 '23 06:08 aaastafyev

Please add device support - dmaker.fan.p45

griigoriok avatar Aug 09 '23 12:08 griigoriok

Voting for this issue fix:

Logger: custom_components.xiaomi_miio_fan.fan Source: custom_components/xiaomi_miio_fan/fan.py:519 Integration: xiaomi_miio_fan (documentation, issues) First occurred: 10:45:20 AM (1 occurrences) Last logged: 10:45:20 AM Unsupported device found! Please create an issue at https://github.com/syssi/xiaomi_fan/issues and provide the following data: dmaker.fan.p45

hpirila avatar Jan 07 '24 03:01 hpirila

Voting for the support of this device also.

oraichu avatar Jan 13 '24 06:01 oraichu

I used this kind of workaround to gain control for Xiomi Tower Fan 2 (p45).

  1. Copy this code

  2. In HA:

docker exec -it homeassistant bash
cd /usr/local/lib/python3.11/site-packages/miio/integrations/fan/dmaker
mv fan_miot.py fan_miot.py.original
vi fan_miot.py

press i paste code press esc esc

:wq!
exit
  1. restart home assistant

  2. Add fan Add Integration Xiaomi Miot Auto Add device using host/token Use token and IP, see instructions for getting token

  3. Your Fan should be integrated now. I was surprised it still works after upgrade to 2024.1.3, even the fan_miot.py is back to old version.

hpirila avatar Jan 14 '24 04:01 hpirila

Workaround by @hpirila haven't worked for me (even after changing python version in path) - I had an error starting the integration. So I tried the following:

docker exec -it homeassistant bash
cd /usr/local/lib/python3.12/site-packages/miio/integrations/fan/dmaker
mdkir bkp
cp fan* ./bkp/
mkdir github
cd github/
wget https://github.com/rytilahti/python-miio/raw/master/miio/integrations/dmaker/fan/fan.py
wget https://github.com/rytilahti/python-miio/raw/master/miio/integrations/dmaker/fan/fan_miot.py
ls -la
cd ..
cp -f ./github/* ./
exit

So, skip the first step, modify the second and follow the other original steps - and now I can control the fan from HA.

evgenyvolferts avatar Jun 24 '24 07:06 evgenyvolferts

Workaround by @hpirila haven't worked for me (even after changing python version in path) - I had an error starting the integration. So I tried the following:

docker exec -it homeassistant bash
cd /usr/local/lib/python3.12/site-packages/miio/integrations/fan/dmaker
mdkir bkp
cp fan* ./bkp/
mkdir github
cd github/
wget https://github.com/rytilahti/python-miio/raw/master/miio/integrations/dmaker/fan/fan.py
wget https://github.com/rytilahti/python-miio/raw/master/miio/integrations/dmaker/fan/fan_miot.py
ls -la
cd ..
cp -f ./github/* ./
exit

So, skip the first step, modify the second and follow the other original steps - and now I can control the fan from HA.

Eugene, hello!

I am a novice HA user, and I couldn't figure out what I need to do. I have HA in supervized mode. I did the following via terminal in HA:

  1. went to /root/homeassistant/custom_components/xiaomi_miio_fan folder
  2. cp -r fan.py fan.old
  3. wget https://github.com/rytilahti/python-miio/raw/master/miio/integrations/dmaker/fan/fan.py
  4. wget https://github.com/rytilahti/python-miio/raw/master/miio/integrations/dmaker/fan/fan_miot.py

After rebooting HA I got the following message: Unable to configure xiaomi_miio_fan fan by adding platform: xiaomi_miio_fan to fan configuration. Please see the documentation for more information on how to configure this integration.

To resolve this issue:

Remove platform: xiaomi_miio_fan from the fan: configuration in the YAML configuration file. Restart Home Assistant. An example of a snippet that should be deleted:

fan:

  • platform: xiaomi_miio_fan

velizarofff avatar Jun 29 '24 00:06 velizarofff

Workaround by @hpirila haven't worked for me (even after changing python version in path) - I had an error starting the integration. So I tried the following:

docker exec -it homeassistant bash
cd /usr/local/lib/python3.12/site-packages/miio/integrations/fan/dmaker
mdkir bkp
cp fan* ./bkp/
mkdir github
cd github/
wget https://github.com/rytilahti/python-miio/raw/master/miio/integrations/dmaker/fan/fan.py
wget https://github.com/rytilahti/python-miio/raw/master/miio/integrations/dmaker/fan/fan_miot.py
ls -la
cd ..
cp -f ./github/* ./
exit

So, skip the first step, modify the second and follow the other original steps - and now I can control the fan from HA.

a dubious decision. I don't have a model p45 from the list displayed Miio.

inhibitz avatar Jul 01 '24 09:07 inhibitz

@inhibitz @velizarofff Guys, you mention Miio integration, but @hpirila and I wrote about "Xiaomi Miot Auto" from HACS

image

evgenyvolferts avatar Jul 01 '24 09:07 evgenyvolferts

Xiaomi Miot Auto

I apologize. I missed it. :)

inhibitz avatar Jul 01 '24 10:07 inhibitz

@inhibitz @velizarofff Guys, you mention Miio integration, but @hpirila and I wrote about "Xiaomi Miot Auto" from HACS

image

Thank you! I just install this addon and it worked without any edits.

velizarofff avatar Jul 01 '24 10:07 velizarofff