Watchdog Triggered during vTaskDelay

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

Watchdog Triggered during vTaskDelay

跳至解决方案
2,986 次查看
pavankishore1
Contributor II

Hi Team,

On s32k144 with FreeRTOS, we are doing a non-blocking i2c read which is having a delay of 1ms via OSIF_TimeDelay(1). During which we notice a WDOG being triggered.

pavankishore1_0-1608033952558.png

I doubt if this is an actual watchdog; The CFSR register contents are follows:

pavankishore1_1-1608034047781.png

if the register addresses are correct, then I believe the IMPRECISERR and FORCED bit are set which means there is a hard fault.

The stack usage is within the limit. 

Wondering why would a vTaskDelay() cause a fault? Can somebody please shed some light or direct to the right forum for attention?

Thanks.

标记 (1)
0 项奖励
回复
1 解答
2,975 次查看
danielmartynek
NXP TechSupport
NXP TechSupport

Hi,

Yes, this is not WDOG but a bus fault exception.

It looks like the issue discussed here:

https://community.nxp.com/t5/S32K/S32K142-lpi2c-is-not-working-with-freeRTOS-integration/m-p/875028

"As the driver uses FreeRTOS API, the driver must be initialized and used inside a FreeRTOS task after the scheduler is started."

 

Regards,

Daniel

在原帖中查看解决方案

0 项奖励
回复
2 回复数
2,976 次查看
danielmartynek
NXP TechSupport
NXP TechSupport

Hi,

Yes, this is not WDOG but a bus fault exception.

It looks like the issue discussed here:

https://community.nxp.com/t5/S32K/S32K142-lpi2c-is-not-working-with-freeRTOS-integration/m-p/875028

"As the driver uses FreeRTOS API, the driver must be initialized and used inside a FreeRTOS task after the scheduler is started."

 

Regards,

Daniel

0 项奖励
回复
2,957 次查看
pavankishore1
Contributor II

Hi @danielmartynek,

Thanks for the prompt response. I was performing the driver init outside the task context, and with this change it works fine.

We have similar usage in other projects and we don't see this failure. Can we get more information on the root cause for this error so it helps me to re-structure them based on the failure scenario?

Regards,

Pavan 

0 项奖励
回复