2019年6月23日 星期日

Understanding The Node-Red Message Object (將mqtt節點 輸出到 msg)

A msg object that originates from an MQTT input node has the following properties:
  • payload
  • topic
  • qos
  • _msgid
  • retain









[{"id":"175e7d84.8bf972","type":"inject","z":"afe7af4b.c2261","name":"","topic":"","payload":"ON","payloadType":"str","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":130,"y":1120,"wires":[["6c3ddc5e.369654"]]},{"id":"c5a83572.51d158","type":"inject","z":"afe7af4b.c2261","name":"","topic":"","payload":"OFF","payloadType":"str","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":130,"y":1160,"wires":[["6c3ddc5e.369654"]]},{"id":"6c3ddc5e.369654","type":"mqtt out","z":"afe7af4b.c2261","name":"","topic":"alex9ufo/LED","qos":"0","retain":"true","broker":"b0f7c1ff.aede5","x":380,"y":1140,"wires":[]},{"id":"2360d725.8f5bb8","type":"debug","z":"afe7af4b.c2261","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","x":370,"y":1240,"wires":[]},{"id":"8813311a.4d943","type":"mqtt in","z":"afe7af4b.c2261","name":"","topic":"alex9ufo/LED","qos":"2","broker":"b0f7c1ff.aede5","x":130,"y":1240,"wires":[["2360d725.8f5bb8"]]},{"id":"b0f7c1ff.aede5","type":"mqtt-broker","z":"","name":"mqtt","broker":"broker.mqtt-dashboard.com","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"60","cleansession":true,"willTopic":"","willQos":"0","willPayload":"","birthTopic":"","birthQos":"0","birthRetain":"true","birthPayload":""}]






[{"id":"175e7d84.8bf972","type":"inject","z":"afe7af4b.c2261","name":"","topic":"","payload":"ON","payloadType":"str","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":130,"y":1120,"wires":[["6c3ddc5e.369654","2360d725.8f5bb8"]]},{"id":"c5a83572.51d158","type":"inject","z":"afe7af4b.c2261","name":"","topic":"","payload":"OFF","payloadType":"str","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":130,"y":1160,"wires":[["6c3ddc5e.369654","2360d725.8f5bb8"]]},{"id":"6c3ddc5e.369654","type":"mqtt out","z":"afe7af4b.c2261","name":"","topic":"alex9ufo/LED","qos":"0","retain":"true","broker":"b0f7c1ff.aede5","x":380,"y":1140,"wires":[]},{"id":"2360d725.8f5bb8","type":"debug","z":"afe7af4b.c2261","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","x":370,"y":1240,"wires":[]},{"id":"8813311a.4d943","type":"mqtt in","z":"afe7af4b.c2261","name":"","topic":"alex9ufo/LED","qos":"2","broker":"b0f7c1ff.aede5","x":130,"y":1240,"wires":[["2360d725.8f5bb8"]]},{"id":"b0f7c1ff.aede5","type":"mqtt-broker","z":"","name":"mqtt","broker":"broker.mqtt-dashboard.com","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"60","cleansession":true,"willTopic":"","willQos":"0","willPayload":"","birthTopic":"","birthQos":"0","birthRetain":"true","birthPayload":""}]

沒有留言:

張貼留言

113 學年度第 1 學期 RFID應用課程 Arduino程式

113 學年度第 1 學期 RFID應用課程 Arduino程式 https://www.mediafire.com/file/zr0h0p3iosq12jw/MFRC522+(2).7z/file 內含修改過後的 MFRC522 程式庫 (原程式有錯誤) //定義MFRC522...