From 26f6c2bb4cf7220e95d4e9498c8726fdcc014659 Mon Sep 17 00:00:00 2001 From: Jefferson Lopes Date: Sat, 2 Mar 2024 15:35:09 -0300 Subject: [PATCH] remove task example --- ECU_front/main/main.c | 26 +++++++++++++------------- components/rollover/src/rollover.c | 19 ------------------- 2 files changed, 13 insertions(+), 32 deletions(-) diff --git a/ECU_front/main/main.c b/ECU_front/main/main.c index 91af924..e095074 100755 --- a/ECU_front/main/main.c +++ b/ECU_front/main/main.c @@ -28,9 +28,9 @@ static const char* TAG = "ECU_front"; static const gpio_num_t alive_pin = GPIO_NUM_2; -// static const int cr = 8; // coding rate -// static const int sbw = 1; // signal bandwidth -// static const int sf = 7; // spreading factor rate +static const int cr = 8; // coding rate +static const int sbw = 1; // signal bandwidth +static const int sf = 7; // spreading factor rate void app_main(void) { ESP_LOGW(TAG, "ECU front v5"); @@ -42,7 +42,7 @@ void app_main(void) { print_mac_address(); - // system_lora_init(cr, sbw, sf); + system_lora_init(cr, sbw, sf); // -----fire up tasks----- xTaskCreatePinnedToCore( @@ -65,15 +65,15 @@ void app_main(void) { APP_CPU_NUM // core number ); - // xTaskCreatePinnedToCore( - // task_lora_sender, // task function - // "lora sender", // task name - // 4096, // stack size - // NULL, // parameters - // 8, // priority - // &th_lora, // handler - // PRO_CPU_NUM // core number - // ); + xTaskCreatePinnedToCore( + task_lora_sender, // task function + "lora sender", // task name + 4096, // stack size + NULL, // parameters + 8, // priority + &th_lora, // handler + PRO_CPU_NUM // core number + ); xTaskCreatePinnedToCore( task_rollover, // task function diff --git a/components/rollover/src/rollover.c b/components/rollover/src/rollover.c index 5529624..3b3be46 100644 --- a/components/rollover/src/rollover.c +++ b/components/rollover/src/rollover.c @@ -2,25 +2,6 @@ static const char *TAG = "task_rollover"; -void task_example(void *arg){ - (void)arg; - - // create task variables - - // show remaining task space - print_task_remaining_space(); - - for (;;) { - // do something - ESP_LOGW(TAG, "do some work"); - - // some delay - vTaskDelay(pdMS_TO_TICKS(500)); - - vTaskDelay(pdMS_TO_TICKS(1)); // free up the processor - } -} - void task_rollover(void *arg){ (void)arg;