|
I2C_Drivers (ARM) 1.1
SMFSW collection of HAL I2C Drivers for ARM
|
TCS3400 Driver. More...
#include "sarmfsw.h"#include "I2C_component.h"#include "I2C_peripheral.h"#include "TCS3400_proc.h"#include "TCS3400_ex.h"

Data Structures | |
| union | uTCS3400_REG__ENABLE |
| Union for ENABLE register of TCS3400. More... | |
| union | uTCS3400_REG__PERSIST |
| Union for PERSIST register of TCS3400. More... | |
| union | uTCS3400_REG__CONFIG |
| Union for CONFIG register of TCS3400. More... | |
| union | uTCS3400_REG__CONTROL |
| Union for CONTROL register of TCS3400. More... | |
| union | uTCS3400_REG__AUX |
| Union for AUX register of TCS3400. More... | |
| union | uTCS3400_REG__STATUS |
| Union for STATUS register of TCS3400. More... | |
| union | uTCS3400_REG__IR |
| Union for IR sensor access register of TCS3400. More... | |
Macros | |
| #define | I2C_TCS3400_NB 1U |
| Number of TCS3400 peripherals. | |
| #define | TCS34001_ADDR 0x39U |
| TCS34001 Base address. | |
| #define | TCS34003_ADDR 0x39U |
| TCS34003 Base address. | |
| #define | TCS34005_ADDR 0x29U |
| TCS34005 Base address. | |
| #define | TCS34007_ADDR 0x29U |
| TCS34007 Base address. | |
| #define | TCS3400_BASE_ADDR TCS34005_ADDR |
| TCS3400 Base address. | |
Functions | |
| FctERR | TCS3400_Init (const uint8_t idx, I2C_HandleTypeDef *const hi2c, const uint16_t devAddress) |
| Initialization for TCS3400 peripheral. | |
| FctERR | TCS3400_Init_Single (void) |
| Initialization for TCS3400 peripheral. | |
| FctERR | TCS3400_Write (I2C_slave_t *const pSlave, const uint8_t *data, const uint16_t addr, const uint16_t nb) |
| I2C Write function for TCS3400. | |
| FctERR | TCS3400_Read (I2C_slave_t *const pSlave, uint8_t *data, const uint16_t addr, const uint16_t nb) |
| I2C Read function for TCS3400. | |
| FctERR | TCS3400_Write_Word (I2C_slave_t *const pSlave, const uint16_t *data, const uint16_t addr) |
| I2C Word Write (little endian) function for TCS3400. | |
| FctERR | TCS3400_Read_Word (I2C_slave_t *const pSlave, uint16_t *data, const uint16_t addr) |
| I2C Word Read (little endian) function for TCS3400. | |
TCS3400 Driver.
TCS3400: Color Light-to-Digital Converter
| #define I2C_TCS3400_NB 1U |
Number of TCS3400 peripherals.
| #define TCS34001_ADDR 0x39U |
TCS34001 Base address.
| #define TCS34003_ADDR 0x39U |
TCS34003 Base address.
| #define TCS34005_ADDR 0x29U |
TCS34005 Base address.
| #define TCS34007_ADDR 0x29U |
TCS34007 Base address.
| #define TCS3400_BASE_ADDR TCS34005_ADDR |
TCS3400 Base address.
| enum TCS3400_gain |
| enum TCS3400_it_persist |
Persistence control of TCS3400.
| enum TCS3400_reg |
Register map enum of TCS3400.
| FctERR TCS3400_Init | ( | const uint8_t | idx, |
| I2C_HandleTypeDef *const | hi2c, | ||
| const uint16_t | devAddress ) |
Initialization for TCS3400 peripheral.
| [in] | idx | - TCS3400 index |
| [in] | hi2c | - pointer to TCS3400 I2C instance |
| [in] | devAddress | - TCS3400 device address |


| FctERR TCS3400_Init_Single | ( | void | ) |
Initialization for TCS3400 peripheral.

| FctERR TCS3400_Read | ( | I2C_slave_t *const | pSlave, |
| uint8_t * | data, | ||
| const uint16_t | addr, | ||
| const uint16_t | nb ) |
I2C Read function for TCS3400.
| [in,out] | pSlave | - Pointer to I2C slave instance |
| [in,out] | data | - pointer to read to |
| [in] | addr | - Address to read from |
| [in] | nb | - Number of bytes to read |


| FctERR TCS3400_Read_Word | ( | I2C_slave_t *const | pSlave, |
| uint16_t * | data, | ||
| const uint16_t | addr ) |
I2C Word Read (little endian) function for TCS3400.
| [in,out] | pSlave | - Pointer to I2C slave instance |
| [in,out] | data | - pointer to read to |
| [in] | addr | - Address to read from |


| FctERR TCS3400_Write | ( | I2C_slave_t *const | pSlave, |
| const uint8_t * | data, | ||
| const uint16_t | addr, | ||
| const uint16_t | nb ) |
I2C Write function for TCS3400.
| [in,out] | pSlave | - Pointer to I2C slave instance |
| [in] | data | - pointer to write from |
| [in] | addr | - Address to write to |
| [in] | nb | - Number of bytes to write |


| FctERR TCS3400_Write_Word | ( | I2C_slave_t *const | pSlave, |
| const uint16_t * | data, | ||
| const uint16_t | addr ) |
I2C Word Write (little endian) function for TCS3400.
| [in,out] | pSlave | - Pointer to I2C slave instance |
| [in] | data | - pointer to write from |
| [in] | addr | - Address to write to |

