Skip to content

Commit

Permalink
Merge branch 'release/0.6.17'
Browse files Browse the repository at this point in the history
  • Loading branch information
syssi committed Dec 19, 2021
2 parents 0138542 + 6bfcfd4 commit 5f7d9cc
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 10 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -451,6 +451,7 @@ This model uses newer MiOT communication protocol.
- `motor_speed`
- `extra_features`
- `ptc` (zhimi.airfresh.va4 only)
- `ntc_temperature` (zhimi.airfresh.va4 only)

### Mi Fresh Air Ventilator (dmaker.airfresh.t2017, dmaker.airfresh.a1)

Expand Down
18 changes: 9 additions & 9 deletions custom_components/xiaomi_miio_airpurifier/fan.py
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,8 @@
ATTR_CO2 = "co2"
ATTR_PTC = "ptc"

ATTR_NTC_TEMPERATURE = "ntc_temperature"

# Air Fresh T2017
ATTR_POWER = "power"
ATTR_PM25 = "pm25"
Expand Down Expand Up @@ -479,12 +481,14 @@
**AVAILABLE_ATTRIBUTES_AIRHUMIDIFIER_COMMON,
ATTR_TARGET_HUMIDITY: "target_humidity",
ATTR_MOTOR_SPEED: "motor_speed",
ATTR_DEPTH: "depth",
ATTR_DEPTH: "depth", # deprecated
ATTR_DRY: "dry",
ATTR_CHILD_LOCK: "child_lock",
ATTR_LED_BRIGHTNESS: "led_brightness",
ATTR_USE_TIME: "use_time",
ATTR_HARDWARE_VERSION: "hardware_version",
ATTR_WATER_LEVEL: "water_level",
ATTR_WATER_TANK_DETACHED: "water_tank_detached",
}

AVAILABLE_ATTRIBUTES_AIRHUMIDIFIER_CA4 = {
Expand Down Expand Up @@ -516,9 +520,7 @@
ATTR_WET_PROTECTION: "wet_protection",
}

AVAILABLE_ATTRIBUTES_AIRHUMIDIFIER_JSQ5 = {
**AVAILABLE_ATTRIBUTES_AIRHUMIDIFIER_MJJSQ
}
AVAILABLE_ATTRIBUTES_AIRHUMIDIFIER_JSQ5 = {**AVAILABLE_ATTRIBUTES_AIRHUMIDIFIER_MJJSQ}

AVAILABLE_ATTRIBUTES_AIRHUMIDIFIER_JSQ = {
**AVAILABLE_ATTRIBUTES_AIRHUMIDIFIER_COMMON,
Expand Down Expand Up @@ -547,7 +549,7 @@
ATTR_EXTRA_FEATURES: "extra_features",
}

AVAILABLE_ATTRIBUTES_AIRFRESH_VA4 = {**AVAILABLE_ATTRIBUTES_AIRFRESH, ATTR_PTC: "ptc"}
AVAILABLE_ATTRIBUTES_AIRFRESH_VA4 = {**AVAILABLE_ATTRIBUTES_AIRFRESH, ATTR_PTC: "ptc", ATTR_NTC_TEMPERATURE: "ntc_temperature"}

AVAILABLE_ATTRIBUTES_AIRFRESH_A1 = {
ATTR_POWER: "power",
Expand Down Expand Up @@ -816,9 +818,7 @@
)

FEATURE_FLAGS_AIRHUMIDIFIER_JSQ5 = (
FEATURE_SET_BUZZER
| FEATURE_SET_LED
| FEATURE_SET_TARGET_HUMIDITY
FEATURE_SET_BUZZER | FEATURE_SET_LED | FEATURE_SET_TARGET_HUMIDITY
)

FEATURE_FLAGS_AIRHUMIDIFIER_JSQ = (
Expand Down Expand Up @@ -1115,7 +1115,7 @@ async def async_setup_platform(hass, config, async_add_entities, discovery_info=
MODEL_AIRHUMIDIFIER_MJJSQ,
MODEL_AIRHUMIDIFIER_JSQ,
MODEL_AIRHUMIDIFIER_JSQ1,
MODEL_AIRHUMIDIFIER_JSQ5
MODEL_AIRHUMIDIFIER_JSQ5,
]:
air_humidifier = AirHumidifierMjjsq(host, token, model=model)
device = XiaomiAirHumidifierMjjsq(name, air_humidifier, model, unique_id)
Expand Down
2 changes: 1 addition & 1 deletion custom_components/xiaomi_miio_airpurifier/manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"domain": "xiaomi_miio_airpurifier",
"name": "Xiaomi Mi Air Purifier, Air Humidifier, Air Fresh and Pedestal Fan Integration",
"version": "0.6.16",
"version": "0.6.17",
"iot_class": "local_polling",
"config_flow": false,
"documentation": "https://github.com/syssi/xiaomi_airpurifier",
Expand Down

0 comments on commit 5f7d9cc

Please sign in to comment.