Code Monkey home page Code Monkey logo

lovelace-air-filter-card's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

lovelace-air-filter-card's Issues

Great Idea - Here is another fan

Nice work.

You can find the basic info to support various models on the home assistant documentation:
https://www.home-assistant.io/integrations/fan.xiaomi_miio/

The following is the details from my fan. I'm guessing it may just work once you accept the pending pull request.

speed_list: Auto, Silent, Favorite
speed: Silent
model: zhimi.airpurifier.mc1
temperature: 22
humidity: 43
aqi: 1
mode: silent
filter_hours_used: 532
filter_life_remaining: 84
favorite_level: 14
child_lock: false
led: true
motor_speed: 184
average_aqi: 1
learn_mode: false
extra_features: 0
turbo_mode_supported: false
button_pressed: power
buzzer: false
filter_rfid_product_id: 0:0:41:30
filter_rfid_tag: 80:5d:c1:22:b6:74:4
filter_type: anti-bacterial
illuminance: 0
friendly_name: Xiaomi Miio Device
supported_features: 1

Xiaomi Mi Air Purifier File "/usr/src/homeassistant/homeassistant/components/xiaomi_miio/fan.py", line 651, in _try_command

Hello. is only 1 thing that does not work .. When I choose mode Strong I get error, change to Strong or Favorite comes the same error

`speed_list:

  • Auto
  • Silent
  • Favorite
    speed: Auto
    model: zhimi.airpurifier.mc1
    temperature: 20.2
    humidity: 36
    aqi: 1
    mode: auto
    filter_hours_used: 1472
    filter_life_remaining: 57
    favorite_level: 8
    child_lock: false
    led: true
    motor_speed: 350
    average_aqi: 3
    learn_mode: false
    extra_features: 0
    turbo_mode_supported: false
    button_pressed: power
    buzzer: false
    filter_rfid_product_id: 'xxxxxxxxxxx'
    filter_rfid_tag: 'xxxxxxxxxxxxxxx'
    filter_type: regular
    illuminance: 0
    friendly_name: Xiaomi Air Purifier 2S
    supported_features: 1
    `

`Loggdetaljer (ERROR)
Logger: homeassistant.components.websocket_api.http.connection.139985340805776
Source: components/system_log/init.py:97
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 7:07:02 (1 occurrences)
Last logged: 7:07:02

not all arguments converted during string formatting
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/xiaomi_miio/fan.py", line 651, in _try_command
partial(func, *args, **kwargs)
File "/usr/local/lib/python3.7/concurrent/futures/thread.py", line 57, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/local/lib/python3.7/site-packages/miio/airpurifier.py", line 448, in set_mode
return self.send("set_mode", [mode.value])
File "/usr/local/lib/python3.7/site-packages/miio/device.py", line 124, in send
return self._protocol.send(command, parameters, retry_count)
File "/usr/local/lib/python3.7/site-packages/miio/miioprotocol.py", line 196, in send
raise DeviceError(error)
miio.exceptions.DeviceError: {'code': -5001, 'message': 'invaild_arg'}

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 130, in handle_call_service`

No icon for idle mode

Hi,

I want to have an Idle button on the card, but no icon was shown.

config:

type: 'custom:air-filter'
entity: fan.xiaomi_air_purifier
modes:
  - Auto
  - Silent
  - Idle
aspect_ratio: '.6'

Annotation 2020-06-30 165101

Information for XiaoMi Air Purifier 2:

speed_list:
  - Auto
  - Silent
  - Favorite
  - Idle

One suggestion, pressing the active button again to switch the device to Idle mode.

Does not display PM2.5

Why doesn't the purifier show me the PM2.5 value?
I can turn it on and off set Auto Silent Strong. only the PM value is undefine.
Przechwytywanie

Status of card in HACS List

Hello,
I see install option every time after installation too.
Probably it is error of HACS new version
BR,
Andrey

Uncaught DOMException error breaks lovelace

Hi,

not sure since when but when air-filter-card's .js is loaded in my setup, it causes this error:
tsrhteshtesheheshrs

Results in breaking several parts of Lovelace UI (doesn't break frontend completely like in #8 ).

Default sample breaks lovelace rendering

When installing this card in a clean lovelace UI using the sample provided, the entire lovelace dashboard stops rendering.

image

config used for the card

`type: 'custom:air-filter'
modes:

  • auto
  • silent
  • Strong
    entity: fan.mi_air_purifier_3h_bedroom
    title: air_filter
    aspect_ratio: '.6'
    `
    lovelace yaml config:

`title: Home
views:

  • badges:
    • entity: binary_sensor.updater
    • entity: binary_sensor.remote_ui
    • entity: person.sjors_robroek
    • entity: sun.sun
      cards:
    • entities:
      • light.living_room_tv
      • light.reading_corner
      • light.bookcase
      • light.television_backlight
      • light.living_room
        title: Light
        type: entities
    • entity: media_player.shield
      type: media-control
    • compact_view: false
      entities:
      • entity: cover.office_curtains
      • entity: cover.bedroom_curtains
      • entity: cover.living_room_curtains
      • entity: cover.living_room_left_curtains
      • entity: cover.living_room_right_curtains
      • entity: cover.balcony_door_curtains
        entity: vacuum.rob
        image: default
        show_header_toggle: false
        title: Blinds
        type: entities
    • type: 'custom:flex-table-card'
      title: Climate
      entities:
      include: fan.mi_air_purifier_*
      columns:
      • data: friendly_name
        name: Device
      • data: temperature
        name: Temperature
      • data: humidity
        name: Humidity
      • data: aqi
        name: AQI
      • data: average_aqi
        name: average AQI
    • type: 'custom:air-filter'
      modes:
      • auto
      • silent
      • Strong
        entity: fan.mi_air_purifier_3h_bedroom
        title: air_filter
        aspect_ratio: '.6'
        `

Suggestion: change to Speed

Hello,
Ive got one xiaomi air purifier 2s and one 3 now. The problem is the model 3 has changed to use numbers instead of string in the mode.. I started to adapt the card and such but got held up with other things.
But looking at the attributes, I am not sure why you picked mode instead of speed?
anyway, here is model 3 attributes:

speed_list: Auto, Silent, Favorite, Fan
speed: Auto
model: zhimi.airpurifier.ma4
temperature: 24.1
humidity: 62
aqi: 1
mode: 0
filter_hours_used: 135
filter_life_remaining: 96
favorite_level: 14
child_lock: true
led: true
motor_speed: 390
average_aqi: 1
purify_volume: 5306
use_time: 486600
buzzer: false
led_brightness: 1
filter_rfid_product_id: 0:0:30:33
filter_rfid_tag: 80:67:b7:da:40:fa:4
filter_type: regular
fan_level: 1
friendly_name: Air purity 3
supported_features: 1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.