[En-Nut-Discussion] Re STM32F7xx Fixes

Holger Mai mai at gemac.info
Tue Apr 19 09:31:00 CEST 2016

OK i see that. In fact i let me irritate, that another tool from standard
periphal drivers, RCC_GetClocksFreq(), brings out wrong values since clock
management is reworked. This tool uses the real divider settings in the RCC
configuration rergisters, and has an invalid prescaler table for this case. So
this tool has to be updated instead stm32_clk.c. But, on the other side, it
looks for me, that the background of the HPRE organisation is, to switch between
full and reduced AHB clock  without loose the divider of reduced clock.
I dont can say, if other familys are affected by this effect. Therefore i think
it can be better, to continue the HPRE setting in the "old" way: set HPRE to
0000 if no divider is used. That will be good for down compatibility with
existing applications.

The construct to define DSABLE/ENABLE only if not defined doesnt work. The
preprocessor doesnt know DISABLE/ENABLE, because they are content of an enum
(and so only visible for the compiler). So he defines they, and than the
compiler finds this as error (because he has DISBALE as content of an enum):
...stm/stm32xxxx.h:487:18:  error: expected identifier before numeric constant
 # define DISABLE 0

An other way may be, to detect if the type of the enum, FunctionalState, is
always defined. But that is not possible with C tools. If anyone knows a
backdoor or a trick to do this nevertheless?


How tom send patches? I have no repository access, and i dont want that. And
atttachments to discussion mails are forbidden.

mit freundlichen Grüßen /Best Regards

Holger Mai

mai at gemac-chemnitz.de

GEMAC - Gesellschaft für Mikroelektronik-
anwendung Chemnitz mbH
Zwickauer Straße 227
D-09116 Chemnitz
Tel. +49 371 3377 - 0
Fax +49 371 3377 272
UST-ID: DE140851265
HRB 6443 Chemnitz/Stadt
Geschäftsführer: Dirk Hübner / Karsten Grönwoldt

More information about the En-Nut-Discussion mailing list