Hi NXP Experts,
There was an abnormality in the use of the LLCE can function of the S32G399A in our project. Occasionally, there was an issue with the reception of a certain CAN message reported by the ECU, while the transmission was normal. After debugging, it was found that the can interrupt could be triggered normally, but the u32Word0 read from Can_SharedMemory changed from 0x18008 to 0x1800f, which was an abnormal value. The calculated u32MbMessageId was 0.This led to message loss.
The RxMbDescIdx had a value and was changing, and word1 sometimes was 0 but was also changing. This situation occurred sporadically, and the affected CAN line was also random.
Please help analyze this situation,The debugging screenshots are provided below. How should I proceed with the next debugging steps, or what solutions are there?
The LLCE version is: 1.0.10
.LLCE_Abnormal.png
Hi,canhe
Thank you for contacting us.
Could you tell us more information?
1. Which version of RTD are you using?
2.Are you using your own boards and your own software?
BR
Joey
Hi NXP Experts,
Syncing the information: In an abnormal situation, we read the controller status through Can_Llce_GetControllerMode as "start", and then executed a "stop->start" transition through the Can_43_LLCE_SetControllerMode interface. The abnormal CAN can recover. From the value of word0, it seems that there was an error in the internal DTE kernel of LLCE when transferring data to the shared memory.
Currently, the abnormality probability is still quite high at around 20%-30%. Our team has signed the relevant NDA documents. Could you please prioritize the handling of this issue?
Hi,canhe
Ok, we will raise the priority of your questions!
1.Could you please tell me whether the CAN frames you received originated from an external device or from such the CANoe device? Is it receiving CAN or CANFD frame?
2.What is the set baud rate? Which port are you using?
3.is the frame be processed by the internal core or routed via CAN2CAN?
BR
Joey
Hi,canhe
It seems that you have made some changes to Can_Llce_ProcessRxMb. Did you have any issues before the changes were made? Could you share the modified code?
Joey_z_0-1785135823536.png
BR
Joey
Hi,Joey
Thank you for your reply. This issue occurred before I added the debugging code. I added the debugging code to confirm the specific cause. The debugging code merely reads certain states. It seems that the value of the shared memory is abnormal. The patch has been provided to you.
Hi,canhe
Thank you for your information.
1.In the scenarios where you encountered problems, what was the Busload of the CAN bus? Is the Busload too high?
2.When frame loss occurs, does the Notification report any errors? If you have any error messages, please share them with me.
Joey_z_0-1785211817403.png
3.When does the error occur - during the Routing process or when the frame is sent to the Host? Is it CAN or CAN FD frame that is being used?
BR
Joey
Hi,Joey
1. The bus load rate is between 40% and 50%, which doesn't seem very high.
2. BCAN_RXFIFO_OVERRUN has occurred under abnormal conditions, but I also observe this notification during normal operation.
3. Currently, LLCE does not have routing functionality enabled; it only forwards data to the host. Most frames used are CAN FD, with a small number of CAN frames.
Hi,joey
Thank you for your reply. I will reduce the load rate and conduct the test again. Regarding the second point you mentioned about the MB size, I have tried increasing it from 20 to 300, but there were still abnormalities.
Furthermore, do you know if LLCE has any internal logic regarding the handling of shared memory? Under what circumstances would an abnormal value occur for the "word0" field? For instance, if the value of "word1" is written to "word0".
Hi,canhe
1.Test to reduce the bus load and observe whether the frequency of the problematic frames decreases.
2.Also, try to increase the number in the parameters shown in the picture.
Joey_z_0-1785313583389.png
BR
Joey
Hi,joey
1. The received CAN frames originated from the external ECU. Currently, the abnormality is replicated in the test bench using the CANOE device for simulation. In reality, the abnormality has occurred in both situations. The majority of the received messages are CANFD frames, while a small number are CAN frames.
2. The baud rate is set at 500k for the arbitration segment, 2M for the data segment, and 80% for the sampling rate. The controller uses BCAN1-BACN5.
3. The frames are processed by the internal core.
Hi,canhe
Thank you for your detail information.
Are all of you using BCAN1-BACN5 to perform the receiving frame operation?
I use the same version of LLCE and the same configuration as yours in a receiving testing on one port, and not encounter the similar error as yours.
Joey_z_0-1785405650366.png
BR
Joey
Hi,Joey
We mainly use BCAN1-BCAN3 to receive most of the application message frames. BCAN4 is currently not capable of sending or receiving data. BCAN5 is connected to the internal bus and transmits a small number of messages.
Hi,canhe
According to the previous tests.
Will reducing the CAN busload and using a single CAN channel cause any problems for you?
BR
Joey
Hi,joey
Thank you for your help. I have completed this case. The tracking number is: 00997151.
Hi,Joey
Could I kindly ask if it's convenient for you to contact the local FAE (Field Application Engineer) for on-site support or online support in China? I think this would help us solve the problem more quickly.
Hi,canhe
Please try to create a case through the link below.
Regarding this issue, please fill in the relevant case information, I will help you contact the software team and LLCE experts through internal channels.
BR
Joey