Building Attached to the Colibri via I2C1 and SAI3 is a WM8523 for audio playback. For the device tree I followed mostly the thread here.
With the following device tree I still have no soundcard or WM8523 loaded.
/ {
sound-wm8523 {
compatible = "simple-audio-card";
simple-audio-card,name = "Wolfson WM8523";
simple-audio-card,format = "i2s";
simple-audio-card,widgets =
//"AMIC","Microphone",
//"Headphone", "Headphone",
"Speaker", "Speaker";
simple-audio-card,routing =
//"LMICN","AMIC",
//"RMICN","AMIC",
//"Headphone","LSPK",
//"Headphone","RSPK",
"Speaker","LSPK",
"Speaker","RSPK";
simple-audio-card,cpu {
sound-dai = <&sai3 0>;
system-clock-frequency = <2624000>; // freq 41000 * channels 32 * wordlen 2 = 2'634'000
bitclock-master;
frame-master;
};
simple-audio-card,codec {
sound-dai = <&wm8523 0>;
clocks = <24000000>;
};
};
};
&i2c1 {
status = "okay";
clock-frequency = <400000>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_i2c1>;
wm8523: wm8523@1a {
compatible = "wlf,wm8523";
reg = <0x1a>;
};
};
&sai3 {
status = "okay";
};
&iomuxc {
imx6ull-colibri {
pinctrl_audmux: audmuxgrp {
fsl,pins = <
MX6UL_PAD_SD1_CLK__SAI2_MCLK 0x130b1
MX6UL_PAD_JTAG_TDI__SAI2_TX_BCLK 0x130b0
MX6UL_PAD_JTAG_TRST_B__SAI2_TX_DATA 0x130b0
MX6UL_PAD_SD1_DATA2__SAI2_RX_DATA 0x130b1
>;
};
};
};
I2C seems OK, I can read the registers:
i2cdetect 0
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- 1a -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- UU -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --
i2cget 0 0x1a 0x00 w
0x2385
But there is no sound card.
cat /proc/asound/cards
--- no soundcards ---
Also in dmesg i don’t see any WM8523 message.
2020-12-18 Progress update
Updated menuconfig and it looks as follows
--> Device Drivers
--> Sound card support
--> Advanced Linux Sound Architecture
--> [*] Enable OSS Emulation
--> [*] Generic sound devices
--> [*] Dummy (dev/null) soundcard
--> [*] SPI sound devices
--> [*] ALSA for SoC audio support
--> SoC Audio for Freescale CPUs
--> [*] Synchronous Audio Interface (SAI) module support
--> [*] Synchronous Serial Interface module (SSI) support
--> [*] Enhanced Serial Audio Interface (ESAI) module support
--> [*] SoC Audio for Freescale i.MX CPUs
--> [*] Generic ASoC Sound Card with ASRC support
--> CODEC drivers
--> [*] Wolfson Microelectronics WM8523 DAC
--> [*] ASoC Simple sound card support
No I see the i2c is used
i2cdetect 0
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- UU -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- UU -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --
But no soundcard seen in alsamixer (except the dummy one).
I the Generic sound devices is deactivated, no soundcards are found.