MQTT Client Command Line Application for Windows, OSX and Linux
MQTT Client CommandsThe MQTT messages are delivered asynchronously (“push”) through publish subscribe architecture.
Component supports MQTT 3.1.1 protocol and latest 5.0 protocol.
Three QoS for message delivery could be achieved using MQTT
Supports MQTT over WebSockets and over TCP (encrypted and none encrypted).
sgcMQTTClient Win32
MQTTClient Client Win32
sgcMQTTClient Win64
MQTTClient Client Win64
sgcMQTTClient OSX64
MQTTClient Client OSX64
sgcMQTTClient OSXARM64
MQTTClient Client OSXARM64
sgcMQTTClient Linux64
MQTTClient Client Linux64
How Open a new MQTT connectionExample: open a tcp mqtt connection to test.mosquitto.org
Example: open a websocket mqtt connection to test.mosquitto.org
|
How Subscribe / UnSubscribeExample: subscribe to topic "myTopic"
Example: unsubscribe from topic "myTopic"
|
How Enable MQTT OptionsExample: enable mqtt 5.0
Example: enable authentication
Example: Enable heartbeat every 30 seconds.
|
Close ConnectionExample: close connection
|
TCP ServerAll console applications can run an internal TCP Server that allows to send and receive commands as if were written directly on the console application. Just start the application with the command -server and a new server will be started listening on port 8080. Example: if you want enable the server on WebSocket client, start the console application as follows:
Find below the full TCP Server parameters:
If the server is enabled, a client connected to this server can send any JSON message and will receive any response as if was written directly from console application. Example: if you want enable server on IP 192.168.1.1 and Port 5412
|