Merge PR #279: Shelly: Add support for the Shelly Dimmer 2

This commit is contained in:
Jenkins nymea 2020-07-21 10:22:11 +02:00
commit a865dec36e
4 changed files with 12 additions and 12 deletions

View File

@ -8,7 +8,7 @@ The currently supported devices are:
* Shelly 2.5 * Shelly 2.5
* Shelly Plug / PlugS * Shelly Plug / PlugS
* Shelly RGBW2 * Shelly RGBW2
* Shelly Dimmer * Shelly Dimmer / Dimmer 2
## Requirements ## Requirements
Shelly devices communicate with via MQTT. This means, in order to add Shelly devices to nymea, the nymea instance is required Shelly devices communicate with via MQTT. This means, in order to add Shelly devices to nymea, the nymea instance is required

View File

@ -199,7 +199,7 @@ void IntegrationPluginShelly::discoverThings(ThingDiscoveryInfo *info)
} else if (info->thingClassId() == shellyRgbw2ThingClassId) { } else if (info->thingClassId() == shellyRgbw2ThingClassId) {
namePattern = QRegExp("^shellyrgbw2-[0-9A-Z]+$"); namePattern = QRegExp("^shellyrgbw2-[0-9A-Z]+$");
} else if (info->thingClassId() == shellyDimmerThingClassId) { } else if (info->thingClassId() == shellyDimmerThingClassId) {
namePattern = QRegExp("^shellydimmer-[0-9A-Z]+$"); namePattern = QRegExp("^shellydimmer(2)?-[0-9A-Z]+$");
} else if (info->thingClassId() == shelly25ThingClassId) { } else if (info->thingClassId() == shelly25ThingClassId) {
namePattern = QRegExp("^shellyswitch25-[0-9A-Z]+$"); namePattern = QRegExp("^shellyswitch25-[0-9A-Z]+$");
} }

View File

@ -365,7 +365,7 @@
{ {
"id": "3a1d6fc1-c623-4b45-9c81-1573fcc15f99", "id": "3a1d6fc1-c623-4b45-9c81-1573fcc15f99",
"name": "shellyDimmer", "name": "shellyDimmer",
"displayName": "Shelly Dimmer", "displayName": "Shelly Dimmer / Dimmer 2",
"createMethods": ["discovery"], "createMethods": ["discovery"],
"interfaces": ["dimmablelight", "connectable"], "interfaces": ["dimmablelight", "connectable"],
"paramTypes": [ "paramTypes": [

View File

@ -4,38 +4,38 @@
<context> <context>
<name>IntegrationPluginShelly</name> <name>IntegrationPluginShelly</name>
<message> <message>
<location filename="../integrationpluginshelly.cpp" line="620"/> <location filename="../integrationpluginshelly.cpp" line="629"/>
<source>Unable to find the thing in the network.</source> <source>Unable to find the thing in the network.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../integrationpluginshelly.cpp" line="631"/> <location filename="../integrationpluginshelly.cpp" line="640"/>
<source>Roller shutter mode can&apos;t be mixed with relay mode. Please configure both connected devices to control a shutter or relays.</source> <source>Roller shutter mode can&apos;t be mixed with relay mode. Please configure both connected devices to control a shutter or relays.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../integrationpluginshelly.cpp" line="636"/> <location filename="../integrationpluginshelly.cpp" line="645"/>
<location filename="../integrationpluginshelly.cpp" line="641"/> <location filename="../integrationpluginshelly.cpp" line="650"/>
<source>For using a roller shutter, one channel must be set to up, the other to down.</source> <source>For using a roller shutter, one channel must be set to up, the other to down.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../integrationpluginshelly.cpp" line="652"/> <location filename="../integrationpluginshelly.cpp" line="663"/>
<source>Error creating MQTT channel. Please check MQTT server settings.</source> <source>Error creating MQTT channel. Please check MQTT server settings.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../integrationpluginshelly.cpp" line="691"/> <location filename="../integrationpluginshelly.cpp" line="704"/>
<source>Username and password not set correctly.</source> <source>Username and password not set correctly.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../integrationpluginshelly.cpp" line="693"/> <location filename="../integrationpluginshelly.cpp" line="706"/>
<source>Error connecting to Shelly device.</source> <source>Error connecting to Shelly device.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../integrationpluginshelly.cpp" line="702"/> <location filename="../integrationpluginshelly.cpp" line="715"/>
<source>Unexpected data received from Shelly device.</source> <source>Unexpected data received from Shelly device.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
@ -665,7 +665,7 @@ The name of the plugin shelly ({6162773b-0435-408c-a4f8-7860d38031a9})</extracom
</message> </message>
<message> <message>
<location filename="../../../build-nymea-plugins-Desktop-Debug/shelly/plugininfo.h" line="728"/> <location filename="../../../build-nymea-plugins-Desktop-Debug/shelly/plugininfo.h" line="728"/>
<source>Shelly Dimmer</source> <source>Shelly Dimmer / Dimmer 2</source>
<extracomment>The name of the ThingClass ({3a1d6fc1-c623-4b45-9c81-1573fcc15f99})</extracomment> <extracomment>The name of the ThingClass ({3a1d6fc1-c623-4b45-9c81-1573fcc15f99})</extracomment>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>