English
Language : 

WM8352 Datasheet, PDF (174/336 Pages) Wolfson Microelectronics plc – Wolfson AudioPlus™ Stereo CODEC with Power Management
WM8352
Production Data
19.4 AUXADC READBACK
Measured data from the AUXADC can be accessed by reading registers R152 through to R159, as
defined in Table 117. This data may be read at any time, or may be read in response to the WM8352
indicating that new data is available.
The WM8352 indicates that new AUXADC data is available by setting the AUX_DATARDY_EINT
interrupt flag as described in Section 19.7. This is one of five second-level interrupts which triggers a
first-level System Interrupt, AUXADC_INT (see Section 24). This interrupt can be masked by setting
the mask bit as described in Table 120. The AUX_DATARDY_EINT interrupt is set high when new
data is available. It is reset when the associated interrupt register R26 is read.
The WM8352 can also indicate that new AUXADC data is available via a GPIO pin configured as
ADA (Aux Data Available). This flag is set high when new data is available. It is reset when the
associated data has been read from the readback registers R152 through to R159. See Section 20
for details of how to configure a GPIO pin as ADA.
To avoid losing data that has not yet been read, the WM8352 can inhibit overwriting the
measurement registers with new data until the previous data has been read. When the
AUXADC_WAIT bit is set, then AUXADC measurements are prevented from being overwritten until
they have been read. Any Poll, Continuous or Mask-triggered AUXADC measurement will be ignored
if the AUXADC_WAIT feature prevents the measurement from being overwritten.
Always specify the address of the starting register. Single data read from last register is not
supported.
Reading from registers R152 to R159 returns a 12-bit code which represents the most recent
AUXADC measurement on the associated channel. This code can be equated to the actual voltage
(or temperature) according to the following equations:
To calculate the voltage for external measurements on the AUX input pins use the following formula:
AUXn = (Output Code / 4095) x Reference Voltage x AUX Input Scale
To calculate the voltage for internal AUXADC measurements on USB, LINE and Battery:
USB, LINE & BATT = (Output Code / 4095) x VRTC x 2
To calculate the temperature (in degrees Celsius) from AUXADC measurements on TEMP:
Temperature = 460.32 - ((Output Code / 4095) x VRTC x 614.6)
where-
Output Code = the relevant AUXADC_DATA field, decoded as an unsigned integer
Reference Voltage = VRTC voltage or VREF voltage, depending on AUXADC_REFn
AUX Input Scale = 1, 2 or 4, depending on AUXADC_SCALEn [1:0]
In a typical application, the AUX1 input is the battery pack temperature sensing (NTC) input. The
voltage at this input may be used as an indicator of the battery pack temperature.
The NTC input should be measured relative to the VRTC voltage. The hot temperature threshold
(CHG_BATT_HOT_EINT) corresponds to 0.33 x VRTC. This equates to approximately +45°C. The
cold temperature threshold (CHG_BATT_COLD_EINT) corresponds to 0.74 x VRTC. This equates to
approximately 0°C.
w
PD, February 2011, Rev 4.4
174