
Semiconductor Group
92
On-Chip Peripheral Components
7.5.2.2 Compare Mode 1
In compare mode 1, the software adaptively determines the transition of the output signal. lt is
commonly used when output signals are not related to a constant signal period (as in a standard
PWM generation) but must be controlled very precisely with high resolution and without jitter. In
compare mode 1, both transitions of a signal can be controlled. Compare outputs in this mode can
be regarded as high speed outputs which are independent of the CPU activity.
lf mode 1 is enabled, and the software writes to the appropriate output latch at the port, the new
value will not appear at the output pin until the next compare match occurs. Thus, one can choose
whether the output signal is to make a new transition (1-to-0 or 0-to-1, depending on the actual pin-
level) or should keep its old value at the time the timer 2 count matches the stored compare value.
Figure 7-39 shows a functional diagram of a timer/compare register/port latch configuration in
compare mode 1. In this function, the port latch consists of two separate latches. The upper latch
(which acts as a "shadow latch") can be written under software control, but its value will only be
transferred to the output latch (and thus to the port pin) in response to a compare match.
Note that the double latch structure is transparent as long as the internal compare signal is active.
While the compare signal is active, a write operation to the port will then change both latches. This
may become important when driving timer 2 with a slow external clock. In this case the compare
signal could be active for many machine cycles in which the CPU could unintentionally change the
contents of the port latch. For details see also section 7.5.2.3 "Using Interrupts in Combination with
the Compare Function".
A read-modify-write instruction (see section 7.1) will read the user-controlled "shadow latch" and
write the modified value back to this "shadow-latch". A standard read instruction will - as usual - read
the pin of the corresponding compare output.
*
Summary of Contents for SAB 80515 Series
Page 9: ...Semiconductor Group 9 Introduction Figure 1 2 Block Diagram ...
Page 12: ...Semiconductor Group 12 Fundamental Structure Figure 2 1 Detailed Block Diagram ...
Page 18: ...Semiconductor Group 18 Central Processing Unit Figure 3 1 Fetch Execute Sequence ...
Page 73: ...Semiconductor Group 73 On Chip Peripheral Components Figure 7 25 A D Converter Block Diagram ...
Page 83: ...Semiconductor Group 83 On Chip Peripheral Components Figure 7 33 a Timer 2 Block Diagram ...
Page 215: ...Device Specifications Semiconductor Group 215 ...
Page 217: ...Device Specifications Semiconductor Group 217 Pin Configuration P LCC 68 ...
Page 219: ...Device Specifications Semiconductor Group 219 Logic Symbol ...
Page 226: ...Device Specifications Semiconductor Group 226 Figure 1 Block Diagram ...
Page 229: ...Device Specifications Semiconductor Group 229 Figure 2 Memory Address Spaces ...
Page 239: ...Device Specifications Semiconductor Group 239 Figure 4 Block Diagram of the A D Converter ...
Page 241: ...Device Specifications Semiconductor Group 241 Figure 5 Interrupt Request Sources ...
Page 242: ...Device Specifications Semiconductor Group 242 Figure 6 Interrupt Priority Level Structure ...