Pārlūkot izejas kodu

update:支持idf

Dozingfiretruck 3 gadi atpakaļ
vecāks
revīzija
4bdc5926f6

+ 5 - 0
luat/freertos/luat_msgbus_freertos.c

@@ -1,8 +1,13 @@
 #include "luat_base.h"
 #include "luat_msgbus.h"
 
+#if (defined(CONFIG_IDF_CMAKE))
+#include "freertos/FreeRTOS.h"
+#include "freertos/queue.h"
+#else
 #include "FreeRTOS.h"
 #include "queue.h"
+#endif
 
 static QueueHandle_t xQueue = {0};
 

+ 7 - 0
luat/freertos/luat_timer_freertos.c

@@ -3,9 +3,16 @@
 #include "luat_malloc.h"
 #include "luat_timer.h"
 #include "luat_msgbus.h"
+
+#if (defined(CONFIG_IDF_CMAKE))
+#include "freertos/FreeRTOS.h"
+#include "freertos/task.h"
+#include "freertos/timers.h"
+#else
 #include "FreeRTOS.h"
 #include "task.h"
 #include "timers.h"
+#endif
 
 #define LUAT_LOG_TAG "timer"
 #include "luat_log.h"