Skip to content

Commit

Permalink
fix: add missing const to _write_reg
Browse files Browse the repository at this point in the history
  • Loading branch information
vil02 committed Oct 2, 2024
1 parent 1abe2e5 commit 50b1024
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion components/dps310/priv_include/helper_i2c.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ esp_err_t _read_reg_mask(i2c_dev_t *dev, uint8_t reg, uint8_t mask, uint8_t *val
/**
* @brief Write a single byte to a 8-bit resister with locking.
*/
esp_err_t _write_reg(i2c_dev_t *dev, uint8_t reg, uint8_t *value);
esp_err_t _write_reg(i2c_dev_t *dev, uint8_t reg, const uint8_t *value);

/**
* @brief Update a 8-bit resister with a masked value without locking.
Expand Down
2 changes: 1 addition & 1 deletion components/dps310/src/helper_i2c.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ esp_err_t _update_reg_nolock(i2c_dev_t *dev, uint8_t reg, uint8_t mask, uint8_t
return ESP_OK;
}

esp_err_t _write_reg(i2c_dev_t *dev, uint8_t reg, uint8_t *value)
esp_err_t _write_reg(i2c_dev_t *dev, uint8_t reg, const uint8_t *value)
{
esp_err_t err = ESP_FAIL;

Expand Down

0 comments on commit 50b1024

Please sign in to comment.