-
Notifications
You must be signed in to change notification settings - Fork 7.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Simultaneous operation of USB and i2s. (IDFGH-9789) #11127
Comments
@suda-morris Thanks for the quick response! |
Hi @EfanovIvan, I can't reproduce the issue only by initializing I2S and USB console, not sure if I missed anything, here is my test codes, could you give more details to reproduce this issue? #include <stdio.h>
#include "esp_check.h"
#include "driver/i2s_pdm.h"
#include "driver/usb_serial_jtag.h"
#include "esp_console.h"
void init_i2s()
{
i2s_chan_handle_t rxHandle = NULL;
i2s_chan_config_t chanCfg = I2S_CHANNEL_DEFAULT_CONFIG(I2S_NUM_AUTO, I2S_ROLE_MASTER);
ESP_ERROR_CHECK(i2s_new_channel(&chanCfg, NULL, &rxHandle));
i2s_pdm_rx_config_t pdmRxCfg = {
.clk_cfg = I2S_PDM_RX_CLK_DEFAULT_CONFIG(16000),
/* The default mono slot is the left slot (whose 'select pin' of the PDM microphone is pulled down) */
.slot_cfg = I2S_PDM_RX_SLOT_DEFAULT_CONFIG(I2S_DATA_BIT_WIDTH_16BIT, I2S_SLOT_MODE_MONO),
.gpio_cfg = {
.clk = 1,
.din = 2,
.invert_flags = {
.clk_inv = false,
},
},
};
ESP_ERROR_CHECK(i2s_channel_init_pdm_rx_mode(rxHandle, &pdmRxCfg));
ESP_ERROR_CHECK(i2s_channel_enable(rxHandle));
}
void init_usb_serial_jtag()
{
esp_console_repl_t* pRepl = NULL;
esp_console_repl_config_t replCfg = ESP_CONSOLE_REPL_CONFIG_DEFAULT();
esp_console_dev_usb_serial_jtag_config_t usbjtag_config = ESP_CONSOLE_DEV_USB_SERIAL_JTAG_CONFIG_DEFAULT();
ESP_ERROR_CHECK(esp_console_new_repl_usb_serial_jtag(&usbjtag_config, &replCfg, &pRepl));
ESP_ERROR_CHECK(esp_console_start_repl(pRepl));
}
void app_main(void)
{
init_usb_serial_jtag();
init_i2s();
} |
Hello @L-KAYA I will build a test project and upload it. |
I have the same issue using a full duplex ES8388 codec in parallel with TUSB in midi configuration, is this still open? |
Hi @EfanovIvan @ctag-fh-kiel, does the issue still exist? And could you upload the test project to reproduce? (This issue will be closed if no more replies) |
There is a new example i2s_usb available on the master, it doesn't have this error, it is possibly not the coexistence issue of USB and I2S. Going to close this issue since no further response, feel free to reopen it or open a new issue about the GDMA. |
Answers checklist.
IDF version.
v5.0.1
Operating System used.
Windows
How did you build your project?
Command line with idf.py
If you are using Windows, please specify command line type.
CMD
Development Kit.
ESP32-S3-WROOM-1-N16R8
Power Supply used.
USB
What is the expected behavior?
Simultaneous operation of USB and i2s.
What is the actual behavior?
I am getting the following error when initializing i2s
Initialization code
Steps to reproduce.
Initialize usb
After that i2s, the code is shown above
Debug Logs.
No response
More Information.
No response
The text was updated successfully, but these errors were encountered: