DEVKIT-MPC5744P CAN testing

取消
显示结果 
搜索替代 
您的意思是: 
已解决

DEVKIT-MPC5744P CAN testing

跳至解决方案
672 次查看
wei_w_he
Contributor IV

Dear Officer,

We have one DVKIT-MPC5744P REV E. and want to verify the CAN communication. We use PC/PCAN device to connect with CAN connector on DEVKIT board, and trying the FlexCAN_MPC5744P example code, but Neither configure (DEVKIT and LOOPBACK) options seems working. Can I check?

1. the CAN connector on DVKIT is connecting to CAN0 with PB0 and PB1?

2. What is configuration/changing to make this sample code to work with my setup: TX/RX CAN data from PC via PCAN to DEVKIT REV E CAN connector?

Thanks and best regards

He Wei

 

标记 (1)
0 项奖励
1 解答
664 次查看
PetrS
NXP TechSupport
NXP TechSupport

Hi,

If referring to FLEXCAN_MPC5744P demo example available within S32DS, seems this will not work by default with DEVKIT rev.E board as was done for the previous one. I do not have this rev E board, only the older one, but as per the schematic (rev.E) :
- LINFlex_0 (PB2/PB3 pins) is connected to MK20 MCU, which serve as OpenSDA and virtual serial port
- FlexCAN_0 (PB0/PB1) is connected to SBC's CAN transceiver

So try to modify can.h to have 
#define DEVKIT    0

This way you should see messages on terminal program. FlexCAN_0 stays in loopback mode, so nothing will be seen on CAN connector (P111).
To allow FlexCAN_0 communicate with other node, below modifications should be done too:
- within initCAN_0 comment line
CAN_0.CTRL1.B.LPB = 1;        //Enable loopback mode

BR, Petr

在原帖中查看解决方案

2 回复数
665 次查看
PetrS
NXP TechSupport
NXP TechSupport

Hi,

If referring to FLEXCAN_MPC5744P demo example available within S32DS, seems this will not work by default with DEVKIT rev.E board as was done for the previous one. I do not have this rev E board, only the older one, but as per the schematic (rev.E) :
- LINFlex_0 (PB2/PB3 pins) is connected to MK20 MCU, which serve as OpenSDA and virtual serial port
- FlexCAN_0 (PB0/PB1) is connected to SBC's CAN transceiver

So try to modify can.h to have 
#define DEVKIT    0

This way you should see messages on terminal program. FlexCAN_0 stays in loopback mode, so nothing will be seen on CAN connector (P111).
To allow FlexCAN_0 communicate with other node, below modifications should be done too:
- within initCAN_0 comment line
CAN_0.CTRL1.B.LPB = 1;        //Enable loopback mode

BR, Petr

652 次查看
wei_w_he
Contributor IV

Dear Petr,

Tks a lot

BR

He Wei

 

0 项奖励