53 #define I2C_HIGH_SPEED 0
56 #define I2C_START 0x08
57 #define I2C_REP_START 0x10
58 #define I2C_MT_SLA_ACK 0x18
59 #define I2C_MT_DATA_ACK 0x28
60 #define I2C_MR_SLA_ACK 0x40
61 #define I2C_MR_DATA_ACK 0x50
62 #define I2C_MR_DATA_NACK 0x58
68 int8_t i2c_start(uint8_t addr);
69 int8_t i2c_rep_start(uint8_t addr);
71 int8_t i2c_read(uint8_t *data, uint8_t ack);
72 int8_t i2c_read_ack(uint8_t *data);
73 int8_t i2c_read_nack(uint8_t *data);