diff options
author | Drashna Jaelre <drashna@live.com> | 2020-02-24 16:47:19 -0800 |
---|---|---|
committer | Florian Didron <fdidron@users.noreply.github.com> | 2020-02-26 10:15:12 +0900 |
commit | a8e1406574feffe8a5c981d1963f1bcf9708b23a (patch) | |
tree | 1834d16b4c4e1f244e901b1f88eb9840f3e1c0f1 /keyboards | |
parent | ca79f45ea8e87b55ce9d63ad78a2f7cd15d852b3 (diff) |
Revert "[Keyboard] Remove i2c write command when reading columns on Ergodox EZ (#8092)"
This reverts commit 737d2793a6ecd6ca9355a92019c8e47cc3f0c4c5.
Diffstat (limited to 'keyboards')
-rw-r--r-- | keyboards/ergodox_ez/matrix.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/keyboards/ergodox_ez/matrix.c b/keyboards/ergodox_ez/matrix.c index 6ce3d7216e..6d976f143c 100644 --- a/keyboards/ergodox_ez/matrix.c +++ b/keyboards/ergodox_ez/matrix.c @@ -216,8 +216,10 @@ static matrix_row_t read_cols(uint8_t row) { return 0; } else { uint8_t data = 0; - // reading GPIOB (column port) since in mcp23018's sequential mode - // it is addressed directly after writing to GPIOA in select_row() + mcp23018_status = i2c_start(I2C_ADDR_WRITE, ERGODOX_EZ_I2C_TIMEOUT); + if (mcp23018_status) goto out; + mcp23018_status = i2c_write(GPIOB, ERGODOX_EZ_I2C_TIMEOUT); + if (mcp23018_status) goto out; mcp23018_status = i2c_start(I2C_ADDR_READ, ERGODOX_EZ_I2C_TIMEOUT); if (mcp23018_status) goto out; mcp23018_status = i2c_read_nack(ERGODOX_EZ_I2C_TIMEOUT); |