2314505_en-US

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

2314505_en-US

2314505_en-US

Initialization of the external SJA1105 driver for s32k344

I ported the SJA1105 driver and DP83848 driver based on the code package shown in Figure 1; however, during initialization, the program gets stuck in that loop as shown in Figure 2. Since the ported files are .a files (static library files), I cannot view the corresponding .c source files and have no idea about the specific cause. Could you tell me what leads to the program getting stuck in this loop?

18036965586_0-1770628614407.png

18036965586_2-1770628413494.png


Re: Initialization of the external SJA1105 driver for s32k344

Hello @18036965586 ,

The original example - available on this page Solved: S32K344-WB (WhiteBoard) EVB source code - NXP Community - has been built with S32K3 RTD 2.0.0. Unfortunately, the source code for libsja1105_driver.a (the low level SPI driver for SJA1105) is not available.

As you have observed, the driver built with S32K3 RTD 2.0.0 doesn't work in the newer version  of S32K3 RTD - that's' the reason why program gets stuck in this loop.

Best regards,

Pavel

Re: Initialization of the external SJA1105 driver for s32k344

Hello @jianghao ,

My observation shows that there should be installed TCPIP 1.0.0, but the example uses modified source files and , based on  S32K344_Whiteboard_SW(LLD)_QuickStartGuide(UG10049).pdf, you should not do "Update code" anyway.

Best regards,

Pavel

Re: Initialization of the external SJA1105 driver for s32k344

Thanks, from what I understand, you mean that the RTD2.0 library must be used if Iwant to configure the SJA1105. I would like to ask which version of TCPIP_STACK is used in this example?

Re: Initialization of the external SJA1105 driver for s32k344

Thanks, I got it. This example cannot be directly updated to generate code using mex. So, can I create a new project, transfer the driver for the SJA1105 part to the new project, and then update the code using mex? If possible, which files do I need to transfer? (As I want to know which file in the original project caused the inability to directly update the code by .mex) Additionally, I now want to use the S32DS3.5 version + RTD3.0 + FreeRTOS_10_5_1_UOS_3_1_0_DS_updatesite_D2304. Can this be achieved?

Re: Initialization of the external SJA1105 driver for s32k344

Hello @jianghao ,

It is always recommended to start a new project in the latest S32K3 RTD.

I would recommend to create a new project from lwIP example and add LPSPI routines for SJA1105. Similar task is being discussed in this thread: NXP SJA1105S connection via SPI to TC397XP( QSPI5) - NXP Community

Best regards,

Pavel 

Re: Initialization of the external SJA1105 driver for s32k344

Thanks for you suggestions, I have transplanted the SJA1105's driver to the new project and compiled successfully. But I encountered a  new problem that the function named  "extern uint8_t SJA1105P_loadConfig(uint8_t configIndex, uint8_t switchId) " haven't been called throughout the entire project. And  is it called in any .a files?image.pngimage.pngimage.pngimage.png

Looking forward to your reply.

Thanks.

Re: Initialization of the external SJA1105 driver for s32k344Thanks,I got it.
Tags (1)
No ratings
Version history
Last update:
‎04-18-2026 02:34 AM
Updated by: