For creating an IOT application, the most important thing is creating a platform allows user to monitor and control remotely user’s application.
As the current development on IOT application, there were a lot of IOT clouds allowing user to use their platform to create their own dream.
MQTT is one of the protocols will be used in IOT cloud. It required simple coding and data formatting to create a communication with IOT cloud.
MQTT is a protocol allows devices publish formatted data to a MQTT broker’s channel as a temporary storage. If there is a device has subscribed that related channel, it will collect this information from the MQTT broker for its own purpose.
As the MQTT could be consider as a real time communication, this only required a simple coding to allow low end solution like WIZnet with Raspberry Pi PICO to have an opportunity to create a IOT application on cloud platforms.
Adding MQTT protocol Procedure:
- Add adafruit_minimqtt library
- Basic WIZnet’s networking setups (Please refer link 5 and 6)
- Data formmating
- MQTT client setup
- Subscribe channels
- Connect MQTT broker
- Publish information to broker or Collect information from subscribed channels
- WIZnet’s MQTT example – https://maker.wiznet.io/2021/10/21/wiznet-ethernet-hatrp2040-mqtt-publish-mosquitto/
- WIZnet’s ASW cloud example – https://maker.wiznet.io/2021/12/31/connect-w5100s-evb-pico-to-aws-cloud/
- MQTT – https://mqtt.org/
- WIZnet’s general MQTT coding example – https://github.com/Wiznet/RP2040-HAT-CircuitPython/tree/master/examples/MQTT/PubSub
- How to add DHCO into your Raspberry Pi Pico? – https://www.iwiznet.cn/2021/12/20/how-to-add-dhcp-into-your-raspberry-pi-pico/
- How to create a simple TCP/IP connection? – https://www.iwiznet.cn/2021/12/15/how-to-create-a-simple-tcp-ip-connection/