eMcem_Eim_SetupInjectionChannel return fail

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

eMcem_Eim_SetupInjectionChannel return fail

Jump to solution
720 Views
Sylvia_jiang
Contributor IV

Hi Nxp Community,

       I am thankful for having a chance to consult about something. I am stuck in EIM because api eMcem_Eim_SetupInjectionChannel that is necessary to inject faults always return fail. Access to pEim->EICHD[u16EimChannel].WORD[0] (address is 0x40258100) causes to BusFault_Handler(). Is there any solution? looking forward to your reply.

Sylvia_jiang_0-1680162281247.png

main() is as belows:

Sylvia_jiang_1-1680162752564.png

BR,

Sylvia

 

Tags (4)
0 Kudos
Reply
1 Solution
667 Views
frantisekdobes
NXP Employee
NXP Employee

Hello Sylvia,

by default the clock for EIM module is disabled so when trying to access EIM registers a bus fault is generated. In order to enable clocks for EIM module, there can be used Power_Ip driver.

 

In the configuration it is needed to add POWER module:

frantisekdobes_0-1681296813075.png

 

Then in configuration of POWER module enable clock for EIM:

frantisekdobes_1-1681296855341.png

And then in main function call Power_Ip_SetMode API to enable the EIM clock:
Power_Ip_SetMode(&Power_Ip_aModeConfigPB[0]);

Best Regards,
Frantisek

 

 

View solution in original post

0 Kudos
Reply
1 Reply
668 Views
frantisekdobes
NXP Employee
NXP Employee

Hello Sylvia,

by default the clock for EIM module is disabled so when trying to access EIM registers a bus fault is generated. In order to enable clocks for EIM module, there can be used Power_Ip driver.

 

In the configuration it is needed to add POWER module:

frantisekdobes_0-1681296813075.png

 

Then in configuration of POWER module enable clock for EIM:

frantisekdobes_1-1681296855341.png

And then in main function call Power_Ip_SetMode API to enable the EIM clock:
Power_Ip_SetMode(&Power_Ip_aModeConfigPB[0]);

Best Regards,
Frantisek

 

 

0 Kudos
Reply