mirror of
https://github.com/lehanspb/tuya-mqtt.git
synced 2025-12-18 00:10:20 +00:00
Update README.md
This commit is contained in:
14
README.md
14
README.md
@@ -62,11 +62,12 @@ Set DEBUG=-* & node c:/openhab2/userdata/etc/scripts/tuya-mqtt.js
|
|||||||
tuya/ver3.3/<tuyAPI-id>/<tuyAPI-key>/<tuyAPI-ip/state
|
tuya/ver3.3/<tuyAPI-id>/<tuyAPI-key>/<tuyAPI-ip/state
|
||||||
tuya/ver3.3/<tuyAPI-id>/<tuyAPI-key>/<tuyAPI-ip>/command
|
tuya/ver3.3/<tuyAPI-id>/<tuyAPI-key>/<tuyAPI-ip>/command
|
||||||
```
|
```
|
||||||
Example command topic to set the device state:
|
### Example command topic to set the device state:
|
||||||
```
|
```
|
||||||
tuya/<tuyAPI-id>/<tuyAPI-key>/<tuyAPI-ip>/command
|
tuya/<tuyAPI-id>/<tuyAPI-key>/<tuyAPI-ip>/command
|
||||||
|
```
|
||||||
Example MQTT message payload for basic command (assumes DPS 1 is "on/off" control):
|
### Example MQTT message payload for basic command (assumes DPS 1 is "on/off" control):
|
||||||
|
```
|
||||||
"ON"
|
"ON"
|
||||||
"OFF"
|
"OFF"
|
||||||
"on"
|
"on"
|
||||||
@@ -75,15 +76,16 @@ Example command topic to set the device state:
|
|||||||
"0"
|
"0"
|
||||||
"toggle"
|
"toggle"
|
||||||
"TOGGLE"
|
"TOGGLE"
|
||||||
|
```
|
||||||
Example MQTT message payload for advanced commands (set any DPS value):
|
### Example MQTT message payload for advanced commands (set any DPS value):
|
||||||
|
```
|
||||||
"{ \"dps\": 1, \"set\": true }"
|
"{ \"dps\": 1, \"set\": true }"
|
||||||
"{ \"dps\": 7, \"set\": true }"
|
"{ \"dps\": 7, \"set\": true }"
|
||||||
"{ \"multiple\": true, \"data\": { \"1\": true, \"7\": true } }"
|
"{ \"multiple\": true, \"data\": { \"1\": true, \"7\": true } }"
|
||||||
"{ \"schema\": true }"
|
"{ \"schema\": true }"
|
||||||
"{ \"multiple\": true, \"data\": { \"1\": true, \"2\": \"scene_4\" } }"
|
"{ \"multiple\": true, \"data\": { \"1\": true, \"2\": \"scene_4\" } }"
|
||||||
"{ \"multiple\": true, \"data\": { \"1\": true, \"2\": \"scene\", \"6\": \"c479000025ffc3\" } }"
|
"{ \"multiple\": true, \"data\": { \"1\": true, \"2\": \"scene\", \"6\": \"c479000025ffc3\" } }"
|
||||||
|
```
|
||||||
Command topic for color change of lightbulb
|
Command topic for color change of lightbulb
|
||||||
tuya/<tuyAPI-id>/<tuyAPI-key>/<tuyAPI-ip>/color
|
tuya/<tuyAPI-id>/<tuyAPI-key>/<tuyAPI-ip>/color
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user