-->
Page 5 of 6

Re: UDP send from esp8266

PostPosted: Tue Jan 03, 2017 1:11 pm
by picstart
I have a GPS that chirps 6 sentences per second at 9600 baud. The code reads the Serial data from the GPS char by char and when it hits the end of a sentence it Multicasts the sentence as a UDP packet. I can see many packets with a UDP Android app but many are also missing. I am getting the the 6 chirped sentences proof is I can echo them back to the Arduino Serial monitor and they are all there. I'm suspecting there is a through put block with the UDP sending. I'm using yield() after each UDP end_packet.

Does anyone have this issue....can a 9600 baud UART stream be placed into packets and put in the air without data loss?

Re: UDP send from esp8266

PostPosted: Tue Jan 03, 2017 3:13 pm
by rudy
Delivery for UDP is not guaranteed. I had read some articles from a professional action game programmer. His solution is to sent three times. But it depends on how critical the information is and in what time frame it needs to be there. You pick the right solution that meets your needs.

Re: UDP send from esp8266

PostPosted: Wed Jan 04, 2017 6:38 am
by schufti

Re: UDP send from esp8266

PostPosted: Wed Jan 04, 2017 9:09 am
by lalo_uy
I have the same problem.
My info is broadcasted every 50ms to 4 diferent displays, and not every packet is send on time or ever.
BUT if I send the info to a normal IP all goes ok, but only to one destination.
I tryed multicas & broadcast with the same result.
If the sender is a PC all goes perfect.