You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
esp_wifi_start causes i2s_read to read the same data from the DMA buffer for the ADC. I tried changing wifi settings in menuconfig like optimizations, cores, flash. Also tried wrapping i2s_read() in i2s_adc_enable and i2s_adc_disable.
See my gist example which is based on the i2s_adc_dac example. I launch wifi station at the bottom of app_main
The example plays a test file (i2s_write) in one task and reads the DMA buffer (i2s_read) from a second task.
Result without starting wifi (this is what I expect):
When wifi is started like in my gist example you can see the buffer returns the same value. Seems like the DMA receive buffer stops being filled when wifi driver is in use.
Playing file example:
I (584) ad/da: ESP_WIFI_MODE_STA
I (604) wifi:wifi driver task: 3ffcf300, prio:23, stack:6656, core=1
I (604) system_api: Base MAC address is not set
I (604) system_api: read default base MAC address from EFUSE
I (604) wifi:wifi firmware version: cdcf32f
I (614) wifi:wifi certification version: v7.0
I (614) wifi:config NVS flash: disabled
I (614) wifi:config nano formating: disabled
I (624) wifi:Init dynamic tx buffer num: 32
I (624) wifi:Init data frame dynamic rx buffer num: 32
I (634) wifi:Init management frame dynamic rx buffer num: 32
I (634) wifi:Init management short buffer num: 32
I (644) wifi:Init static rx buffer size: 1600
I (644) wifi:Init static rx buffer num: 10
I (644) wifi:Init dynamic rx buffer num: 32
I (754) phy: phy_version: 4181, c9a03e2, Mar 10 2020, 12:45:06, 0, 0
I (754) wifi:mode : sta (24:0a:c4:17:e8:c4)
I (754) ad/da: wifi_init_sta finished.
I (1484) wifi:new:<6,0>, old:<1,0>, ap:<255,255>, sta:<6,0>, prof:1
======
4e 75 4e 75 9f 75 9f 75
00 76 00 76 70 76 70 76
f0 76 f0 76 83 77 83 77
00 78 00 78 63 78 63 78
58 78 58 78 5a 78 5a 78
7f 78 7f 78 3c 78 3c 78
e0 77 e0 77 a7 77 a7 77
ff 76 ff 76 7f 76 7f 76
======
I (2254) wifi:state: init -> auth (b0)
I (2264) wifi:state: auth -> assoc (0)
I (2274) wifi:state: assoc -> run (10)
Playing file example:
I (2294) wifi:connected with Echo_42, aid = 4, channel 6, BW20, bssid = 80:2a:a8:41:64:cd
I (2294) wifi:security type: 4, phy: bgn, rssi: -43
I (2294) wifi:pm start, type: 1
I (2354) wifi:AP's beacon interval = 102400 us, DTIM period = 1
======
ff 74 ff 74 59 75 59 75
9d 75 9d 75 3e 76 3e 76
ad 76 ad 76 58 77 58 77
75 77 75 77 13 78 13 78
6b 78 6b 78 7f 78 7f 78
7f 78 7f 78 ae 78 ae 78
3f 78 3f 78 00 78 00 78
63 77 63 77 d2 76 d2 76
======
======
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
======
I (3094) esp_netif_handlers: sta ip: 192.168.1.66, mask: 255.255.255.0, gw: 192.168.1.1
I (3094) ad/da: got ip:192.168.1.66
I (3094) ad/da: connected to ap SSID:Echo_42 password:qscwdvpk
======
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
======
======
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
======
======
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
fa 74 fa 74 fa 74 fa 74
The text was updated successfully, but these errors were encountered:
github-actionsbot
changed the title
Can Not Read I2S ADC DMA Buffer with Wifi Enabled
Can Not Read I2S ADC DMA Buffer with Wifi Enabled (IDFGH-3418)
Jun 2, 2020
Testing with ESP-IDF v4.2-dev-1415-ga2263571b
esp_wifi_start causes i2s_read to read the same data from the DMA buffer for the ADC. I tried changing wifi settings in menuconfig like optimizations, cores, flash. Also tried wrapping i2s_read() in i2s_adc_enable and i2s_adc_disable.
See my gist example which is based on the i2s_adc_dac example. I launch wifi station at the bottom of app_main
The example plays a test file (i2s_write) in one task and reads the DMA buffer (i2s_read) from a second task.
Result without starting wifi (this is what I expect):
When wifi is started like in my gist example you can see the buffer returns the same value. Seems like the DMA receive buffer stops being filled when wifi driver is in use.
The text was updated successfully, but these errors were encountered: