mirror of
https://gitee.com/Lyon1998/pikapython.git
synced 2025-01-15 17:02:53 +08:00
16 lines
305 B
C
16 lines
305 B
C
#include <stdint.h>
|
|
#include "BaseObj.h"
|
|
#include "freertos/FreeRTOS.h"
|
|
#include "freertos/task.h"
|
|
|
|
#include "ESP32_common.h"
|
|
|
|
void ESP32_Time_sleep_ms(PikaObj *self, int ms)
|
|
{
|
|
vTaskDelay(pdMS_TO_TICKS(ms));
|
|
}
|
|
void ESP32_Time_sleep_s(PikaObj *self, int s)
|
|
{
|
|
vTaskDelay(pdMS_TO_TICKS(1000 * s));
|
|
}
|