mirror of
https://github.com/esphome/esphome.git
synced 2026-05-28 13:37:24 +08:00
fix bad rebase
This commit is contained in:
@@ -275,12 +275,12 @@ esp_err_t I2SAudioSpeakerBase::init_i2s_channel_(const i2s_chan_config_t &chan_c
|
|||||||
xQueueReset(this->i2s_event_queue_);
|
xQueueReset(this->i2s_event_queue_);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this->i2s_event_queue_ == nullptr) {
|
// Lockstep records queue. One record per in-flight DMA buffer; sized to match the I2S event queue
|
||||||
ESP_LOGE(TAG, "Failed to allocate I2S event queue(s)");
|
// so a fully-saturated DMA pipeline cannot overflow either side before drain.
|
||||||
i2s_del_channel(this->tx_handle_);
|
if (this->write_records_queue_ == nullptr) {
|
||||||
this->tx_handle_ = nullptr;
|
this->write_records_queue_ = xQueueCreate(event_queue_size, sizeof(uint32_t));
|
||||||
this->parent_->unlock();
|
} else {
|
||||||
return ESP_ERR_NO_MEM;
|
xQueueReset(this->write_records_queue_);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this->i2s_event_queue_ == nullptr || this->write_records_queue_ == nullptr) {
|
if (this->i2s_event_queue_ == nullptr || this->write_records_queue_ == nullptr) {
|
||||||
|
|||||||
Reference in New Issue
Block a user