summaryrefslogtreecommitdiff
path: root/firmware
diff options
context:
space:
mode:
authorSolomon Peachy <pizza@shaftnet.org>2020-10-25 00:32:36 -0400
committerSolomon Peachy <pizza@shaftnet.org>2020-10-25 00:42:41 -0400
commit4afd1f9aa6a15f34e48b6af8d0152bb45f672cf1 (patch)
treec43435f1b78d0315f1ac2d97f58dffc02bf18f3f /firmware
parente7a492ef55df87bd7873a176a76a9a524da3f2ce (diff)
hosted: Document HW capabilities of audio drivers
One surprise: X3ii is capable of 384KHz playback Change-Id: I0cc88637c81a21d54979e82b2941fe14de933d4d
Diffstat (limited to 'firmware')
-rw-r--r--firmware/drivers/audio/erosqlinux_codec.c26
-rw-r--r--firmware/drivers/audio/xduoolinux_codec.c42
2 files changed, 68 insertions, 0 deletions
diff --git a/firmware/drivers/audio/erosqlinux_codec.c b/firmware/drivers/audio/erosqlinux_codec.c
index 268da54280..3b7155faef 100644
--- a/firmware/drivers/audio/erosqlinux_codec.c
+++ b/firmware/drivers/audio/erosqlinux_codec.c
@@ -37,6 +37,32 @@
#include "logf.h"
+/*
+ PCM device hw:0,0
+
+ ACCESS: MMAP_INTERLEAVED RW_INTERLEAVED
+ FORMAT: S16_LE S24_LE
+ SUBFORMAT: STD
+ SAMPLE_BITS: [16 32]
+ FRAME_BITS: [16 64]
+ CHANNELS: [1 2]
+ RATE: [8000 192000]
+ PERIOD_TIME: (2666 8192000]
+ PERIOD_SIZE: [512 65536]
+ PERIOD_BYTES: [4096 131072]
+ PERIODS: [4 128]
+ BUFFER_TIME: (10666 32768000]
+ BUFFER_SIZE: [2048 262144]
+ BUFFER_BYTES: [4096 524288]
+ TICK_TIME: ALL
+
+ Mixer controls:
+
+ numid=1,iface=MIXER,name='Output Port Switch'
+ ; type=INTEGER,access=rw------,values=1,min=0,max=5,step=0
+ : values=4
+*/
+
static int fd_hw = -1;
static long int vol_l_hw = 255;
diff --git a/firmware/drivers/audio/xduoolinux_codec.c b/firmware/drivers/audio/xduoolinux_codec.c
index 5b83f0fa8c..5452a0f5c3 100644
--- a/firmware/drivers/audio/xduoolinux_codec.c
+++ b/firmware/drivers/audio/xduoolinux_codec.c
@@ -36,6 +36,48 @@
#include "logf.h"
+/*
+
+X3ii:
+
+ PCM device hw:0,0
+
+ ACCESS: MMAP_INTERLEAVED RW_INTERLEAVED
+ FORMAT: S16_LE S24_LE
+ SUBFORMAT: STD
+ SAMPLE_BITS: [16 32]
+ FRAME_BITS: [16 64]
+ CHANNELS: [1 2]
+ RATE: [8000 384000]
+ PERIOD_TIME: (1333 16384000]
+ PERIOD_SIZE: [512 131072]
+ PERIOD_BYTES: [4096 262144]
+ PERIODS: [4 256]
+ BUFFER_TIME: (5333 65536000]
+ BUFFER_SIZE: [2048 524288]
+ BUFFER_BYTES: [4096 1048576]
+ TICK_TIME: ALL
+
+ Mixer controls:
+
+ numid=1,iface=MIXER,name='Left Playback Volume'
+ ; type=INTEGER,access=rw------,values=1,min=0,max=255,step=0
+ : values=0
+ numid=2,iface=MIXER,name='Right Playback Volume'
+ ; type=INTEGER,access=rw------,values=1,min=0,max=255,step=0
+ : values=0
+ numid=3,iface=MIXER,name='AK4490 Digital Filter'
+ ; type=INTEGER,access=rw------,values=1,min=0,max=4,step=0
+ : values=0
+ numid=4,iface=MIXER,name='AK4490 Soft Mute'
+ ; type=BOOLEAN,access=rw------,values=1
+ : values=off
+ numid=5,iface=MIXER,name='Output Port Switch'
+ ; type=INTEGER,access=rw------,values=1,min=0,max=5,step=0
+ : values=0
+
+*/
+
static int fd_hw = -1;
static long int vol_l_hw = 255;