S32K344 CAN can't send Message

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

S32K344 CAN can't send Message

2,475件の閲覧回数
longfeiwang
Contributor III
I am using S32K344 and New "FlexCAN_example_CT(SDK version: RTD 0.9.0 D2013)",Update the code after modifying the CAN0 IO configuration.But CAN0 did not send any information, use the oscilloscope to check the CAN0 PTA6 level and there is no change.After checking the code, I found that the updated code did not add IO initialization information, so I added the function Siul2_Port_Ip_Init(NUM_OF_CONFIGURED_PINS0,g_pin_mux_InitConfigArr0).It still doesn't work after adding IO initialization.
0 件の賞賛
返信
9 返答(返信)

1,453件の閲覧回数
Emily54
Contributor I

Infopulsepro@

  1. Check CAN Transceiver Connections: Ensure that the CAN transceiver is properly connected to the S32K344 microcontroller. Verify that the CAN_H and CAN_L lines are connected correctly and that the transceiver is powered appropriately.

  2. Verify CAN Controller Configuration: Double-check the configuration of the S32K344 CAN controller registers. Ensure that the baud rate, timing parameters, and other settings are correctly set according to your CAN network requirements.

  3. Check Error Flags: Monitor the CAN error flags to determine if there are any issues detected by the CAN controller. Common error flags include bit stuffing errors, CRC errors, form errors, and ACK errors. Clear any error flags and observe if they reappear during message transmission.

0 件の賞賛
返信

1,434件の閲覧回数
avinashstarkenn
Contributor III

Please look into the code and give me specific solution. You are giving me generic debugging method

0 件の賞賛
返信

2,457件の閲覧回数
danielmartynek
NXP TechSupport
NXP TechSupport

Hello @longfeiwang,

Could you please share the project so that I can test it?

PTA6 is a CAN0_RX pin.

Have you read the corresponding MSCRn registers of the TX, RX pins after the initialization?

Were the correct source signal selected in the registers?

 

Thank you,

BR, Daniel

 

 

Regards,

Daniel

0 件の賞賛
返信

2,447件の閲覧回数
longfeiwang
Contributor III

Hi Daniel

              The IO configuration is shown in the figure below:

longfeiwang_2-1617762787495.png

 

0 件の賞賛
返信

2,418件の閲覧回数
danielmartynek
NXP TechSupport
NXP TechSupport

Hello @longfeiwang,

I'm sorry for the delay,

You haven't changed the FlexCAN mode:

danielmartynek_0-1618218543771.png

Please have a look at the description of the FlexCAN modes in the S32K3xx RM:

danielmartynek_1-1618218623079.png

 

Regards,

Daniel

 

0 件の賞賛
返信

1,475件の閲覧回数
avinashstarkenn
Contributor III

Hello @danielmartynek ,

I am also using same controller s32k344 following is the example that I am attaching. I was getting the same issue as @longfeiwang ,so like you said I disabled the loopback.

avinashstarkenn_0-1706706349029.png

But now it is not transmitting and not entering CanIf_TxConfirmation function which confirms Transmission is done.

Please resolve the issue as soon as possible

0 件の賞賛
返信

1,357件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

see attached modified code. It sends message with std ID 0x1 first then wait for message with std ID 0x2, once received it send ID 0x1 message back with incrementing first byte in payload.
This what I see with PCAN connected on S32K3x4EVB-Q172 board (rev.A).
PetrS_0-1707124263572.png

But I gave you this already within a Case you created.

BR, Petr

0 件の賞賛
返信

1,466件の閲覧回数
danielmartynek
NXP TechSupport
NXP TechSupport

HI @avinashstarkenn,

Can you please create a new thread?

 

Thank you,

BR, Daniel

0 件の賞賛
返信

1,457件の閲覧回数
avinashstarkenn
Contributor III

Hello @danielmartynek ,

As my issue is same please resolve the issue here.

Please do it as soon as possible.

 

0 件の賞賛
返信