Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/pcpratheesh/mqtt-publisher-subscriber-golang

This repository contains a simple example of an MQTT producer and consumer implemented in Golang using the popular "paho.mqtt.golang" library. The producer publishes simulated temperature readings, and the consumer subscribes to the topic to receive and display the messages.
https://github.com/pcpratheesh/mqtt-publisher-subscriber-golang

Last synced: 12 days ago
JSON representation

This repository contains a simple example of an MQTT producer and consumer implemented in Golang using the popular "paho.mqtt.golang" library. The producer publishes simulated temperature readings, and the consumer subscribes to the topic to receive and display the messages.

Awesome Lists containing this project

README

        

# mqtt-publisher-subscriber-golang
This repository contains a simple example of an MQTT publisher and subscriber implemented in Golang using the popular "paho.mqtt.golang" library. The publisher publishes simulated temperature readings, and the subscriber subscribes to the topic to receive and display the messages.

**Key Features**:
- MQTT Publisher: Publishes messages to an MQTT broker at regular intervals.
- MQTT subscriber: Subscribes to the topic and displays received messages.
- Lightweight: Built with Golang and uses the lightweight MQTT protocol, making it efficient for IoT and M2M applications.

**Usage**:
1. Clone the repository: `git clone https://github.com/pcpratheesh/mqtt-publisher-subscriber-golang`
2. Make sure you have Golang installed on your system.
3. Install the required dependencies: `go get -u github.com/eclipse/paho.mqtt.golang`
4. Run the MQTT publisher: `go run publisher.go`
5. Run the MQTT subscriber: `go run subscriber.go`