ARMEBS4  revision-26.06.2015
bsp_stm32_camera.h
Go to the documentation of this file.
1 /**
2  * \file bsp_stm32_camera.h
3  * \brief BSP for stm32f4 camera
4  * \author marc dot pignat at hevs dot ch
5  * @{
6  ***************************************************************************/
7 #ifndef HEIVS_BSP_STM32_CAMERA_H
8 #define HEIVS_BSP_STM32_CAMERA_H
9 
10 #include <stdint.h>
11 #include "heivs/lightness_to_pwm.h"
12 
13 #ifndef BOARD_STM32_CAMERA
14 #error this file should not be included by hand
15 #endif
16 
17 #define BSP_BOARD_PRETTY_NAME "stm32_camera"
18 
19 #define BSP_LED_NR 4
20 #define BSP_PWM_LED_STEPS LIGHTNESS_PWM_STEP
21 
22 #define BSP_BUTTON_NR 2
23 
24 #define BSP_I2C_BUS_COUNT 2
25 #define BSP_I2C_BUS0_CTRL I2C2
26 #define BSP_I2C_BUS0_GPIO_SCL GPIO_I2C2_SCL_PB10
27 #define BSP_I2C_BUS0_GPIO_SDA GPIO_I2C2_SDA_PB11
28 #define BSP_I2C_BUS1_CTRL I2C1
29 #define BSP_I2C_BUS1_GPIO_SCL GPIO_I2C1_SCL_PB6
30 #define BSP_I2C_BUS1_GPIO_SDA GPIO_I2C1_SDA_PB9
31 
32 #define BSP_SPI_BUS_COUNT 1
33 #define BSP_SPI_BUS0_CTRL SPI1
34 #define BSP_SPI_BUS0_GPIO_MISO GPIO_SPI1_MISO_PA6
35 #define BSP_SPI_BUS0_GPIO_MOSI GPIO_SPI1_MOSI_PA7
36 #define BSP_SPI_BUS0_GPIO_SCK GPIO_SPI1_SCK_PA5
37 #define BSP_SPI_BUS0_GPIO_CS DEF_GPIOE(3, GPIO_OUTPUT_1 | GPIO_SPEED_100)
38 
39 #define BSP_USART_BUS_COUNT 1
40 #define BSP_USART_BUS0_CTRL USART1
41 #define BSP_USART_BUS0_GPIO_TX GPIO_USART1_TX_PA9
42 #define BSP_USART_BUS0_GPIO_RX GPIO_USART1_RX_PA10
43 
44 #define BSP_USART_BUS0_SPEED 115200
45 
46 #ifdef __cplusplus
47  extern "C" {
48 #endif
49 
50 void bsp_light_set(uint32_t value);
51 
52 extern struct clock_gen_t bsp_clock_gen;
53 
54 #ifdef __cplusplus
55  }
56 #endif
57 
58 
59 
60 /**
61  * @}
62  */
63 #endif /* HEIVS_BSP_STM32_CAMERA_H */
Handle non-linearity in human eye brightness sensitivity.