mirror of
https://github.com/apache/nuttx.git
synced 2026-10-13 01:00:12 +00:00
lpc17_40 i2c: Fix I2C driver state desynchronization.
This commit is contained in:
parent
9a6fa489d8
commit
b2659424d5
1 changed files with 2 additions and 0 deletions
|
|
@ -227,6 +227,8 @@ static int lpc17_40_i2c_start(struct lpc17_40_i2cdev_s *priv)
|
|||
uint32_t timeout;
|
||||
int i;
|
||||
|
||||
nxsem_reset(&priv->wait, 0);
|
||||
|
||||
putreg32(I2C_CONCLR_STAC | I2C_CONCLR_SIC,
|
||||
priv->base + LPC17_40_I2C_CONCLR_OFFSET);
|
||||
putreg32(I2C_CONSET_STA, priv->base + LPC17_40_I2C_CONSET_OFFSET);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue