Solved
This topic has been closed for replies.
Posted on February 11, 2018 at 13:50
Seems I found the problem.
The CubeMX generated code enters the 'default' trimming value for the HSI, which is according to the datasheet and CubeMX 0x10 (16).
LL_RCC_HSI_SetCalibTrimming(16);
This causes large deviations of the clock and so the baud rate is off and frame error occurs.
If I mask this line in the code I see the
default value is actually 0x40 and not 0x10(HSITRIM in ICSCR), and in this case all functions well.
I will add a discussion regarding this to see STs comment.
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.