WM8959
Pre-Production
MICBIAS CURRENT AND ACCESSORY DETECT
A MICBIAS current detect function is provided for accessory detection. When a microphone current
is detected (e.g. when a headset is inserted), an interrupt event can be generated and the
microphone status read back via the control interface.
The MICBIAS current detect threshold is programmable. A short-circuit current detection is also
available, with a programmable threshold. These functions are enabled by register bit MCD; the
thresholds are programmable via register fields MCDTHR and MCDSCTR as shown in Table 41.
The polarity of the current detect GPIO signals may be controlled by register bits MICDET_POL and
MICSHRT_POL. Note that these polarity inversion bits apply to the Interrupt register behaviour only;
they do not affect the direct GPIO output of the Current Detect functions. The respective interrupt
events may be masked or enabled by register bits MICDET_IRQ_ENA and MICSHRT_IRQ_ENA.
The MICBIAS current threshold status bits contained in the IRQ Register (R18) may be read at any
time or else in response to an Interrupt event. See Table 47 for more details of the Interrupt function.
If direct output of the MICBIAS current detect function is required to the external pins of the WM8959,
the following register settings are required:
•
•
•
•
•
•
•
GPIO1_ENA = 1 (only required if using GPIO1)
AIF_SEL = 0 (only required if using GPIO3, GPIO4 or GPIO5)
AIF_TRIS = 0
GPIOn_SEL = 1000 for the selected GPIO MICBIAS Current Detect output pin
GPIOn_SEL = 1001 for the selected GPIO MICBIAS Short Circuit Detect output pin
GPIOn_PU = 0 for the selected GPIO MICBIAS output pin or pins
GPIOn_PD = 0 for the selected GPIO MICBIAS output pin or pins
The register fields used to configure the MICBIAS Current Detect function are described in Table 41.
REGISTER
ADDRESS
BIT
LABEL
DEFAULT
DESCRIPTION
R58 (3Ah)
7:6
MCDSCTH
00b
MICBIAS Short Circuit Detect Threshold
00 = 600uA
[1:0]
01 = 1200uA
10 = 1800uA
11 = 2400uA
These values are for AVDD=3.3V and
scale proportionally with AVDD.
5:3
MCDTHR
[2:0]
000b
MICBIAS Current Detect Threshold
000 = 200uA
001 = 350uA
010 = 500uA
011 = 650uA
100 = 800uA
101 = 950uA
110 = 1100uA
111 = 1250uA
These values are for AVDD=3.3V and
scale proportionally with AVDD.
2
MCD
0b
0b
MICBIAS Current and Short Circuit
Detect Enable
0 = disabled
1 = enabled
R23 (17h)
10
MICSHRT_POL
(rw)
MICBIAS short circuit detect polarity
0 = Non-inverted
1 = Inverted
PP, May 2008, Rev 3.1
78
w