i2c: handle errors at i2ccmds
Signed-off-by: Timofey Titovets <nefelim4ag@gmail.com>
This commit is contained in:
committed by
KevinOConnor
parent
08a85ba869
commit
a4aa2a9002
@@ -4,6 +4,15 @@
|
||||
#include <inttypes.h>
|
||||
#include "board/gpio.h" // i2c_config
|
||||
|
||||
// I2C ERROR Codes
|
||||
enum {
|
||||
I2C_BUS_SUCCESS,
|
||||
I2C_BUS_NACK,
|
||||
I2C_BUS_TIMEOUT,
|
||||
I2C_BUS_START_NACK,
|
||||
I2C_BUS_START_READ_NACK,
|
||||
};
|
||||
|
||||
struct i2cdev_s {
|
||||
union {
|
||||
struct i2c_config i2c_hw;
|
||||
|
||||
Reference in New Issue
Block a user