Skip to content

Commit

Permalink
Merge pull request #54 from esp-cpp/fix/es7210-write
Browse files Browse the repository at this point in the history
fix(es7210): fix i2c write
  • Loading branch information
finger563 authored Jan 8, 2024
2 parents c4fa256 + 03ae1be commit f494698
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion components/codec/es7210/es7210.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ static const struct _coeff_div coeff_div[] = {
static esp_err_t es7210_write_reg(uint8_t reg_addr, uint8_t data)
{
uint8_t write_buf[2] = {reg_addr, data};
return i2c_write_(ES7210_ADDR, write_buf, sizeof(write_buf)) == ESP_OK ? ESP_OK : ESP_FAIL;
return i2c_write_(ES7210_ADDR, write_buf, sizeof(write_buf)) ? ESP_OK : ESP_FAIL;
}

static esp_err_t es7210_update_reg_bit(uint8_t reg_addr, uint8_t update_bits, uint8_t data)
Expand Down

0 comments on commit f494698

Please sign in to comment.