sai_edma_tdm_record_playback#
Overview#
The sai_edma_tdm_record_playback example shows how to use sai edma driver receive and playback TDM format data:
In this example, one sai instance reocrd and playbacks the audio data in TDM format.
Supported Boards#
MIMXRT1060-EVKB
Hardware requirements
Micro USB cable
EVKB-MIMXRT1060 board
Personal Computer
Headphone or speaker
CS42448 audio board
Line in line
Board settings
Insert the CS42448 audio board into J23 Uninstall J41
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Insert the headphones into the headphone jack of CS42448 audio board line output.
Connect the audio input source to the CS42448 audio board by line in line.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
Note: The Stereo input 1 will playback through Line 1&2 output. The Stereo input 2 will playback through Line 3&4 output. The MIC input 1&2 will playback through Line 5&6 output.
SAI TDM record playback example started!
Codec Init Done.
MIMXRT1170-EVKB
Hardware requirements
Micro USB cable
EVKB-MIMXRT1170 board
Personal Computer
Headphone or speaker
CS42448 audio board
Line in line
Board settings
1.Please mount resistors below, R2008,R2022,R2011,R2021,R2009,R2010,R2012,R2016,R1998,R2013,R2014, R2018,R2017,R2000
2.Remove the resistors below: R2001,R2002,R2003,R2004,R2005,R2006 and R2007.
3.Insert AUDIO board into J76.
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Insert the CS42448 audio board into J76.
Insert the headphones into the headphone jack of CS42448 audio board line output.
Connect the audio input source to the CS42448 audio board by line in line.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
Note: The Stereo input 1 will playback through Line 1&2 output. The Stereo input 2 will playback through Line 3&4 output. The MIC input 1&2 will playback through Line 5&6 output.
SAI TDM record playback example started!
Codec Init Done.
Known issue: project: sai_edma_tdm_record_playback@cm4 compilers: armgcc target: sdram_debug, sdram_release. issue: no sound output.
MIMXRT1060-EVKC
Hardware requirements
Micro USB cable
MIMXRT1060-EVKC board
Personal Computer
Headphone or speaker
CS42448 audio board
Line in line
Board settings
Insert AUDIO board into J23
If use MIC as input, please remove J99
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Insert the CS42448 audio board into J23.
Insert the headphones into the headphone jack of CS42448 audio board line output.
Connect the audio input source to the CS42448 audio board by line in line.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
Note: The Stereo input 1 will playback through Line 1&2 output. The Stereo input 2 will playback through Line 3&4 output. The MIC input 1&2 will playback through Line 5&6 output.
SAI TDM record playback example started!
Codec Init Done.
MIMXRT1040-EVK
Hardware requirements
Mini/micro USB cable
EVKB-MIMXRT1040 board
CS42448 audio board
Personal Computer
Headphone(OMTP standard)
RCA to 3.5mm line
Headphone or speaker
Board settings
1.Please mount resistor R480.
2.Please remove the jumper J41.
3.Insert AUDIO board into J23.
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
Note: 1.The Stereo input 1 will playback through Line 1&2 output. 2.The Stereo input 2 will playback through Line 3&4 output. 3.The MIC input 1&2 will playback through Line 5&6 output.
SAI TDM record playback example started!
Codec Init Done.
MIMXRT1180-EVK
Hardware requirements
Micro USB cable
MIMXRT1180-EVK board
Personal Computer
Headphone or speaker
CS42448 audio board
Line in line
Power adapter
Board settings
1.Remove Jumper J99 and remove R1084 resistor. (If use MCU-LINK JLINK firmware, please also remove R82 resistor)
2.Insert AUDIO board into J47.
Switch Jumper J1 to 1-2, insert power adapter on J2 and power on the board by SW1. (Since the power consumption exceeds the USB power supply capacity when using CS42448 audio board, an external power supply must be used)
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Insert the CS42448 audio board into J47.
Insert the headphones into the headphone jack of CS42448 audio board line output.
Connect the audio input source to the CS42448 audio board by line in line.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
Note: The Stereo input 1 will playback through Line 1&2 output. The Stereo input 2 will playback through Line 3&4 output. The MIC input 1&2 will playback through Line 5&6 output.
SAI TDM record playback example started!
Codec Init Done.