mirror of https://github.com/ARMmbed/mbed-os.git
[HAL][KSDK] Fixed ACK/NACK received inverted (https://github.com/mbedmicro/mbed/issues/661)
As reported by Geremia G (http://developer.mbed.org/forum/bugs-suggestions/topic/5220/)pull/684/head
parent
57a79c08a9
commit
d3e2cacff3
|
@ -97,7 +97,7 @@ static int i2c_wait_end_tx_transfer(i2c_t *obj) {
|
|||
}
|
||||
|
||||
// check if we received the ACK or not
|
||||
return I2C_HAL_GetStatusFlag(i2c_addrs[obj->instance], kI2CReceivedNak) ? 0 : 1;
|
||||
return I2C_HAL_GetStatusFlag(i2c_addrs[obj->instance], kI2CReceivedNak) ? 1 : 0;
|
||||
}
|
||||
|
||||
// this function waits the end of a rx transfer and return the status of the transaction:
|
||||
|
|
Loading…
Reference in New Issue