- Raspberry pi with Raspberry pi OS installed. Recomended 32bit "NO DISPLAY".
- $ sudo apt update
- $ bash <(curl -sL https://raw.githubusercontent.com/node-red/linux-installers/master/deb/update-nodejs-and-nodered)
- $ sudo reboot
- for more information: https://nodered.org/docs/getting-started/raspberrypi
- node-red-start - this starts the Node-RED service and displays its log output.
- node-red-stop - this stops the Node-RED service.
- node-red-restart - this stops and restarts the Node-RED service.
- node-red-log - this displays the log output of the service.
- $ sudo systemctl enable nodered.service
- $ sudo systemctl disable nodered.service
- http://{your_ip_address}:1880
- $ sudo apt update
- $ sudo apt install -y mosquitto mosquitto-clients
- $ sudo nano /etc/mosquitto/mosquitto.conf
- add this line:
listener 1883
allow_anonymous true
- $ sudo systemctl enable mosquitto.service
- $ sudo systemctl disable mosquitto.service
- $ mosquitto_sub -h {your_ip_address} -d -t testTopic on second tab:
- $ mosquitto_pub -h {your_ip_address} -d -t testTopic -m "Hello world!"
for more information of commands: https://mosquitto.org/man/mosquitto-8.html
- Open Browser with: http://{your_ip_address}:1880
- Import the test_mqtt.json file to the editor
- Edit the mqtt nodes server to your ip address save it and deploy.
- go to debug tab and trigger the inject.
- check if the message is received from the mqtt_out at the same topic if not check your mqtt configurations or the network.