roverSTM  UM2 2013
Projet M1 Navarro Benjamin
 All Classes Files Functions Groups Pages
Macros | Enumerations | Functions
stm32f4_discovery.h File Reference

This file contains definitions for STM32F4-Discovery Kit's Leds and push-button hardware resources. More...

#include "stm32f4xx.h"

Go to the source code of this file.

Macros

#define LEDn   4
 
#define LED4_PIN   GPIO_Pin_12
 
#define LED4_GPIO_PORT   GPIOD
 
#define LED4_GPIO_CLK   RCC_AHB1Periph_GPIOD
 
#define LED3_PIN   GPIO_Pin_13
 
#define LED3_GPIO_PORT   GPIOD
 
#define LED3_GPIO_CLK   RCC_AHB1Periph_GPIOD
 
#define LED5_PIN   GPIO_Pin_14
 
#define LED5_GPIO_PORT   GPIOD
 
#define LED5_GPIO_CLK   RCC_AHB1Periph_GPIOD
 
#define LED6_PIN   GPIO_Pin_15
 
#define LED6_GPIO_PORT   GPIOD
 
#define LED6_GPIO_CLK   RCC_AHB1Periph_GPIOD
 
#define BUTTONn   1
 
#define USER_BUTTON_PIN   GPIO_Pin_0
 Wakeup push-button.
 
#define USER_BUTTON_GPIO_PORT   GPIOA
 
#define USER_BUTTON_GPIO_CLK   RCC_AHB1Periph_GPIOA
 
#define USER_BUTTON_EXTI_LINE   EXTI_Line0
 
#define USER_BUTTON_EXTI_PORT_SOURCE   EXTI_PortSourceGPIOA
 
#define USER_BUTTON_EXTI_PIN_SOURCE   EXTI_PinSource0
 
#define USER_BUTTON_EXTI_IRQn   EXTI0_IRQn
 

Enumerations

enum  Led_TypeDef { LED4 = 0, LED3 = 1, LED5 = 2, LED6 = 3 }
 
enum  Button_TypeDef { BUTTON_USER = 0 }
 
enum  ButtonMode_TypeDef { BUTTON_MODE_GPIO = 0, BUTTON_MODE_EXTI = 1 }
 

Functions

void STM_EVAL_LEDInit (Led_TypeDef Led)
 Configures LED GPIO. More...
 
void STM_EVAL_LEDOn (Led_TypeDef Led)
 Turns selected LED On. More...
 
void STM_EVAL_LEDOff (Led_TypeDef Led)
 Turns selected LED Off. More...
 
void STM_EVAL_LEDToggle (Led_TypeDef Led)
 Toggles the selected LED. More...
 
void STM_EVAL_PBInit (Button_TypeDef Button, ButtonMode_TypeDef Button_Mode)
 Configures Button GPIO and EXTI Line. More...
 
uint32_t STM_EVAL_PBGetState (Button_TypeDef Button)
 Returns the selected Button state. More...
 

Detailed Description

This file contains definitions for STM32F4-Discovery Kit's Leds and push-button hardware resources.

Author
MCD Application Team
Version
V1.1.0
Date
28-October-2011
Attention

THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE TIME. AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.

© COPYRIGHT 2011 STMicroelectronics