Changed execution order in ALPAKA initialization

This commit is contained in:
dario 2023-10-15 21:49:41 +02:00
parent 1028264eef
commit cf5466fe55
2 changed files with 31 additions and 3 deletions

View File

@ -0,0 +1,28 @@
/*
* debug.hpp
*
* Created on: Oct 15, 2023
* Author: Dario
*/
#ifndef RTOS2_UTILS_INCLUDE_STA_RTOS_DEBUG_HPP_
#define RTOS2_UTILS_INCLUDE_STA_RTOS_DEBUG_HPP_
#include <sta/config.hpp>
#ifdef STA_DEBUGGING_ENABLED
# define STA_DEBUG_THREADS() \
{ \
}
#else // !STA_DEBUGGING_ENABLED
# define STA_DEBUG_THREADS() ((void)0)
#endif // STA_DEBUGGING_ENABLED
#endif /* RTOS2_UTILS_INCLUDE_STA_RTOS_DEBUG_HPP_ */

View File

@ -44,15 +44,15 @@ void startALPAKA(void * arg)
{
STA_ASSERT_MSG(osKernelGetState() != osKernelInactive, "Cannot call startALPAKA() before osKernelInitialize()");
// Call further initialization code
sta::rtos::startupExtras(arg);
// Initialize HAL
sta::initHAL();
// Initialize RTOS system resources
sta::rtos::initSystem();
// Call further initialization code
sta::rtos::startupExtras(arg);
// Wake threads
sta::rtos::signalStartupEvent();