NOTICE: The Processors Wiki will End-of-Life on January 15, 2021. It is recommended to download any files or other content you may need that are hosted on processors.wiki.ti.com. The site is now set to read only.
Sitara Linux Audio Introduction
Linux Software Developer's Guide | → | Linux Kernel | → | Audio | → | Introduction |
Overview[edit]
This section provides a high level overview of the hardware and software elements that are required for audio related functionality on Sitara processors.
System Overview
[edit]
Though various hardware and software configurations are used on Sitara EVMs, there are a common set of elements that must be properly set up so that audio is enabled in linux. They are as follows:
- An external audio capture or playback device (such as ADCs, DACs, audio codecs, or even network devices)
- A Sitara data interface (such McASP or USB) that can communicate with that external audio device
- The linux audio framework (ALSA)
- An ALSA compatible driver for the selected external audio device
Multimedia frameworks, such as GStreamer, can sit on top of the ALSA driver and allow for more advanced features, but are not required for basic usage.
Hardware Components
[edit]
The most common hardware component on Sitara processors that is used to enable audio is the McASP, which provides an I2S interface that can be connected to external audio device, such as the AIC3106 codec that is used on many Sitara EVMs.
USB audio dongles are another common way of providing hardware audio capability; linux by default provides an extensive amount of driver support for USB audio devices, which in many cases may make them easier to integrate into a system than an I2S solution.
Network audio sources are yet another way for linux to transmit and receive audio data. These are possible through a number of hardware elements, such as Ethernet, USB Wifi Dongles, and MDIO based Wifi chips.
Software Components
[edit]
Regardless of the hardware being used, linux uses one standard architecture for all audio support: ALSA. ALSA consists of kernel drivers and a user-space API that allows for the creation of audio applications.
Any audio hardware device that is connected linux must have an ALSA compatible driver in order for it to be accessible; for instance, AIC3x codecs present on Sitara EVMs have such an ALSA based driver. For USB audio dongles, configuring the ALSA driver is often quite simple; when plugged into a USB port, linux will automatically detect the device and configure it as an ALSA device.
The linux community has produced a host of powerful software libraries, frameworks, and applications that greatly expand the audio possibilities of linux. Two of these that are included within the Sitara SDK filesystem are GStreamer and PulseAudio. GStreamer is a flexible multimedia framework that can be used to prototype audio playback and capture for various usecases, and PulseAudio is a sound server that allows for mixing, network audio, and a number of others.
Acronyms & Definitions[edit]
Acronym | Definition |
---|---|
ALSA | Advanced Linux Sound Architecture |
ALSA SoC | ALSA System on Chip |
DMA | Direct Memory Access |
I2C | Inter-Integrated Circuit |
McASP | Multi-channel Audio Serial Port |
PCM | Pulse Code Modulation |
TDM | Time Division Multiplexing |
OSS | Open Sound System |
I2S | Inter-IC Sound |