Kaynağa Gözat

Enable backward compatibility for rt_align/ALIGN

tangzz98 3 yıl önce
ebeveyn
işleme
8367493d63
2 değiştirilmiş dosya ile 8 ekleme ve 0 silme
  1. 4 0
      test/test_queue_isr.c
  2. 4 0
      test/test_semaphore_isr.c

+ 4 - 0
test/test_queue_isr.c

@@ -27,7 +27,11 @@
 static QueueHandle_t xQueue = NULL;
 static rt_timer_t timer1;
 
+#ifdef rt_align
 rt_align(RT_ALIGN_SIZE)
+#else
+ALIGN(RT_ALIGN_SIZE)
+#endif
 static char thread1_stack[1024];
 static struct rt_thread thread1;
 static void rt_thread1_entry(void *parameter)

+ 4 - 0
test/test_semaphore_isr.c

@@ -26,7 +26,11 @@
 static SemaphoreHandle_t dynamic_sem = RT_NULL;
 static rt_timer_t timer1;
 
+#ifdef rt_align
 rt_align(RT_ALIGN_SIZE)
+#else
+ALIGN(RT_ALIGN_SIZE)
+#endif
 static char thread1_stack[1024];
 static struct rt_thread thread1;
 static void rt_thread1_entry(void *parameter)