annotate doc/Audio-mode-config @ 786:b761029f9c03

simagent: spenh command implemented
author Mychaela Falconia <falcon@freecalypso.org>
date Sat, 13 Mar 2021 22:41:33 +0000
parents 0321cd08b19f
children 02d92d49c9f8
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
245
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 There exist a number of tunable settings in the Iota ABB (the chip that performs
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 A-to-D and D-to-A conversion for the voice path) and in the Calypso DSP which
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 in TI's firmware architecture are meant to be configured through the audio mode
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 facility of the RiViera Audio Service. The ABB settings grouped under the audio
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 mode are as follows:
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 * The selection of which analog interface pins the downlink audio should be
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 sent to: EARN&EARP (earpiece), AUXON&AUXOP (auxiliary) or HSO (headset).
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 * The selection of which analog interface pins the uplink audio should be taken
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 from: MICIN&MICIP (main microphone), AUXI (auxiliary input) or HSMICP
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 (headset microphone).
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 * The selection of AUXI input levels when this analog input is in use for the
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 voice uplink.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 * Analog gains for the uplink, the downlink and the analog sidetone from the
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18 uplink input to the downlink output.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20 * Selection of a special filter bypass mode for the voice downlink.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22 * The selection of MICBIAS (or HSMICBIAS) voltage between 2.0 V and 2.5 V.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24 The DSP voice path settings grouped under the audio mode are as follows:
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26 * The selection of the digital voice path as being between GSM and the ABB (the
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 default for analog voice interfaces), between GSM and MCSI (the external
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28 digital voice interface) or between MCSI and the ABB (non-GSM operation).
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 * FIR filter coefficients for the voice uplink and for the voice downlink.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32 * Enabling/disabling and configuration of the Acoustic Echo Cancellation (AEC)
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33 mechanism.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 The firmware paradigm for working with all of the above settings is as follows:
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 * In a lab environment, each of the listed settings can be independently tweaked
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38 and read back through ETM packets over the RVTMUX debug serial interface; the
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39 corresponding fc-tmsh commands (matching TI's original Windows-based TMSH)
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40 are auw for writing individual audio parameters and aur for reading them back.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 * In end-use operation, TI's intent as realized in the firmware design is that
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43 all of the listed audio settings will only be changed as a group, loaded from
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 audio mode configuration files in FFS.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46 Each audio mode configuration needs to be assigned a name between 1 and 9
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47 characters long, and for each named configuration there are two files in FFS:
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49 /aud/modename.cfg is the main configuration file
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50 /aud/modename.vol is the corresponding volume setting file
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52 This paradigm is a good fit for "dumbphone" handsets in which there usually
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53 will be several different voice audio configurations for classic handheld
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54 operation, for the hands-free loudspeaker mode, for operation with a wired
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55 headset, and if the phone uses a loudspeaker (as opposed to a piezo buzzer) to
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56 play ringtones and uses the Calypso DSP to generate those ringtone melodies,
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
57 there will also need to be an output-only audio configuration for ringing.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
58
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
59 How do the audio mode config files under /aud come into being? It appears that
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60 TI's original intent was that a configuration would be manually constructed on
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61 a test device via TMSH auw commands, saved in the FFS of that test device with
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
62 the aus command, then read out of that test device FFS in binary form and
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
63 reuploaded as an opaque blob to all devices on the production line. One can do
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
64 the same procedure with our fc-tmsh and fc-fsio which fully replicate the
261
0321cd08b19f doc/Audio-mode-config: typo fix
Mychaela Falconia <falcon@freecalypso.org>
parents: 247
diff changeset
65 relevant functionality of TI's original TMSH (to the best of our knowledge),
245
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
66 but in FreeCalypso we have an alternate way which fits better with our UNIX
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
67 philosophy: we have created our own ASCII text format for representing all of
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
68 the content in TI's /aud/*.cfg binary files and tiaud-* utilities for compiling
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
69 TI's binary cfg files from our ASCII source format, disassembling a *.cfg file
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
70 read out of FFS into the same ASCII format, and creating the required *.vol
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
71 companion files, which are also binary.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
72
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
73 A note about volume settings: the Iota ABB has two variable gain controls in
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
74 the voice downlink path: the main "volume" gain in rather coarse 6 dB steps
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
75 (the choices being 0 dB, -6 dB, -12 dB, -18 dB, -24 dB and mute) and a finer
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
76 "calibration" gain in 1 dB steps between -6 and +6 dB. It appears that TI's
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
77 intent was that only the coarse volume control in 6 dB steps is to be visible
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
78 to the user, with just 5 possible non-mute volume levels, and that the finer
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
79 gain control be set at the factory in the audio mode config files for each mode
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
80 as some form of calibration. Pirelli DP-L10 significantly deviates from this
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
81 model by providing 10 non-mute volume levels to the user with 2 dB or 3 dB steps
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
82 between them by changing both VOLCTL and VDLPG fields in the VBDCTRL register,
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
83 but at the present time we have no plans to make a similar drastic change in
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
84 FreeCalypso.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
85
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
86 Another noteworthy feature of the audio mode system with respect to volume
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
87 control is that there is a separate *.vol file that stores the current volume
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
88 setting for each mode. In a "dumbphone" handset firmware built according to
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
89 TI's paradigm, the /aud/*.cfg files will be written once on the factory
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
90 production line and only read afterward, but whenever the user turns the volume
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
91 up or down in the UI, the *.vol file _corresponding to the current mode_ will
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
92 be updated by the running fw. Thus the fw would maintain a separate notion of
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
93 the current volume for ringing, for the earpiece speaker, for the hands-free
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
94 loudspeaker and for the wired headset, something which Pirelli's fw very
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
95 notoriously fails to do.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
96
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
97 Default audio configuration
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
98 ===========================
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
99
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
100 The default audio config set in the Iota ABB registers and in the DSP when no
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
101 named audio mode config has been loaded with the audio_mode_load() API call
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
102 (accessible via AT@AUL or via fc-tmsh aul command) is as follows, in the syntax
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
103 which our tiaud-compile utility accepts as input and which our tiaud-decomp
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
104 utility emits as output:
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
105
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
106 voice-path 0
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
107 mic default {
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
108 gain 3
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
109 output-bias 0
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
110 fir 0 0x4000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
111 fir 8 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
112 fir 16 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
113 fir 24 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
114 }
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
115 speaker ear+aux {
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
116 gain 0
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
117 audio-filter 0
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
118 fir 0 0x4000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
119 fir 8 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
120 fir 16 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
121 fir 24 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000 0x0000
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
122 }
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
123 sidetone -5
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
124 aec 0 0 0 0 0
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
125
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
126 The meaning is as follows:
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
127
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
128 * voice-path is the DSP digital voice path setting, 0 means the standard
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
129 configuration with the voice channel going between GSM and the local analog
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
130 voice hardware attached to the ABB.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
131
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
132 * The default microphone input is used for the voice uplink (MICIN&MICIP pins),
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
133 whereas the voice downlink is presented on both EARN&EARP and AUXON&AUXOP
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
134 pins, i.e., both "ear" and "aux" VDL amplifiers are enabled.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
135
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
136 * The microphone gain is 3 dB, the fine gain adjustment in the voice downlink
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
137 path is 0 dB, and the sidetone gain is -5 dB.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
138
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
139 * output-bias 0 under mic means that the MICBIAS voltage is set to 2.0 V.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
140
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
141 * audio-filter 0 under speaker means that the VFBYP bit in the VBCTRL1 register
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
142 is NOT set, i.e., the normal configuration.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
143
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
144 * DSP FIR filters do nothing, as coefficient 0 is set to unity and all other
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
145 coefficients are set to zero.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
146
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
147 * The AEC mechanism in the DSP is disabled.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
148
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
149 Creating your own audio mode configurations
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
150 ===========================================
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
151
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
152 The input to our tiaud-compile utility can contain every setting shown in the
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
153 default case above, or any desired subset thereof. For any settings not given
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
154 in the input, the defaults from the above will be used, except that
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
155 tiaud-compile's current default for the speaker mode is just ear rather than
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
156 ear+aux. (It is a default which you should NOT depend on; set it explicitly if
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
157 it matters!) A few notes:
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
158
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
159 * For all settings given as numbers, the number given in the ASCII input is the
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
160 number that goes into TI's binary structure, without any transformation, even
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
161 in those cases where the result is counter-intuitive, such as "audio-filter 0"
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
162 meaning that the filter is *enabled*.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
163
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
164 * The 3 possible mode keywords for the mic mode are default, aux and headset,
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
165 corresponding to MICIN&MICIP, AUXI and HSMICP analog inputs, respectively.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
166
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
167 * The 5 possible mode keywords for the speaker mode are ear, aux, headset,
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
168 buzzer and ear+aux. The buzzer speaker mode exists only on TI's Nausica ABB
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
169 predating Iota, i.e., it won't work on any of the Calypso+Iota+Rita devices
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
170 built or supported by FreeCalypso, but our tiaud-compile and tiaud-decomp
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
171 utilities support it because it is nominally supported by TI's RiViera Audio
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
172 Service and its binary data structure for audio mode configuration.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
173
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
174 * When mic is set to aux, an additional mic setting called extra-gain becomes
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
175 available. If extra-gain is set to 0, the AUXI gain will be set to 28.2 dB,
247
b5b148ef63da doc/Audio-mode-config: fixed logic error in the description of extra-gain
Mychaela Falconia <falcon@freecalypso.org>
parents: 245
diff changeset
176 if extra-gain is set to 1, the AUXI gain will be set to 4.6 dB; all other
245
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
177 values will be considered invalid by the firmware.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
178
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
179 * Each of the two FIR filters in the DSP (one for uplink, one for downlink) has
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
180 a total of 31 coefficients, numbered 0 through 30, inclusive. In the ASCII
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
181 input to tiaud-compile you can put each coefficient on its own fir line, put
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
182 all 31 coefficients on the same line, or group them in any other way you like.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
183 The grouping used in the tiaud-decomp output has been chosen for line length
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
184 reasons.
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
185
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
186 * The numbers given on fir and aec lines are 16-bit values that go directly into
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
187 the DSP; the former are FIR coefficients and the latter are bit masks. They
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
188 can be given as either decimal or hexadecimal with 0x prefix in the ASCII
796c659b747c doc/Audio-mode-config written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
189 input to tiaud-compile.