beautypg.com

Reading out counter data – Epson S1C33210 User Manual

Page 254

background image

III PERIPHERAL BLOCK: 8-BIT PROGRAMMABLE TIMERS

B-III-3-6

EPSON

S1C33210 FUNCTION PART

When both the timer RUN/STOP control bit (PTRUNx) and the timer preset bit (PSETx) are set to "1" at the
same time, the timer starts counting after presetting the reload register value into the counter.

PTRUNx

PSETx

RLDx

Input clock

PTDx7

PTDx6

PTDx5

PTDx4

PTDx3

PTDx2

PTDx1

PTDx0

Preset

Timer
initial setup

Reload and
interrupt

0xA6

0x10

0xF3

Figure 3.2 Basic Operation Timing of Counter

Reading out counter data

The counter data is read out via a PTDx data buffer. The counter data can be read out at any time.
Timer 0 data: PTD0[7:0] (D[7:0]) / 8-bit timer 0 counter data register (0x40162)
Timer 1 data: PTD1[7:0] (D[7:0]) / 8-bit timer 1 counter data register (0x40166)
Timer 2 data: PTD2[7:0] (D[7:0]) / 8-bit timer 2 counter data register (0x4016A)
Timer 3 data: PTD3[7:0] (D[7:0]) / 8-bit timer 3 counter data register (0x4016E)
Timer 4 data: PTD4[7:0] (D[7:0]) / 8-bit timer 4 counter data register (0x40176)
Timer 5 data: PTD5[7:0] (D[7:0]) / 8-bit timer 5 counter data register (0x4017A)