Просмотр исходного кода

esp32: use binary semaphore instead of mutex in dport tests

Ivan Grokhotkov 7 лет назад
Родитель
Сommit
d539183b40
1 измененных файлов с 1 добавлено и 2 удалено
  1. 1 2
      components/esp32/test/test_dport.c

+ 1 - 2
components/esp32/test/test_dport.c

@@ -66,8 +66,7 @@ void run_tasks(const char *task1_description, void (* task1_func)(void *), const
 
     for (i=0; i<2; i++) {
         if((task1_func != NULL && i == 0) || (task2_func != NULL && i == 1)){
-            exit_sema[i] = xSemaphoreCreateMutex();
-            xSemaphoreTake(exit_sema[i], portMAX_DELAY);
+            exit_sema[i] = xSemaphoreCreateBinary();
         }
     }