added somfy repeat option (#957)
update somfy dependency to fix bug with multiple somfy remotes
This commit is contained in:
1 parent
aaf1d17495
commit
18c8524ae0
3 files changed
+7
-2
No files matched your search
@@ -102,6 +102,9 @@ The json message must contain two properties:
|
||||
* remote: the index of the remote which is used to send the command (index start at zero)
|
||||
* command: the command which should be send with the remote as string, see [table of command names](https://github.com/Legion2/Somfy_Remote_Lib#available-commands).
|
||||
|
||||
Optionally it can contain the following property:
|
||||
* repeat: the number how often the command is repeated, default 4. Should be used to simulate long button presses, by increasing the repeat number, e.g. 20.
|
||||
|
||||
::: tip
|
||||
The middle button on physical Somfy RTS Remote controls is called "My".
|
||||
:::
|
||||
|
||||
@@ -67,9 +67,11 @@ void MQTTtoSomfy(char* topicOri, JsonObject& jsonData) {
|
||||
const String commandData = jsonData["command"];
|
||||
const Command command = getSomfyCommand(commandData);
|
||||
|
||||
const int repeat = jsonData["repeat"] | 4;
|
||||
|
||||
EEPROMRollingCodeStorage rollingCodeStorage(EEPROM_ADDRESS_START + remoteIndex * 2);
|
||||
SomfyRemote somfyRemote(RF_EMITTER_GPIO, somfyRemotes[remoteIndex], &rollingCodeStorage);
|
||||
somfyRemote.sendCommand(command);
|
||||
somfyRemote.sendCommand(command, repeat);
|
||||
# ifdef ZradioCC1101
|
||||
ELECHOUSE_cc1101.SetRx(receiveMhz); // set Receive on
|
||||
# endif
|
||||
|
||||
+1
-1
@@ -119,7 +119,7 @@ m5stack = M5Stack@0.3.1
|
||||
smartrc-cc1101-driver-lib = SmartRC-CC1101-Driver-Lib@2.5.5
|
||||
stl = https://github.com/mike-matera/ArduinoSTL.git#7411816
|
||||
shtc3 = https://github.com/sparkfun/SparkFun_SHTC3_Arduino_Library
|
||||
somfy_remote=Somfy_Remote_Lib@0.2.0
|
||||
somfy_remote=Somfy_Remote_Lib@0.3.0
|
||||
rtl_433_ESP = https://github.com/NorthernMan54/rtl_433_ESP#38ee89a
|
||||
emodbus = miq19/eModbus@1.0.0
|
||||
gfSunInverter = https://github.com/BlackSmith/GFSunInverter.git#v1.0.1
|
||||
|
||||
Reference in new issue
Block a user