CAN handler development

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

CAN handler development

跳至解决方案
3,652 次查看
shrutib
Contributor I

Dear Community,

I am using s32k144 EVB with s32 design studio version R1.2018. While calling CAN_init and CAN_deinit from ISR routine, the code got stuck into vPortEnterCritical(). Please find the attachment for more details. Looking forward to your reply.

 

标记 (4)
0 项奖励
回复
1 解答
3,374 次查看
raresvasile
NXP Employee
NXP Employee

Hi Shruti,

CAN_Init and CAN_Deinit are using FreeRTOS API to create/destroy semaphores. This is the reason why the FreeRTOS flow will block into assert.

If CAN driver initialization and deinitialization are made outside of the ISR, then everything should work ok.

Best regards,

Rares

在原帖中查看解决方案

0 项奖励
回复
4 回复数
3,374 次查看
raresvasile
NXP Employee
NXP Employee

Hi,

Is your application using SDK? 

Thank you,

Rares

0 项奖励
回复
3,374 次查看
shrutib
Contributor I

Hi Rares,

Yes, RTM SDK v2.0.0, also using FreeRTOS v8.2.1 

Thanks,

Shruti.

0 项奖励
回复
3,375 次查看
raresvasile
NXP Employee
NXP Employee

Hi Shruti,

CAN_Init and CAN_Deinit are using FreeRTOS API to create/destroy semaphores. This is the reason why the FreeRTOS flow will block into assert.

If CAN driver initialization and deinitialization are made outside of the ISR, then everything should work ok.

Best regards,

Rares

0 项奖励
回复
3,374 次查看
shrutib
Contributor I

Hi Rares,

Currently we did the same as you told. It means there is no other way to call CAN_init and CAN_deinit through ISR. Thanks for your time.

Regards,

Shruti.

0 项奖励
回复