Hallo,
ich veruche gerade einen simplen code auf dem STM32F4 Discovery-Board
zum Laufen zu kriegen und komme nicht weiter.
Erstmal der code:
1 | #include "stm32f4xx_conf.h"
|
2 | #include <stm32f4xx.h>
|
3 |
|
4 | int main(void)
|
5 | {
|
6 | SystemInit();
|
7 |
|
8 | GPIO_InitTypeDef GPIO_InitStructure;
|
9 |
|
10 | RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_GPIOA, ENABLE);
|
11 |
|
12 |
|
13 |
|
14 | GPIO_InitStructure.GPIO_Pin = GPIO_Pin_0 | GPIO_Pin_1 | GPIO_Pin_2 | GPIO_Pin_3;
|
15 | GPIO_InitStructure.GPIO_Mode = GPIO_Mode_OUT;
|
16 | GPIO_InitStructure.GPIO_OType = GPIO_OType_PP;
|
17 | GPIO_InitStructure.GPIO_Speed = GPIO_Speed_100MHz;
|
18 | GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_NOPULL;
|
19 |
|
20 | GPIO_Init(GPIOA, &GPIO_InitStructure);
|
21 |
|
22 | GPIO_WriteBit(GPIOA, GPIO_Pin_0, Bit_SET);
|
23 |
|
24 |
|
25 |
|
26 |
|
27 | while(1)
|
28 | {
|
29 |
|
30 | }
|
31 | }
|
Am code sollte es denke ich nicht liegen, der is ja recht überschaubar.
Alle notwendigen Konfigurationen habe ich in der stm32f4xx.h und
system_stm32f4xx.c vorgenommen.
Ich benutze die CoIDE.
ST-Link ist als Adapter ausgewählt und CoFlash ist auch konfiguriert.
Wenn ich in den Debug-Modus gehe, bekomme ich folgenede Meldungen:
[Bild im Anhang]
Auch wenn ich das Programm via "Download Program" lade, funktioniert es
nicht.
Kommunikation mit dem Board findet statt.
Ich hoffe mir kann jemand helfen.
Gruß, Gregor