I think we are talking about two different scenarios (I am talking about outgoing data, you about incoming data) wink:
I have to elaborate:
I am using the "dynamic variables" to send custom data (jsons) from the PIC to the client. These can get quite long (10k and longer).
So the data buffer is full and needs to be split into multiple messages, since the socket tx-buffer is much smaller.
It looks like just one TX-socket buffer is send for each timeslot (set by TCPIP_STACK_TICK_RATE).
To reproduce, I have just tried the Harmony example "web_server_nvm_mpfs" with the PIC32MZ EFM StarterKit:
* If you set the TCPIP_HTTP_TASK_RATE to 33 you can see several delays in the range from 10 to 33ms when fetching a html page. (all_30ms.png)
* If you set the TCPIP_HTTP_TASK_RATE to 1, you see delays up to 1ms (all_1ms.png)
* If the function TCPIP_HTTP_Process() is called within the superloop SYS_Tasks() the delays get much smaller. (all_http_net_manual_call.png)
This might not matter when the transfered data is small, but when your website is 5MB big and other, frequently transfered data is 10k and larger, these delays really hurt.
So the delay (at least for TCPIP_HTTP_TASK_RATE) limits the throughput. It looks like the other delays are not as influential as I thought.
I will call the tcpip_http_process() function in my web-task for now (unless you know a reason not to do that). Edit
: I just saw that the example is using HTTP not HTTPNet... The way the tasks are called look similar though.
post edited by David Green - 2020/03/24 06:45:06