Application Software containing ICU and CAN, is get stuck into Hardfault for S32k344

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

Application Software containing ICU and CAN, is get stuck into Hardfault for S32k344

693 次查看
RushikeshK_DC
Contributor I

I have application software containing the CAN, ICU, DIO, PWM out,  configuration. Here the Can Rx is on interrupt and ICU also have interrupt. 

The issue is, as we include the ICU configuration in application the application is stuck in Hard-Fault, when i am sending any CAN message. As we remove the ICU configuration the application works fine. I not able to find any reason for this.

Someone pls help me. Does the interrupt priority create this type of issue?

Thanks  

0 项奖励
回复
2 回复数

602 次查看
dragostoma
NXP Employee
NXP Employee

Hi, @RushikeshK_DC,

In general, hardfaults are caused by the lack of enabling the clocks required by each component. This is done in the Mcu tab -> McuModuleConfiguration -> McuModeSettingConf -> McuPeripheral tab, where all peripheral clocks are listed.

dragostoma_0-1733997926882.png

Maybe the eMIOS instance you are using does not have the related clock enabled. In the first phase, try to follow existing models configured to work using ICU, which are delivered with the toolbox. If you still cannot get your application to work, you can attach the archive with the model and the related configuration to try to help you solve the problem.

 

Best regards,

Dragos

0 项奖励
回复

587 次查看
RushikeshK_DC
Contributor I
thank you @dragostoma for your replay,
but in my case all the required clocks are enable and if the ICU test independently works fine on interrupt but when it is integrate with application, application get stops when some message is get transmitted over can. I can't share the application but i can share the mex file if it is ok for you.

thank you!
0 项奖励
回复