Forum: Mikrocontroller und Digitale Elektronik set up Brefetch buffer ( STM32F103)


von Flash control REG stm32F103RE (Gast)


Lesenswert?

Hello,

im searching the STM32F103 FLASH access control Register, set up the 
FLASH prefetch buffer and theres waitstates after Reset.
I want to Enable th eprefetch register and set it up to two waitstates 
in p. language C


I couldn't find it in the handbook, perhaps I've searched with the wrong 
keywords.


thanks
thomas

von TSE (Gast)


Lesenswert?

Hallo Thomas,
do you work with the STD-LIb? Or do you set every bit per hand?

von arm (Gast)


Lesenswert?

Hallo,

thank's for the reminder.

I'm working with the standart lib.

thanks
thomas

von Mehmet K. (mkmk)


Lesenswert?

If you are working with the library, you do not have to bother with 
them.
Just call SystemInit() as first function in main.
This function is calling SetSysClock(), wich will set the desired 
register.

(All this functions are in the file system_stm32f10x.c)

von Matthias K. (matthiask)


Lesenswert?

STM LIB:
1
#include "stm32f10x_conf.h"
2
...
3
FLASH_SetLatency(FLASH_Latency_2);
4
FLASH_PrefetchBufferCmd(FLASH_PrefetchBuffer_Enable);
5
...

Bitte melde dich an um einen Beitrag zu schreiben. Anmeldung ist kostenlos und dauert nur eine Minute.
Bestehender Account
Schon ein Account bei Google/GoogleMail? Keine Anmeldung erforderlich!
Mit Google-Account einloggen
Noch kein Account? Hier anmelden.