diff --git a/cores/nRF5/rtos.cpp b/cores/nRF5/rtos.cpp index 7afe79b0..2dc052ca 100644 --- a/cores/nRF5/rtos.cpp +++ b/cores/nRF5/rtos.cpp @@ -45,13 +45,12 @@ static void _redirect_task(void* arg) while(1) { taskfunc(); - delay(0); + yield(); } } SchedulerRTOS::SchedulerRTOS(void) { - _num = 1; // loop is already created by default } bool SchedulerRTOS::startLoop(taskfunc_t task, uint32_t stack_size, uint32_t prio, const char* name) diff --git a/cores/nRF5/rtos.h b/cores/nRF5/rtos.h index 7c610ff0..86e7b0b2 100644 --- a/cores/nRF5/rtos.h +++ b/cores/nRF5/rtos.h @@ -85,9 +85,6 @@ static inline void rtos_free( void *pv ) class SchedulerRTOS { -private: - uint8_t _num; - public: typedef void (*taskfunc_t)(void);