LLCE CAN test failed and felt into HardFault_Handler()

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

LLCE CAN test failed and felt into HardFault_Handler()

Jump to solution
1,357 Views
harry_choi
Contributor III

Hello, 

I'm trying to test LLCE CAN with Can_Llce_DS_Can2Can_S32G274A_M7 example on your S32G-VNP-RDB2 board.

Actually there was no problem on your example without any change.

But I wanted to test only CAN not CAN FD, so I blocked all and just put below codes in the for loop in the Can_Driver_Sample_Test() function.

CanMessage.length = CAN_STD_FRAME_LEN;
CanMessage.sdu = can_std_data;
CanMessage.id = 1;

can_retval = Can_43_LLCE_Write(CanHO_Config1_TX1, &CanMessage);

With this change, first trial to send was successful but there was no CAN transmit from second trial and the software felt into HardFault_Handler() exception after some trials.

Could you advise what should I do to test CAN Tx/Rx only not CAN FD?

Thanks,

Harry

 

0 Kudos
Reply
1 Solution
1,332 Views
bpe
NXP Employee
NXP Employee

In principle, there is nothing wrong in your initializations. The hard faults
you are observing are most likely because you removed something that the
rest of the code expects. You have to debug it to identify the root cause.
CAN2CAN is a relatively complex demo. If you just want to see how to initiate
a non-FD LLCE CAN transmission, a good alternative is
sample_app_llce\llce_sample_app_af\sample_app_can_customization\src\main.c
Although that demo implies the presence of FDK, it is more compact and
useful as a reference even without it.

 

Best Regards,
Platon

 

View solution in original post

0 Kudos
Reply
1 Reply
1,333 Views
bpe
NXP Employee
NXP Employee

In principle, there is nothing wrong in your initializations. The hard faults
you are observing are most likely because you removed something that the
rest of the code expects. You have to debug it to identify the root cause.
CAN2CAN is a relatively complex demo. If you just want to see how to initiate
a non-FD LLCE CAN transmission, a good alternative is
sample_app_llce\llce_sample_app_af\sample_app_can_customization\src\main.c
Although that demo implies the presence of FDK, it is more compact and
useful as a reference even without it.

 

Best Regards,
Platon

 

0 Kudos
Reply