Page 1 of 2
STM32F469I-DISCO Board clock setup
Posted: Wed Oct 23, 2024 2:08 pm
by stefan.erni
Hi Ben
STM32F469I-DISCO Boardis already included as a target in Flowcode.
It's working nice and it's easy to flash. no additional hardware is required.
And to program several boards just drag and drop the bin file onto the virtual drive of the connected board.

- 2024-10-23_14-49-24.PNG (598 KiB) Viewed 7845 times
But...
There is a small problem with the clock.
I2C (1Mhz) speed and UART (921600 Baud) are perfect
The display clock from the HSI bus is probably wrong, there is interference in the display.
If I change the clockspeed to 16Mhz, the interference is gone but I2C and Uart are then to slow.

- 2024-10-23_15-00-20.PNG (18.77 KiB) Viewed 7845 times
Clock to high or low':

- 2024-10-23_14-44-54.PNG (166.68 KiB) Viewed 7845 times
For a 200Hz interrupt choose 20Hz.....

- 2024-10-23_14-14-00.PNG (36.14 KiB) Viewed 7845 times
Re: STM32F469I-DISCO Board clock setup
Posted: Thu Oct 24, 2024 12:32 pm
by LeighM
Looks like this Discovery board has an 8MHz crystal, so if you select HSE then the Flowcode settings clock speed needs to be set to 8MHz.
If you use the STM32F469NI internal source (HSI) then the setting needs to be 16MHz.
If you need to tinker with the internal clocks (and there are a few of them!) via the Flowcode Project Options, then you at least need to look at the STM32F469NI reference manual (RM0386)
or better still use the clock configurator of STM32CubeMX.
Otherwise you risk overclocking and possible failure.
Regarding timer interrupts, that Flowcode dialog does not properly calculate timings for STM32 devices, as it isn't aware of the internal clock complexities. Prescaler and roll over values need to be determined manually, once you know the frequency of the internal APB2 timer clock.
Hope that helps.
Re: STM32F469I-DISCO Board clock setup
Posted: Thu Oct 24, 2024 1:15 pm
by stefan.erni
Hi Leigh
Yes I found the 8Mhz on board.
If the IRQ is 10 times wrong it's OK. I can handle this.
I found the Clock conficurator but the Flowcode Project Options dont support all (or the required parameter)

- 2024-10-24_14-04-01.PNG (156.88 KiB) Viewed 7811 times
How the display look with 8Mhz but with 16Mhz it's ok

- IMG_3566_2.jpg (196.7 KiB) Viewed 7811 times
Re: STM32F469I-DISCO Board clock setup
Posted: Tue Nov 05, 2024 9:54 am
by stefan.erni
Hi Leigh
The error in the display occurs at startup if the "clock speed defines delay related timings" is set to 8 Mhz (8Mhz is correct).
and remains until I remove the power plug.
Even a new flashing with 16Mhz does not change anything. Once wrong, always wrong
But if I first load a program with 16Mhz and then flash programs with 8Mhz it is ok.
I suspect it goes wrong when I plug in the power plug and starting the Board.
The "reset on power" from the display, or the speed is too high during this time
But I have no possibility to change anything.

- 2024-11-05_10-39-16.PNG (13.3 KiB) Viewed 7385 times
Re: STM32F469I-DISCO Board clock setup
Posted: Tue Nov 05, 2024 3:09 pm
by LeighM
This looks like a display component issue then.
I can't help just at the moment, I'm not near my pc/lab/office/hobbyroom

Re: STM32F469I-DISCO Board clock setup
Posted: Mon Dec 02, 2024 1:42 pm
by stefan.erni
Hi Leigh
Do you already have an idea how to solve the problem with the display?
I could try a trial version if that would help.
Re: STM32F469I-DISCO Board clock setup
Posted: Tue Dec 03, 2024 10:20 am
by LeighM
At a guess, it looks like the issue could be related to display setup, perhaps delay related? or SPI settings?
Could you post your project, or part of it, that demonstrates the issue?
Re: STM32F469I-DISCO Board clock setup
Posted: Tue Dec 03, 2024 1:26 pm
by stefan.erni
Hi Leigh
If I use 8Mhz both program generate a bad display
If I use 16Mhz both program are ok, but Uart and I2C clock are wrong

- 2024-12-03_14-22-11.PNG (28.2 KiB) Viewed 6581 times
In my program I removed the IMU so you don't need to connect it
With this program I get the bad display. (tested on several board)
Sometimes the error only occurs when the board is restarted with my program. Resetting then does not help, it resets and restarts but the display is still bad.
With a simple program the same problem
I have tested several times
Re: STM32F469I-DISCO Board clock setup
Posted: Wed Dec 04, 2024 10:32 am
by LeighM
Looks like the display code uses STM libraries so not sure what's going on here.
Maybe try running the device system clock slower and see if that improves things?
e.g. change your PLLN from 360 to 180
Otherwise this is going to need help from Matrix (as I don't have a disco board to test)
Re: STM32F469I-DISCO Board clock setup
Posted: Wed Dec 04, 2024 10:51 am
by stefan.erni
That makes it worse, like not synch, nothing to read
change your PLLN from 360 to 180