diff options
author | Joel Challis <git@zvecr.com> | 2019-07-16 09:36:23 +0100 |
---|---|---|
committer | Florian Didron <fdidron@users.noreply.github.com> | 2019-07-19 10:23:51 +0900 |
commit | 90853e60bbb0ffe3eb391ee9aadb8d9d0ddbc1a8 (patch) | |
tree | 55a2872bf9e8c08ba059d743c454544a4e9927f1 /drivers/arm/i2c_master.c | |
parent | c08ddb41a6a16b95126b94e2075fd284c9e363e1 (diff) |
Align ARM i2c_readReg with AVR (#6314)
* Align arm i2c_readReg with avr
* Align arm i2c_readReg with avr - fix cannonkeys
Diffstat (limited to 'drivers/arm/i2c_master.c')
-rw-r--r-- | drivers/arm/i2c_master.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/arm/i2c_master.c b/drivers/arm/i2c_master.c index 9b4a752b1c..cba5a1c679 100644 --- a/drivers/arm/i2c_master.c +++ b/drivers/arm/i2c_master.c @@ -117,11 +117,11 @@ i2c_status_t i2c_writeReg(uint8_t devaddr, uint8_t regaddr, const uint8_t* data, return chibios_to_qmk(&status); } -i2c_status_t i2c_readReg(uint8_t devaddr, uint8_t* regaddr, uint8_t* data, uint16_t length, uint16_t timeout) +i2c_status_t i2c_readReg(uint8_t devaddr, uint8_t regaddr, uint8_t* data, uint16_t length, uint16_t timeout) { i2c_address = devaddr; i2cStart(&I2C_DRIVER, &i2cconfig); - msg_t status = i2cMasterTransmitTimeout(&I2C_DRIVER, (i2c_address >> 1), regaddr, 1, data, length, MS2ST(timeout)); + msg_t status = i2cMasterTransmitTimeout(&I2C_DRIVER, (i2c_address >> 1), ®addr, 1, data, length, MS2ST(timeout)); return chibios_to_qmk(&status); } |