|
Hierodule 1.6.2
Utility module set for STM32 MCUs
|
: Header file for the I2C module. More...
Go to the source code of this file.
Data Structures | |
| struct | HIERODULE_I2C_Wrapper |
| Struct that keeps variables for the data buffers, a pointer to the I2C peripheral, the slave address and pointers to the transmission end callback routines. More... | |
Enumerations | |
| enum | HIERODULE_I2C_Status { HIERODULE_I2C_Status_IDLE , HIERODULE_I2C_Status_MTX_SB , HIERODULE_I2C_Status_MTX_ADR , HIERODULE_I2C_Status_MTX , HIERODULE_I2C_Status_SRX , HIERODULE_I2C_Status_MRX_SB , HIERODULE_I2C_Status_MRX_ADR , HIERODULE_I2C_Status_MRX , HIERODULE_I2C_Status_STX } |
| I2C wrapper status enumeration. More... | |
Functions | |
| uint8_t | HIERODULE_I2C_GetNextByte (HIERODULE_I2C_Wrapper *Wrapper) |
| Fetches the next byte in the SRX ring buffer. | |
| HIERODULE_I2C_Wrapper ** | HIERODULE_I2C_InitWrapper (I2C_TypeDef *_I2C, uint16_t SRX_BufferSize, void(*SRX_Handler)(void), void(*MTX_Handler)(void), void(*STX_Handler)(void), void(*MRX_Handler)(void)) |
| Initializes a wrapper for the specified I2C peripheral. | |
| void | HIERODULE_I2C_ReleaseWrapper (HIERODULE_I2C_Wrapper *Wrapper) |
| Frees the memory allocated to an I2C wrapper. | |
| void | HIERODULE_I2C_MasterTransmit (HIERODULE_I2C_Wrapper *Wrapper, uint8_t SlaveAddress, uint8_t *MTX_Buffer, uint32_t Size) |
| Puts the peripheral in master transmitter mode and handles the transmission. | |
| void | HIERODULE_I2C_MasterReceive (HIERODULE_I2C_Wrapper *Wrapper, uint8_t SlaveAddress, uint8_t *MRX_Buffer, uint32_t Size) |
| Puts the peripheral in master receiver mode and handles the transmission. | |
Definition in file hierodule_i2c.h.