mirror of https://github.com/arendst/Tasmota.git
Merge pull request #10706 from s-hadinger/zigbee_so_syn
Add Zigbee SetOption synonyms
This commit is contained in:
commit
61e13b79f4
|
@ -529,6 +529,12 @@
|
|||
|
||||
// Commands xdrv_23_zigbee.ino
|
||||
#define D_PRFX_ZB "Zb"
|
||||
#define D_SO_ZIGBEE_NAMEKEY "NameKey"
|
||||
#define D_SO_ZIGBEE_DEVICETOPIC "DeviceTopic"
|
||||
#define D_SO_ZIGBEE_NOPREFIX "NoPrefix"
|
||||
#define D_SO_ZIGBEE_ENDPOINTSUFFIX "EndpointSuffix"
|
||||
#define D_SO_ZIGBEE_NOAUTOBIND "NoAutoBind"
|
||||
#define D_SO_ZIGBEE_NAMETOPIC "NameTopic"
|
||||
#define D_ZIGBEE_NOT_STARTED "Zigbee not started"
|
||||
#define D_CMND_ZIGBEE_PERMITJOIN "PermitJoin"
|
||||
#define D_CMND_ZIGBEE_STATUS "Status"
|
||||
|
|
|
@ -24,6 +24,9 @@
|
|||
#include "UnishoxStrings.h"
|
||||
|
||||
const char kZbCommands[] PROGMEM = D_PRFX_ZB "|" // prefix
|
||||
// SetOption synonyms
|
||||
D_SO_ZIGBEE_NAMEKEY "|" D_SO_ZIGBEE_DEVICETOPIC "|" D_SO_ZIGBEE_NOPREFIX "|" D_SO_ZIGBEE_ENDPOINTSUFFIX "|" D_SO_ZIGBEE_NOAUTOBIND "|"
|
||||
D_SO_ZIGBEE_NAMETOPIC "|"
|
||||
#ifdef USE_ZIGBEE_ZNP
|
||||
D_CMND_ZIGBEEZNPSEND "|" D_CMND_ZIGBEEZNPRECEIVE "|"
|
||||
#endif // USE_ZIGBEE_ZNP
|
||||
|
@ -39,6 +42,12 @@ const char kZbCommands[] PROGMEM = D_PRFX_ZB "|" // prefix
|
|||
D_CMND_ZIGBEE_CONFIG "|" D_CMND_ZIGBEE_DATA
|
||||
;
|
||||
|
||||
const uint8_t kZbSynonyms[] PROGMEM = {
|
||||
6, // number of synonyms
|
||||
83, 89, 100, 101, 110,
|
||||
112,
|
||||
};
|
||||
|
||||
void (* const ZigbeeCommand[])(void) PROGMEM = {
|
||||
#ifdef USE_ZIGBEE_ZNP
|
||||
&CmndZbZNPSend, &CmndZbZNPReceive,
|
||||
|
@ -2182,7 +2191,7 @@ bool Xdrv23(uint8_t function)
|
|||
ZigbeeInit();
|
||||
break;
|
||||
case FUNC_COMMAND:
|
||||
result = DecodeCommand(kZbCommands, ZigbeeCommand);
|
||||
result = DecodeCommand(kZbCommands, ZigbeeCommand, kZbSynonyms);
|
||||
break;
|
||||
case FUNC_SAVE_BEFORE_RESTART:
|
||||
#ifdef USE_ZIGBEE_EZSP
|
||||
|
|
Loading…
Reference in New Issue