Skip to main content
Associate II
November 8, 2023
Solved

CAN FD multiple MCUs

I am trying to connect 2 NUCLEO-G0B1RET6 boards,using CAN FD. I previously did it using CAN, But now i am trying to connect these boards using CAN FD. So far no success,I want to know if it is possible to do it using CANFD.Kindly help me in this regard.

This topic has been closed for replies.
Arjun_BansalBest answer
Associate II
November 16, 2023

Issue solved. 

  • I upload the updated code,with exact desired output.
  • This project was built using 2nos. G0B1RE, BD41041FJ-C CAN Transceiver
  • Solution:There is need of typeCasting,configure filter id carefully to do this.

27 replies

mƎALLEm
ST Technical Moderator
November 8, 2023

Hello,

Sure you can do it but you should add a FDCAN transceiver to each board.

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.
Associate II
November 8, 2023

i am using ROHM41041 transceiver on both boards.please let me know if there is any tutorial for this.I am trying since 3days with no success.

mƎALLEm
ST Technical Moderator
November 8, 2023

Sorry I didn't find that transceiver on internet. Do you have its datasheet?

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.
mƎALLEm
ST Technical Moderator
November 8, 2023

Another important point to consider:

From your tranceiver datasheet: it's a 5V one (VCC Min: 4.75V, Max: 5.25V)

SofLit_0-1699450022991.png

If I consider you supply it with around 5V, you have an issue with TxD pin minimum 'High level input voltage': 

VIHmin = 0.7 x VCC = 3.5V > IO voltage level provided by the STM32G0 pin (@3.3V).

Even with VCCmin: VIHmin = 0.7 x 4.75 = 3,325V really at the limit!

 

 

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.
Associate II
November 8, 2023

What would be your suggestion to overcome this problem?

mƎALLEm
ST Technical Moderator
November 8, 2023

Simply use 3.3V transceiver or use voltage level shifter for the final project.

But for testing I think there is an internal pull-up resistor connected to the transceiver TxD pin:

SofLit_0-1699456414453.png

Try to configure CAN_Tx pin in Open Drain. But I cannot guarantee this workaround.

 

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.
Karl Yamashita
Principal
November 8, 2023

You can look into the NCV7344 from ON Semiconductor. It's CAN FD compliant and it can interface a 3V-5V Microcontroller.

If a reply has proven helpful, click on Accept as Solution so that it'll show at top of the post.CAN Jammer an open source CAN bus hacking toolCANableV3 Open Source
mƎALLEm
ST Technical Moderator
November 9, 2023

Hello,

VIHmin  = 5.05V x 0.7 = 3,535V > 3.316V (VDD) -> out of the transceiver spec. As I said, you have to use a 3.3V transceiver. Or test TxD pin in OD config

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.
mƎALLEm
ST Technical Moderator
November 16, 2023

Hi @Arjun_Bansal ,

You're welcome. Please click on Accept as Solution on the reply which solved your first issue (described in your first comment) as its gives a better visibility on the answered topics.

Thank you

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.