01.04.2014 Views

Preliminary C8051F120/1/2/3 C8051F124/5/6/7 - KEMT FEI TUKE

Preliminary C8051F120/1/2/3 C8051F124/5/6/7 - KEMT FEI TUKE

Preliminary C8051F120/1/2/3 C8051F124/5/6/7 - KEMT FEI TUKE

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>C8051F120</strong>/1/2/3<br />

<strong>C8051F124</strong>/5/6/7<br />

<strong>Preliminary</strong><br />

24.2.1. Edge-triggered Capture Mode<br />

In this mode, a valid transition on the CEXn pin causes PCA0 to capture the value of the PCA0 counter/timer and<br />

load it into the corresponding module's 16-bit capture/compare register (PCA0CPLn and PCA0CPHn). The CAPPn<br />

and CAPNn bits in the PCA0CPMn register are used to select the type of transition that triggers the capture: low-tohigh<br />

transition (positive edge), high-to-low transition (negative edge), or either transition (positive or negative edge).<br />

When a capture occurs, the Capture/Compare Flag (CCFn) in PCA0CN is set to logic 1 and an interrupt request is<br />

generated if CCF interrupts are enabled. The CCFn bit is not automatically cleared by hardware when the CPU vectors<br />

to the interrupt service routine, and must be cleared by software.<br />

Figure 24.4. PCA Capture Mode Diagram<br />

PCA Interrupt<br />

PCA0CPMn<br />

P E C C M T P E<br />

W C A A A O W C<br />

M O P P T G M C<br />

1 M P N n n n F<br />

6 n n n n<br />

n<br />

PCA0CN<br />

C C C C C C C C<br />

F R C C C C C C<br />

F F F F F F<br />

5 4 3 2 1 0<br />

Port I/O<br />

Crossbar<br />

CEXn<br />

0<br />

1<br />

0<br />

(to CCFn)<br />

Capture<br />

PCA0CPLn<br />

PCA0CPHn<br />

1<br />

PCA<br />

Timebase<br />

PCA0L<br />

PCA0H<br />

Note: The signal at CEXn must be high or low for at least 2 system clock cycles in order to be valid.<br />

Page 294<br />

DS008-0.8-AUG02 © 2002 Cygnal Integrated Products, Inc.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!