njh / EtherCard

EtherCard is an IPv4 driver for the ENC28J60 chip, compatible with Arduino IDE
https://www.aelius.com/njh/ethercard/
GNU General Public License v2.0
1.03k stars 455 forks source link

Concurrent requests possible? #414

Open ras-marques opened 3 years ago

ras-marques commented 3 years ago

I have been looking at the code and it seemed to me that work was started to make up to 8 concurrent requests possible.

Each time I log the result of tcpSend, the session number does increase, but looking at tcp_datafill_cb that takes fd as the argument, fd is not used. Instead, result_fd is filled with a dummy 123 value.

My goal is to be able to send up to 8 requests to a REST API from the Arduino before the reply from the server to the first request comes back. Is this even possible using the ENC28J60? Did I understand correctly that the work is only half done as of this date? I wouldn't mind expanding the library a bit to make this possible.