ARMEBS4  revision-26.06.2015
bsp_stm32f4_discovery_lcd.h
1 /************************************************************************//**
2 
3  * \file bsp_stm32f4_discovery.h
4  * \brief BSP for stm32f4 discovery
5  * \author marc dot pignat at hevs dot ch
6  * \ingroup bsp
7  * @{
8  ***************************************************************************/
9 #ifndef HEIVS_BSP_STM32F4_DISCOVERY_H
10 #define HEIVS_BSP_STM32F4_DISCOVERY_H
11 
12 #include <stdint.h>
13 #include "stm32/usb/usb_core.h"
14 
15 #define BSP_PWM_LED_STEPS 255
16 
17 #ifndef BOARD_STM32F4_DISCOVERY
18 #error this file should not be included by hand
19 #endif
20 
21 #define BSP_BOARD_PRETTY_NAME "STM32F4 discovery"
22 
23 #define BSP_LED_NR 4
24 #define BSP_BUTTON_NR 1
25 
26 #define BSP_I2C_BUS_COUNT 1
27 #define BSP_I2C_BUS0_CTRL I2C1
28 #define BSP_I2C_BUS0_GPIO_SCL GPIO_I2C1_SCL_PB8
29 #define BSP_I2C_BUS0_GPIO_SDA GPIO_I2C1_SDA_PB9
30 
31 #define BSP_SPI_BUS_COUNT 1
32 #define BSP_SPI_BUS0_CTRL SPI1
33 #define BSP_SPI_BUS0_GPIO_MISO GPIO_SPI1_MISO_PA6
34 #define BSP_SPI_BUS0_GPIO_MOSI GPIO_SPI1_MOSI_PA7
35 #define BSP_SPI_BUS0_GPIO_SCK GPIO_SPI1_SCK_PA5
36 #define BSP_SPI_BUS0_GPIO_CS DEF_GPIOE(3, GPIO_OUTPUT_1 | GPIO_SPEED_100)
37 
38 #define BSP_USART_BUS_COUNT 1
39 #define BSP_USART_BUS0_CTRL USART2
40 #define BSP_USART_BUS0_GPIO_TX GPIO_USART2_TX_PA2
41 #define BSP_USART_BUS0_GPIO_RX GPIO_USART2_RX_PA3
42 
43 #define BSP_USART_BUS0_SPEED 115200
44 
45 #include "heivs/config.h"
46 #if (USE_STM32_USB_HOST_MODE || USE_STM32_USB_USE_DEVICE_MODE || USE_STM32_USB_OTG_MODE)
47 
48 #ifdef __cplusplus
49  extern "C" {
50 #endif
51 void USB_OTG_BSP_DriveVBUS(USB_OTG_CORE_HANDLE *pdev, uint8_t state);
52 void USB_OTG_BSP_ConfigVBUS(USB_OTG_CORE_HANDLE *pdev);
53 #ifdef __cplusplus
54  }
55 #endif
56 
57 #endif /* (USE_STM32_USB_HOST_MODE || USE_STM32_USB_USE_DEVICE_MODE || USE_STM32_USB_OTG_MODE) */
58 
59 void bsp_lcd_backlight_set(uint32_t value);
60 
61 /**
62  * @}
63  */
64 #endif /* HEIVS_BSP_STM32F4_DISCOVERY_H */
void bsp_lcd_backlight_set(uint32_t value)
Set the brightness of the backlight.
Definition: bsp_armebs4.c:314
libheivs configuration file