-->
Page 1 of 1

Using a cheap W5500 Ethernet board as an MQTT gateway

PostPosted: Wed Mar 07, 2018 6:33 am
by PuceBaboon
This project uses one of the cheap, W5500-based ethernet modules (available from EBay for about $4.50) to implement an ESP-Now to MQTT gateway.

https://esp8266hints.wordpress.com/2018/02/13/adding-an-ethernet-port-to-your-esp-revisited/

The code is based on TornTrousers' ESP-Now demo, with the ESP8266 driving the W5500 board via the SPI (plus one extra pin to control the W5500 reset). Multiple (battery-powered) sensor nodes connect at regular intervals to the gateway, transferring a data packet. The data is then sent by the ESP8266, via the wired ethernet interface, to the MQTT broker. Using ESP-Now, the sensor nodes are only awake for about half a second (including the time taken to read the sensor), so battery drain is very much reduced compared to a normal WiFi connection.

Although this particular demo uses ESP-Now, the same configuration and most of the code could be used to provide a WiFi to wired MQTT gateway for virtually any application (the RF connection between ESPs doesn't have to be ESP-Now).

Re: Using a cheap W5500 Ethernet board as an MQTT gateway

PostPosted: Wed Mar 07, 2018 7:10 am
by Shivanikittu
That's interesting, Using Ethernet board for publish-subscribe-based messaging protocol.

Re: Using a cheap W5500 Ethernet board as an MQTT gateway

PostPosted: Thu Mar 08, 2018 2:57 am
by torntrousers
Nice!

Re: Using a cheap W5500 Ethernet board as an MQTT gateway

PostPosted: Thu Mar 08, 2018 3:29 am
by PuceBaboon
@torntrousers - On the shoulders of giants. Thank you :!: