Missing 24.576MHz Oscillator in AM62 D?

Dear support,

I have a specific question about the Verdin AM62 D 1GB IT, V1.1A product (15190237). In the technical documentation, on pin 38, there should be an output of 24.576MHz Oscillator (I2S_1_MCLK) but I do not see any on the board (only 25.000 and Wifi). There is no signal coming from the pin 38, only noise.

I wanted to ask if this is intended and if the oscillator is only an optional feature (and has to be bought) or if I am understanding it wrong. Thank you in advance.

Matej I.

Hello @Matt,

welcome to our community!
The output you mentioned belongs to the I2S interface. this has to be configured in the device tree so it is not set up by default. What is your use case and are you using torizon or one of our ref. Images?

Best Matthias

Dear Matthias,

Thank you. Our use case is:

We have a board with an external audio codec, which we want to connect using the I2S interface in slave mode. We want to receive a clock signal from I2S_1_MCLK (pin 38, GPMC0_WPn). I guess we need to change the mode from 7 to 1 based on documentation. What registry should we change to allow this?

We have not installed torizon yet.

Best,

Matej I.

Hi @Matt !

Your Account Manager from Toradex sent you some emails. Could you please check them and get back to him?

Thanks in advance.

Best regards,

Hello Henrique,

I received the e-mails and arranged a further meeting.

Thank you.

Best regards,

Matej I.

Hi @Matt !

Sorry for the delay.

I checked the device tree for Verdin AM62 on Verdin Development board and the SODIMM 38 (I2S_1_MCLK / GPMC0_WPn) it is by default configured as AUDIO_EXT_REFCLK1.

SODIMM 38 (pin GPMC0_WPn) configured as AUDIO_EXT_REFCLK: k3-am62-verdin.dtsi « ti « dts « boot « arm64 « arch - linux-toradex.git - Linux kernel for Apalis, Colibri and Verdin modules

pinctrl_i2s1_mclk used in nau8822_1a, which is enabled (inside main_i2c1, which is also enabled): k3-am62-verdin-dev.dtsi « ti « dts « boot « arm64 « arch - linux-toradex.git - Linux kernel for Apalis, Colibri and Verdin modules

Furthermore, I also tested the output of SODIMM 38 (I2S_1_MCLK) and I get a clock when I use aplay to play some audio file (reference: Audio (Linux) | Toradex Developer Center).

This is what I used for this test:

Hardware

  • Verdin AM62 Q 2GB WB IT V1.1A
  • Verdin Development Board V1.1A
    • SODIMM 38 is accessible from X3.15
  • Digilent Digital Discovery (to record the signal from SODIMM 38)

Software

I used the Reference Multimedia Image instead of the Reference Minimal Image.

root@verdin-am62-15133487:~# tdx-info

Software summary
------------------------------------------------------------
Bootloader:               U-Boot
Kernel version:           6.1.46-6.5.0+git.8e6a2ddd4fe6 #1 SMP PREEMPT Thu Dec 21 17:08:38 UTC 2023
Kernel command line:      root=PARTUUID=3ad362ac-02 ro rootwait console=tty1 console=ttyS2,115200 consoleblank=0 earlycon=ns16550a,mmio32,0x02800000
Distro name:              NAME="TDX Wayland with XWayland"
Distro version:           VERSION_ID=6.5.0-build.9
Distro variant:           -
Hostname:                 verdin-am62-15133487
------------------------------------------------------------

Hardware info
------------------------------------------------------------
HW model:                 Toradex Verdin AM62 WB on Verdin Development Board
Toradex version:          0076 V1.1A
Serial number:            15133487
Processor arch:           aarch64
------------------------------------------------------------

Here I also share the device tree information. As the pin is already configured as the clock output, I didn’t have to change a thing.

root@verdin-am62-15133487:~# tdx-info -dt

Device tree
------------------------------------------------------------
Device tree enabled:      -
Compatible string:        toradex,verdin-am62-wifi-devtoradex,verdin-am62-wifitoradex,verdin-am62ti,am625
Device trees available:
                          k3-am625-verdin-nonwifi-dahlia.dtb
                          k3-am625-verdin-nonwifi-dev.dtb
                          k3-am625-verdin-nonwifi-mallow.dtb
                          k3-am625-verdin-nonwifi-yavia.dtb
                          k3-am625-verdin-wifi-dahlia.dtb
                          k3-am625-verdin-wifi-dev.dtb
                          k3-am625-verdin-wifi-mallow.dtb
                          k3-am625-verdin-wifi-yavia.dtb
------------------------------------------------------------

Device tree overlays
------------------------------------------------------------
Overlays enabled:         fdt_overlays=verdin-am62_dsi-to-hdmi_overlay.dtbo verdin-am62_spidev_overlay.dtbo
Overlays available:
                          verdin-am62_dsi-to-hdmi_overlay.dtbo
                          verdin-am62_dsi-to-lvds_panel-cap-touch-10inch-lvds_overlay.dtbo
                          verdin-am62_mezzanine_panel-cap-touch-10inch-lvds_overlay.dtbo
                          verdin-am62_mezzanine_panel-lvds-dual-channel-1080p_overlay.dtbo
                          verdin-am62_nau8822-btl_overlay.dtbo
                          verdin-am62_ov5640_overlay.dtbo
                          verdin-am62_panel-cap-touch-10inch-dsi_overlay.dtbo
                          verdin-am62_panel-cap-touch-10inch-lvds_overlay.dtbo
                          verdin-am62_spidev_overlay.dtbo
------------------------------------------------------------

Let us know if this helps you.

Best regards,

Dear Henrique,

I tested the output of SODIMM 38 but received no signal. I thought that the signal was outputted automatically even without calling aplay function. Is that correct? Do you first need a signal from a sound card to start generating a clock signal on output? (such as calling aplay function with specified codec)

I cannot test your settings as I use AM62 on the Mallow V1.1A board and when I run “cat /proc/asound/cards”, it outputs: “— no soundcards —”, which means I cannot use aplay, amixer etc. Does that mean I cannot receive a clock signal as long as there is no external device connected?

Here is the sofware summary:

and binary of “main-system-audio-ext-reflock1-pins-default”, which seems to be correct:

Thank you.

Best

Matej I.

Hi @Matt,

What you write is kind of correct. You would need a driver for the codec so that the MCLK will be output, it will not just output anything. This is what the Linux drivers exect. This is why you unfortunately don’t see the clock.

Maybe you could use sound/soc/codecs/spdif_transmitter.c as kind of a dummy because it does not expect a device but acts as codec. Something like this might work (untested):

 {
	sound {
		compatible = "simple-audio-card";
		simple-audio-card,bitclock-master = <&codec_dai>;
		simple-audio-card,format = "i2s";
		simple-audio-card,frame-master = <&codec_dai>;
		simple-audio-card,name = "verdin-spdif";
		simple-audio-card,routing =
			"Line Out", "Playback";
		simple-audio-card,widgets =
			"Line Out", "Line Out";

		codec_dai: simple-audio-card,codec {
			clocks = <&audio_refclk1>;
			sound-dai = <&codec>;
		};

		simple-audio-card,cpu {
			sound-dai = <&mcasp0>;
		};
	};
}

codec: spdif-transmitter {
	compatible = "linux,spdif-dit";
};

Regards,
Stefan

Dear Henrique,

I have one more question. You tested that on Verdin dev board but my board is Mallow. Is the pin already configured in this scenario as well?

Thank you.

Matej I.

Hi @Matt !

We can compare the schematics of both carrier boards to check it. You can find their schematics in the pages below:

  • Verdin Development Board
  • Mallow Carrier Board:

From the schematics of Verdin Development Board V1.1, we have:

From the schematics of Mallow Carrier Board V1.1, we have:

So we can see that the hardware has no difference, since on Verdin Development Board I just removed one jumper so that the pin would not connect with the codec NAU88C22YG. Even the serial resistors have the same value :slight_smile:

Best regards,

Excellent, thank you.

Best regards

Matej I.

Hi @Matt !

You are welcome!

If this one is solved, please don’t forget to mark the most suitable question as the Solution :wink:

Have a nice day!