File tree Expand file tree Collapse file tree 2 files changed +29
-0
lines changed
tests/drivers/audio/dmic_api Expand file tree Collapse file tree 2 files changed +29
-0
lines changed Original file line number Diff line number Diff line change
1
+ /*
2
+ * Copyright 2025 NXP
3
+ *
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+
7
+ / {
8
+ aliases {
9
+ dmic-dev = &pdm;
10
+ };
11
+ };
12
+
13
+ &pdm {
14
+ status = "okay";
15
+
16
+ channel0: pdm-channel@0 {
17
+ status = "okay";
18
+ };
19
+
20
+ channel1: pdm-channel@1 {
21
+ status = "okay";
22
+ };
23
+ };
Original file line number Diff line number Diff line change @@ -27,6 +27,12 @@ static const struct device *dmic_dev = DEVICE_DT_GET(DT_ALIAS(dmic_dev));
27
27
#define BYTES_PER_SAMPLE sizeof(int16_t)
28
28
#define SLAB_ALIGN 4
29
29
#define MAX_SAMPLE_RATE 48000
30
+ #elif DT_HAS_COMPAT_STATUS_OKAY (nxp_pdm )
31
+ #define PDM_CHANNELS 2
32
+ #define SAMPLE_BIT_WIDTH 24
33
+ #define BYTES_PER_SAMPLE 3
34
+ #define SLAB_ALIGN 4
35
+ #define MAX_SAMPLE_RATE 16000
30
36
#else
31
37
#error "Unsupported DMIC device"
32
38
#endif
You can’t perform that action at this time.
0 commit comments