espressif / esp-adf

Espressif Audio Development Framework
Other
1.49k stars 667 forks source link

使用ESP32-LyraT V4.3开发板跑例程pipeline_hfp_stream, MIC没有声音 (AUD-5228) #1160

Open dinasind opened 4 months ago

dinasind commented 4 months ago

----------------------------- Delete below -----------------------------

Reminder: If your issue is a general question, start similar to "How do I..". If it is related to 3rd party development kits/libs, please discuss this on our community forum at https://esp32.com instead.

INSTRUCTIONS

Before submitting a new issue, please follow the checklist and try to find the answer.

If the issue cannot be solved after the steps above, please follow these instructions so we can get the needed information to help you quickly and effectively.

  1. Fill in all the fields under Environment marked with [ ] by picking the correct option for you in each case and deleting the others.
  2. Describe your issues.
  3. Include debug logs from the "monitor" tool, or coredumps.
  4. Providing as much information as possible under Other Items If Possible will help us locate and fix the problem.
  5. Use Markdown (see formatting buttons above) and the Preview tab to check what the issue will look like.
  6. Delete these instructions from the above to the below marker lines before submitting this issue.

IMPORTANT: Please follow the above instructions and provide as many details as possible. It will save a lot of communication time and improve the efficiency of problem solving. The more details you provide, the faster we may be able to reproduce and resolve the issue. Thanks!

----------------------------- Delete above -----------------------------

Environment

rst:0x1 (POWERON_RESET),boot:0x1f (SPI_FAST_FLASH_BOOT) configsip: 0, SPIWP:0xee clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00 mode:DIO, clock div:2 load:0x3fff0030,len:6672 load:0x40078000,len:15060 ho 0 tail 12 room 4 load:0x40080400,len:3836 0x40080400: _init at ??:?

entry 0x4008069c I (29) boot: ESP-IDF v4.4.6-502-g6897e4e0fa-dirty 2nd stage bootloader I (29) boot: compile time 14:46:56 I (30) boot: Multicore bootloader I (34) boot: chip revision: v3.1 I (38) boot.esp32: SPI Speed : 40MHz I (43) boot.esp32: SPI Mode : DIO I (47) boot.esp32: SPI Flash Size : 4MB I (52) boot: Enabling RNG early entropy source... I (57) boot: Partition Table: I (61) boot: ## Label Usage Type ST Offset Length I (68) boot: 0 nvs WiFi data 01 02 00009000 00006000 I (76) boot: 1 phy_init RF data 01 01 0000f000 00001000 I (83) boot: 2 factory factory app 00 00 00010000 002dc6c0 I (91) boot: End of partition table I (95) esp_image: segment 0: paddr=00010020 vaddr=3f400020 size=2cb50h (183120) map I (169) esp_image: segment 1: paddr=0003cb78 vaddr=3ffbdb60 size=034a0h ( 13472) load I (175) esp_image: segment 2: paddr=00040020 vaddr=400d0020 size=b4914h (739604) map I (443) esp_image: segment 3: paddr=000f493c vaddr=3ffc1000 size=00fc4h ( 4036) load I (445) esp_image: segment 4: paddr=000f5908 vaddr=40080000 size=1a57ch (107900) load I (506) boot: Loaded app from partition at offset 0x10000 I (506) boot: Disabling RNG early entropy source... I (517) cpu_start: Multicore app I (518) cpu_start: Pro cpu up. I (518) cpu_start: Starting app cpu, entry point is 0x400813a8 0x400813a8: call_start_cpu1 at D:/InstallProgrames/esp-adf/esp-idf/components/esp_system/port/cpu_start.c:151

I (0) cpu_start: App cpu up. I (538) cpu_start: Pro cpu start user code I (538) cpu_start: cpu freq: 160000000 I (538) cpu_start: Application information: I (542) cpu_start: Project name: pipeline_hfp_stream_example I (549) cpu_start: App version: 1 I (554) cpu_start: Compile time: Feb 27 2024 14:44:55 I (560) cpu_start: ELF file SHA256: a5137e4f0dd4d239... I (566) cpu_start: ESP-IDF: v4.4.6-502-g6897e4e0fa-dirty I (572) cpu_start: Min chip rev: v0.0 I (577) cpu_start: Max chip rev: v3.99 I (582) cpu_start: Chip rev: v3.1 I (587) heap_init: Initializing. RAM available for dynamic allocation: I (594) heap_init: At 3FFAFF10 len 000000F0 (0 KiB): DRAM I (600) heap_init: At 3FFB7468 len 00000B98 (2 KiB): DRAM I (606) heap_init: At 3FFB9A20 len 00004108 (16 KiB): DRAM I (612) heap_init: At 3FFCC440 len 00013BC0 (78 KiB): DRAM I (618) heap_init: At 3FFE0440 len 00003AE0 (14 KiB): D/IRAM I (625) heap_init: At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM I (631) heap_init: At 4009A57C len 00005A84 (22 KiB): IRAM I (639) spi_flash: detected chip: generic I (642) spi_flash: flash io: dio W (646) spi_flash: Detected size(8192k) larger than the size in the binary image header(4096k). Using the size in the binary image header. I (660) cpu_start: Starting scheduler on PRO CPU. I (0) cpu_start: Starting scheduler on APP CPU. I (712) HFP_EXAMPLE: [ 1 ] init Bluetooth I (712) BTDM_INIT: BT controller compile version [0f0c5a2] I (722) system_api: Base MAC address is not set I (722) system_api: read default base MAC address from EFUSE I (722) BTDM_INIT: Bluetooth MAC: a0:a3:b3:85:f6:f2 I (732) phy_init: phy_version 4791,2c4672b,Dec 20 2023,16:06:06 I (1432) HFP_EXAMPLE: [ 2 ] Start codec chip I (1442) gpio: GPIO[19]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:3 I (1462) gpio: GPIO[21]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0 I (1462) ES8388_DRIVER: init,out:02, in:00 I (1472) AUDIO_HAL: Codec mode is 3, Ctrl:1 I (1482) HFP_EXAMPLE: [ 3 ] Create audio pipeline for playback I (1482) HFP_EXAMPLE: [3.1] Create i2s stream to write data to codec chip and read data from codec chip I (1492) I2S: APLL expected frequency is 8192000 Hz, real frequency is 8191999 Hz I (1492) I2S: DMA Malloc info, datalen=blocksize=600, dma_buf_count=3 I (1502) I2S: DMA Malloc info, datalen=blocksize=600, dma_buf_count=3 I (1512) I2S: I2S0, MCLK output by GPIO0 E (1512) I2S: register I2S object to platform failed I (1522) I2S: I2S0, MCLK output by GPIO0 I (1522) HFP_EXAMPLE: [3.2] Get hfp stream I (1532) HFP_STREAM: outgoing stream init I (1532) HFP_STREAM: incoming stream init I (1542) HFP_EXAMPLE: [3.2] Register all elements to audio pipeline I (1542) HFP_EXAMPLE: [3.3] Link it together [Bluetooth]-->hfp_in_stream-->i2s_stream_writer-->[codec_chip] I (1562) AUDIO_PIPELINE: link el->rb, el:0x3ffd81fc, tag:incoming, rb:0x3ffd85a0 I (1562) AUDIO_PIPELINE: link el->rb, el:0x3ffd7798, tag:i2s_reader, rb:0x3ffda6f0 I (1572) HFP_EXAMPLE: [ 4 ] Initialize peripherals E (1582) gpio: gpio_install_isr_service(450): GPIO isr service already installed I (1582) HFP_EXAMPLE: [ 5 ] Set up event listener I (1592) HFP_EXAMPLE: [5.1] Listening event from all elements of pipeline I (1602) HFP_EXAMPLE: [5.2] Listening event from peripherals I (1602) HFP_EXAMPLE: [ 6 ] Listen for all pipeline events W (33192) BT_HCI: hcif conn complete: hdl 0x80, st 0x0 W (33232) BT_HCI: hcif link supv_to changed: hdl 0x80, supv_to 8000 W (33402) BT_APPL: new conn_srvc id:27, app_id:1 I (33412) HFP_STREAM: APP HFP event: CONNECTION_STATE_EVT I (33412) HFP_STREAM: --Connection state connected, peer feats 0x0, chld_feats 0x0 I (33522) HFP_STREAM: APP HFP event: CALL_IND_EVT I (33522) HFP_STREAM: --Call indicator NO call in progress I (33522) HFP_STREAM: APP HFP event: CALL_SETUP_IND_EVT I (33532) HFP_STREAM: --Call setup indicator NONE I (33542) HFP_STREAM: APP HFP event: NETWORK_STATE_EVT I (33542) HFP_STREAM: --NETWORK state available I (33552) HFP_STREAM: APP HFP event: SIGNAL_STRENGTH_IND_EVT I (33552) HFP_STREAM: --Signal strength: 5 I (33562) HFP_STREAM: APP HFP event: ROAMING_STATUS_IND_EVT I (33562) HFP_STREAM: --ROAMING: inactive I (33572) HFP_STREAM: APP HFP event: BATTERY_LEVEL_IND_EVT I (33572) HFP_STREAM: --Battery level 2 I (33582) HFP_STREAM: APP HFP event: CALL_HELD_IND_EVT I (33602) HFP_STREAM: --Call held indicator NONE held I (33602) HFP_STREAM: APP HFP event: CONNECTION_STATE_EVT I (33612) HFP_STREAM: --Connection state slc_connected, peer feats 0xf6f, chld_feats 0x2b I (33622) HFP_STREAM: APP HFP event: INBAND_RING_TONE_EVT I (33622) HFP_STREAM: --Inband ring state Provided W (33632) BT_L2CAP: L2CAP - rcvd conn req for unknown PSM: 25 W (33712) BT_L2CAP: L2CAP - rcvd conn req for unknown PSM: 25 W (39752) BT_L2CAP: L2CAP - rcvd conn req for unknown PSM: 25 W (40012) BT_L2CAP: L2CAP - rcvd conn req for unknown PSM: 25 W (40602) BT_HCI: hci cmd send: sniff: hdl 0x80, intv(400 800) W (40632) BT_HCI: hcif mode change: hdl 0x80, mode 2, intv 800, status 0x0

Problem Description

使用ESP32-LyraT V4.3开发板跑例程pipeline_hfp_stream,MIC输入没有声音。 看到代码中有两次i2s_stream_init初始化,从log输出看第二次是失败的,需要怎么解决?