adding freeRtos API from different project

This commit is contained in:
2024-11-16 15:50:59 +01:00
parent 49b3b46ffe
commit deccb3186c
14 changed files with 1061 additions and 0 deletions
+11
View File
@@ -26,6 +26,7 @@
#include "ethernet_init.h"
#include "esp_netif.h"
#include "esp_eth.h"
#include "Task.hpp"
static const char *TAG = "Watch";
static esp_eth_handle_t s_eth_handle = NULL;
@@ -107,6 +108,15 @@ static void initialize_ethernet(void)
ESP_ERROR_CHECK(esp_eth_start(s_eth_handle));
}
void LightingTask() {
ESP_LOGI(TAG, "Start Lighting");
while (true) {
ESP_LOGI("Light", "Tick");
fos::Task::delayMs(1000);
}
}
void app_main(void)
{
esp_err_t ret = nvs_flash_init();
@@ -117,4 +127,5 @@ void app_main(void)
ESP_ERROR_CHECK(ret);
// ESP_ERROR_CHECK(esp_event_loop_create_default());
initialize_ethernet();
static fos::Task lightingTask(LightingTask, "Lights", 0x4000uL);
}