me-no-dev/ESPAsyncTCP

About waiting for data

fabitom opened this issue · 1 comments

Hi, is there any way to wait some time when there is too much data ? I just trying ESPAsync client and in example provided I need wait. I fill my data buffer in client->onData but when my buffer is full I need wait some time (other process takes data from my buffer).
When I use delay(1) inside client->onData() function program will crash. I probably don't quite understand the concept of client->onConnect ->onData ;(
Can I use delay() in onData function ?

Ok, I think I need SyncClient for that :)