MPC5777C MCAN stuck on TX buffer request pending

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

MPC5777C MCAN stuck on TX buffer request pending

ソリューションへジャンプ
915件の閲覧回数
darq
Contributor III

Hello,

What i'm trying to do is to use a M_CAN interface on our custom board. I tired to use the source code snippets from one of the examples available from this forum:

https://community.nxp.com/t5/MPC5xxx-Knowledge-Base/Example-MPC5777C-MCAN-simpleTXRX-GHS616/ta-p/110...

I'm just using M_CAN1 to send the messages instead of M_CAN0 and the receiver is just a Kvaser interface. I have configured the pins 195 and 196 as alternate function (0x3) to use them as M_CAN1 interface. The external oscillator is used as interface clock.

The problem that i'm facing is that when i try to send any message from dedicated buffer then i can see that the bit for buffer 0 is set in TXBRP but the message is never sent and the state of the TX pin also never changes, it stays constantly high. I can see the message RAM is updated with a frame data and i also tested that when using TEST register i can set and reset the TX pin state. I can't really see any errors in the registers (see attached screen).

Any ideas why the interface never sends the message? In case more info is needed please don't hesitate to ask.

Best regards

 

タグ(1)
0 件の賞賛
1 解決策
624件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

another hint from register values; after leaving init mode the PSR[ACT] is still 0, it indicated the module is not synchronized to the bus, so cannot start transmission. It can be due to wrong pin configuration or the RX pin is seen low. You can try to disconnect transceiver and connect TX/RX pins together.
Did you set respective IMUX register as well to select pin you are using?

PetrS_0-1712659366643.png

For 3N45H example you can refer to  https://community.nxp.com/docs/DOC-342013 

BR, Petr

元の投稿で解決策を見る

0 件の賞賛
4 返答(返信)
638件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

I see ACK error is detected, from register view, but in this case I expect error counters set as well and TX signal should be visible.
What is MCU mask set used in fact, there is little difference between 2N45H and 3N45H.

BR, Petr

0 件の賞賛
629件の閲覧回数
darq
Contributor III

Hello,

It is 3N45H.

Best regards

0 件の賞賛
625件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

another hint from register values; after leaving init mode the PSR[ACT] is still 0, it indicated the module is not synchronized to the bus, so cannot start transmission. It can be due to wrong pin configuration or the RX pin is seen low. You can try to disconnect transceiver and connect TX/RX pins together.
Did you set respective IMUX register as well to select pin you are using?

PetrS_0-1712659366643.png

For 3N45H example you can refer to  https://community.nxp.com/docs/DOC-342013 

BR, Petr

0 件の賞賛
614件の閲覧回数
darq
Contributor III

Hello,

Yes, it looks like there was a bug in the software resulting in IMUX registers being overwritten with wrong values resulting in selecting incorrect input for M_CAN1 RX pin.

Thank you for help.

Best regards

0 件の賞賛