#include <drivers/i2c.h>
#include "hal_i2c.h"
Go to the source code of this file.
|
| enum | i2c_target_error_status {
I2C_TARGET_HAS_NO_ERR
, I2C_TARGET_BUS_INVALID
, I2C_TARGET_NOT_INIT
, I2C_TARGET_NOT_REGISTER = 0x04
,
I2C_TARGET_CONTROLLER_ERR
} |
| |
| enum | i2c_target_api_error_status {
I2C_TARGET_API_NO_ERR
, I2C_TARGET_API_INPUT_ERR
, I2C_TARGET_API_LOCK_ERR
, I2C_TARGET_API_MEMORY_ERR
,
I2C_TARGET_API_MSGQ_ERR
, I2C_TARGET_API_BUS_GET_FAIL
, I2C_TARGET_API_UNKNOWN_ERR = 0xFF
} |
| |
| enum | i2c_target_api_control_mode { I2C_CONTROL_UNREGISTER
, I2C_CONTROL_REGISTER
, I2C_CONTROL_MAX = 0xFF
} |
| |
◆ I2C_CONTROLLER_NAME_GET
◆ I2C_DEVICE_PREFIX
| #define I2C_DEVICE_PREFIX "I2C_" |
◆ MAX_I2C_TARGET_BUFF
| #define MAX_I2C_TARGET_BUFF 256 |
◆ MAX_TARGET_NUM
| #define MAX_TARGET_NUM 16 |
◆ i2c_target_api_control_mode
| Enumerator |
|---|
| I2C_CONTROL_UNREGISTER | |
| I2C_CONTROL_REGISTER | |
| I2C_CONTROL_MAX | |
◆ i2c_target_api_error_status
| Enumerator |
|---|
| I2C_TARGET_API_NO_ERR | |
| I2C_TARGET_API_INPUT_ERR | |
| I2C_TARGET_API_LOCK_ERR | |
| I2C_TARGET_API_MEMORY_ERR | |
| I2C_TARGET_API_MSGQ_ERR | |
| I2C_TARGET_API_BUS_GET_FAIL | |
| I2C_TARGET_API_UNKNOWN_ERR | |
◆ i2c_target_error_status
| Enumerator |
|---|
| I2C_TARGET_HAS_NO_ERR | |
| I2C_TARGET_BUS_INVALID | |
| I2C_TARGET_NOT_INIT | |
| I2C_TARGET_NOT_REGISTER | |
| I2C_TARGET_CONTROLLER_ERR | |
◆ __attribute__()
◆ i2c_target_cfg_get()
◆ i2c_target_control()
◆ i2c_target_read()
| uint8_t i2c_target_read |
( |
uint8_t |
bus_num, |
|
|
uint8_t * |
buff, |
|
|
uint16_t |
buff_len, |
|
|
uint16_t * |
msg_len |
|
) |
| |
◆ i2c_target_status_get()
| uint8_t i2c_target_status_get |
( |
uint8_t |
bus_num | ) |
|
◆ i2c_target_status_print()
| uint8_t i2c_target_status_print |
( |
uint8_t |
bus_num | ) |
|
◆ i2c_target_write()
| uint8_t i2c_target_write |
( |
uint8_t |
bus_num, |
|
|
uint8_t * |
buff, |
|
|
uint16_t |
buff_len |
|
) |
| |
◆ util_init_I2C_target()
| void util_init_I2C_target |
( |
void |
| ) |
|
◆ I2C_TARGET_CONFIG_TABLE
◆ I2C_TARGET_ENABLE_TABLE