English
Language : 

HT45F3630 Datasheet, PDF (77/137 Pages) Holtek Semiconductor Inc – Power Tool Controller 8-Bit Flash MCU
HT45F3630
Power Tool Controller 8-Bit Flash MCU
A/D Converter Reference Voltage
The reference voltage supply to the A/D converter can be supplied from the positive power supply
pin, AVDD, or from an external reference source supplied on pin VREF. The desired selection
is made using the SAVRS1 and SAVRS0 bits. When the SAVRS bit field is set to “01”, the A/D
converter reference voltage will come from the AVDD pin. Otherwise, if the SAVRS bit field is
set to any other value except “01”, the A/D converter reference voltage will come from the VREF
pin. As the A/D converter and OCP D/A converter external reference voltage come from the same
VREF pin, when the VREF pin is selected as the A/D converter reference voltage pin, the OCP
D/A converter reference voltage selection bit OCPVRS should be also properly configured except
the pin-shared function control bits to avoid functional abnormity. However, if the internal A/D
converter power is selected as the reference voltage, the VREF pin must not be configured as the
reference voltage input function for the A/D converter to avoid the internal connection between the
VREF pin to A/D converter power AVDD. The analog input values must not be allowed to exceed the
value of the selected reference voltage, AVDD or VREF.
The following table shows how to properly select reference voltage for the A/D converter or OCP D/A
converter.
ADC Reference
Voltage Selection
AVDD
AVDD
VREF
VREF
OCP DAC Reference
Voltage Selection
AVDD
VREF
AVDD
VREF
SAVRS[1:0] OCPVRS PAS07~PAS06
01
0
Others except “10”
01
1
01
Others except “01”
0
10
Others except “01”
1
10
A/D Converter Input Signals
All the external A/D analog channel input pins are pin-shared with the I/O pins as well as other
functions. The corresponding control bits for each A/D external input pin in the PAS0 and PAS1
register determine whether the input pins are setup as A/D converter analog inputs or whether
they have other functions. If the pin is setup to be as an A/D analog channel input, the original pin
functions will be 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 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 two internal analog signals derived from the Bandgap reference voltage or Over Current
Protection analog output signal, which can be connected to the A/D converter as the analog
input signal by configuring the SAINS2~SAINS0 bits. If the external channel input is selected
to be converted, the SAINS2~SAINS0 bits should be set to “000” and the SACS3~SACS0 bits
can determine which external channel is selected. If the internal analog signal is selected to be
converted, the SACS3~SACS0 bits must be configured with a value from 1000 to 1111 to switch off
the external analog channel input. Otherwise, the internal analog signal will be connected together
with the external channel input. This will result in unpredictable situations.
Rev. 1.00
77
March 03, 2016