diff options
Diffstat (limited to 'keyboards/handwired/pterodactyl/matrix.c')
-rw-r--r-- | keyboards/handwired/pterodactyl/matrix.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/keyboards/handwired/pterodactyl/matrix.c b/keyboards/handwired/pterodactyl/matrix.c index 0dff65eda6..54da26a7d4 100644 --- a/keyboards/handwired/pterodactyl/matrix.c +++ b/keyboards/handwired/pterodactyl/matrix.c @@ -182,14 +182,14 @@ void init_expander(void) { uint8_t data[] = { expander_input_pin_mask, 0}; # endif #endif - expander_status = i2c_writeReg(I2C_ADDR, IODIRA, data, sizeof(data), I2C_TIMEOUT); + expander_status = i2c_write_register(I2C_ADDR, IODIRA, data, sizeof(data), I2C_TIMEOUT); if (!expander_status) { // set pull-up // - unused : off : 0 // - input : on : 1 // - driving : off : 0 - expander_status = i2c_writeReg(I2C_ADDR, GPPUA, data, sizeof(data), I2C_TIMEOUT); + expander_status = i2c_write_register(I2C_ADDR, GPPUA, data, sizeof(data), I2C_TIMEOUT); } } @@ -305,7 +305,7 @@ static bool read_cols_on_row(matrix_row_t current_matrix[], uint8_t current_row) // Read columns from expander, unless it's in an error state if (! expander_status) { uint8_t data; - i2c_readReg(I2C_ADDR, EXPANDER_COL_REGISTER, &data, 1, I2C_TIMEOUT); + i2c_read_register(I2C_ADDR, EXPANDER_COL_REGISTER, &data, 1, I2C_TIMEOUT); current_matrix[current_row] |= (~data) & expander_input_pin_mask; } @@ -329,7 +329,7 @@ static void select_row(uint8_t row) { // set active row low : 0 // set other rows hi-Z : 1 uint8_t data = 0xFF & ~(1<<row); - i2c_writeReg(I2C_ADDR, EXPANDER_ROW_REGISTER, &data, 1, I2C_TIMEOUT); + i2c_write_register(I2C_ADDR, EXPANDER_ROW_REGISTER, &data, 1, I2C_TIMEOUT); } // select on teensy @@ -385,7 +385,7 @@ static bool read_rows_on_col(matrix_row_t current_matrix[], uint8_t current_col) return false; } - i2c_writeReg(I2C_ADDR, EXPANDER_ROW_REGISTER, &column_state, 1, I2C_TIMEOUT); + i2c_write_register(I2C_ADDR, EXPANDER_ROW_REGISTER, &column_state, 1, I2C_TIMEOUT); column_state = ~column_state; } else { for (uint8_t current_row = 0; current_row < MATRIX_ROWS; current_row++) { |