Chat freely about anything...

User avatar
By whiledo
#10694 Hi,

I noticed that it is not possible to create an UDP server on the ESP8266.
Could someone suggest me the best way to find an ESP8266 module previously registered on my network (only STA mode)?
How I can find them without the possibility to send an UDP broadcast message?

Any idea?
User avatar
By gerardwr
#10878
whiledo wrote:I noticed that from firmware version 0.94 the possibility to create an UDP Server disappear.


Please note that I have no hands-on experience with UDP and the ESP8266, but setting up an UDP server in the ESP would be the way to go. You will probably need a "multicast" UDP server, if case you have more ESP's on the network that you would like to address.

In SDK0.9.5 there are references to UDP, in file espconn.h, not sure why you think UDP was removed.

Some alternate suggestions as "food for thought":
- On a PC use a "broadcast ping" on your network, and evaluate the responses
- On a (Linux/OSX) PC use the ARP command to get IP/Mac addresses, all ESP's seem to have the same first 2 bytes in the Mac-address.
User avatar
By whiledo
#10940 Thank you Gerard for your answer.
You are right and finally I discovered how to create an UDP Server on ESP8226.
As you know there are so many documents, posts and information about ESP8226 that it is very difficult each time to find the right way to follow.
My first error was to think that to create an UDP Server I need to use the AT+CIPSERVER command , but it is not the right way.
This command will works only for TCP Server.
So if someone else is still struggling with this matter I can say to you that the right command to use is AT+CIPSTART….. yes it was strange also for me but when in UDP mode there are two more parameters that will do the job.
Have a look to the "AT Espressif AT Instruction set” document for more information or feel free to ask me if you want more details.