About MQTT

Get started with Wemos D1 R2

Mosquitto (MQTT broker)

Make sure the service named Mosquitto Broker is running on your computer.

mosquitto_sub -h “localhost” (-p “9487” -u “username” -P “pwd”) -t “topic/#” (-d)
mosquitto_pub -h “localhost” (-p “9487” -u “username” -P “pwd”) -m “Publishing Message” -t “topic/”

PubSubClient (arduino library)

example for esp8266