]> git.basschouten.com Git - openhab-addons.git/commitdiff
[miio] update zhimi humiddifier ca4 (#10032)
authorMarcel <marcel@verpaalen.com>
Wed, 3 Feb 2021 10:05:03 +0000 (11:05 +0100)
committerGitHub <noreply@github.com>
Wed, 3 Feb 2021 10:05:03 +0000 (11:05 +0100)
https://community.openhab.org/t/zhimi-humidifier-ca4-issue/116009

Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
bundles/org.openhab.binding.miio/README.md
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.humidifier.ca4.json

index 3be986d9fe0b27f4b4e687c0b440797fc82f5e1f..7bf5b5f7772d0c60ebe19fd3c00d6a0f5d795e77 100644 (file)
@@ -4329,12 +4329,12 @@ e.g. `openhab:send actionCommand 'upd_timer["1498595904821", "on"]'` would enabl
 | Channel          | Type    | Description                         | Comment    |
 |------------------|---------|-------------------------------------|------------|
 | power            | Switch  | Power                               |            |
-| mode             | Number  | Mode                                |            |
+| mode             | Number  | Mode - Fan Level                    | Value mapping ["0"="Auto","1"="Silent","2"="Normal","3"="Maximum"] |
 | Fault            | Number  | Humidifier Device Fault             |            |
 | humidity         | Number:Dimensionless | Humidity                            |            |
-| targetHumidity   | Number  | Target Humidity                     |            |
+| targetHumidity   | Number:Dimensionless | Target Humidity                     |            |
 | waterlevel       | Number  | Water Level                         |            |
-| bright           | Dimmer  | LED Brightness                      |            |
+| bright           | Number  | LED Brightness                      | Value mapping ["0"="Dark","1"="Dimmed","2"="Brightest"] |
 | buzzer           | Switch  | Buzzer Status                       |            |
 | dry              | Switch  | Dry                                 |            |
 | usedhours        | Number:Time | Run Time                            |            |
@@ -4343,9 +4343,8 @@ e.g. `openhab:send actionCommand 'upd_timer["1498595904821", "on"]'` would enabl
 | actualmotorspeed | Number  | Actual Motor Speed                  |            |
 | temperature      | Number:Temperature | Temperature                         |            |
 | childlock        | Switch  | Child Lock                          |            |
-| ButtonPressed    | Number  | Button Pressed                      |            |
+| ButtonPressed    | Number  | Button Pressed                      | Value mapping ["0"="none","1"="led","2"="power"] |
 | clean            | Switch  | Clean Mode                          |            |
-| countryCode      | Number  | Country Code                        |            |
 
 ### Smartmi Evaporative Humidifier (<a name="zhimi-humidifier-cb1">zhimi.humidifier.cb1</a>) Channels
 
@@ -9022,12 +9021,12 @@ note: Autogenerated example. Replace the id (humidifier) in the channel with you
 ```
 Group G_humidifier "Smartmi Evaporative Humidifer 2" <status>
 Switch power "Power" (G_humidifier) {channel="miio:basic:humidifier:power"}
-Number mode "Mode" (G_humidifier) {channel="miio:basic:humidifier:mode"}
+Number mode "Mode - Fan Level" (G_humidifier) {channel="miio:basic:humidifier:mode"}
 Number Fault "Humidifier Device Fault" (G_humidifier) {channel="miio:basic:humidifier:Fault"}
 Number:Dimensionless humidity "Humidity" (G_humidifier) {channel="miio:basic:humidifier:humidity"}
-Number targetHumidity "Target Humidity" (G_humidifier) {channel="miio:basic:humidifier:targetHumidity"}
+Number:Dimensionless targetHumidity "Target Humidity" (G_humidifier) {channel="miio:basic:humidifier:targetHumidity"}
 Number waterlevel "Water Level" (G_humidifier) {channel="miio:basic:humidifier:waterlevel"}
-Dimmer bright "LED Brightness" (G_humidifier) {channel="miio:basic:humidifier:bright"}
+Number bright "LED Brightness" (G_humidifier) {channel="miio:basic:humidifier:bright"}
 Switch buzzer "Buzzer Status" (G_humidifier) {channel="miio:basic:humidifier:buzzer"}
 Switch dry "Dry" (G_humidifier) {channel="miio:basic:humidifier:dry"}
 Number:Time usedhours "Run Time" (G_humidifier) {channel="miio:basic:humidifier:usedhours"}
@@ -9038,7 +9037,6 @@ Number:Temperature temperature "Temperature" (G_humidifier) {channel="miio:basic
 Switch childlock "Child Lock" (G_humidifier) {channel="miio:basic:humidifier:childlock"}
 Number ButtonPressed "Button Pressed" (G_humidifier) {channel="miio:basic:humidifier:ButtonPressed"}
 Switch clean "Clean Mode" (G_humidifier) {channel="miio:basic:humidifier:clean"}
-Number countryCode "Country Code" (G_humidifier) {channel="miio:basic:humidifier:countryCode"}
 ```
 
 ### Smartmi Evaporative Humidifier (zhimi.humidifier.cb1) item file lines
index 9f89eab62097165b9c65009340aa5e8debebd8e5..f61da2ae3dc307e61a0d2f4765b2e428806bda73 100644 (file)
@@ -12,7 +12,6 @@
                                "piid": 1,
                                "friendlyName": "Power",
                                "channel": "power",
-                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
                                "property": "mode",
                                "siid": 2,
                                "piid": 5,
-                               "friendlyName": "Mode",
+                               "friendlyName": "Mode - Fan Level",
                                "channel": "mode",
-                               "channelType": "humidifierOperationMode",
                                "type": "Number",
+                               "stateDescription": {
+                                       "options": [
+                                               {
+                                                       "value": "0",
+                                                       "label": "Auto"
+                                               },
+                                               {
+                                                       "value": "1",
+                                                       "label": "Silent"
+                                               },
+                                               {
+                                                       "value": "2",
+                                                       "label": "Normal"
+                                               },
+                                               {
+                                                       "value": "3",
+                                                       "label": "Maximum"
+                                               }
+                                       ]
+                               },
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "actions": [
@@ -44,7 +62,8 @@
                                ],
                                "tags": [
                                        "Control"
-                               ]
+                               ],
+                               "readmeComment": "Value mapping [\"0\"\u003d\"Auto\",\"1\"\u003d\"Silent\",\"2\"\u003d\"Normal\",\"3\"\u003d\"Maximum\"]"
                        },
                        {
                                "property": "fault",
                                "piid": 2,
                                "friendlyName": "Humidifier Device Fault",
                                "channel": "Fault",
-                               "channelType": "miot_uint8",
                                "type": "Number",
+                               "stateDescription": {
+                                       "minimum": 0,
+                                       "maximum": 15,
+                                       "step": 1,
+                                       "pattern": "%.0f",
+                                       "readOnly": true
+                               },
                                "refresh": true,
                                "actions": []
                        },
                                "piid": 6,
                                "friendlyName": "Target Humidity",
                                "channel": "targetHumidity",
-                               "channelType": "humidity",
-                               "type": "Number",
+                               "type": "Number:Dimensionless",
+                               "unit": "percentage",
+                               "stateDescription": {
+                                       "minimum": 30,
+                                       "maximum": 80,
+                                       "step": 1,
+                                       "pattern": "%.0f %unit%"
+                               },
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "actions": [
                                "piid": 7,
                                "friendlyName": "Water Level",
                                "channel": "waterlevel",
-                               "channelType": "waterlevel",
                                "type": "Number",
+                               "stateDescription": {
+                                       "minimum": 0,
+                                       "maximum": 100,
+                                       "step": 1,
+                                       "pattern": "%.0f %%",
+                                       "readOnly": true
+                               },
                                "refresh": true,
                                "transformation": "tankLevel",
                                "ChannelGroup": "Status",
                                "piid": 2,
                                "friendlyName": "LED Brightness",
                                "channel": "bright",
-                               "type": "Dimmer",
+                               "type": "Number",
+                               "stateDescription": {
+                                       "options": [
+                                               {
+                                                       "value": "0",
+                                                       "label": "Dark"
+                                               },
+                                               {
+                                                       "value": "1",
+                                                       "label": "Dimmed"
+                                               },
+                                               {
+                                                       "value": "2",
+                                                       "label": "Brightest"
+                                               }
+                                       ]
+                               },
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "actions": [
                                "tags": [
                                        "Control",
                                        "Light"
-                               ]
+                               ],
+                               "readmeComment": "Value mapping [\"0\"\u003d\"Dark\",\"1\"\u003d\"Dimmed\",\"2\"\u003d\"Brightest\"]"
                        },
                        {
                                "property": "buzzer",
                                "piid": 1,
                                "friendlyName": "Buzzer Status",
                                "channel": "buzzer",
-                               "channelType": "buzzer",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "piid": 8,
                                "friendlyName": "Dry",
                                "channel": "dry",
-                               "channelType": "dry",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "piid": 9,
                                "friendlyName": "Run Time",
                                "channel": "usedhours",
-                               "channelType": "usedhours",
                                "type": "Number:Time",
                                "unit": "hours",
                                "refresh": true,
                                "piid": 3,
                                "friendlyName": "Power Time",
                                "channel": "powerhours",
-                               "channelType": "powerhours",
                                "type": "Number:Time",
                                "unit": "hours",
                                "refresh": true,
                                "piid": 11,
                                "friendlyName": "Target Motor Speed",
                                "channel": "targetmotorspeed",
-                               "channelType": "motorspeed",
                                "type": "Number",
+                               "stateDescription": {
+                                       "minimum": 200,
+                                       "maximum": 2000,
+                                       "step": 10,
+                                       "pattern": "%.0f"
+                               },
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "actions": []
                                "piid": 1,
                                "friendlyName": "Actual Motor Speed",
                                "channel": "actualmotorspeed",
-                               "channelType": "motorspeed",
                                "type": "Number",
+                               "stateDescription": {
+                                       "minimum": 0,
+                                       "maximum": 2000,
+                                       "step": 1,
+                                       "pattern": "%.0f",
+                                       "readOnly": true
+                               },
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "actions": []
                                "type": "Number:Temperature",
                                "unit": "CELCIUS",
                                "stateDescription": {
+                                       "minimum": -40,
+                                       "maximum": 125,
                                        "pattern": "%.1f %unit%",
                                        "readOnly": true
                                },
                                "piid": 1,
                                "friendlyName": "Child Lock",
                                "channel": "childlock",
-                               "channelType": "childlock",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "piid": 10,
                                "friendlyName": "Button Pressed",
                                "channel": "ButtonPressed",
-                               "channelType": "humidifierLastPressedButton",
                                "type": "Number",
+                               "stateDescription": {
+                                       "readOnly": true,
+                                       "options": [
+                                               {
+                                                       "value": "0",
+                                                       "label": "none"
+                                               },
+                                               {
+                                                       "value": "1",
+                                                       "label": "led"
+                                               },
+                                               {
+                                                       "value": "2",
+                                                       "label": "power"
+                                               }
+                                       ]
+                               },
                                "refresh": true,
-                               "actions": []
+                               "actions": [],
+                               "readmeComment": "Value mapping [\"0\"\u003d\"none\",\"1\"\u003d\"led\",\"2\"\u003d\"power\"]"
                        },
                        {
                                "property": "clean",
                                "piid": 5,
                                "friendlyName": "Clean Mode",
                                "channel": "clean",
-                               "channelType": "clean",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
                                                "parameterType": "ONOFFBOOL"
                                        }
                                ]
-                       },
-                       {
-                               "property": "country_code",
-                               "siid": 7,
-                               "piid": 4,
-                               "friendlyName": "Country Code",
-                               "channel": "countryCode",
-                               "channelType": "countryCode",
-                               "type": "Number",
-                               "refresh": true,
-                               "ChannelGroup": "Status",
-                               "actions": [
-                                       {
-                                               "command": "set_properties",
-                                               "parameterType": "NUMBER"
-                                       }
-                               ]
                        }
                ]
        }