Controlling connected devices in real time with MQTT and Go
Four building blocks
- Flutter: dashboard, controls and alerts
- Go · Gin: REST API, authentication, history
- MQTT: pub / sub messaging between the API and the devices
- Devices: sensors and actuators
Why MQTT
Publish / subscribe decouples the app from the devices: each device publishes its state, and the API subscribes to the topics it cares about.