Philips Semiconductors
Audio In
File: ain.fm5, modified 7/24/99
PRELIMINARY INFORMATION
8-3
mined by Audio Out (Audio In SER_MASTER=0,
AI_SCK and AI_WS externally wired to the correspond-
ing Audio Out pins). In such systems, independent soft-
ware control over A/D and D/A sampling rate is not pos-
sible, but component count is minimized.
8.6
SERIAL DATA FRAMING
The Audio In unit can accept data in a wide variety of se-
rial data framing conventions.
Figure 8-2 illustrates the
notion
of
a
serial
frame.
If
POLARITY=1
and
CLOCK_EDGE=0, a frame is defined with respect to the
positive transition of the AI_WS signal, as observed by a
positive clock transition on AI_SCK. Each data bit sam-
pled on positive AI_SCK transitions has a specific bit po-
sition: the data bit sampled on the clock edge after the
clock edge on which the AI_WS transition is seen has bit
position 0. Each subsequent clock edge defines a new
bit position. As defined in
Table 8-4, other combinations
of POLARITY and CLOCK_EDGE can be used to define
a variety of serial frame bitposition definitions.
The capturing of samples is governed by FRAMEMODE.
If FRAMEMODE=00, every serial frame results in one
sample from the serial-parallel converter. A sample is de-
fined as a left/right pair in stereo modes or a single left
channel value in mono modes. If FRAMEMODE=1y, the
serial frame data bit in bit position VALIDPOS is exam-
ined. If it has value ‘y’, a sample is taken from the data
stream (the valid bit is allowed to precede or follow the
left or right channel data provided it is in the same serial
frame as the data).
The left and right sample data can be in a LSB-first or
MSB-first form, at an arbitrary bit position, and with an ar-
bitrary length.
In MSB-first mode, the serial-to-parallel converter as-
signs the value of the bit at LEFTPOS to LEFT[15]. Sub-
Table 8-3. Audio In MMIO Clock & Interface Control
Bits
Field Name
Description
SER_MASTER
0
(RESET default), the A/D converter
is the timing master over the serial inter-
face. AI_SCK and AI_WS are set to be
input.
1
TM1100 is the timing master over the
Audio In serial interface. The AI_SCK and
AI_WS pins are set to be outputs.
FREQUENCY
Sets the clock frequency emitted by the
AI_OSCLK output. RESET default 0.
SCKDIV
Sets the divider used to derive AI_SCK
from AI_OSCLK. Set to 0..255, for divi-
sion by 1..256. RESET default 0.
WSDIV
Sets the divider used to derive AI_WS
from AI_SCK. Set to 0..511 for a serial
frame length of 1..512. RESET default 0.
7
6
5
4
3
2
1
0
31
30
29
28
27
26
25
24
23
22
21
20
19
18
17
16
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
AI_SCK
AI_WS
framen
0
AI_SD
framen+1
Figure 8-2. Audio In serial frame and bit position definition (POLARITY=1, CLOCK_EDGE=0).
Table 8-4. Audio In MMIO Serial Framing Control
Fields
Field Name
Description
POLARITY
0
serial frame starts on AI_WS negedge
(RESET default)
1
serial frame starts on AI_WS posedge
FRAMEMODE
00
accept a sample every serial frame
(RESET default)
01
unused, reserved
10
accept sample if valid bit = 0
11
accept sample if valid bit = 1
VALIDPOS
Denes the bit position within a serial frame
where the valid bit is found.
Default 0.
LEFTPOS
Denes the bit position within a serial frame
where the rst data bit of the left channel is
found.
Default 0.
RIGHTPOS
Denes the bit position within a serial frame
where the rst data bit of the right channel
is found.
Default 0.
DATAMODE
0
MSB rst (RESET default)
1
LSB rst
SSPOS
Start/Stop bit position. Default 0.
If DATAMODE=MSB rst, SSPOS deter-
mines the bit index (0..15) in the parallel
word of the last data bit. Bits 15 (MSB) up
to/including SSPOS are taken in order from
the serial frame data. All other bits are set
to zero.
If DATAMODE=LSB rst, SSPOS deter-
mines the bit index (0..15) in the parallel
word of the rst data bit. Bits SSPOS up to/
including 15 are taken in order from the
serial frame data. All other bits are set to
zero.
CLOCK_EDGE
if 0 (RESET default) the AI_SD and AI_WS
pins are sampled on positive edges of the
AI_SCK pin. If SER_MASTER =1, AI_WS is
asserted on negative edges of AI_SCK.
if 1, AI_SD and AI_WS are sampled on neg-
ative edges of AI_SCK. As output, AI_WS
is asserted on positive edges of AI_SCK.