mirror of
https://github.com/esp8266/Arduino.git
synced 2025-06-25 06:22:11 +03:00
Automatically call yield() in WiFiClient::available if called more than once
This commit is contained in:
@ -49,6 +49,13 @@ extern void (*__init_array_end)(void);
|
||||
static cont_t g_cont;
|
||||
static os_event_t g_loop_queue[LOOP_QUEUE_SIZE];
|
||||
|
||||
static uint32_t g_micros_at_task_start;
|
||||
|
||||
extern "C" uint32_t esp_micros_at_task_start()
|
||||
{
|
||||
return g_micros_at_task_start;
|
||||
}
|
||||
|
||||
extern "C" void abort()
|
||||
{
|
||||
while(1){}
|
||||
@ -86,6 +93,7 @@ static void loop_wrapper()
|
||||
|
||||
static void loop_task(os_event_t *events)
|
||||
{
|
||||
g_micros_at_task_start = system_get_time();
|
||||
cont_run(&g_cont, &loop_wrapper);
|
||||
if (cont_check(&g_cont) != 0)
|
||||
{
|
||||
|
Reference in New Issue
Block a user