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

Add dmaker.fan.p45 support #214

Open
VikeDragon opened this issue May 10, 2023 · 15 comments
Open

Add dmaker.fan.p45 support #214

VikeDragon opened this issue May 10, 2023 · 15 comments

Comments

@VikeDragon
Copy link

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.

@slakouz
Copy link

slakouz commented Jun 3, 2023

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

@saraykina
Copy link

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

@nevizhon
Copy link

nevizhon commented Jun 26, 2023

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

@aaastafyev
Copy link

Please add device support. This model is becoming popular.

@griigoriok
Copy link

Please add device support - dmaker.fan.p45

@hpirila
Copy link

hpirila commented Jan 7, 2024

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

@oraichu
Copy link

oraichu commented Jan 13, 2024

Voting for the support of this device also.

@hpirila
Copy link

hpirila commented Jan 14, 2024

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.

@evgenyvolferts
Copy link

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.

@velizarofff
Copy link

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

@inhibitz
Copy link

inhibitz commented Jul 1, 2024

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.

@evgenyvolferts
Copy link

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

image

@inhibitz
Copy link

inhibitz commented Jul 1, 2024

Xiaomi Miot Auto

I apologize. I missed it. :)

@velizarofff
Copy link

@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.

@syssi syssi changed the title Unsupported device found dmaker.fan.p45 Add dmaker.fan.p45 support Aug 14, 2024
@Sungurik
Copy link

Hi! But still would be nice to have it supported in this intergration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests