upd78f0103hmca1-5a4-a Renesas Electronics Corporation., upd78f0103hmca1-5a4-a Datasheet - Page 150

no-image

upd78f0103hmca1-5a4-a

Manufacturer Part Number
upd78f0103hmca1-5a4-a
Description
8-bit Single-chip Microcontrollers
Manufacturer
Renesas Electronics Corporation.
Datasheet
7.4.3 Operation as square-wave output
compare register 50 (CR50).
(TOE50) of 8-bit timer mode control register 50 (TMC50) to 1. This enables a square wave with any selected
frequency to be output (duty = 50%).
150
A square wave with any selected frequency is output at intervals determined by the value preset to 8-bit timer
The TO50 pin output status is inverted at intervals determined by the count value preset to CR50 by setting bit 0
<1> Set each register.
<2> After TCE50 = 1 is set, the count operation starts.
<3> The timer output F/F is inverted by a match of TM50 and CR50. After INTTM50 is generated, TM50 is
<4> After these settings, the timer output F/F is inverted at the same interval and a square wave is output from
Caution Do not write other values to CR50 during operation.
Note The initial value of TO50 output can be set by bits 2 and 3 (LVR50, LVS50) of 8-bit timer mode control
Setting
TM50 count value
• Set the port output latch (P17) and port mode register 1 (PM17) to 0.
• TCL50: Select the count clock.
• CR50:
• TMC50: Stop the count operation, select clear & start mode entered on a match of TM50 and CR50.
cleared to 00H.
TO50.
The frequency is as follows.
register 50 (TMC50).
Count clock
TO50
Frequency = 1/2t (N + 1)
(N: 00H to FFH)
CR50
Note
Count start
Compare value
00H
Timer output F/F inversion enabled
Timer output enabled
(TMC50 = 00001011B or 00000111B)
LVS50
01H
t
1
0
Figure 7-9. Square-Wave Output Operation Timing
CHAPTER 7 8-BIT TIMER/EVENT COUNTER 50
02H
N
LVR50
0
1
User’s Manual U16846EJ3V0UD
High-level output
Low-level output
N − 1
Timer Output F/F Status Setting
N
00H
01H
02H
N − 1
N
00H

Related parts for upd78f0103hmca1-5a4-a