English
Language : 

HT45F3420 Datasheet, PDF (88/141 Pages) Holtek Semiconductor Inc – Personal Care Flash MCU
HT45F3420/HT45F3430
Personal Care Flash MCU
The reference voltage supply to the A/D Converter can be supplied from either the internal ADC
power or from an external reference sources supplied on pin VREF or VBG voltage. The desired
selection is made using the SAVRS1~ SAVRS0 bits. As the VREF pin is pin-shared with other
functions, when the VREF pin is selected as the reference voltage supply pin, the VREF pin-shared
function control bits should be properly configured to disable other pin functions. When VR is
selected by ADC reference voltage, the PGA needs to be enabled by setting the ADPGAEN bit to 1.
A/D Converter Input Signals
All of the A/D analog input pins are pin-shared with the I/O pins on Port A as well as other
functions. The corredponding selection bits for each I/O pin in the PAS0 and PAS1 registers,
determine whether the input pins are setup as A/D converter analog inputs or whether they have
other functions. If the pin-shared function control bits configure its corresponding pin as an A/
D analog channel input, the pin will be setup to be an A/D converter external channel input and
the original pin functions disabled. In this way, pins can be changed under program control to
change their function between A/D inputs and other functions. All pull-high resistors, which are
setup through register programming, will be automatically disconnected if the pins are setup as A/
D inputs. Note that it is not necessary to first setup the A/D pin as an input in the PAC port control
register to enable the A/D input as when the pin-shared function control bits enable an A/D input,
the status of the port control register will be overridden.
There are several internal analog signals, the Bandgap reference voltage VBG, VDD, PGA output
VR, OCP output OCPAO or the integrated voltage diving circuit generating VBAT_ADIN and
OVP_ADIN signals, which can be connected to the A/D converter as the analog input signal by
configuring the SAINS3~SAINS0 bits. If the SAINS3~SAINS0 bits are set to "0000", the external
analog channel input is selected to be converted and the SACS3~SACS0 bits can determine
which actual external channel is selected to be converted. If the SAINS3~SAINS0 bits are set to
"0001~0011", the VDD voltage is selected to be converted. If the SAINS3~SAINS0 bits are set to
"0101~0111", the PGA output voltage is selected to be converted.
The A/D converter has its own reference voltage pin, VREF, however the reference voltage can
also be supplied from the power supply pin, a choice which is made through the SAVRS[1:0] in the
SADC2 register. The analog input values must not be allowed to exceed the value of the selected
ADC reference voltage. The A/D converter also has a VREFI pin which is one of PGA inputs for
ADC reference. To select this PGA input signal, the PGAIS bit must be cleared to zero and the
revelent pin-shared control bits should be properly configured.
Note that when the programs select external signal (AN0~AN3 for HT45F3420, AN0~AN7 for
HT45F3430) and internal signal (VDD, VDD/2, VDD/4, VR, VR/2, VR/4, OVPAO, VBAT_ADIN or
OVP_ADIN) as an A/D Converter input signal simultaneously, then the hardware will only choose
the internal signal as an ADC input. In addition, if the program selects an external reference voltage
VREF and the internal reference voltage VDD or VR as the ADC reference voltage, then the hardware
will only choose the internal reference voltage as the ADC reference voltage input. The same
hardware control method can be applied to the PGA input selection. If the application program
selects the external voltage, VREFI, and an internal voltage VBG as PGA input simultaneously, then the
hardware will only choose the internal voltage VBG as the PGA input.
Rev. 1.31
88
April 11, 2017