aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--apps/px4io/i2c.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/px4io/i2c.c b/apps/px4io/i2c.c
index c16d5700c..2b8c502c7 100644
--- a/apps/px4io/i2c.c
+++ b/apps/px4io/i2c.c
@@ -157,7 +157,7 @@ i2c_interrupt(int irq, FAR void *context)
{
uint16_t sr1 = rSR1;
- if (sr1 & (I2C_SR1_STOPF | I2C_SR1_AF)) {
+ if (sr1 & (I2C_SR1_STOPF | I2C_SR1_AF | I2C_SR1_ADDR)) {
if (sr1 & I2C_SR1_STOPF) {
/* write to CR1 to clear STOPF */
@@ -165,7 +165,7 @@ i2c_interrupt(int irq, FAR void *context)
rCR1 |= I2C_CR1_PE;
}
- /* it's likely that the DMA hasn't stopped, so we have to do it here */
+ /* DMA never stops, so we should do that now */
switch (direction) {
case DIR_TX:
i2c_tx_complete();