Add sleep function
This commit is contained in:
parent
9f4fd4e143
commit
3b553ecb39
1 changed files with 8 additions and 0 deletions
8
Firmware/src/FreeRTOS/Util.h
Normal file
8
Firmware/src/FreeRTOS/Util.h
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
#pragma once
|
||||||
|
#include <Arduino.h>
|
||||||
|
|
||||||
|
namespace freertos {
|
||||||
|
/// @brief Blocks the task for the specified amount of time
|
||||||
|
/// @param time in milliseconds
|
||||||
|
void sleep(int time) { vTaskDelay(time * portTICK_PERIOD_MS); }
|
||||||
|
} // namespace freertos
|
Loading…
Reference in a new issue