Rev. 1.10
34
November 04, 2019
Rev. 1.10
35
November 04, 2019
HT45F5Q-3
Battery Charger Flash MCU
HT45F5Q-3
Battery Charger Flash MCU
Reading Data from the Emulated EEPROM – polling method
MOV A, EEPROM_ADRES ; user-defined address
MOV EAR, A
SET ERDEN ; set ERDEN bit, enable read operation
SET ERD ; start Read Cycle – set ERD bit
BACK:
SZ ERD ; check for read cycle end
JMP BACK
CLR ECR ; disable Emulated EEPROM read if no more read operations
;
are
required
MOV A, ED0L ; move read data which is placed in the ED0L/ED0H
; to user-defined registers
MOV READ_DATA_L, A
MOV A, ED0H
MOV READ_DATA_H, A
Note: For each read operation, the address register should be re-specified followed by setting the
ERD bit high to activate a read cycle even if the target address is consecutive.
Oscillators
Various oscillator options offer the user a wide range of functions according to their various
application requirements. The flexible features of the oscillator functions ensure that the best
optimisation can be achieved in terms of speed and power saving. Oscillator selections and operation
are selected through the application program by using relevant control registers.
Oscillator Overview
In addition to being the source of the main system clock the oscillators also provide clock sources
for the Watchdog Timer and Time Base Interrupts. Two fully integrated internal oscillators, requiring
no external components, are provided to form a wide range of both fast and slow system oscillators.
The higher frequency oscillators provide higher performance but carry with it the disadvantage of
higher power requirements, while the opposite is of course true for the lower frequency oscillators.
With the capability of dynamically switching between fast and slow system clock, the device has the
flexibility to optimize the performance/power ratio, a feature especially important in power sensitive
portable applications.
Type
Name
Frequency
Internal High Speed RC
HIRC
8MHz
Internal Low Speed RC
LIRC
32kHz
Oscillator Types
System Clock Configurations
There are two methods of generating the system clock, one high speed oscillator and one low
speed oscillator. The high speed oscillator is the internal 8MHz RC oscillator, HIRC. The low
speed oscillator is the internal 32kHz RC oscillator, LIRC. Selecting whether the low or high speed
oscillator is used as the system oscillator is implemented using the CKS2~CKS0 bits in the SCC
register and as the system clock can be dynamically selected.