Running Adafruit I2S 3W Stereo Speaker Bonnet with the Nvidia Nx

I am trying to run the Adafruit I2S 3W Stereo Speaker Bonnet (with 3W 4ohm stereo speakers connected) with the Nvidia Nx using the I2S0 interface that is exposed on the 40 pin connector:
Currently, I have the following pins connected to the Adafruit board:
2- 5V
4- 5V
6- GND
12- I2S0_SCLK (Connected to pin 12 on the Adafruit board)
14- GND
35- I2S0_LRCK (Connected to pin 35 on the Adafruit board)
40- I2S_SDOUT (Connected to pin 40 on the Adafruit board)

Is there any command that I need to run to enable this interface? Do I need to modify the device tree? I tried playing sounds but it does not seem to be working. This is my first time using an I2S interface. It actually looks like the Adafruit board plugs right into the 40pin connector on the NX which is pretty convenient. The sound settings give me the option of playing sound through the “HDMI / Display Port 2” and the “Analog Output”, but neither one actually plays any sound when selecting the Test Sound option.
Thanks for your help!


By default the I2S pins are not enabled, but you can enable them by running the following commands …

$ sudo /opt/nvidia/jetson-io/ -o dtb i2s5
$ sudo reboot

Then you should be able to try speaker-test as follows (assuming it supports 16-bit samples @ 48kHz) …

$ speaker-test -D hw:jetsonxaviernxa,0 -c 2 -r 48000 -F S16_LE -t sine -f 500

For more details on jetson-io see …

For more details on Jetson audio see …


Great. That worked. Thank you

How would I go about enabling the AUD_MCLK (GPIO09) and using it with I2S0? I needed more power and started using TAS5760xxEVM, which requires MCLK. MCLK should be synchronized and has to be 128fs, 192fs, 256fs, 384fs or 512*fs. fs is 48kHz(MCLK ~512 x fs = 512 x 48kHz=24.576MHz). Thank you!


To enable the pin you just need to …

$ sudo /opt/nvidia/jetson-io/ -o dtb i2s5 aud_mclk
$ sudo reboot

By default the AUD_MCLK operates at 256fs. The ratio can be configured in device-tree via the ‘mclk-fs’ property as described here.


That worked. Thanks jonathanh.