
VS1063a Datasheet 11 OPERATION
If SCI_AICTRL3 bit 15 is set at startup, codec mode is initialized. If MP3 and Ogg Vorbis
formats are specified, the configuration bit is ignored and codec mode is not available. In
codec mode the encoded data is provided through HDAT0 and HDAT1, and data to be de-
coded is expected through the serial data interface (SDI). In codec mode, and with certain
restrictions, it is also possible to activate bit 14, AEC (Ecoustic Echo Cancellation). For de-
tails on how to use AEC, see VS1063a Application Note: AEC with VS1063a, available at
http://www.vlsi.fi/en/support/applicationnotes.html .
If SCI_AICTRL3 bit 13 is set at encode/codec startup, UART transmission of data is initialized
with parameters taken from
parametric_x.i.encoding
(see Chapter 11.10.9, Parametric: En-
coding, for details). If you want to use UART transmission, first initialize the required fields of
the
parametric_x.i.encoding
structure, then set the SCI_AICTRL3 UART TX enable bit, and
only after that start the encoding/codec mode using SCI_MODE register. When in UART mode,
do not read data through SCI_HDAT0 and SCI_HDAT1!
SCI_AICTRL3 bits 4 to 7 select the encoding format. 0 = IMA ADPCM, 1 = PCM, 2 = G.711
µ-law, 3 = G.711 A-law, 4 = G.722 ADPCM, 5 = Ogg Vorbis, 6 = MP3.
Note: If MP3 encoding is attempted with VS1163a or VS8063a, Ogg Vorbis will be encoded.
SCI_AICTRL3 bits 0 to 2 select the ADC mode and implicitly the number of channels. 0 = joint
stereo (common AGC), 1 = dual channel (separate AGC), 2 = left channel, 3 = right channel,
4 = mono downmix.
SCI_WRAMADDR sets the quality / bit rate selection for Ogg Vorbis and MP3 encoding. For
WAV formats this setting is not used. Use value 0xe080 for constant bitrate of 128 kbps. Note
that WRAMADDR is read at encoder startup, so modifying it later does not change the settings.
Bits Description
15:14 Bitrate mode, 0 = Quality Mode, 1 = VBR, 2 = ABR, 3 = CBR
13:12 Bitrate multiplier, 0 = 10, 1 = 100, 2 = 1000, 3 = 10000
11 Encoder-specific, Ogg Vorbis: 1=use parametric_x.i.encoding.serialNumber
10 Encoder-specific, Ogg Vorbis: 1=limited frame length
mp3: 1 = do not use bit-reservoir
9 Used internally, set to 0.
8:0 Bitrate base 0 to 511 (or quality 0 to 9 if Quality Mode selected).
The
bitrate base
and
bitrate multipler
define a target bitrate value. For example 2 in
multiplier and 128 in base means 128 kbit/s. The
bitrate mode
selects how the
bitrate
and
bitrate multiplier
fields are interpreted. In variable bitrate (VBR) mode the bitrate and
bitrate multiplier fields sets a very relaxed average bitrate. Currently the average bitrate mode
(ABR) equals VBR mode in both encoders. In Quality Mode
bitrate multiplier
is ignored
and the
bitrate base
field value sets encoding quality from 0 to 9.
SCI_WRAMADDR bit 10 is encoder-specific. When set with the MP3 encoder, the bit reservoir
will not be used. When set with Ogg Vorbis encoder, the bit requests a smaller output delay.
SCI_WRAMADDR bit 11 is encoder-specific. When set with Ogg Vorbis encoder, the stream
serial number is fetched from
parametric_x.i.encoding.serialNumber
.
Note: When recording,
parametric_x.i.encoding.channelMax
contains the maximum abso-
lute value encountered in the corresponding channel since the last clear of the variable. In
mono modes only
channelMax[0]
is updated.
Version: 1.31, 2017-10-06 60