]> git.basschouten.com Git - openhab-addons.git/commitdiff
[miio] Allow for custom refresh commands (#8796)
authorMarcel <marcelrv@users.noreply.github.com>
Wed, 21 Oct 2020 21:01:22 +0000 (23:01 +0200)
committerGitHub <noreply@github.com>
Wed, 21 Oct 2020 21:01:22 +0000 (14:01 -0700)
* [miio] Allow for custom refresh commands

Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
49 files changed:
bundles/org.openhab.binding.miio/src/main/java/org/openhab/binding/miio/internal/MiIoHandlerFactory.java
bundles/org.openhab.binding.miio/src/main/java/org/openhab/binding/miio/internal/MiIoSendCommand.java
bundles/org.openhab.binding.miio/src/main/java/org/openhab/binding/miio/internal/basic/MiIoBasicChannel.java
bundles/org.openhab.binding.miio/src/main/java/org/openhab/binding/miio/internal/handler/MiIoBasicHandler.java
bundles/org.openhab.binding.miio/src/main/java/org/openhab/binding/miio/internal/handler/MiIoUnsupportedHandler.java
bundles/org.openhab.binding.miio/src/main/java/org/openhab/binding/miio/internal/transport/MiIoAsyncCommunication.java
bundles/org.openhab.binding.miio/src/main/resources/database/cgllc.airmonitor.b1.json
bundles/org.openhab.binding.miio/src/main/resources/database/cgllc.airmonitor.s1.json
bundles/org.openhab.binding.miio/src/main/resources/database/chuangmi.plug.m1.json
bundles/org.openhab.binding.miio/src/main/resources/database/chuangmi.plug.v1.json
bundles/org.openhab.binding.miio/src/main/resources/database/chuangmi.plug.v2.json
bundles/org.openhab.binding.miio/src/main/resources/database/chuangmi.plug.v3.json
bundles/org.openhab.binding.miio/src/main/resources/database/chuangmi.plug.v3fw.json
bundles/org.openhab.binding.miio/src/main/resources/database/dmaker.airfresh.a1.json
bundles/org.openhab.binding.miio/src/main/resources/database/dmaker.airfresh.t2017.json
bundles/org.openhab.binding.miio/src/main/resources/database/dmaker.fan.p5.json
bundles/org.openhab.binding.miio/src/main/resources/database/dmaker.fan.p8-miot.json
bundles/org.openhab.binding.miio/src/main/resources/database/dmaker.fan.p9-miot.json
bundles/org.openhab.binding.miio/src/main/resources/database/dreame.vacuum.mc1808-miot.json
bundles/org.openhab.binding.miio/src/main/resources/database/philips.light.bceiling1.json
bundles/org.openhab.binding.miio/src/main/resources/database/philips.light.bulb.json
bundles/org.openhab.binding.miio/src/main/resources/database/philips.light.candle.json
bundles/org.openhab.binding.miio/src/main/resources/database/philips.light.cbulb.json
bundles/org.openhab.binding.miio/src/main/resources/database/philips.light.ceiling.json
bundles/org.openhab.binding.miio/src/main/resources/database/philips.light.mono.json
bundles/org.openhab.binding.miio/src/main/resources/database/philips.light.moonlight.json
bundles/org.openhab.binding.miio/src/main/resources/database/philips.light.rwread.json
bundles/org.openhab.binding.miio/src/main/resources/database/philips.light.sread1.json
bundles/org.openhab.binding.miio/src/main/resources/database/viomi.vacuum.v8.json
bundles/org.openhab.binding.miio/src/main/resources/database/xjx.toilet.json
bundles/org.openhab.binding.miio/src/main/resources/database/yeelink.bhf1.json
bundles/org.openhab.binding.miio/src/main/resources/database/yeelink.light.ceiling.json
bundles/org.openhab.binding.miio/src/main/resources/database/yeelink.light.ceiling2.json
bundles/org.openhab.binding.miio/src/main/resources/database/yeelink.light.ceiling4.json
bundles/org.openhab.binding.miio/src/main/resources/database/yeelink.light.color1.json
bundles/org.openhab.binding.miio/src/main/resources/database/yeelink.light.lamp1.json
bundles/org.openhab.binding.miio/src/main/resources/database/yunmi.waterpurifier.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.airmonitor.v1.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.airpurifier.m1.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.airpurifier.v1.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.airpurifier.v6.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.airpurifier.v7.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.fan.sa1.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.fan.v3.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.fan.za4.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.heater.za1.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.humidifier.cb1.json
bundles/org.openhab.binding.miio/src/main/resources/database/zhimi.humidifier.v1.json
bundles/org.openhab.binding.miio/src/main/resources/database/zimi.powerstrip.v2.json

index 058c07310e20d44c9f90bbd17ca978124e19acb3..78099746323b4ca6cfe4229232baf2dbb0047501 100644 (file)
@@ -82,7 +82,7 @@ public class MiIoHandlerFactory extends BaseThingHandlerFactory {
             return new MiIoGenericHandler(thing, miIoDatabaseWatchService);
         }
         if (thingTypeUID.equals(THING_TYPE_BASIC)) {
-            return new MiIoBasicHandler(thing, miIoDatabaseWatchService);
+            return new MiIoBasicHandler(thing, miIoDatabaseWatchService, channelTypeRegistry);
         }
         if (thingTypeUID.equals(THING_TYPE_VACUUM)) {
             return new MiIoVacuumHandler(thing, miIoDatabaseWatchService, cloudConnector, channelTypeRegistry);
index 0ccbd728fe13b998a510e154a046f219720cb1ca..47aa56fb506ad888588f48b281c377c2c8b2b733 100644 (file)
@@ -15,6 +15,7 @@ package org.openhab.binding.miio.internal;
 import org.eclipse.jdt.annotation.NonNullByDefault;
 import org.eclipse.jdt.annotation.Nullable;
 
+import com.google.gson.JsonArray;
 import com.google.gson.JsonElement;
 import com.google.gson.JsonObject;
 
@@ -28,17 +29,17 @@ public class MiIoSendCommand {
 
     private final int id;
     private final MiIoCommand command;
-    private final String commandString;
+    private final JsonObject commandJson;
     private @Nullable JsonObject response;
 
     public void setResponse(JsonObject response) {
         this.response = response;
     }
 
-    public MiIoSendCommand(int id, MiIoCommand command, String commandString) {
+    public MiIoSendCommand(int id, MiIoCommand command, JsonObject fullCommand) {
         this.id = id;
         this.command = command;
-        this.commandString = commandString;
+        this.commandJson = fullCommand;
     }
 
     public int getId() {
@@ -49,8 +50,20 @@ public class MiIoSendCommand {
         return command;
     }
 
+    public JsonObject getCommandJson() {
+        return commandJson;
+    }
+
     public String getCommandString() {
-        return commandString;
+        return commandJson.toString();
+    }
+
+    public String getMethod() {
+        return commandJson.has("method") ? commandJson.get("method").getAsString() : "";
+    }
+
+    public JsonElement getParams() {
+        return commandJson.has("params") ? commandJson.get("params").getAsJsonArray() : new JsonArray();
     }
 
     public JsonObject getResponse() {
index 37c6bfcbee483eef9bc657135671f0b46509bb7c..27b1bf52dae4ae7a47401aa12401362011abb9ec 100644 (file)
@@ -56,6 +56,9 @@ public class MiIoBasicChannel {
     @SerializedName("refresh")
     @Expose
     private @Nullable Boolean refresh;
+    @SerializedName("customRefreshCommand")
+    @Expose
+    private @Nullable String channelCustomRefreshCommand;
     @SerializedName("transformation")
     @Expose
     private @Nullable String transfortmation;
@@ -133,7 +136,7 @@ public class MiIoBasicChannel {
     public String getChannelType() {
         final @Nullable String ct = channelType;
         if (ct == null || ct.isEmpty()) {
-            return BINDING_ID + ":" + getChannel();
+            return "";
         } else {
             return (ct.startsWith("system") ? ct : BINDING_ID + ":" + ct);
         }
@@ -161,6 +164,15 @@ public class MiIoBasicChannel {
         this.refresh = refresh;
     }
 
+    public String getChannelCustomRefreshCommand() {
+        final @Nullable String channelCustomRefreshCommand = this.channelCustomRefreshCommand;
+        return channelCustomRefreshCommand != null ? channelCustomRefreshCommand : "";
+    }
+
+    public void setChannelCustomRefreshCommand(String channelCustomRefreshCommand) {
+        this.channelCustomRefreshCommand = channelCustomRefreshCommand;
+    }
+
     public String getChannelGroup() {
         final @Nullable String channelGroup = this.channelGroup;
         return channelGroup != null ? channelGroup : "";
index 81824519ae4c1d0a5180132968fc9448cba0f635..72068c9d0c660dbd39c3e0f16514ce7cf94480a5 100644 (file)
@@ -50,6 +50,7 @@ import org.openhab.core.thing.ChannelUID;
 import org.openhab.core.thing.Thing;
 import org.openhab.core.thing.binding.builder.ChannelBuilder;
 import org.openhab.core.thing.binding.builder.ThingBuilder;
+import org.openhab.core.thing.type.ChannelTypeRegistry;
 import org.openhab.core.thing.type.ChannelTypeUID;
 import org.openhab.core.types.Command;
 import org.openhab.core.types.RefreshType;
@@ -73,7 +74,6 @@ import com.google.gson.JsonSyntaxException;
  */
 @NonNullByDefault
 public class MiIoBasicHandler extends MiIoAbstractHandler {
-
     private final Logger logger = LoggerFactory.getLogger(MiIoBasicHandler.class);
     private boolean hasChannelStructure;
 
@@ -83,12 +83,16 @@ public class MiIoBasicHandler extends MiIoAbstractHandler {
     });
 
     List<MiIoBasicChannel> refreshList = new ArrayList<>();
+    private Map<String, MiIoBasicChannel> refreshListCustomCommands = new HashMap<>();
 
     private @Nullable MiIoBasicDevice miioDevice;
     private Map<ChannelUID, MiIoBasicChannel> actions = new HashMap<>();
+    private ChannelTypeRegistry channelTypeRegistry;
 
-    public MiIoBasicHandler(Thing thing, MiIoDatabaseWatchService miIoDatabaseWatchService) {
+    public MiIoBasicHandler(Thing thing, MiIoDatabaseWatchService miIoDatabaseWatchService,
+            ChannelTypeRegistry channelTypeRegistry) {
         super(thing, miIoDatabaseWatchService);
+        this.channelTypeRegistry = channelTypeRegistry;
     }
 
     @Override
@@ -97,6 +101,7 @@ public class MiIoBasicHandler extends MiIoAbstractHandler {
         hasChannelStructure = false;
         isIdentified = false;
         refreshList = new ArrayList<>();
+        refreshListCustomCommands = new HashMap<>();
     }
 
     @Override
@@ -259,6 +264,7 @@ public class MiIoBasicHandler extends MiIoAbstractHandler {
             final MiIoBasicDevice midevice = miioDevice;
             if (midevice != null) {
                 refreshProperties(midevice);
+                refreshCustomProperties(midevice);
                 refreshNetwork();
             }
         } catch (Exception e) {
@@ -266,6 +272,12 @@ public class MiIoBasicHandler extends MiIoAbstractHandler {
         }
     }
 
+    private void refreshCustomProperties(MiIoBasicDevice midevice) {
+        for (MiIoBasicChannel miChannel : refreshListCustomCommands.values()) {
+            sendCommand(miChannel.getChannelCustomRefreshCommand());
+        }
+    }
+
     private boolean refreshProperties(MiIoBasicDevice device) {
         MiIoCommand command = MiIoCommand.getCommand(device.getDevice().getPropertyMethod());
         int maxProperties = device.getDevice().getMaxProperties();
@@ -326,7 +338,12 @@ public class MiIoBasicHandler extends MiIoAbstractHandler {
             if (miioDevice != null) {
                 for (MiIoBasicChannel miChannel : miioDevice.getDevice().getChannels()) {
                     if (miChannel.getRefresh()) {
-                        refreshList.add(miChannel);
+                        if (miChannel.getChannelCustomRefreshCommand().isBlank()) {
+                            refreshList.add(miChannel);
+                        } else {
+                            String i = miChannel.getChannelCustomRefreshCommand().split("\\[")[0];
+                            refreshListCustomCommands.put(i.trim(), miChannel);
+                        }
                     }
                 }
             }
@@ -398,7 +415,6 @@ public class MiIoBasicHandler extends MiIoAbstractHandler {
             return null;
         }
         ChannelUID channelUID = new ChannelUID(getThing().getUID(), channel);
-        ChannelTypeUID channelTypeUID = new ChannelTypeUID(channelType);
 
         // TODO: Need to understand if this harms anything. If yes, channel only to be added when not there already.
         // current way allows to have no issues when channels are changing.
@@ -406,9 +422,17 @@ public class MiIoBasicHandler extends MiIoAbstractHandler {
             logger.info("Channel '{}' for thing {} already exist... removing", channel, getThing().getUID());
             thingBuilder.withoutChannel(new ChannelUID(getThing().getUID(), channel));
         }
-        Channel newChannel = ChannelBuilder.create(channelUID, datatype).withType(channelTypeUID)
-                .withLabel(friendlyName).build();
-        thingBuilder.withChannel(newChannel);
+        ChannelBuilder newChannel = ChannelBuilder.create(channelUID, datatype).withLabel(friendlyName);
+        if (!channelType.isBlank()) {
+            ChannelTypeUID channelTypeUID = new ChannelTypeUID(channelType);
+            if (channelTypeRegistry.getChannelType(channelTypeUID) != null) {
+                newChannel = newChannel.withType(channelTypeUID);
+            } else {
+                logger.debug("ChannelType '{}' is not available. Check the Json file for {}", channelTypeUID,
+                        getThing().getUID());
+            }
+        }
+        thingBuilder.withChannel(newChannel.build());
         return channelUID;
     }
 
@@ -528,6 +552,23 @@ public class MiIoBasicHandler extends MiIoAbstractHandler {
                     }
                     break;
                 default:
+                    if (refreshListCustomCommands.containsKey(response.getMethod())) {
+                        logger.debug("Processing custom refresh command response for !{}", response.getMethod());
+                        MiIoBasicChannel ch = refreshListCustomCommands.get(response.getMethod());
+                        if (response.getResult().isJsonArray()) {
+                            JsonArray cmdResponse = response.getResult().getAsJsonArray();
+                            final String transformation = ch.getTransfortmation();
+                            if (transformation == null || transformation.isBlank()) {
+                                updateChannel(ch, ch.getChannel(),
+                                        cmdResponse.get(0).isJsonPrimitive() ? cmdResponse.get(0)
+                                                : new JsonPrimitive(cmdResponse.get(0).toString()));
+                            } else {
+                                updateChannel(ch, ch.getChannel(), cmdResponse);
+                            }
+                        } else {
+                            updateChannel(ch, ch.getChannel(), new JsonPrimitive(response.getResult().toString()));
+                        }
+                    }
                     break;
             }
         } catch (Exception e) {
index 4dfaaf3e8f02e35034ba1d7d525d3c4b1e253008..9862b92e8e9872ac76d5f2daea4e78bd0d56e6b9 100644 (file)
@@ -30,6 +30,7 @@ import java.util.List;
 import java.util.concurrent.TimeUnit;
 
 import org.eclipse.jdt.annotation.NonNullByDefault;
+import org.eclipse.jdt.annotation.Nullable;
 import org.openhab.binding.miio.internal.MiIoBindingConfiguration;
 import org.openhab.binding.miio.internal.MiIoCommand;
 import org.openhab.binding.miio.internal.MiIoDevices;
@@ -170,7 +171,9 @@ public class MiIoUnsupportedHandler extends MiIoAbstractHandler {
         sb.append("Properties: ");
         int lastCommand = -1;
         for (String c : channelList.keySet()) {
-            String cmd = "get_prop[" + c + "]";
+            MiIoBasicChannel ch = channelList.get(c);
+            String cmd = ch.getChannelCustomRefreshCommand().isBlank() ? ("get_prop[" + c + "]")
+                    : ch.getChannelCustomRefreshCommand();
             sb.append(c);
             sb.append(" -> ");
             lastCommand = sendCommand(cmd);
@@ -183,10 +186,13 @@ public class MiIoUnsupportedHandler extends MiIoAbstractHandler {
         logger.info("{}", sb.toString());
     }
 
-    private LinkedHashMap<String, MiIoBasicChannel> collectProperties(String model) {
+    private LinkedHashMap<String, MiIoBasicChannel> collectProperties(@Nullable String model) {
         LinkedHashMap<String, MiIoBasicChannel> testChannelsList = new LinkedHashMap<>();
         LinkedHashSet<MiIoDevices> testDeviceList = new LinkedHashSet<>();
-
+        if (model == null || model.length() < 2) {
+            logger.info("Wait until the model is determined, than try again");
+            return testChannelsList;
+        }
         // first add similar devices to test those channels first, then test all others
         int[] subset = { model.length() - 1, model.lastIndexOf("."), model.indexOf("."), 0 };
         for (int i : subset) {
@@ -203,9 +209,16 @@ public class MiIoUnsupportedHandler extends MiIoAbstractHandler {
         }
         for (MiIoDevices dev : testDeviceList) {
             for (MiIoBasicChannel ch : getBasicChannels(dev.getModel())) {
-                if (!ch.isMiOt() && !ch.getProperty().isBlank() && !testChannelsList.containsKey(ch.getProperty())) {
+                // Add all (unique) properties
+                if (!ch.isMiOt() && !ch.getProperty().isBlank() && ch.getChannelCustomRefreshCommand().isBlank()
+                        && !testChannelsList.containsKey(ch.getProperty())) {
                     testChannelsList.put(ch.getProperty(), ch);
                 }
+                // Add all (unique) custom refresh commands
+                if (!ch.isMiOt() && !ch.getChannelCustomRefreshCommand().isBlank()
+                        && !testChannelsList.containsKey(ch.getChannelCustomRefreshCommand())) {
+                    testChannelsList.put(ch.getChannelCustomRefreshCommand(), ch);
+                }
             }
         }
         return testChannelsList;
index 6720d590358687039e28a881c6bba68bcda42ea6..9fb9ccd32e2fefa2c4fb419b19b19e99fe8b0369 100644 (file)
@@ -143,8 +143,7 @@ public class MiIoAsyncCommunication {
             fullCommand.addProperty("id", cmdId);
             fullCommand.addProperty("method", command);
             fullCommand.add("params", parser.parse(params));
-            MiIoSendCommand sendCmd = new MiIoSendCommand(cmdId, MiIoCommand.getCommand(command),
-                    fullCommand.toString());
+            MiIoSendCommand sendCmd = new MiIoSendCommand(cmdId, MiIoCommand.getCommand(command), fullCommand);
             concurrentLinkedQueue.add(sendCmd);
             if (logger.isDebugEnabled()) {
                 // Obfuscate part of the token to allow sharing of the logfiles
index 6bc6936cc7530c5c165a501f8b5eab90717a7f16..47a3c31494cfd0b11bbebd61bab4dd362414e900 100644 (file)
@@ -20,6 +20,7 @@
                                "property": "pm25",
                                "friendlyName": "PM2.5",
                                "channel": "pm25",
+                               "channelType": "pm25",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -29,6 +30,7 @@
                                "property": "co2e",
                                "friendlyName": "CO2e",
                                "channel": "co2",
+                               "channelType": "co2",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -38,6 +40,7 @@
                                "property": "tvoc",
                                "friendlyName": "tVOC",
                                "channel": "tvoc",
+                               "channelType": "tvoc",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -47,6 +50,7 @@
                                "property": "humidity",
                                "friendlyName": "Humidity",
                                "channel": "humidity",
+                               "channelType": "humidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -56,6 +60,7 @@
                                "property": "temperature",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
index ab1b748e4a257adbfa4a1526b806ca90cf7a5aef..4ad1bc81fb7252fdc766e9539daf9aabea7ed0f7 100644 (file)
@@ -20,6 +20,7 @@
                                "property": "pm25",
                                "friendlyName": "PM2.5",
                                "channel": "pm25",
+                               "channelType": "pm25",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -29,6 +30,7 @@
                                "property": "co2",
                                "friendlyName": "CO2",
                                "channel": "co2",
+                               "channelType": "co2",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -38,6 +40,7 @@
                                "property": "tvoc",
                                "friendlyName": "tVOC",
                                "channel": "tvoc",
+                               "channelType": "tvoc",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -47,6 +50,7 @@
                                "property": "humidity",
                                "friendlyName": "Humidity",
                                "channel": "humidity",
+                               "channelType": "humidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -56,6 +60,7 @@
                                "property": "temperature",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
index 3a83fce4a0cffde55d47122ec86d3f218494363a..1e09d2c03cc186811695786e80ff87f32a3e940d 100644 (file)
@@ -10,6 +10,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -24,6 +25,7 @@
                                "property": "temperature",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -33,6 +35,7 @@
                                "property": "wifi_led",
                                "friendlyName": "Indicator light",
                                "channel": "led",
+                               "channelType": "led",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
index 8ed1dc4ab75b9fdeaa563fb9229c5ba290ea0f49..f9038317e7531b41993e0bd362bc042f5af4cd96 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "on",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -21,6 +22,7 @@
                                "property": "usb_on",
                                "friendlyName": "USB",
                                "channel": "usb",
+                               "channelType": "usb",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
index 64a8a6721ee1d014ebacf46a2f06226c6e1bd7ef..79113a6a61b218cc8655478c54aa08aef2df0981 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -22,6 +23,7 @@
                                "property": "usb_on",
                                "friendlyName": "USB",
                                "channel": "usb",
+                               "channelType": "usb",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
index 8ef70ddc3fbef331ff48b632cd07bdd2f39daf2c..14801d8f9684508e6328ca8d909067549f490e31 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -21,6 +22,7 @@
                                "property": "usb_on",
                                "friendlyName": "USB",
                                "channel": "usb",
+                               "channelType": "usb",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -35,6 +37,7 @@
                                "property": "temperature",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -44,6 +47,7 @@
                                "property": "wifi_led",
                                "friendlyName": "Wifi LED",
                                "channel": "led",
+                               "channelType": "led",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
index 04acd4fc574e2779c55ea7906eb5b4ffccb3d1f5..c3e5f63084655a154d928c644b108db9c623574d 100644 (file)
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
-                               "readmeComment": "If this channel does not respond to on/off replace the model with chuangmi.plug.v3old in the config or upgrade firmware",
                                "actions": [
                                        {
                                                "command": "set_power",
                                                "parameterType": "ONOFF"
                                        }
-                               ]
+                               ],
+                               "readmeComment": "If this channel does not respond to on/off replace the model with chuangmi.plug.v3old in the config or upgrade firmware"
                        },
                        {
                                "property": "usb_on",
                                "friendlyName": "USB",
                                "channel": "usb",
+                               "channelType": "usb",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -40,6 +42,7 @@
                                "property": "temperature",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -49,6 +52,7 @@
                                "property": "wifi_led",
                                "friendlyName": "Wifi LED",
                                "channel": "led",
+                               "channelType": "led",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
index 4cf1123ab702f4a0387a9f021ee539c106e3c542..e21cee069c5e553a09e93ccd49d2350e9590bec1 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -21,6 +22,7 @@
                                "property": "mode",
                                "friendlyName": "Mode",
                                "channel": "airFreshMode",
+                               "channelType": "airFreshMode",
                                "type": "String",
                                "refresh": true,
                                "actions": [
@@ -34,6 +36,7 @@
                                "property": "ptc_on",
                                "friendlyName": "PTC",
                                "channel": "airFreshPTCPower",
+                               "channelType": "airFreshPTCPower",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -47,6 +50,7 @@
                                "property": "ptc_status",
                                "friendlyName": "PTC Status",
                                "channel": "airFreshPTCStatus",
+                               "channelType": "airFreshPTCStatus",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -56,6 +60,7 @@
                                "property": "display",
                                "friendlyName": "Display",
                                "channel": "airFreshDisplay",
+                               "channelType": "airFreshDisplay",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -69,6 +74,7 @@
                                "property": "child_lock",
                                "friendlyName": "Child Lock",
                                "channel": "airFreshChildLock",
+                               "channelType": "airFreshChildLock",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -82,6 +88,7 @@
                                "property": "sound",
                                "friendlyName": "Sound",
                                "channel": "airFreshSound",
+                               "channelType": "airFreshSound",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
                                "property": "pm25",
                                "friendlyName": "PM2.5",
                                "channel": "airFreshPM25",
+                               "channelType": "airFreshPM25",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "co2",
                                "friendlyName": "CO2",
                                "channel": "airFreshCO2",
+                               "channelType": "airFreshCO2",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "control_speed",
                                "friendlyName": "Current Speed",
                                "channel": "airFreshCurrentSpeed",
+                               "channelType": "airFreshCurrentSpeed",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "favourite_speed",
                                "friendlyName": "Favorite Speed",
                                "channel": "airFreshFavoriteSpeed",
+                               "channelType": "airFreshFavoriteSpeed",
                                "type": "Number",
                                "refresh": true,
                                "actions": [
                                "property": "temperature_outside",
                                "friendlyName": "Temperature Outside",
                                "channel": "airFreshTemperature",
+                               "channelType": "airFreshTemperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "filter_rate",
                                "friendlyName": "Filter Percents Remaining",
                                "channel": "airFreshFilterPercents",
+                               "channelType": "airFreshFilterPercents",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
                                "property": "filter_day",
                                "friendlyName": "Filter Days Remaining",
                                "channel": "airFreshFilterDays",
+                               "channelType": "airFreshFilterDays",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "",
                                "friendlyName": "Reset Filter",
                                "channel": "airFreshResetFilterA1",
+                               "channelType": "airFreshResetFilterA1",
                                "type": "String",
                                "refresh": false,
                                "ChannelGroup": "actions",
index 336e1619108513739683f3c5ea5628293a77d0a6..39095e2afd0f052d2cfe0d207f09aa398fea6c5c 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -21,6 +22,7 @@
                                "property": "mode",
                                "friendlyName": "Mode",
                                "channel": "airFreshMode",
+                               "channelType": "airFreshMode",
                                "type": "String",
                                "refresh": true,
                                "actions": [
@@ -34,6 +36,7 @@
                                "property": "ptc_on",
                                "friendlyName": "PTC",
                                "channel": "airFreshPTCPower",
+                               "channelType": "airFreshPTCPower",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -47,6 +50,7 @@
                                "property": "ptc_level",
                                "friendlyName": "PTC Level",
                                "channel": "airFreshPtcLevel",
+                               "channelType": "airFreshPtcLevel",
                                "type": "String",
                                "refresh": true,
                                "actions": [
@@ -60,6 +64,7 @@
                                "property": "ptc_status",
                                "friendlyName": "PTC Status",
                                "channel": "airFreshPTCStatus",
+                               "channelType": "airFreshPTCStatus",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -69,6 +74,7 @@
                                "property": "screen_direction",
                                "friendlyName": "Screen direction",
                                "channel": "airFreshDisplayDirection",
+                               "channelType": "airFreshDisplayDirection",
                                "type": "String",
                                "refresh": true,
                                "actions": [
@@ -82,6 +88,7 @@
                                "property": "display",
                                "friendlyName": "Display",
                                "channel": "airFreshDisplay",
+                               "channelType": "airFreshDisplay",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
                                "property": "child_lock",
                                "friendlyName": "Child Lock",
                                "channel": "airFreshChildLock",
+                               "channelType": "airFreshChildLock",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
                                "property": "sound",
                                "friendlyName": "Sound",
                                "channel": "airFreshSound",
+                               "channelType": "airFreshSound",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
                                "property": "pm25",
                                "friendlyName": "PM2.5",
                                "channel": "airFreshPM25",
+                               "channelType": "airFreshPM25",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "co2",
                                "friendlyName": "CO2",
                                "channel": "airFreshCO2",
+                               "channelType": "airFreshCO2",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "control_speed",
                                "friendlyName": "Current Speed",
                                "channel": "airFreshCurrentSpeed",
+                               "channelType": "airFreshCurrentSpeed",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "favourite_speed",
                                "friendlyName": "Favorite Speed",
                                "channel": "airFreshFavoriteSpeed",
+                               "channelType": "airFreshFavoriteSpeed",
                                "type": "Number",
                                "refresh": true,
                                "actions": [
                                "property": "temperature_outside",
                                "friendlyName": "Temperature Outside",
                                "channel": "airFreshTemperature",
+                               "channelType": "airFreshTemperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "filter_intermediate",
                                "friendlyName": "Filter Percents Remaining",
                                "channel": "airFreshFilterPercents",
+                               "channelType": "airFreshFilterPercents",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
                                "property": "filter_inter_day",
                                "friendlyName": "Filter Days Remaining",
                                "channel": "airFreshFilterDays",
+                               "channelType": "airFreshFilterDays",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "filter_efficient",
                                "friendlyName": "Filter Pro Percents Remaining",
                                "channel": "airFreshFilterProPercents",
+                               "channelType": "airFreshFilterProPercents",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "filter_effi_day",
                                "friendlyName": "Filter Pro Days Remaining",
                                "channel": "airFreshFilterProDays",
+                               "channelType": "airFreshFilterProDays",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "",
                                "friendlyName": "Reset Filter",
                                "channel": "airFreshResetFilter",
+                               "channelType": "airFreshResetFilter",
                                "type": "String",
                                "refresh": false,
                                "ChannelGroup": "actions",
index 35ee631c35dd09c2c2da9600b38271e837891887..7c194253ca472f6178145a96a1aea681f12d11a1 100644 (file)
 {
-    "deviceMapping": {
-        "id": [
-            "dmaker.fan.p5"
-        ],
-        "channels": [
-            {
-                "property": "power",
-                "friendlyName": "Power",
-                "channel": "power",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "s_power",
-                        "parameterType": "ONOFF"
-                    }
-                ]
-            },
-            {
-                "property": "roll",
-                "friendlyName": "Rotation",
-                "channel": "roll",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "s_roll",
-                        "parameterType": "ONOFF"
-                    }
-                ]
-            },
-            {
-                "property": "mode",
-                "friendlyName": "Mode",
-                "channel": "mode",
-                "type": "Number",
-                "refresh": true,
-                "ChannelGroup": "actions",
-                "actions": [
-                    {
-                        "command": "s_mode",
-                        "parameterType": "STRING"
-                    }
-                ]
-            },
-            {
-                "property": "roll_angle",
-                "friendlyName": "Angle",
-                "channel": "angle",
-                "type": "Number",
-                "refresh": true,
-                "ChannelGroup": "actions",
-                "actions": [
-                    {
-                        "command": "s_angle",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "timer_off",
-                "friendlyName": "Timer",
-                "channel": "timer",
-                "type": "Number",
-                "refresh": true,
-                "ChannelGroup": "actions",
-                "actions": [
-                    {
-                        "command": "s_t_off",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "beep_sound",
-                "friendlyName": "Beep Sound",
-                "channel": "beep",
-                "type": "Switch",
-                "refresh": true,
-                "ChannelGroup": "actions",
-                "actions": [
-                    {
-                        "command": "s_beep_sound",
-                        "parameterType": "ONOFF"
-                    }
-                ]
-            },
-            {
-                "property": "light",
-                "friendlyName": "Light",
-                "channel": "light",
-                "type": "Number",
-                "refresh": true,
-                "ChannelGroup": "actions",
-                "actions": [
-                    {
-                        "command": "s_light",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "child_lock",
-                "friendlyName": "Child Lock",
-                "channel": "child_lock",
-                "type": "Switch",
-                "refresh": true,
-                "ChannelGroup": "actions",
-                "actions": [
-                    {
-                        "command": "s_lock",
-                        "parameterType": "ONOFF"
-                    }
-                ]
-            },
-            {
-                "property": "speed",
-                "friendlyName": "Speed",
-                "channel": "speed",
-                "type": "Number",
-                "refresh": true,
-                "ChannelGroup": "actions",
-                "actions": [
-                    {
-                        "command": "s_speed",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            }
-        ]
-    }
+       "deviceMapping": {
+               "id": [
+                       "dmaker.fan.p5"
+               ],
+               "channels": [
+                       {
+                               "property": "power",
+                               "friendlyName": "Power",
+                               "channel": "power",
+                               "channelType": "power",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "s_power",
+                                               "parameterType": "ONOFF"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "roll",
+                               "friendlyName": "Rotation",
+                               "channel": "roll",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "s_roll",
+                                               "parameterType": "ONOFF"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "mode",
+                               "friendlyName": "Mode",
+                               "channel": "mode",
+                               "channelType": "mode",
+                               "type": "Number",
+                               "refresh": true,
+                               "ChannelGroup": "actions",
+                               "actions": [
+                                       {
+                                               "command": "s_mode",
+                                               "parameterType": "STRING"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "roll_angle",
+                               "friendlyName": "Angle",
+                               "channel": "angle",
+                               "channelType": "angle",
+                               "type": "Number",
+                               "refresh": true,
+                               "ChannelGroup": "actions",
+                               "actions": [
+                                       {
+                                               "command": "s_angle",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "timer_off",
+                               "friendlyName": "Timer",
+                               "channel": "timer",
+                               "type": "Number",
+                               "refresh": true,
+                               "ChannelGroup": "actions",
+                               "actions": [
+                                       {
+                                               "command": "s_t_off",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "beep_sound",
+                               "friendlyName": "Beep Sound",
+                               "channel": "beep",
+                               "type": "Switch",
+                               "refresh": true,
+                               "ChannelGroup": "actions",
+                               "actions": [
+                                       {
+                                               "command": "s_beep_sound",
+                                               "parameterType": "ONOFF"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "light",
+                               "friendlyName": "Light",
+                               "channel": "light",
+                               "type": "Number",
+                               "refresh": true,
+                               "ChannelGroup": "actions",
+                               "actions": [
+                                       {
+                                               "command": "s_light",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "child_lock",
+                               "friendlyName": "Child Lock",
+                               "channel": "child_lock",
+                               "type": "Switch",
+                               "refresh": true,
+                               "ChannelGroup": "actions",
+                               "actions": [
+                                       {
+                                               "command": "s_lock",
+                                               "parameterType": "ONOFF"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "speed",
+                               "friendlyName": "Speed",
+                               "channel": "speed",
+                               "channelType": "speed",
+                               "type": "Number",
+                               "refresh": true,
+                               "ChannelGroup": "actions",
+                               "actions": [
+                                       {
+                                               "command": "s_speed",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       }
+               ]
+       }
 }
index 344d423a912aec9e1ec198cbd4a96c287b145c53..e30682af671e70a8255e956e79d2987c3eefeb79 100644 (file)
 {
-    "deviceMapping": {
-        "id": [
-            "dmaker.fan.p8",
-            "dmaker.fan.1c"
-        ],
-        "propertyMethod": "get_properties",
-        "maxProperties": 2,
-        "channels": [
-            {
-                "property": "manufacturer",
-                "siid": 1,
-                "piid": 1,
-                "friendlyName": "Device Information-Device Manufacturer",
-                "channel": "Manufacturer",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "model",
-                "siid": 1,
-                "piid": 2,
-                "friendlyName": "Device Information-Device Model",
-                "channel": "Model",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "serial-number",
-                "siid": 1,
-                "piid": 3,
-                "friendlyName": "Device Information-Device Serial Number",
-                "channel": "SerialNumber",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "firmware-revision",
-                "siid": 1,
-                "piid": 4,
-                "friendlyName": "Device Information-Current Firmware Version",
-                "channel": "FirmwareRevision",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "on",
-                "siid": 2,
-                "piid": 1,
-                "friendlyName": "Fan-Switch Status",
-                "channel": "On",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            },
-            {
-                "property": "fan-level",
-                "siid": 2,
-                "piid": 2,
-                "friendlyName": "Fan-Fan Level",
-                "channel": "FanLevel",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "horizontal-swing",
-                "siid": 2,
-                "piid": 3,
-                "friendlyName": "Fan-Horizontal Swing",
-                "channel": "HorizontalSwing",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            },
-            {
-                "property": "mode",
-                "siid": 2,
-                "piid": 7,
-                "friendlyName": "Fan-Mode",
-                "channel": "Mode",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "off-delay-time",
-                "siid": 2,
-                "piid": 10,
-                "friendlyName": "Fan-Power Off Delay Time",
-                "channel": "OffDelayTime",
-                "channelType": "miot_uint16",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "alarm",
-                "siid": 2,
-                "piid": 11,
-                "friendlyName": "Fan-Alarm",
-                "channel": "Alarm",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            },
-            {
-                "property": "brightness",
-                "siid": 2,
-                "piid": 12,
-                "friendlyName": "Fan-Brightness",
-                "channel": "Brightness",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            },
-            {
-                "property": "physical-controls-locked",
-                "siid": 3,
-                "piid": 1,
-                "friendlyName": "Physical Control Locked-Physical Control Locked",
-                "channel": "PhysicalControlsLocked",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            }
-        ]
-    }
+       "deviceMapping": {
+               "id": [
+                       "dmaker.fan.p8",
+                       "dmaker.fan.1c"
+               ],
+               "propertyMethod": "get_properties",
+               "maxProperties": 2,
+               "channels": [
+                       {
+                               "property": "manufacturer",
+                               "siid": 1,
+                               "piid": 1,
+                               "friendlyName": "Device Information-Device Manufacturer",
+                               "channel": "Manufacturer",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "model",
+                               "siid": 1,
+                               "piid": 2,
+                               "friendlyName": "Device Information-Device Model",
+                               "channel": "Model",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "serial-number",
+                               "siid": 1,
+                               "piid": 3,
+                               "friendlyName": "Device Information-Device Serial Number",
+                               "channel": "SerialNumber",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "firmware-revision",
+                               "siid": 1,
+                               "piid": 4,
+                               "friendlyName": "Device Information-Current Firmware Version",
+                               "channel": "FirmwareRevision",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "on",
+                               "siid": 2,
+                               "piid": 1,
+                               "friendlyName": "Fan-Switch Status",
+                               "channel": "On",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "fan-level",
+                               "siid": 2,
+                               "piid": 2,
+                               "friendlyName": "Fan-Fan Level",
+                               "channel": "FanLevel",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "horizontal-swing",
+                               "siid": 2,
+                               "piid": 3,
+                               "friendlyName": "Fan-Horizontal Swing",
+                               "channel": "HorizontalSwing",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "mode",
+                               "siid": 2,
+                               "piid": 7,
+                               "friendlyName": "Fan-Mode",
+                               "channel": "Mode",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "off-delay-time",
+                               "siid": 2,
+                               "piid": 10,
+                               "friendlyName": "Fan-Power Off Delay Time",
+                               "channel": "OffDelayTime",
+                               "channelType": "miot_uint16",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "alarm",
+                               "siid": 2,
+                               "piid": 11,
+                               "friendlyName": "Fan-Alarm",
+                               "channel": "Alarm",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "brightness",
+                               "siid": 2,
+                               "piid": 12,
+                               "friendlyName": "Fan-Brightness",
+                               "channel": "Brightness",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "physical-controls-locked",
+                               "siid": 3,
+                               "piid": 1,
+                               "friendlyName": "Physical Control Locked-Physical Control Locked",
+                               "channel": "PhysicalControlsLocked",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       }
+               ]
+       }
 }
index a33c7058d0e3a8927a06517e5a03e96a5aad75b7..eb71d84efe6d4cbff9412f44f75d0975d1d0d3c2 100644 (file)
 {
-    "deviceMapping": {
-        "id": [
-            "dmaker.fan.p9",
-            "dmaker.fan.p10"
-        ],
-        "propertyMethod": "get_properties",
-        "maxProperties": 2,
-        "channels": [
-            {
-                "property": "manufacturer",
-                "siid": 1,
-                "piid": 1,
-                "friendlyName": "Device Information-Device Manufacturer",
-                "channel": "Manufacturer",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "model",
-                "siid": 1,
-                "piid": 2,
-                "friendlyName": "Device Information-Device Model",
-                "channel": "Model",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "serial-number",
-                "siid": 1,
-                "piid": 3,
-                "friendlyName": "Device Information-Device Serial Number",
-                "channel": "SerialNumber",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "firmware-revision",
-                "siid": 1,
-                "piid": 4,
-                "friendlyName": "Device Information-Current Firmware Version",
-                "channel": "FirmwareRevision",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "on",
-                "siid": 2,
-                "piid": 1,
-                "friendlyName": "Fan-Switch Status",
-                "channel": "On",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            },
-            {
-                "property": "fan-level",
-                "siid": 2,
-                "piid": 2,
-                "friendlyName": "Fan-Fan Level",
-                "channel": "FanLevel",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "mode",
-                "siid": 2,
-                "piid": 4,
-                "friendlyName": "Fan-Mode",
-                "channel": "Mode",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "horizontal-swing",
-                "siid": 2,
-                "piid": 5,
-                "friendlyName": "Fan-Horizontal Swing",
-                "channel": "HorizontalSwing",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            },
-            {
-                "property": "horizontal-angle",
-                "siid": 2,
-                "piid": 6,
-                "friendlyName": "Fan-Horizontal Angle",
-                "channel": "HorizontalAngle",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "alarm",
-                "siid": 2,
-                "piid": 7,
-                "friendlyName": "Fan-Alarm",
-                "channel": "Alarm",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            },
-            {
-                "property": "off-delay-time",
-                "siid": 2,
-                "piid": 8,
-                "friendlyName": "Fan-Power Off Delay Time",
-                "channel": "OffDelayTime",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "brightness",
-                "siid": 2,
-                "piid": 9,
-                "friendlyName": "Fan-Brightness",
-                "channel": "Brightness",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            },
-            {
-                "property": "motor-control",
-                "siid": 2,
-                "piid": 10,
-                "friendlyName": "Fan-Motor Control",
-                "channel": "MotorControl",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "speed-level",
-                "siid": 2,
-                "piid": 11,
-                "friendlyName": "Fan-Speed Level",
-                "channel": "SpeedLevel",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "physical-controls-locked",
-                "siid": 3,
-                "piid": 1,
-                "friendlyName": "Physical Control Locked-Physical Control Locked",
-                "channel": "PhysicalControlsLocked",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            }
-        ]
-    }
+       "deviceMapping": {
+               "id": [
+                       "dmaker.fan.p9",
+                       "dmaker.fan.p10"
+               ],
+               "propertyMethod": "get_properties",
+               "maxProperties": 2,
+               "channels": [
+                       {
+                               "property": "manufacturer",
+                               "siid": 1,
+                               "piid": 1,
+                               "friendlyName": "Device Information-Device Manufacturer",
+                               "channel": "Manufacturer",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "model",
+                               "siid": 1,
+                               "piid": 2,
+                               "friendlyName": "Device Information-Device Model",
+                               "channel": "Model",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "serial-number",
+                               "siid": 1,
+                               "piid": 3,
+                               "friendlyName": "Device Information-Device Serial Number",
+                               "channel": "SerialNumber",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "firmware-revision",
+                               "siid": 1,
+                               "piid": 4,
+                               "friendlyName": "Device Information-Current Firmware Version",
+                               "channel": "FirmwareRevision",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "on",
+                               "siid": 2,
+                               "piid": 1,
+                               "friendlyName": "Fan-Switch Status",
+                               "channel": "On",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "fan-level",
+                               "siid": 2,
+                               "piid": 2,
+                               "friendlyName": "Fan-Fan Level",
+                               "channel": "FanLevel",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "mode",
+                               "siid": 2,
+                               "piid": 4,
+                               "friendlyName": "Fan-Mode",
+                               "channel": "Mode",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "horizontal-swing",
+                               "siid": 2,
+                               "piid": 5,
+                               "friendlyName": "Fan-Horizontal Swing",
+                               "channel": "HorizontalSwing",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "horizontal-angle",
+                               "siid": 2,
+                               "piid": 6,
+                               "friendlyName": "Fan-Horizontal Angle",
+                               "channel": "HorizontalAngle",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "alarm",
+                               "siid": 2,
+                               "piid": 7,
+                               "friendlyName": "Fan-Alarm",
+                               "channel": "Alarm",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "off-delay-time",
+                               "siid": 2,
+                               "piid": 8,
+                               "friendlyName": "Fan-Power Off Delay Time",
+                               "channel": "OffDelayTime",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "brightness",
+                               "siid": 2,
+                               "piid": 9,
+                               "friendlyName": "Fan-Brightness",
+                               "channel": "Brightness",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "motor-control",
+                               "siid": 2,
+                               "piid": 10,
+                               "friendlyName": "Fan-Motor Control",
+                               "channel": "MotorControl",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "speed-level",
+                               "siid": 2,
+                               "piid": 11,
+                               "friendlyName": "Fan-Speed Level",
+                               "channel": "SpeedLevel",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "physical-controls-locked",
+                               "siid": 3,
+                               "piid": 1,
+                               "friendlyName": "Physical Control Locked-Physical Control Locked",
+                               "channel": "PhysicalControlsLocked",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       }
+               ]
+       }
 }
index de2614c4a6820cb08105f7b52f74d55c051c5edf..b7bc045ff00f64478eb4dee14573b0d638cdd99b 100644 (file)
 {
-    "deviceMapping": {
-        "id": [
-            "dreame.vacuum.mc1808"
-        ],
-        "propertyMethod": "get_properties",
-        "maxProperties": 2,
-        "channels": [
-            {
-                "property": "",
-                "friendlyName": "Vacuum Action",
-                "channel": "vacuumaction",
-                "channelType": "dreameControl",
-                "type": "String",
-                "refresh": false,
-                "actions": [
-                    {
-                        "command": "action",
-                        "parameterType": "EMPTY",
-                        "siid": 18,
-                        "aiid": 1,
-                        "condition": {
-                            "name": "matchValue",
-                            "parameters": [
-                                {
-                                    "matchValue": "vacuum",
-                                    "returnValue": [
-                                        {
-                                            "piid": 1,
-                                            "value": 2
-                                        }
-                                    ]
-                                },
-                                {
-                                    "matchValue": "start",
-                                    "returnValue": [
-                                        {
-                                            "piid": 1,
-                                            "value": 2
-                                        }
-                                    ]
-                                }
-                            ]
-                        }
-                    },
-                    {
-                        "command": "action",
-                        "parameterType": "EMPTY",
-                        "siid": 18,
-                        "aiid": 2,
-                        "condition": {
-                            "name": "matchValue",
-                            "parameters": [
-                                {
-                                    "matchValue": "stop"
-                                }
-                            ]
-                        }
-                    },
-                    {
-                        "command": "action",
-                        "parameterType": "EMPTY",
-                        "siid": 3,
-                        "aiid": 1,
-                        "condition": {
-                            "name": "matchValue",
-                            "parameters": [
-                                {
-                                    "matchValue": "sweep"
-                                }
-                            ]
-                        }
-                    },
-                    {
-                        "command": "action",
-                        "parameterType": "EMPTY",
-                        "siid": 3,
-                        "aiid": 2,
-                        "condition": {
-                            "name": "matchValue",
-                            "parameters": [
-                                {
-                                    "matchValue": "stopsweep"
-                                }
-                            ]
-                        }
-                    },
-                    {
-                        "command": "action",
-                        "parameterType": "EMPTY",
-                        "siid": 2,
-                        "aiid": 1,
-                        "condition": {
-                            "name": "matchValue",
-                            "parameters": [
-                                {
-                                    "matchValue": "dock"
-                                }
-                            ]
-                        }
-                    }
-                ]
-            },
-            {
-                "property": "battery-level",
-                "siid": 2,
-                "piid": 1,
-                "friendlyName": "Battery-Battery Level",
-                "channel": "BatteryLevel",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "charging-state",
-                "siid": 2,
-                "piid": 2,
-                "friendlyName": "Battery-Charging State",
-                "channel": "ChargingState",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "fault",
-                "siid": 3,
-                "piid": 1,
-                "friendlyName": "Robot Cleaner-Device Fault",
-                "channel": "Fault",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "status",
-                "siid": 3,
-                "piid": 2,
-                "friendlyName": "Robot Cleaner-Status",
-                "channel": "Status",
-                "channelType": "miot_int8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "brush-left-time",
-                "siid": 26,
-                "piid": 1,
-                "friendlyName": "Main Cleaning Brush-Brush Left Time",
-                "channel": "BrushLeftTime",
-                "channelType": "miot_uint16",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "brush-life-level",
-                "siid": 26,
-                "piid": 2,
-                "friendlyName": "Main Cleaning Brush-Brush Life Level",
-                "channel": "BrushLifeLevel",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "filter-life-level",
-                "siid": 27,
-                "piid": 1,
-                "friendlyName": "Filter-Filter Life Level",
-                "channel": "FilterLifeLevel",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "filter-left-time",
-                "siid": 27,
-                "piid": 2,
-                "friendlyName": "Filter-Filter Left Time",
-                "channel": "FilterLeftTime",
-                "channelType": "miot_uint16",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "brush-left-time1",
-                "siid": 28,
-                "piid": 1,
-                "friendlyName": "Side Cleaning Brush-Brush Left Time",
-                "channel": "BrushLeftTime1",
-                "channelType": "miot_uint16",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "brush-life-level1",
-                "siid": 28,
-                "piid": 2,
-                "friendlyName": "Side Cleaning Brush-Brush Life Level",
-                "channel": "BrushLifeLevel1",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "work-mode",
-                "siid": 18,
-                "piid": 1,
-                "friendlyName": "clean-workmode",
-                "channel": "WorkMode",
-                "channelType": "miot_int32",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "area",
-                "siid": 18,
-                "piid": 4,
-                "friendlyName": "clean-area",
-                "channel": "Area",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "STRING"
-                    }
-                ]
-            },
-            {
-                "property": "timer",
-                "siid": 18,
-                "piid": 5,
-                "friendlyName": "clean-timer",
-                "channel": "Timer",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "STRING"
-                    }
-                ]
-            },
-            {
-                "property": "mode",
-                "siid": 18,
-                "piid": 6,
-                "friendlyName": "clean-mode",
-                "channel": "Mode",
-                "channelType": "miot_int32",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "total-clean-time",
-                "siid": 18,
-                "piid": 13,
-                "friendlyName": "clean-total time",
-                "channel": "TotalCleanTime",
-                "channelType": "miot_uint32",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "total-clean-times",
-                "siid": 18,
-                "piid": 14,
-                "friendlyName": "clean-total times",
-                "channel": "TotalCleanTimes",
-                "channelType": "miot_uint32",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "total-clean-area",
-                "siid": 18,
-                "piid": 15,
-                "friendlyName": "clean-Total area",
-                "channel": "TotalCleanArea",
-                "channelType": "miot_uint32",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "clean-log-start-time",
-                "siid": 18,
-                "piid": 16,
-                "friendlyName": "clean-Start Time",
-                "channel": "CleanLogStartTime",
-                "channelType": "miot_uint32",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "button-led",
-                "siid": 18,
-                "piid": 17,
-                "friendlyName": "clean-led",
-                "channel": "ButtonLed",
-                "channelType": "miot_uint16",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "task-done",
-                "siid": 18,
-                "piid": 18,
-                "friendlyName": "clean-task done",
-                "channel": "TaskDone",
-                "channelType": "miot_uint8",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "life-sieve",
-                "siid": 19,
-                "piid": 1,
-                "friendlyName": "consumable-life-sieve",
-                "channel": "LifeSieve",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "STRING"
-                    }
-                ]
-            },
-            {
-                "property": "life-brush-side",
-                "siid": 19,
-                "piid": 2,
-                "friendlyName": "consumable-life-brush-side",
-                "channel": "LifeBrushSide",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "STRING"
-                    }
-                ]
-            },
-            {
-                "property": "life-brush-main",
-                "siid": 19,
-                "piid": 3,
-                "friendlyName": "consumable-life-brush-main",
-                "channel": "LifeBrushMain",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "STRING"
-                    }
-                ]
-            },
-            {
-                "property": "enable",
-                "siid": 20,
-                "piid": 1,
-                "friendlyName": "annoy-enable",
-                "channel": "Enable",
-                "channelType": "miot_bool",
-                "type": "Switch",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "ONOFFBOOL"
-                    }
-                ]
-            },
-            {
-                "property": "start-time",
-                "siid": 20,
-                "piid": 2,
-                "friendlyName": "annoy-start-time",
-                "channel": "StartTime",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "STRING"
-                    }
-                ]
-            },
-            {
-                "property": "stop-time",
-                "siid": 20,
-                "piid": 3,
-                "friendlyName": "annoy-stop-time",
-                "channel": "StopTime",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "STRING"
-                    }
-                ]
-            },
-            {
-                "property": "map-view",
-                "siid": 23,
-                "piid": 1,
-                "friendlyName": "map-map-view",
-                "channel": "MapView",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "volume",
-                "siid": 24,
-                "piid": 1,
-                "friendlyName": "audio-volume",
-                "channel": "Volume",
-                "channelType": "miot_int32",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "voice-packets",
-                "siid": 24,
-                "piid": 3,
-                "friendlyName": "audio-voiceId",
-                "channel": "VoicePackets",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_properties",
-                        "parameterType": "STRING"
-                    }
-                ]
-            },
-            {
-                "property": "time-zone",
-                "siid": 25,
-                "piid": 1,
-                "friendlyName": "timezone",
-                "channel": "TimeZone",
-                "channelType": "miot_string",
-                "type": "String",
-                "refresh": true,
-                "actions": [
-                ]
-            }
-        ]
-    }
+       "deviceMapping": {
+               "id": [
+                       "dreame.vacuum.mc1808"
+               ],
+               "propertyMethod": "get_properties",
+               "maxProperties": 2,
+               "channels": [
+                       {
+                               "property": "",
+                               "friendlyName": "Vacuum Action",
+                               "channel": "vacuumaction",
+                               "channelType": "dreameControl",
+                               "type": "String",
+                               "refresh": false,
+                               "actions": [
+                                       {
+                                               "command": "action",
+                                               "parameterType": "EMPTY",
+                                               "siid": 18,
+                                               "aiid": 1,
+                                               "condition": {
+                                                       "name": "matchValue",
+                                                       "parameters": [
+                                                               {
+                                                                       "matchValue": "vacuum",
+                                                                       "returnValue": [
+                                                                               {
+                                                                                       "piid": 1,
+                                                                                       "value": 2
+                                                                               }
+                                                                       ]
+                                                               },
+                                                               {
+                                                                       "matchValue": "start",
+                                                                       "returnValue": [
+                                                                               {
+                                                                                       "piid": 1,
+                                                                                       "value": 2
+                                                                               }
+                                                                       ]
+                                                               }
+                                                       ]
+                                               }
+                                       },
+                                       {
+                                               "command": "action",
+                                               "parameterType": "EMPTY",
+                                               "siid": 18,
+                                               "aiid": 2,
+                                               "condition": {
+                                                       "name": "matchValue",
+                                                       "parameters": [
+                                                               {
+                                                                       "matchValue": "stop"
+                                                               }
+                                                       ]
+                                               }
+                                       },
+                                       {
+                                               "command": "action",
+                                               "parameterType": "EMPTY",
+                                               "siid": 3,
+                                               "aiid": 1,
+                                               "condition": {
+                                                       "name": "matchValue",
+                                                       "parameters": [
+                                                               {
+                                                                       "matchValue": "sweep"
+                                                               }
+                                                       ]
+                                               }
+                                       },
+                                       {
+                                               "command": "action",
+                                               "parameterType": "EMPTY",
+                                               "siid": 3,
+                                               "aiid": 2,
+                                               "condition": {
+                                                       "name": "matchValue",
+                                                       "parameters": [
+                                                               {
+                                                                       "matchValue": "stopsweep"
+                                                               }
+                                                       ]
+                                               }
+                                       },
+                                       {
+                                               "command": "action",
+                                               "parameterType": "EMPTY",
+                                               "siid": 2,
+                                               "aiid": 1,
+                                               "condition": {
+                                                       "name": "matchValue",
+                                                       "parameters": [
+                                                               {
+                                                                       "matchValue": "dock"
+                                                               }
+                                                       ]
+                                               }
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "battery-level",
+                               "siid": 2,
+                               "piid": 1,
+                               "friendlyName": "Battery-Battery Level",
+                               "channel": "BatteryLevel",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "charging-state",
+                               "siid": 2,
+                               "piid": 2,
+                               "friendlyName": "Battery-Charging State",
+                               "channel": "ChargingState",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "fault",
+                               "siid": 3,
+                               "piid": 1,
+                               "friendlyName": "Robot Cleaner-Device Fault",
+                               "channel": "Fault",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "status",
+                               "siid": 3,
+                               "piid": 2,
+                               "friendlyName": "Robot Cleaner-Status",
+                               "channel": "Status",
+                               "channelType": "miot_int8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "brush-left-time",
+                               "siid": 26,
+                               "piid": 1,
+                               "friendlyName": "Main Cleaning Brush-Brush Left Time",
+                               "channel": "BrushLeftTime",
+                               "channelType": "miot_uint16",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "brush-life-level",
+                               "siid": 26,
+                               "piid": 2,
+                               "friendlyName": "Main Cleaning Brush-Brush Life Level",
+                               "channel": "BrushLifeLevel",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "filter-life-level",
+                               "siid": 27,
+                               "piid": 1,
+                               "friendlyName": "Filter-Filter Life Level",
+                               "channel": "FilterLifeLevel",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "filter-left-time",
+                               "siid": 27,
+                               "piid": 2,
+                               "friendlyName": "Filter-Filter Left Time",
+                               "channel": "FilterLeftTime",
+                               "channelType": "miot_uint16",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "brush-left-time1",
+                               "siid": 28,
+                               "piid": 1,
+                               "friendlyName": "Side Cleaning Brush-Brush Left Time",
+                               "channel": "BrushLeftTime1",
+                               "channelType": "miot_uint16",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "brush-life-level1",
+                               "siid": 28,
+                               "piid": 2,
+                               "friendlyName": "Side Cleaning Brush-Brush Life Level",
+                               "channel": "BrushLifeLevel1",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "work-mode",
+                               "siid": 18,
+                               "piid": 1,
+                               "friendlyName": "clean-workmode",
+                               "channel": "WorkMode",
+                               "channelType": "miot_int32",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "area",
+                               "siid": 18,
+                               "piid": 4,
+                               "friendlyName": "clean-area",
+                               "channel": "Area",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "STRING"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "timer",
+                               "siid": 18,
+                               "piid": 5,
+                               "friendlyName": "clean-timer",
+                               "channel": "Timer",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "STRING"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "mode",
+                               "siid": 18,
+                               "piid": 6,
+                               "friendlyName": "clean-mode",
+                               "channel": "Mode",
+                               "channelType": "miot_int32",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "total-clean-time",
+                               "siid": 18,
+                               "piid": 13,
+                               "friendlyName": "clean-total time",
+                               "channel": "TotalCleanTime",
+                               "channelType": "miot_uint32",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "total-clean-times",
+                               "siid": 18,
+                               "piid": 14,
+                               "friendlyName": "clean-total times",
+                               "channel": "TotalCleanTimes",
+                               "channelType": "miot_uint32",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "total-clean-area",
+                               "siid": 18,
+                               "piid": 15,
+                               "friendlyName": "clean-Total area",
+                               "channel": "TotalCleanArea",
+                               "channelType": "miot_uint32",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "clean-log-start-time",
+                               "siid": 18,
+                               "piid": 16,
+                               "friendlyName": "clean-Start Time",
+                               "channel": "CleanLogStartTime",
+                               "channelType": "miot_uint32",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "button-led",
+                               "siid": 18,
+                               "piid": 17,
+                               "friendlyName": "clean-led",
+                               "channel": "ButtonLed",
+                               "channelType": "miot_uint16",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "task-done",
+                               "siid": 18,
+                               "piid": 18,
+                               "friendlyName": "clean-task done",
+                               "channel": "TaskDone",
+                               "channelType": "miot_uint8",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "life-sieve",
+                               "siid": 19,
+                               "piid": 1,
+                               "friendlyName": "consumable-life-sieve",
+                               "channel": "LifeSieve",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "STRING"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "life-brush-side",
+                               "siid": 19,
+                               "piid": 2,
+                               "friendlyName": "consumable-life-brush-side",
+                               "channel": "LifeBrushSide",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "STRING"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "life-brush-main",
+                               "siid": 19,
+                               "piid": 3,
+                               "friendlyName": "consumable-life-brush-main",
+                               "channel": "LifeBrushMain",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "STRING"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "enable",
+                               "siid": 20,
+                               "piid": 1,
+                               "friendlyName": "annoy-enable",
+                               "channel": "Enable",
+                               "channelType": "miot_bool",
+                               "type": "Switch",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "ONOFFBOOL"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "start-time",
+                               "siid": 20,
+                               "piid": 2,
+                               "friendlyName": "annoy-start-time",
+                               "channel": "StartTime",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "STRING"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "stop-time",
+                               "siid": 20,
+                               "piid": 3,
+                               "friendlyName": "annoy-stop-time",
+                               "channel": "StopTime",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "STRING"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "map-view",
+                               "siid": 23,
+                               "piid": 1,
+                               "friendlyName": "map-map-view",
+                               "channel": "MapView",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "volume",
+                               "siid": 24,
+                               "piid": 1,
+                               "friendlyName": "audio-volume",
+                               "channel": "Volume",
+                               "channelType": "miot_int32",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "voice-packets",
+                               "siid": 24,
+                               "piid": 3,
+                               "friendlyName": "audio-voiceId",
+                               "channel": "VoicePackets",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_properties",
+                                               "parameterType": "STRING"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "time-zone",
+                               "siid": 25,
+                               "piid": 1,
+                               "friendlyName": "timezone",
+                               "channel": "TimeZone",
+                               "channelType": "miot_string",
+                               "type": "String",
+                               "refresh": true,
+                               "actions": []
+                       }
+               ]
+       }
 }
index 7eee1b59289718ce0976e5b9cc2af9932cdcb320..70877a9419f35f20d1aaa846d2f9d3dc571dc8a4 100644 (file)
@@ -13,6 +13,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -26,6 +27,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "actions": [
@@ -49,6 +51,7 @@
                                "property": "cct",
                                "friendlyName": "Correlated Color Temperature",
                                "channel": "cct",
+                               "channelType": "cct",
                                "type": "Dimmer",
                                "refresh": true,
                                "actions": [
@@ -62,6 +65,7 @@
                                "property": "snm",
                                "friendlyName": "Scene",
                                "channel": "scene",
+                               "channelType": "scene",
                                "type": "Number",
                                "refresh": true,
                                "actions": [
@@ -75,6 +79,7 @@
                                "property": "dv",
                                "friendlyName": "DV",
                                "channel": "dv",
+                               "channelType": "dv",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "",
                                "friendlyName": "Delay Off",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Switch",
                                "refresh": false,
                                "ChannelGroup": "actions",
                                ]
                        }
                ],
-               "experimental":true
+               "experimental": true
        }
 }
index 4efe1b8479212e74515751908a350494f2563e74..abee9f42178e2380e7eed33f0bedf26ae242d109 100644 (file)
@@ -13,6 +13,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -27,6 +28,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -51,6 +53,7 @@
                                "property": "cct",
                                "friendlyName": "Correlated Color Temperature",
                                "channel": "cct",
+                               "channelType": "cct",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -65,6 +68,7 @@
                                "property": "snm",
                                "friendlyName": "Scene",
                                "channel": "scene",
+                               "channelType": "scene",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -79,6 +83,7 @@
                                "property": "dv",
                                "friendlyName": "DV",
                                "channel": "dv",
+                               "channelType": "dv",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "",
                                "friendlyName": "Delay Off",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Switch",
                                "refresh": false,
                                "ChannelGroup": "actions",
index 4687ee4c0533f90362c2a68506abfef50129cf74..ce8b6115fd3dae4551d6d44792bdf1775b521780 100644 (file)
@@ -9,6 +9,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -23,6 +24,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -47,6 +49,7 @@
                                "property": "cct",
                                "friendlyName": "Correlated Color Temperature",
                                "channel": "cct",
+                               "channelType": "cct",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -61,6 +64,7 @@
                                "property": "snm",
                                "friendlyName": "Scene",
                                "channel": "scene",
+                               "channelType": "scene",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -75,6 +79,7 @@
                                "property": "",
                                "friendlyName": "Delay Off",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Switch",
                                "refresh": false,
                                "ChannelGroup": "actions",
index 94f52c339aa2a57043ba5f4cbc9b915b7ad74d4a..37039f9e7ad075a0f8c84be29e0e4cb25359cbb6 100644 (file)
@@ -10,6 +10,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -24,6 +25,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -48,6 +50,7 @@
                                "property": "cct",
                                "friendlyName": "Correlated Color Temperature",
                                "channel": "cct",
+                               "channelType": "cct",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -62,6 +65,7 @@
                                "property": "snm",
                                "friendlyName": "Scene",
                                "channel": "scene",
+                               "channelType": "scene",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "",
                                "friendlyName": "Delay Off",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Switch",
                                "refresh": false,
                                "ChannelGroup": "actions",
index 8a23d97aad7e00effd2961e700345cc8c1d17ca7..c21c9347c33cc509eea6071e4a207ca9598cecec 100644 (file)
@@ -9,6 +9,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -23,6 +24,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -47,6 +49,7 @@
                                "property": "cct",
                                "friendlyName": "Correlated Color Temperature",
                                "channel": "cct",
+                               "channelType": "cct",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -61,6 +64,7 @@
                                "property": "snm",
                                "friendlyName": "Scene",
                                "channel": "scene",
+                               "channelType": "scene",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
index d4ecb7873b06d2c9f92580a5af8ebbf353835fa4..06a9479c9590d8fae2858c0c34a92fa0a42b78b5 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -22,6 +23,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -46,6 +48,7 @@
                                "property": "scene_num",
                                "friendlyName": "Scene",
                                "channel": "scene",
+                               "channelType": "scene",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
index 13894279d6378a43588f769240ebf7715acd2e97..74332d9bbebd813921503e7b26f6fefd3816e8ba 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "pow",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -22,6 +23,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -46,6 +48,7 @@
                                "property": "cct",
                                "friendlyName": "Correlated Color Temperature",
                                "channel": "cct",
+                               "channelType": "cct",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -60,6 +63,7 @@
                                "property": "snm",
                                "friendlyName": "Scene",
                                "channel": "scene",
+                               "channelType": "scene",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -74,6 +78,7 @@
                                "property": "dv",
                                "friendlyName": "DV",
                                "channel": "dv",
+                               "channelType": "dv",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -87,6 +92,7 @@
                                "property": "",
                                "friendlyName": "Go Night",
                                "channel": "gonight",
+                               "channelType": "gonight",
                                "type": "Switch",
                                "refresh": false,
                                "ChannelGroup": "actions",
                                "property": "",
                                "friendlyName": "Delay Off",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Switch",
                                "refresh": false,
                                "ChannelGroup": "actions",
index 51280d0d86cc99d3dd541c2fb7b1b961ea41a5cf..3d239febc23717ae7bba37546e86a82c300a483b 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -22,6 +23,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -46,6 +48,7 @@
                                "property": "snm",
                                "friendlyName": "Scene",
                                "channel": "scene",
+                               "channelType": "scene",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -73,6 +76,7 @@
                                "property": "dv",
                                "friendlyName": "DV",
                                "channel": "dv",
+                               "channelType": "dv",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
index 5a2b13c4c8599c2e86b81f555ae5ad0f6ef0711c..9c993f09da228bda8c467845b24c075d1ac39422 100644 (file)
@@ -9,6 +9,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -23,6 +24,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -47,6 +49,7 @@
                                "property": "ambstatus",
                                "friendlyName": "Ambient Power",
                                "channel": "ambientPower",
+                               "channelType": "ambientPower",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -61,6 +64,7 @@
                                "property": "ambvalue",
                                "friendlyName": "Ambient Brightness",
                                "channel": "ambientBrightness",
+                               "channelType": "ambientBrightness",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -75,6 +79,7 @@
                                "property": "dvalue",
                                "friendlyName": "Ambient Illumination",
                                "channel": "illumination",
+                               "channelType": "illumination",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -84,6 +89,7 @@
                                "property": "eyecare",
                                "friendlyName": "Eyecare",
                                "channel": "eyecare",
+                               "channelType": "eyecare",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
index a3e7fcf1b030fb67335f436746a19c6035905ab6..71b0e0bc66747a435d5f2f91a159b56de5bc7175 100644 (file)
 {
-    "deviceMapping": {
-        "id": [
-            "viomi.vacuum.v6",
-            "viomi.vacuum.v7",
-            "viomi.vacuum.v8"
-        ],
-        "channels": [
-            {
-                "property": "",
-                "friendlyName": "Vacuum Action",
-                "channel": "vacuumaction",
-                "channelType": "vacuumaction",
-                "type": "Number",
-                "refresh": false,
-                "actions": [
-                    {
-                        "command": "set_mode_withroom",
-                        "parameterType": "NUMBER",
-                        "parameters": [
-                            0,
-                            "$value$",
-                            0
-                        ]
-                    }
-                ]
-            },
-            {
-                "property": "run_state",
-                "friendlyName": "State",
-                "channel": "state",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "mode",
-                "friendlyName": "Mode",
-                "channel": "mode",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_mode",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "err_state",
-                "friendlyName": "Error",
-                "channel": "err_state",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "battery_life",
-                "friendlyName": "Battery",
-                "channel": "battery_life",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "box_type",
-                "friendlyName": "Box type",
-                "channel": "box_type",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                    }
-                ]
-            },
-            {
-                "property": "mop_type",
-                "friendlyName": "mop_type",
-                "channel": "mop_type",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_mode",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "s_time",
-                "friendlyName": "Clean time",
-                "channel": "s_time",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_mode",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "s_area",
-                "friendlyName": "Clean Area",
-                "channel": "s_area",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_mode",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "suction_grade",
-                "friendlyName": "suction_grade",
-                "channel": "suction_grade",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_suction",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "water_grade",
-                "friendlyName": "water_grade",
-                "channel": "water_grade",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "set_suction",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            },
-            {
-                "property": "remember_map",
-                "friendlyName": "remember_map",
-                "channel": "remember_map",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "has_map",
-                "friendlyName": "has_map",
-                "channel": "has_map",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "is_mop",
-                "friendlyName": "is_mop",
-                "channel": "is_mop",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            },
-            {
-                "property": "has_newmap",
-                "friendlyName": "has_newmap",
-                "channel": "has_newmap",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                ]
-            }
-        ]
-    }
-}
+       "deviceMapping": {
+               "id": [
+                       "viomi.vacuum.v6",
+                       "viomi.vacuum.v7",
+                       "viomi.vacuum.v8"
+               ],
+               "channels": [
+                       {
+                               "property": "",
+                               "friendlyName": "Vacuum Action",
+                               "channel": "vacuumaction",
+                               "channelType": "vacuumaction",
+                               "type": "Number",
+                               "refresh": false,
+                               "actions": [
+                                       {
+                                               "command": "set_mode_withroom",
+                                               "parameterType": "NUMBER",
+                                               "parameters": [
+                                                       0,
+                                                       "$value$",
+                                                       0
+                                               ]
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "run_state",
+                               "friendlyName": "State",
+                               "channel": "state",
+                               "channelType": "state",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "mode",
+                               "friendlyName": "Mode",
+                               "channel": "mode",
+                               "channelType": "mode",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_mode",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "err_state",
+                               "friendlyName": "Error",
+                               "channel": "err_state",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "battery_life",
+                               "friendlyName": "Battery",
+                               "channel": "battery_life",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "box_type",
+                               "friendlyName": "Box type",
+                               "channel": "box_type",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "parameterType": "EMPTY"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "mop_type",
+                               "friendlyName": "mop_type",
+                               "channel": "mop_type",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_mode",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "s_time",
+                               "friendlyName": "Clean time",
+                               "channel": "s_time",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_mode",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "s_area",
+                               "friendlyName": "Clean Area",
+                               "channel": "s_area",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_mode",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "suction_grade",
+                               "friendlyName": "suction_grade",
+                               "channel": "suction_grade",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_suction",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "water_grade",
+                               "friendlyName": "water_grade",
+                               "channel": "water_grade",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "set_suction",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       },
+                       {
+                               "property": "remember_map",
+                               "friendlyName": "remember_map",
+                               "channel": "remember_map",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "has_map",
+                               "friendlyName": "has_map",
+                               "channel": "has_map",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "is_mop",
+                               "friendlyName": "is_mop",
+                               "channel": "is_mop",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
+                       {
+                               "property": "has_newmap",
+                               "friendlyName": "has_newmap",
+                               "channel": "has_newmap",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       }
+               ]
+       }
+}
\ No newline at end of file
index 77647ae6855e2be0c954b0e4e67d7447325167b5..206785a9c7e36b77b4ddd8a2704d6334991c4079 100644 (file)
                                        }
                                ]
                        },
-            {
-                "property": "status_led",
-                "friendlyName": "Night Light",
-                "channel": "status_led",
-                "type": "Number",
-                "refresh": true,
-                "actions": [
-                    {
-                        "command": "work_night_led",
-                        "parameterType": "NUMBER"
-                    }
-                ]
-            }
+                       {
+                               "property": "status_led",
+                               "friendlyName": "Night Light",
+                               "channel": "status_led",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": [
+                                       {
+                                               "command": "work_night_led",
+                                               "parameterType": "NUMBER"
+                                       }
+                               ]
+                       }
                ],
                "experimental": true
        }
index 54a86843758a5abc3d5332c52c3e1f477c33111b..145318af2d635ffffe66ab0583f359e96f12feab 100644 (file)
@@ -9,6 +9,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -37,6 +38,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -61,6 +63,7 @@
                                "property": "delayoff",
                                "friendlyName": "Shutdown Timer",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -79,6 +82,7 @@
                                "property": "temperature",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -88,6 +92,7 @@
                                "property": "nl_br",
                                "friendlyName": "Nightlight Brightness",
                                "channel": "nightlightBrightness",
+                               "channelType": "nightlightBrightness",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
index 79c4523fe4da8a1bd7818a0848d493ce2d433097..bb4cffb794ba3112077c0d253d29fe694669a0a9 100644 (file)
@@ -34,6 +34,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -48,6 +49,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -72,6 +74,7 @@
                                "property": "delayoff",
                                "friendlyName": "Shutdown Timer",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -90,6 +93,7 @@
                                "property": "ct",
                                "friendlyName": "Color Temperature",
                                "channel": "colorTemperature",
+                               "channelType": "colorTemperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "color_mode",
                                "friendlyName": "Color Mode",
                                "channel": "colorMode",
+                               "channelType": "colorMode",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
                                "property": "",
                                "friendlyName": "Set Scene",
                                "channel": "customScene",
+                               "channelType": "customScene",
                                "type": "String",
                                "refresh": false,
                                "ChannelGroup": "actions",
                                "property": "nl_br",
                                "friendlyName": "Nightlight Brightness",
                                "channel": "nightlightBrightness",
+                               "channelType": "nightlightBrightness",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
index 9ab9149d24eb59e7f770877f19a145d8bba6d487..919c3de8dd9ad50836bab41904d8d2e9f748589b 100644 (file)
@@ -9,6 +9,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -23,6 +24,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -47,6 +49,7 @@
                                "property": "delayoff",
                                "friendlyName": "Shutdown Timer",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -65,6 +68,7 @@
                                "property": "ct",
                                "friendlyName": "Color Temperature",
                                "channel": "colorTemperature",
+                               "channelType": "colorTemperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -84,6 +88,7 @@
                                "property": "color_mode",
                                "friendlyName": "Color Mode",
                                "channel": "colorMode",
+                               "channelType": "colorMode",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
                                "property": "",
                                "friendlyName": "Set Scene",
                                "channel": "customScene",
+                               "channelType": "customScene",
                                "type": "String",
                                "refresh": false,
                                "ChannelGroup": "actions",
                                "property": "nl_br",
                                "friendlyName": "Nightlight Brightness",
                                "channel": "nightlightBrightness",
+                               "channelType": "nightlightBrightness",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
index 2fa408e9ca474ec6f9af395ee3e1de2a98f4e0e6..6fdec440ea8a07f81f77d2b718f3b6ca4eace589 100644 (file)
@@ -10,6 +10,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -24,6 +25,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -48,6 +50,7 @@
                                "property": "bg_bright",
                                "friendlyName": "Ambient Brightness",
                                "channel": "ambientBrightness",
+                               "channelType": "ambientBrightness",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -62,6 +65,7 @@
                                "property": "delayoff",
                                "friendlyName": "Shutdown Timer",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -80,6 +84,7 @@
                                "property": "ct",
                                "friendlyName": "Color Temperature",
                                "channel": "colorTemperature",
+                               "channelType": "colorTemperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "color_mode",
                                "friendlyName": "Color Mode",
                                "channel": "colorMode",
+                               "channelType": "colorMode",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
                                "property": "bg_power",
                                "friendlyName": "Ambient Power",
                                "channel": "ambientPower",
+                               "channelType": "ambientPower",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "bg_rgb",
                                "friendlyName": "Ambient Color",
                                "channel": "ambientColor",
+                               "channelType": "ambientColor",
                                "type": "Color",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "bg_ct",
                                "friendlyName": "Ambient Color Temperature",
                                "channel": "ambientColorTemperature",
+                               "channelType": "ambientColorTemperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                        {
                                                "command": "bg_set_ct_abx",
                                                "parameterType": "NUMBER",
-                                               "parameter1": "\"smooth\"",
-                                               "parameter2": "500",
                                                "parameters": [
                                                        "$value$",
                                                        "smooth",
                                "property": "",
                                "friendlyName": "Set Scene",
                                "channel": "customScene",
+                               "channelType": "customScene",
                                "type": "String",
                                "refresh": false,
                                "ChannelGroup": "actions",
                                "property": "bg_lmode",
                                "friendlyName": "Ambient Color Mode",
                                "channel": "ambientColorMode",
+                               "channelType": "ambientColorMode",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
                                "property": "nl_br",
                                "friendlyName": "Nightlight Brightness",
                                "channel": "nightlightBrightness",
+                               "channelType": "nightlightBrightness",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
index 589510c51f50139bd4936c6a00aee684e2abce63..07419e2e4d2d51b16f2eba034c97811d92c5c768 100644 (file)
@@ -17,6 +17,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -31,6 +32,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -55,6 +57,7 @@
                                "property": "delayoff",
                                "friendlyName": "Shutdown Timer",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -73,6 +76,7 @@
                                "property": "ct",
                                "friendlyName": "Color Temperature",
                                "channel": "colorTemperature",
+                               "channelType": "colorTemperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -92,6 +96,7 @@
                                "property": "color_mode",
                                "friendlyName": "Color Mode",
                                "channel": "colorMode",
+                               "channelType": "colorMode",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                        {
                                                "command": "set_rgb",
                                                "parameterType": "COLOR",
-                                               "condition": {
-                                                       "name": "HSBOnly"
-                                               },
                                                "parameters": [
                                                        "$value$",
                                                        "smooth",
                                                        500
-                                               ]
+                                               ],
+                                               "condition": {
+                                                       "name": "HSBOnly"
+                                               }
                                        },
                                        {
                                                "command": "set_bright",
index cc7cb909cb0e53f91dfdf7a689cc585318ceedbc..8194e92957bfa55d53f2e23b87fc68a2640aa18d 100644 (file)
@@ -22,6 +22,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -36,6 +37,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Dimmer",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -60,6 +62,7 @@
                                "property": "delayoff",
                                "friendlyName": "Shutdown Timer",
                                "channel": "delayoff",
+                               "channelType": "delayoff",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -78,6 +81,7 @@
                                "property": "ct",
                                "friendlyName": "Color Temperature",
                                "channel": "colorTemperature",
+                               "channelType": "colorTemperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "color_mode",
                                "friendlyName": "Color Mode",
                                "channel": "colorMode",
+                               "channelType": "colorMode",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
index e8ed15045e6c605813586ab1cb6af22858b571fa..d4ae2310cb49372d5a48e63411a7e7bb0c6986d9 100644 (file)
@@ -22,6 +22,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -43,6 +44,7 @@
                                "property": "temperature",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "actions": []
index 1e883afcb95b7766e1830231e307331bbdad320c..eea7dc8b665facdbcfe953aa0de7b3e1264abebc 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -22,6 +23,7 @@
                                "property": "aqi",
                                "friendlyName": "Air Quality Index",
                                "channel": "aqi",
+                               "channelType": "aqi",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
index 58703ac57ec1e39a094165e317895f8dc56cba3b..45570ce488b3ababb8c553095b8d62b43e20d8de 100644 (file)
@@ -19,6 +19,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -32,6 +33,7 @@
                                "property": "mode",
                                "friendlyName": "Mode",
                                "channel": "mode",
+                               "channelType": "mode",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -46,6 +48,7 @@
                                "property": "humidity",
                                "friendlyName": "Humidity",
                                "channel": "humidity",
+                               "channelType": "humidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -55,6 +58,7 @@
                                "property": "aqi",
                                "friendlyName": "Air Quality Index",
                                "channel": "aqi",
+                               "channelType": "aqi",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -64,6 +68,7 @@
                                "property": "average_aqi",
                                "friendlyName": "Average Air Quality Index",
                                "channel": "averageaqi",
+                               "channelType": "averageaqi",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -73,6 +78,7 @@
                                "property": "led",
                                "friendlyName": "LED Status",
                                "channel": "led",
+                               "channelType": "led",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -87,6 +93,7 @@
                                "property": "buzzer",
                                "friendlyName": "Buzzer Status",
                                "channel": "buzzer",
+                               "channelType": "buzzer",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "f1_hour",
                                "friendlyName": "Filter Max Life",
                                "channel": "filtermaxlife",
+                               "channelType": "filtermaxlife",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "f1_hour_used",
                                "friendlyName": "Filter Hours used",
                                "channel": "filterhours",
+                               "channelType": "filterhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
                                "property": "use_time",
                                "friendlyName": "Run Time",
                                "channel": "usedhours",
+                               "channelType": "usedhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
                                "property": "motor1_speed",
                                "friendlyName": "Motor Speed",
                                "channel": "motorspeed",
+                               "channelType": "motorspeed",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "favorite_level",
                                "friendlyName": "Favorite Level",
                                "channel": "favoritelevel",
+                               "channelType": "favoritelevel",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "temp_dec",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "/10",
                                "property": "purify_volume",
                                "friendlyName": "Purivied Volume",
                                "channel": "purifyvolume",
+                               "channelType": "purifyvolume",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "child_lock",
                                "friendlyName": "Child Lock",
                                "channel": "childlock",
+                               "channelType": "childlock",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
index 696862ae6b52d703fe5dcc801ead5ecb459f3f4a..5fdf71c50fae9b824ee2794d66eb52566b61c03c 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -21,6 +22,7 @@
                                "property": "mode",
                                "friendlyName": "Mode",
                                "channel": "mode",
+                               "channelType": "mode",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -35,6 +37,7 @@
                                "property": "humidity",
                                "friendlyName": "Humidity",
                                "channel": "humidity",
+                               "channelType": "humidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -44,6 +47,7 @@
                                "property": "aqi",
                                "friendlyName": "Air Quality Index",
                                "channel": "aqi",
+                               "channelType": "aqi",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -53,6 +57,7 @@
                                "property": "bright",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -67,6 +72,7 @@
                                "property": "led",
                                "friendlyName": "LED Status",
                                "channel": "led",
+                               "channelType": "led",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -81,6 +87,7 @@
                                "property": "act_det",
                                "friendlyName": "Air AutoDetect",
                                "channel": "act_det",
+                               "channelType": "act_det",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -90,6 +97,7 @@
                                "property": "buzzer",
                                "friendlyName": "Buzzer Status",
                                "channel": "buzzer",
+                               "channelType": "buzzer",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "f1_hour",
                                "friendlyName": "Filter Max Life",
                                "channel": "filtermaxlife",
+                               "channelType": "filtermaxlife",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "filter1_life",
                                "friendlyName": "Filter Life",
                                "channel": "filterlive",
+                               "channelType": "filterlive",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
index 1399f627da09bbe74d1dd9df67d544030902c9cf..55d700223ed616a1fd0135551505eda7991dfed5 100644 (file)
@@ -9,6 +9,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -22,6 +23,7 @@
                                "property": "mode",
                                "friendlyName": "Mode",
                                "channel": "mode",
+                               "channelType": "mode",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -36,6 +38,7 @@
                                "property": "humidity",
                                "friendlyName": "Humidity",
                                "channel": "humidity",
+                               "channelType": "humidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -45,6 +48,7 @@
                                "property": "aqi",
                                "friendlyName": "Air Quality Index",
                                "channel": "aqi",
+                               "channelType": "aqi",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -54,6 +58,7 @@
                                "property": "average_aqi",
                                "friendlyName": "Average Air Quality Index",
                                "channel": "averageaqi",
+                               "channelType": "averageaqi",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -63,6 +68,7 @@
                                "property": "led",
                                "friendlyName": "LED Status",
                                "channel": "led",
+                               "channelType": "led",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -91,6 +97,7 @@
                                "property": "f1_hour",
                                "friendlyName": "Filter Max Life",
                                "channel": "filtermaxlife",
+                               "channelType": "filtermaxlife",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "f1_hour_used",
                                "friendlyName": "Filter Hours used",
                                "channel": "filterhours",
+                               "channelType": "filterhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
                                "property": "use_time",
                                "friendlyName": "Run Time",
                                "channel": "usedhours",
+                               "channelType": "usedhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
                                "property": "motor1_speed",
                                "friendlyName": "Motor Speed",
                                "channel": "motorspeed",
+                               "channelType": "motorspeed",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "favorite_level",
                                "friendlyName": "Favorite Level",
                                "channel": "favoritelevel",
+                               "channelType": "favoritelevel",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "temp_dec",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "/10",
                                "property": "purify_volume",
                                "friendlyName": "Purivied Volume",
                                "channel": "purifyvolume",
+                               "channelType": "purifyvolume",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "child_lock",
                                "friendlyName": "Child Lock",
                                "channel": "childlock",
+                               "channelType": "childlock",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
index 0386ea8b02feae58def9d852e4ba9a429fbfa121..38b7baa6b65663a9564609c1c4d6ef93073349e7 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -21,6 +22,7 @@
                                "property": "mode",
                                "friendlyName": "Mode",
                                "channel": "mode",
+                               "channelType": "mode",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -35,6 +37,7 @@
                                "property": "humidity",
                                "friendlyName": "Humidity",
                                "channel": "humidity",
+                               "channelType": "humidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -44,6 +47,7 @@
                                "property": "aqi",
                                "friendlyName": "Air Quality Index",
                                "channel": "aqi",
+                               "channelType": "aqi",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -53,6 +57,7 @@
                                "property": "average_aqi",
                                "friendlyName": "Average Air Quality Index",
                                "channel": "averageaqi",
+                               "channelType": "averageaqi",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -71,6 +76,7 @@
                                "property": "led",
                                "friendlyName": "LED Status",
                                "channel": "led",
+                               "channelType": "led",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "f1_hour",
                                "friendlyName": "Filter Max Life",
                                "channel": "filtermaxlife",
+                               "channelType": "filtermaxlife",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "f1_hour_used",
                                "friendlyName": "Filter Hours used",
                                "channel": "filterhours",
+                               "channelType": "filterhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
                                "property": "motor1_speed",
                                "friendlyName": "Motor Speed",
                                "channel": "motorspeed",
+                               "channelType": "motorspeed",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "favorite_level",
                                "friendlyName": "Favorite Level",
                                "channel": "favoritelevel",
+                               "channelType": "favoritelevel",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "temp_dec",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "/10",
                                "property": "child_lock",
                                "friendlyName": "Child Lock",
                                "channel": "childlock",
+                               "channelType": "childlock",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
index 7f692d0ac070537a17e59d2b0421d8348267eb14..152c41846c9bdf825d7686f38b44b94b92014253 100644 (file)
@@ -9,6 +9,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -22,6 +23,7 @@
                                "property": "angle_enable",
                                "friendlyName": "Rotation",
                                "channel": "angleEnable",
+                               "channelType": "angleEnable",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -35,6 +37,7 @@
                                "property": "use_time",
                                "friendlyName": "Run Time",
                                "channel": "usedhours",
+                               "channelType": "usedhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
@@ -45,6 +48,7 @@
                                "property": "angle",
                                "friendlyName": "Angle",
                                "channel": "angle",
+                               "channelType": "angle",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -59,6 +63,7 @@
                                "property": "poweroff_time",
                                "friendlyName": "Timer",
                                "channel": "poweroffTime",
+                               "channelType": "poweroffTime",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -73,6 +78,7 @@
                                "property": "buzzer",
                                "friendlyName": "Buzzer",
                                "channel": "buzzer",
+                               "channelType": "buzzer",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "speed_level",
                                "friendlyName": "Speed Level",
                                "channel": "speedLevel",
+                               "channelType": "speedLevel",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "speed",
                                "friendlyName": "Speed",
                                "channel": "speed",
+                               "channelType": "speed",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "natural_level",
                                "friendlyName": "Natural Level",
                                "channel": "naturalLevel",
+                               "channelType": "naturalLevel",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "ac_power",
                                "friendlyName": "AC Power",
                                "channel": "acPower",
+                               "channelType": "acPower",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "",
                                "friendlyName": "Move Direction",
                                "channel": "move",
+                               "channelType": "move",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
index 2f1fc7206e295589254ba1af32bbd2d46d4cba5f..4bcc0281949c37b5b7869f7ceacf569971111a67 100644 (file)
@@ -10,6 +10,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -23,6 +24,7 @@
                                "property": "angle_enable",
                                "friendlyName": "Rotation",
                                "channel": "angleEnable",
+                               "channelType": "angleEnable",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -36,6 +38,7 @@
                                "property": "use_time",
                                "friendlyName": "Run Time",
                                "channel": "usedhours",
+                               "channelType": "usedhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
@@ -46,6 +49,7 @@
                                "property": "angle",
                                "friendlyName": "Angle",
                                "channel": "angle",
+                               "channelType": "angle",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -60,6 +64,7 @@
                                "property": "poweroff_time",
                                "friendlyName": "Timer",
                                "channel": "poweroffTime",
+                               "channelType": "poweroffTime",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -74,6 +79,7 @@
                                "property": "buzzer",
                                "friendlyName": "Buzzer",
                                "channel": "buzzer",
+                               "channelType": "buzzer",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "speed_level",
                                "friendlyName": "Speed Level",
                                "channel": "speedLevel",
+                               "channelType": "speedLevel",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "speed",
                                "friendlyName": "Speed",
                                "channel": "speed",
+                               "channelType": "speed",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "natural_level",
                                "friendlyName": "Natural Level",
                                "channel": "naturalLevel",
+                               "channelType": "naturalLevel",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "humidity",
                                "friendlyName": "Humidity",
                                "channel": "humidity",
+                               "channelType": "humidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "ac_power",
                                "friendlyName": "AC Power",
                                "channel": "acPower",
+                               "channelType": "acPower",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "bat_charge",
                                "friendlyName": "Battery Charge",
                                "channel": "mode",
+                               "channelType": "mode",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "",
                                "friendlyName": "Move Direction",
                                "channel": "move",
+                               "channelType": "move",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
index d6d63cd7fb8c19e25625848d59c36694e9c2ca3c..2c58d5588f3b58258ee0d4b9cbd5307363e6c4eb 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -21,6 +22,7 @@
                                "property": "angle_enable",
                                "friendlyName": "Rotation",
                                "channel": "angleEnable",
+                               "channelType": "angleEnable",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -34,6 +36,7 @@
                                "property": "use_time",
                                "friendlyName": "Run Time",
                                "channel": "usedhours",
+                               "channelType": "usedhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
@@ -44,6 +47,7 @@
                                "property": "angle",
                                "friendlyName": "Angle",
                                "channel": "angle",
+                               "channelType": "angle",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -58,6 +62,7 @@
                                "property": "poweroff_time",
                                "friendlyName": "Timer",
                                "channel": "poweroffTime",
+                               "channelType": "poweroffTime",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -72,6 +77,7 @@
                                "property": "buzzer",
                                "friendlyName": "Buzzer",
                                "channel": "buzzer",
+                               "channelType": "buzzer",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "speed_level",
                                "friendlyName": "Speed Level",
                                "channel": "speedLevel",
+                               "channelType": "speedLevel",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "speed",
                                "friendlyName": "Speed",
                                "channel": "speed",
+                               "channelType": "speed",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "natural_level",
                                "friendlyName": "Natural Level",
                                "channel": "naturalLevel",
+                               "channelType": "naturalLevel",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "",
                                "friendlyName": "Move Direction",
                                "channel": "move",
+                               "channelType": "move",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
index f2c924cf52292dfd1c743852b4dd356158e7a86e..fb20b97dafd070a6929f89d56195d519c3befd6b 100644 (file)
@@ -10,6 +10,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -23,7 +24,7 @@
                                "property": "target_temperature",
                                "friendlyName": "Target Temperature",
                                "channel": "target_temperature",
-                "type": "Number",
+                               "type": "Number",
                                "refresh": true,
                                "actions": [
                                        {
@@ -36,6 +37,7 @@
                                "property": "brightness",
                                "friendlyName": "Brightness",
                                "channel": "brightness",
+                               "channelType": "brightness",
                                "type": "Number",
                                "refresh": true,
                                "actions": [
@@ -49,6 +51,7 @@
                                "property": "buzzer",
                                "friendlyName": "Buzzer Status",
                                "channel": "buzzer",
+                               "channelType": "buzzer",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
                                ]
                        },
                        {
-                "property": "relative_humidity",
-                "friendlyName": "Relative Humidity",
-                "channel": "relative_humidity",
-                "type": "Number",
-                "refresh": true,
-                "actions": []
-            },
+                               "property": "relative_humidity",
+                               "friendlyName": "Relative Humidity",
+                               "channel": "relative_humidity",
+                               "type": "Number",
+                               "refresh": true,
+                               "actions": []
+                       },
                        {
                                "property": "child_lock",
                                "friendlyName": "Child Lock",
                                "channel": "childlock",
+                               "channelType": "childlock",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
                                "property": "temperature",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "actions": []
                                "property": "use_time",
                                "friendlyName": "Run Time",
                                "channel": "usedhours",
+                               "channelType": "usedhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
index d73fd79dbedad1918c494694cef3e8e06f2e7352..631bc743b07f5784729c1ae48659b48f52441b19 100644 (file)
@@ -8,6 +8,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -21,6 +22,7 @@
                                "property": "mode",
                                "friendlyName": "Humidifier Mode",
                                "channel": "humidifierMode",
+                               "channelType": "humidifierMode",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -35,6 +37,7 @@
                                "property": "humidity",
                                "friendlyName": "Humidity",
                                "channel": "humidity",
+                               "channelType": "humidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -44,6 +47,7 @@
                                "property": "limit_hum",
                                "friendlyName": "Humidity Set",
                                "channel": "setHumidity",
+                               "channelType": "setHumidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -72,6 +76,7 @@
                                "property": "buzzer",
                                "friendlyName": "Buzzer Status",
                                "channel": "buzzer",
+                               "channelType": "buzzer",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -86,6 +91,7 @@
                                "property": "depth",
                                "friendlyName": "Depth",
                                "channel": "depth",
+                               "channelType": "depth",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "dry",
                                "friendlyName": "Dry",
                                "channel": "dry",
+                               "channelType": "dry",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "use_time",
                                "friendlyName": "Run Time",
                                "channel": "usedhours",
+                               "channelType": "usedhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
                                "property": "speed",
                                "friendlyName": "Motor Speed",
                                "channel": "motorspeed",
+                               "channelType": "motorspeed",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "temperature",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "child_lock",
                                "friendlyName": "Child Lock",
                                "channel": "childlock",
+                               "channelType": "childlock",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
index af2e69201f9b6d6e523a169130f35dc4512ffbf8..941c5b8e92b462efb22cfac25a7af730bde879b9 100644 (file)
@@ -9,6 +9,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "actions": [
@@ -22,6 +23,7 @@
                                "property": "mode",
                                "friendlyName": "Mode",
                                "channel": "mode",
+                               "channelType": "mode",
                                "type": "String",
                                "refresh": true,
                                "ChannelGroup": "actions",
@@ -36,6 +38,7 @@
                                "property": "humidity",
                                "friendlyName": "Humidity",
                                "channel": "humidity",
+                               "channelType": "humidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -45,6 +48,7 @@
                                "property": "limit_hum",
                                "friendlyName": "Humidity Set",
                                "channel": "setHumidity",
+                               "channelType": "setHumidity",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -59,6 +63,7 @@
                                "property": "aqi",
                                "friendlyName": "Air Quality Index",
                                "channel": "aqi",
+                               "channelType": "aqi",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -68,6 +73,7 @@
                                "property": "trans_level",
                                "friendlyName": "Trans_level",
                                "channel": "translevel",
+                               "channelType": "translevel",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
@@ -91,6 +97,7 @@
                                "property": "buzzer",
                                "friendlyName": "Buzzer Status",
                                "channel": "buzzer",
+                               "channelType": "buzzer",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "actions",
                                "property": "depth",
                                "friendlyName": "Depth",
                                "channel": "depth",
+                               "channelType": "depth",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "dry",
                                "friendlyName": "Dry",
                                "channel": "dry",
+                               "channelType": "dry",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "use_time",
                                "friendlyName": "Run Time",
                                "channel": "usedhours",
+                               "channelType": "usedhours",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "SecondsToHours",
                                "property": "speed",
                                "friendlyName": "Motor Speed",
                                "channel": "motorspeed",
+                               "channelType": "motorspeed",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "Status",
                                "property": "temp_dec",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "transformation": "/10",
                                "property": "child_lock",
                                "friendlyName": "Child Lock",
                                "channel": "childlock",
+                               "channelType": "childlock",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "Status",
index 7803fc22a37288efddd7cc6ee48de30f975d9d8e..de647068aaad71c89af9200925037d582a15eada 100644 (file)
@@ -9,6 +9,7 @@
                                "property": "power",
                                "friendlyName": "Power",
                                "channel": "power",
+                               "channelType": "power",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -23,6 +24,7 @@
                                "property": "power_consume_rate",
                                "friendlyName": "Power Consumption",
                                "channel": "powerUsage",
+                               "channelType": "powerUsage",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -36,6 +38,7 @@
                                "property": "wifi_led",
                                "friendlyName": "wifi LED",
                                "channel": "led",
+                               "channelType": "led",
                                "type": "Switch",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -64,6 +67,7 @@
                                "property": "current",
                                "friendlyName": "Current",
                                "channel": "current",
+                               "channelType": "current",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",
@@ -73,6 +77,7 @@
                                "property": "temperature",
                                "friendlyName": "Temperature",
                                "channel": "temperature",
+                               "channelType": "temperature",
                                "type": "Number",
                                "refresh": true,
                                "ChannelGroup": "",