Khadas Docs

Amazing Khadas, always amazes you!

User Tools

Site Tools


products:sbc:edge-2l:applications:es8316

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
products:sbc:edge-2l:applications:es8316 [2025/11/25 05:14]
gray created
products:sbc:edge-2l:applications:es8316 [2026/05/11 01:55] (current)
nick ↷ Page moved from local:users:gray:products:sbc:edge-2l:applications:es8316 to products:sbc:edge-2l:applications:es8316
Line 1: Line 1:
-====== Edge-2L and ES8316 Audio Usage ======+====== Edge-2L and ES8316 audio usage ======
  
 <WRAP important > <WRAP important >
-ES8316 codec usage require [[https://www.khadas.com/product-page/edge-2l-io-module|Edge-2L IO extension board]].+Using the ES8316 audio codec requires the [[https://www.khadas.com/product-page/edge-2l-io-module|Edge-2L IO board]]
 </WRAP> </WRAP>
  
  
-===== Alsa audio device HW name =====+===== Alsa audio device hardware name =====
  
-Access to **ES8316** codec will be available by ''hw:CARD=rockchipes8316c'' alsa audio device HW name, for example: ''aplay -D **hw:CARD=rockchipes8316c** ... ''+The ES8316 codec is accessible via the ALSA hardware name ''hw:CARD=rockchipes8316c''. Use this name in audio commands, for example: ''aplay -D **hw:CARD=rockchipes8316c** ...''.
  
 +You can verify the hardware name with the following commands:
 ```shell print ES8316 hw name  ```shell print ES8316 hw name 
-~# aplay -L | grep rockchipes8316c -m1+aplay -L | grep rockchipes8316c -m1
 hw:CARD=rockchipes8316c,DEV=0 hw:CARD=rockchipes8316c,DEV=0
  
-~# arecord -L | grep rockchipes8316c -m1+arecord -L | grep rockchipes8316c -m1
 hw:CARD=rockchipes8316c,DEV=0 hw:CARD=rockchipes8316c,DEV=0
 ``` ```
  
-===== Alsa audio device HW index =====+===== Alsa audio device hardware index =====
  
 +You can also identify the ES8316 by its card index. List the available audio devices:
 ```shell print ES8316 hw index ```shell print ES8316 hw index
 ~# arecord -l | grep es8316-codec -A2 ~# arecord -l | grep es8316-codec -A2
Line 33: Line 35:
 ``` ```
  
-The sound **card 3** is the ES8316 device and audio device HW index is ''3''.+In this example, the ES8316 is card 3, so its hardware index is ''3''.
  
-===== Record from ES8316 =====+===== Record audio using ES8316 =====
  
 +Record a 20-second WAV file using the hardware name:
 ``` ```
 arecord -D hw:CARD=rockchipes8316c -f cd -d 20 record.wav arecord -D hw:CARD=rockchipes8316c -f cd -d 20 record.wav
 ``` ```
  
-or by audio device HW index (will be ''3'' for this example)+Or, using the hardware index (e.g., 3):
  
 ```shell ```shell
Line 48: Line 51:
  
 <WRAP info > <WRAP info >
-The headphone mic has the higher priority than the AMIC, which means if you connect the headphone then will record from the headphone mic, otherwise record from the AMIC.+**Microphone Priority:** The headphone microphone has higher priority than the onboard analog microphone (AMIC). If a headphone with a microphone is connectedrecording will use the headphone mic. Otherwiseit will use the onboard AMIC. 
 </WRAP> </WRAP>
  
  
-===== Playback from ES8316 =====+===== Playback audio using ES8316 =====
  
 +Play a WAV file using the hardware name:
 ```shell ```shell
 aplay -D hw:CARD=rockchipes8316c xxx.wav aplay -D hw:CARD=rockchipes8316c xxx.wav
 ``` ```
  
-or by audio device HW index (will be ''3'' for this example+Or, using the hardware index (e.g., 3):
  
 ```shell ```shell
Line 65: Line 69:
  
 <WRAP info > <WRAP info >
-The headphone has the higher priority than the speaker, which means if you connect the headphone then will play from the headphoneotherwise play from the speaker.+**Output Priority:** The headphone output has higher priority than the onboard speaker. If headphones are connectedaudio will play through them. Otherwiseaudio will play through the speaker.
 </WRAP> </WRAP>
  
  
Last modified: 2025/11/25 05:14 by gray