Login | Register 
FEATURES
APPLICATIONS
DOWNLOADS
EDUCATION
BLOG
WIKI
FORUM
STORE

Simple MQTT example

Helpful techniques for working with TouchDesigner. Answers only, no questions.

Simple MQTT example

Postby Achim » Fri Jun 08, 2018 3:39 am

Demo connects to: broker.hivemq.com and in onConnect() subscribes to the topic: "testTD/myTopic"

You can use http://www.hivemq.com/demos/websocket-client/#data as a second client, just subscribe to the same topic: "testTD/myTopic"

Run the publish script to send data (in this case json) to that topic, you will get a callback onMessage() when data was sent to that topic

Run the "deleteRetained_topic" script to delete retained data from the broker. You can read up on retained data and other mqtt essentials here: https://www.hivemq.com/mqtt-essentials/
Attachments
mqtt.toe
(7.71 KiB) Downloaded 59 times

Cologne area TD artists? Let’s get in touch

Achim
 
Posts: 1681
Joined: Wed Nov 14, 2007 1:52 pm
Location: Cologne

Return to Techniques

Who is online

Users browsing this forum: ben and 2 guests