更新(hello APP): APP任务已经可以启动

This commit is contained in:
Alvin Young 2022-09-29 22:07:17 +08:00
parent 6bf1ae00d9
commit 6bfd4ffdee
2 changed files with 13 additions and 2 deletions

10
main/APP/CMakeLists.txt Normal file
View File

@ -0,0 +1,10 @@
cmake_minimum_required(VERSION 3.5)
#_SUB_SOURCES
aux_source_directory(${CMAKE_CURRENT_SOURCE_DIR} _SUB_SOURCES)
#_SOURCES
list(APPEND _SOURCES ${_SUB_SOURCES})
#_SOURCES
set(_SOURCES ${_SOURCES} PARENT_SCOPE)
add_subdirectory(app_task_hello)

View File

@ -21,7 +21,7 @@
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
static void _app_hello_task_run()
static void _app_hello_task_run(void *param)
{
uint16_t idx = 0;
while(1) {
@ -32,7 +32,8 @@ static void _app_hello_task_run()
uint8_t app_hello_task_start()
{
xTaskCreatePinnedToCore(_app_hello_task_run, "hello task", 1024, NULL, 5, NULL, tskNO_AFFINITY);
vTaskDelay(10);
xTaskCreatePinnedToCore(_app_hello_task_run, "hello task", 4096, NULL, 5, NULL, tskNO_AFFINITY);
return 0;
}