aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/avr/i2c_master.h
diff options
context:
space:
mode:
authorGravatar Jack Humbert <jack.humb@gmail.com>2018-06-23 14:18:47 -0400
committerGravatar Jack Humbert <jack.humb@gmail.com>2018-06-23 14:18:47 -0400
commit7a44ad83fce391c938d18abcc2125e15c1982078 (patch)
tree1c0db8fbaf33aa1cf408ba418cdb3705b526d618 /drivers/avr/i2c_master.h
parent6380f8319057d33bb6d07c66789867e49c634504 (diff)
downloadqmk_firmware-7a44ad83fce391c938d18abcc2125e15c1982078.tar.gz
adds immediate i2c return, fixes ez matrix code
Diffstat (limited to 'drivers/avr/i2c_master.h')
-rwxr-xr-xdrivers/avr/i2c_master.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/avr/i2c_master.h b/drivers/avr/i2c_master.h
index 0806d76aa..cf93680be 100755
--- a/drivers/avr/i2c_master.h
+++ b/drivers/avr/i2c_master.h
@@ -14,6 +14,9 @@ typedef int16_t i2c_status_t;
#define I2C_STATUS_ERROR (-1)
#define I2C_STATUS_TIMEOUT (-2)
+#define I2C_TIMEOUT_IMMEDIATE (0)
+#define I2C_TIMEOUT_INFINITE (0xFFFF)
+
void i2c_init(void);
i2c_status_t i2c_start(uint8_t address, uint16_t timeout);
i2c_status_t i2c_write(uint8_t data, uint16_t timeout);