01.06.2014 Views

STM32W108C8

STM32W108C8

STM32W108C8

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>STM32W108C8</strong><br />

General-purpose timers<br />

Figure 30.<br />

Capture/compare channel 1 main circuit<br />

Figure 31. Output stage of capture/compare channel (channel 1)<br />

The capture/compare block is made of a buffer register and a shadow register. Writes and<br />

reads always access the buffer register.<br />

In capture mode, captures are first written to the shadow register, then copied into the buffer<br />

register.<br />

In compare mode, the content of the buffer register is copied into the shadow register which<br />

is compared to the counter.<br />

10.1.5 Input capture mode<br />

In input capture mode, a capture/compare register (TIMx_CCRy) latches the value of the<br />

counter after a transition is detected by the corresponding ICy signal. When a capture<br />

occurs, the corresponding INT_TIMCCyIF flag in the INT_TIMxFLAG register is set, and an<br />

interrupt request is sent if enabled.<br />

If a capture occurs when the INT_TIMCCyIF flag is already high, then the missed capture<br />

flag INT_TIMMISSCCyIF in the INT_TIMxMISS register is set. INT_TIMCCyIF can be<br />

Doc ID 018587 Rev 2 122/215

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

Saved successfully!

Ooh no, something went wrong!