File tree Expand file tree Collapse file tree 3 files changed +31
-1
lines changed
tests/drivers/audio/dmic_dump_buffer Expand file tree Collapse file tree 3 files changed +31
-1
lines changed Original file line number Diff line number Diff line change @@ -12,3 +12,10 @@ config TEST_USE_DMM
1212 The test will use it to determine whether to prealocate DMM
1313 buffer or use regular mem slab and allocate dmm buffer inside
1414 PDM driver.
15+
16+ config TEST_STEREO_CONFIGURATION
17+ bool "Select mono / stereo operation"
18+ help
19+ When set to 'y' PDM driver will be configured in stereo mode.
20+ In such case, import RAW audio data using following configuration:
21+ Signed 16-bit PCM; little-endian; stereo; 16000Hz.
Original file line number Diff line number Diff line change @@ -67,9 +67,16 @@ int main(void)
6767 },
6868 .streams = & stream ,
6969 .channel = {
70- .req_num_chan = 1 ,
7170 .req_num_streams = 1 ,
71+ #if defined(CONFIG_TEST_STEREO_CONFIGURATION )
72+ .req_num_chan = 2 ,
73+ .req_chan_map_lo =
74+ dmic_build_channel_map (0 , 0 , PDM_CHAN_LEFT ) |
75+ dmic_build_channel_map (1 , 0 , PDM_CHAN_RIGHT ),
76+ #else
77+ .req_num_chan = 1 ,
7278 .req_chan_map_lo = dmic_build_channel_map (0 , 0 , PDM_CHAN_LEFT ),
79+ #endif
7380 },
7481 };
7582
Original file line number Diff line number Diff line change @@ -16,9 +16,25 @@ tests:
1616 - nrf5340dk/nrf5340/cpuapp
1717 - nrf54h20dk/nrf54h20/cpuapp
1818 - nrf54l15dk/nrf54l15/cpuapp
19+ drivers.audio.dmic_dump_buffer.stereo :
20+ filter : dt_nodelabel_enabled("dmic_dev")
21+ extra_args :
22+ - CONFIG_TEST_STEREO_CONFIGURATION=y
23+ platform_allow :
24+ - nrf52840dk/nrf52840
25+ - nrf5340dk/nrf5340/cpuapp
26+ - nrf54h20dk/nrf54h20/cpuapp
27+ - nrf54l15dk/nrf54l15/cpuapp
1928 drivers.audio.dmic_dump_buffer.dmm :
2029 filter : dt_nodelabel_enabled("dmic_dev")
2130 platform_allow :
2231 - nrf54h20dk/nrf54h20/cpuapp
2332 extra_args :
2433 - CONFIG_TEST_USE_DMM=y
34+ drivers.audio.dmic_dump_buffer.dmm.stereo :
35+ filter : dt_nodelabel_enabled("dmic_dev")
36+ platform_allow :
37+ - nrf54h20dk/nrf54h20/cpuapp
38+ extra_args :
39+ - CONFIG_TEST_USE_DMM=y
40+ - CONFIG_TEST_STEREO_CONFIGURATION=y
You can’t perform that action at this time.
0 commit comments