Creating a CAN Bridge with MPC5606B

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

Creating a CAN Bridge with MPC5606B

ソリューションへジャンプ
1,221件の閲覧回数
fscheidl
Contributor II

So I am still experimenting with the MPC5606B StarterTRAK and I'm trying to create a CAN Bus bridge using the development board.

 

CAN Bus bridge is supposed to mean, I attach a second CAN transceiver to the board on another CAN port and want all incoming messages on the first port (RX), without any exception, to be forwarded to the second as output (TX) (In the right order!) and vice versa.

 

The first CAN transceiver I'm using is the one included in the system basis chip on the development board, the second one is a Microchip MCP2551. I do have a working setup for this using just a regular ATmega328 and the MCP2551, but I can't seem to get it to work with the MPC5606B.

 

The bitrate my system is using is set to 500kbit/s.

 

Now, the system kind of seems to slow or rather seems to lose some messages. I'm using the example code (CAN driver) included with the development board with the RX-mask set accordingly. Would it be better to use a FIFO CAN structure in this case? Are there any other things I have to consider?

 

Thank you very much in advance!

ラベル(1)
タグ(2)
0 件の賞賛
返信
1 解決策
1,025件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

I am not sure of the driver/example you are using, but still you need some CPU intervention to

- check there is new message in RX MB or RXFIFO

- read RX MB or RXFIFO and forward the data to other module’s TX MB. Message will be send on first opportunity window on the CAN bus.

 

The MB interrupt or RXFIFO interrupt is recommended here as fastest way to know a new message is received.

The RXFIFO can ensure the messages will be send in right order, I think.

BR, Petr

元の投稿で解決策を見る

0 件の賞賛
返信
1 返信
1,026件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

I am not sure of the driver/example you are using, but still you need some CPU intervention to

- check there is new message in RX MB or RXFIFO

- read RX MB or RXFIFO and forward the data to other module’s TX MB. Message will be send on first opportunity window on the CAN bus.

 

The MB interrupt or RXFIFO interrupt is recommended here as fastest way to know a new message is received.

The RXFIFO can ensure the messages will be send in right order, I think.

BR, Petr

0 件の賞賛
返信