cancel
Showing results for 
Search instead for 
Did you mean: 

Incorrect baudrate CAN Network example project on STM32F769I-EVAL?

paul2
Senior
Posted on August 01, 2016 at 08:56

I'm trying to run the CAN Network example (\STM32Cube_FW_F7_V1.4.0\Projects\STM32F769I_EVAL\Examples\CAN\CAN_Networking\MDK-ARM).

EVAL board Jumpers are set according to the documentation, I'm running the example without any changes.

I have one EVAL board connected to a USB CAN-USB monitor (PEAK PCAN-USB). After I hit the tamper button in order to send a CAN message, the CAN monitor gives a BUSHEAVY error. Very often BUSHEAVY is caused by bit timing issues. 

This example based on EVAL units running in the same CAN network. Maybe it�s never tested with an external CAN USB tool, to be sure the bitrate is really according specifications?

Anybody familier with this issue?

#canbus #stm32 #hal #can #cubemx
2 REPLIES 2
Nesrine M_O
Lead II
Posted on August 01, 2016 at 12:42

Hi Gerber,

Thank you for your feedback. your issue related to the wrong baud rate configuration has been reported internally.

-Syrine-

paul2
Senior
Posted on August 04, 2016 at 07:17

Hi,

thanks for your reply. Solved by using the initialisation below:

/*APB1 = 54000000 -> brp = 54000000/3/1000000 = 18 -> (2+11)/(2+11+5)*100 = 72%*/
 CanHandle.Init.TTCM = DISABLE;
CanHandle.Init.ABOM = DISABLE;
CanHandle.Init.AWUM = DISABLE;
CanHandle.Init.NART = DISABLE;
CanHandle.Init.RFLM = DISABLE;
CanHandle.Init.TXFP = DISABLE;
CanHandle.Init.Mode = CAN_MODE_NORMAL;
CanHandle.Init.SJW = CAN_SJW_1TQ;
CanHandle.Init.BS1 = CAN_BS1_12TQ;
CanHandle.Init.BS2 = CAN_BS2_5TQ;
CanHandle.Init.Prescaler = 3;