em78p134n ELAN Microelectronics Corp, em78p134n Datasheet - Page 42

no-image

em78p134n

Manufacturer Part Number
em78p134n
Description
8-bit Microcontroller With Otp Rom
Manufacturer
ELAN Microelectronics Corp
Datasheet
EM78P134N
8-Bit Microcontroller with OTP ROM
36 •
5.8.2 Function Description
The following figure shows the TMRX block diagram followed by descriptions of its
signals and blocks:
Fosc: Input clock
Prescaler (TP2, TP1 and TP0 ): The Options 1:1, 1:2, 1:4, 1:8, 1:16, 1:64, 1:128, and
TMR (TMRH/TMRL): Timer register; TMR is increased until it matches with PRD, and
PRD: PWM time period register.
Comparator: Reset TMR while a match occurs. The TMRIF flag is set at the same
5.8.3 Programming the Related Registers
When defining TMR, refer to the operation of its related registers as shown in the table
below. It must be noted that the PWM bits must be disabled if their related TMR are
employed. That is, Bit 4 of the PWMCON register must be set to ‘0’.
5.8.3.1
5.8.4 Timer Programming Process/Steps
1. Load PRD with the Timer duration
2. Enable interrupt function by writing IOCF0, if required
3. Load a desired TMR prescaler value to PWMCON, enable TMR and disable PWM
Addr.
0x0B
time.
1:256 are defined by TMR. It is cleared when any type of reset occurs.
then is reset to 1 (default valve).
PWMCON/RB CPOUT COS1
TMR Related Control Registers
Name
Bit 7
Figure 5-14 TMRX Block Diagram
Bit 6
(This specification is subject to change without further notice)
COS0
Bit 5
Product Specification (V1.6) 06.02.2010
PWME
Bit 4
Bit 3
TEN
Bit 2
TP2
Bit 1
TP1
Bit 0
TP0

Related parts for em78p134n