MPC5748 CAN FD

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

MPC5748 CAN FD

1,284件の閲覧回数
shijiaguo
Contributor II

Hello all!

 

I'm running into a timing issue while configuring the CAN FD on MPC5748G micro.

 

I’m using 40MHz F40 clock as CAN oscillator clock (fCANCLK). And my arbitration bit rate is set at 500K, and the data bit rate is set to be twice as that =1000K. The PSEG and DIV settings for arbitration and data are as follows:

 

 175479_175479.png1.png

175480_175480.png2.png

 

The arbitration phase turns out to be ok. However, the data rate in the data phase is slightly imperfect. The data is supposed to be 1000ns/bit, however, on my scope it’s showing ~960ns/bit. Here’s the screenshot (yellow and blue are CAN high and low, red is CANH – CANL, I’m sending data 0b1010101….). This is causing the Canalyzer not being able to receive data correctly. Does anyone have any idea what’s happening and how to make the timing more accurate?

 175484_175484.png3.png

 

 

 

ラベル(1)
0 件の賞賛
1 返信

683件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi Shijia,

The length of data bit time is calculated as SYNC + FPROPSEG + (FPSEG1+1) + (FPSEG2+1).

FPROPSEG, FPSEG1, FPSEG2 are values written into FDCBT register.

So for your setting just increase FPROPSEG.

 

However it is recommended to have the same time quanta length for the data phase and set the sample time somewhere in the middle of the data bit time. So you can recalculate your setting to have the same prescaler for both nominal and data bit time.

BR, Petr

0 件の賞賛