Adafruit.io MQTT Bridge

Simple bridge that copies data from Adafruit's MQTT broker to your local MQTT.

[{"id":"7e3063a5.cd8134","type":"mqtt in","z":"703f0e8d.904e08","name":"Adafruit","topic":"fileark/f/homeautomation","qos":"0","broker":"ba85591e.eca128","x":133,"y":130,"wires":[["153ef2b4.465425","504c2b84.334844"]]},{"id":"504c2b84.334844","type":"debug","z":"703f0e8d.904e08","name":"Debug","active":true,"console":"false","complete":"payload","x":535,"y":129,"wires":[]},{"id":"a448539b.43d8a","type":"mqtt out","z":"703f0e8d.904e08","name":"LocalHiveMQ","topic":"","qos":"0","retain":"false","broker":"1e028869.6a935","x":555,"y":178,"wires":[]},{"id":"153ef2b4.465425","type":"function","z":"703f0e8d.904e08","name":"Forward Messages","func":"if (msg.payload == \"OpenGarageDoor\")  {\n   return {topic:'GarageDoor/',payload:'OpenGarageDoor'}; } \n   \nif (msg.payload == \"CloseGarageDoor\")  {\n   return {topic:'GarageDoor/',payload:'CloseGarageDoor'}; }\n   \nif (msg.payload == \"RingDinnerBell\")  {\n   return {topic:'DoorBell',payload:'Chime5'}; }\n\nif (msg.payload == \"GarageACON\")  {\n   return {topic:'Garage/AC',payload:'On'}; } \n\nif (msg.payload == \"GarageACOFF\")  {\n   return {topic:'Garage/AC',payload:'Off'}; } \n   \nif (msg.payload == \"GarageLightOn\")  {\n   return {topic:'Garage/Light',payload:'On'}; } \n\nif (msg.payload == \"GarageLightOff\")  {\n   return {topic:'Garage/Light',payload:'Off'}; }    ","outputs":1,"noerr":0,"x":341,"y":160,"wires":[["a448539b.43d8a","504c2b84.334844"]]},{"id":"ba85591e.eca128","type":"mqtt-broker","z":"","broker":"io.adafruit.com","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"15","cleansession":true,"willTopic":"","willQos":"0","willPayload":"","birthTopic":"","birthQos":"0","birthPayload":""},{"id":"1e028869.6a935","type":"mqtt-broker","z":"","broker":"Localhost","port":"1883","clientid":"LocalNodeRed","usetls":false,"compatmode":true,"keepalive":"15","cleansession":true,"willTopic":"","willQos":"0","willPayload":"","birthTopic":"","birthQos":"0","birthPayload":""}]
ElectronHacks

Flow Info

created 7 months, 2 weeks ago

Node Types

Core
  • debug (x1)
  • function (x1)
  • mqtt in (x1)
  • mqtt out (x1)
  • mqtt-broker (x2)

Tags

  • Adafruit
  • mqtt
  • bridge
Copy this flow JSON to your clipboard and then import into Node-RED using the Import From > Clipboard (Ctrl-I) menu option