Hi, I am currently trying to use freeRtos on s32k344. I am using S32 Design Studio 3.5 and rtd 4.0.0 D2311. I found out that the program got stuck in vPortEnterCritical() in port.c and the configASSERT in this function is triggered. I found out that it was because that SchM_Enter_Can_43_FLEXCAN_CAN_EXCLUSIVE_AREA_18(void) was called from interrupt and inside this function, OsIf_SuspendAllInterrupts() was called.
Then I made the following modification in Oslf_Internal.h by changing the following two lines:
#if defined(USING_OS_FREERTOS)
#define ResumeAllInterrupts() taskEXIT_CRITICAL()
#define SuspendAllInterrupts() taskENTER_CRITICAL()
to :
#if defined(USING_OS_FREERTOS)
#define ResumeAllInterrupts() taskEXIT_CRITICAL_FROM_ISR(0)
#define SuspendAllInterrupts() taskENTER_CRITICAL_FROM_ISR()
Then the issue was solved. Is the above configuation intended? or is it a issue? Will it be fixed in the future? Thank you.
PS: The freeRtos version is shown in the attached screenshot.