sstaub / Ethernet3

Ethernet library for Arduino and Ethernetshield2 / WIZ550io / WIZ850io / USR-ES1 with Wiznet W5500 chip
Other
82 stars 33 forks source link

udp parsePacket is blocking #11

Closed brendanmatkin closed 6 years ago

brendanmatkin commented 6 years ago

EthernetUdp3::parsePacket() should be non blocking.

I'm pretty sure the problem stems from the do-while loop in w5500.getRXReceivedSize(_sock). Not sure how to fix at the moment.

Might be worth implementing some version of Ethernet.socketRecvAvailable(sockindex) > 0 as used in socket utility of Teensy version of Ethernet?

sstaub commented 6 years ago

I canˋt figure out the problem without an short example code. Work the code on Teensy? May be you should make an issue on the github site of the original library.