Functions | |
uint32_t | BSP_GetVersion (void) |
This method returns the STM32F411 DISCO BSP Driver revision. More... | |
void | BSP_LED_Init (Led_TypeDef Led) |
Configures LED GPIO. More... | |
void | BSP_LED_Off (Led_TypeDef Led) |
Turns selected LED Off. More... | |
void | BSP_LED_On (Led_TypeDef Led) |
Turns selected LED On. More... | |
void | BSP_LED_Toggle (Led_TypeDef Led) |
Toggles the selected LED. More... | |
uint32_t | BSP_PB_GetState (Button_TypeDef Button) |
Returns the selected Button state. More... | |
void | BSP_PB_Init (Button_TypeDef Button, ButtonMode_TypeDef ButtonMode) |
Configures Button GPIO and EXTI Line. More... | |
uint8_t | COMPASSACCELERO_IO_Read (uint16_t DeviceAddr, uint8_t RegisterAddr) |
Reads a block of data from the COMPASS / ACCELERO. More... | |
void | COMPASSACCELERO_IO_Write (uint16_t DeviceAddr, uint8_t RegisterAddr, uint8_t Value) |
Writes one byte to the COMPASS / ACCELERO. More... | |
void | GYRO_IO_Read (uint8_t *pBuffer, uint8_t ReadAddr, uint16_t NumByteToRead) |
Reads a block of data from the GYRO. More... | |
void | GYRO_IO_Write (uint8_t *pBuffer, uint8_t WriteAddr, uint16_t NumByteToWrite) |
Writes one byte to the GYRO. More... | |
static void | I2Cx_MspInit (I2C_HandleTypeDef *hi2c) |
I2Cx MSP Init. More... | |
static uint8_t | I2Cx_ReadData (uint16_t Addr, uint8_t Reg) |
Reads a register of the device through BUS. More... | |
static void | I2Cx_WriteData (uint16_t Addr, uint8_t Reg, uint8_t Value) |
Writes a value in a register of the device through BUS. More... | |
static void | SPIx_MspInit (SPI_HandleTypeDef *hspi) |
SPI MSP Init. More... | |
static uint8_t | SPIx_WriteRead (uint8_t Byte) |
Sends a Byte through the SPI interface and return the Byte received from the SPI bus. More... | |
uint32_t BSP_GetVersion | ( | void | ) |
This method returns the STM32F411 DISCO BSP Driver revision.
This method returns the STM32F4 DISCO BSP Driver revision.
version | 0xXYZR (8bits for each decimal, R for RC) |
Definition at line 157 of file stm32f411e_discovery.c.
void BSP_LED_Init | ( | Led_TypeDef | Led | ) |
Configures LED GPIO.
Led | Specifies the Led to be configured. This parameter can be one of following parameters:
|
Definition at line 171 of file stm32f411e_discovery.c.
void BSP_LED_Off | ( | Led_TypeDef | Led | ) |
Turns selected LED Off.
Led | Specifies the Led to be set off. This parameter can be one of following parameters:
|
Definition at line 212 of file stm32f411e_discovery.c.
void BSP_LED_On | ( | Led_TypeDef | Led | ) |
Turns selected LED On.
Led | Specifies the Led to be set on. This parameter can be one of following parameters:
|
Definition at line 198 of file stm32f411e_discovery.c.
void BSP_LED_Toggle | ( | Led_TypeDef | Led | ) |
Toggles the selected LED.
Led | Specifies the Led to be toggled. This parameter can be one of following parameters:
|
Definition at line 226 of file stm32f411e_discovery.c.
uint32_t BSP_PB_GetState | ( | Button_TypeDef | Button | ) |
Returns the selected Button state.
Button | Specifies the Button to be checked. This parameter should be: BUTTON_KEY |
The | Button GPIO pin value. |
Definition at line 278 of file stm32f411e_discovery.c.
void BSP_PB_Init | ( | Button_TypeDef | Button, |
ButtonMode_TypeDef | ButtonMode | ||
) |
Configures Button GPIO and EXTI Line.
Button | Specifies the Button to be configured. This parameter should be: BUTTON_KEY |
ButtonMode | Specifies Button mode. This parameter can be one of following parameters:
|
Definition at line 241 of file stm32f411e_discovery.c.
uint8_t COMPASSACCELERO_IO_Read | ( | uint16_t | DeviceAddr, |
uint8_t | RegisterAddr | ||
) |
Reads a block of data from the COMPASS / ACCELERO.
DeviceAddr | the slave address to be programmed(ACC_I2C_ADDRESS or MAG_I2C_ADDRESS). |
RegisterAddr | the COMPASS / ACCELERO internal address register to read from |
COMPASS | / ACCELERO register value |
Definition at line 724 of file stm32f411e_discovery.c.
void COMPASSACCELERO_IO_Write | ( | uint16_t | DeviceAddr, |
uint8_t | RegisterAddr, | ||
uint8_t | Value | ||
) |
Writes one byte to the COMPASS / ACCELERO.
DeviceAddr | the slave address to be programmed |
RegisterAddr | the COMPASS / ACCELERO register to be written |
Value | Data to be written |
Definition at line 712 of file stm32f411e_discovery.c.
void GYRO_IO_Read | ( | uint8_t * | pBuffer, |
uint8_t | ReadAddr, | ||
uint16_t | NumByteToRead | ||
) |
Reads a block of data from the GYRO.
pBuffer | pointer to the buffer that receives the data read from the GYRO. |
ReadAddr | GYRO's internal address to read from. |
NumByteToRead | Number of bytes to read from the GYRO. |
Definition at line 568 of file stm32f411e_discovery.c.
void GYRO_IO_Write | ( | uint8_t * | pBuffer, |
uint8_t | WriteAddr, | ||
uint16_t | NumByteToWrite | ||
) |
Writes one byte to the GYRO.
pBuffer | pointer to the buffer containing the data to be written to the GYRO. |
WriteAddr | : GYRO's internal address to write to. |
NumByteToWrite | Number of bytes to write. |
Definition at line 534 of file stm32f411e_discovery.c.
|
static |
|
static |
Reads a register of the device through BUS.
Addr | Device address on BUS Bus. |
Reg | The target register address to write |
Data | read at register address |
Definition at line 338 of file stm32f411e_discovery.c.
|
static |
Writes a value in a register of the device through BUS.
Addr | Device address on BUS Bus. |
Reg | The target register address to write |
Value | The target register value to be written |
Definition at line 318 of file stm32f411e_discovery.c.
|
static |
|
static |
Sends a Byte through the SPI interface and return the Byte received from the SPI bus.
Byte | Byte send. |
The | received byte value |
Definition at line 444 of file stm32f411e_discovery.c.