Skip to main content
MKami.0
Visitor II
April 23, 2019
Question

FD CAN doesn't work properly

  • April 23, 2019
  • 1 reply
  • 831 views

What is the best way to set up FD CAN in classic mode on stm32 nucleo h743zi board?

Currently, I'm using FDCAN with 16 Mhz frequency on the bus and I want to get 500kbit/s.

My settings are:

hfdcan1.Init.NominalPrescaler=2;

hfdcan1.Init.NominalSyncJumpWidth=1;

hfdcan1.Init.NominalTimeSeg1=13;

hfdcan1.Init.NominalTimeSeg2=2;

hfdcan1.Init.DataPrescaler=1

hfdcan1.Init.DataSyncJumpWidth=2;

hfdcan1.Init.DataTimeSeg1=13;

hfdcan1.Init.DataTimeSeg2=2;

Using osciloscope I see that one bit is sending in 13 ms time, when it should be in 2 us.

How to set things up properly?

This topic has been closed for replies.

1 reply

Technical Moderator
April 23, 2019

Hello,

I recommend you to follow the FDCAN example within STM32CubeH7, shows how to configure the FDCAN peripheral to send and receive

Classic CAN frames in normal mode:

STM32Cube_FW_H7_V1.3.2\Projects\STM32H743I_EVAL\Examples\FDCAN\FDCAN_Classic_Frame_Networking

Regards,

Imen

In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Thanks