forked from espressif/esp-idf
Merge branch 'fix/i2c_semaphore_release_v5.3' into 'release/v5.3'
fix(i2c): Fix i2c not release semaphore in command send loop(backport v5.3) See merge request espressif/esp-idf!31958
This commit is contained in:
@ -425,6 +425,8 @@ static void s_i2c_send_commands(i2c_master_bus_handle_t i2c_master, TickType_t t
|
|||||||
i2c_master->cmd_idx = 0;
|
i2c_master->cmd_idx = 0;
|
||||||
i2c_master->trans_idx = 0;
|
i2c_master->trans_idx = 0;
|
||||||
atomic_store(&i2c_master->status, I2C_STATUS_TIMEOUT);
|
atomic_store(&i2c_master->status, I2C_STATUS_TIMEOUT);
|
||||||
|
ESP_LOGE(TAG, "I2C software timeout");
|
||||||
|
xSemaphoreGive(i2c_master->cmd_semphr);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user