/go-mqtt-example

mqtt go example

Primary LanguageGo

Go MQTT Example

This is a simple Go example on how to interact with MQTT.

This example sends a messages every second and the same process receive the message and prints it to the console.

Getting started

  • Make sure you have dep installed
  • Clone this repo git clone https://github.com/NagendraPY/go-mqtt-example.git
  • Rplace local hardcode mqtt url with your mqtt topic.
  • Run make to download dependencies and run the application or simple run command go run main.go