전자부품 데이터시트 검색엔진
  Korean  ▼
ALLDATASHEET.CO.KR

X  

AN4013 데이터시트(PDF) 12 Page - STMicroelectronics

부품명 AN4013
상세설명  The purpose of this document
PDF  37 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
제조업체  STMICROELECTRONICS [STMicroelectronics]
홈페이지  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

AN4013 데이터시트(HTML) 12 Page - STMicroelectronics

Back Button AN4013 Datasheet HTML 8Page - STMicroelectronics AN4013 Datasheet HTML 9Page - STMicroelectronics AN4013 Datasheet HTML 10Page - STMicroelectronics AN4013 Datasheet HTML 11Page - STMicroelectronics AN4013 Datasheet HTML 12Page - STMicroelectronics AN4013 Datasheet HTML 13Page - STMicroelectronics AN4013 Datasheet HTML 14Page - STMicroelectronics AN4013 Datasheet HTML 15Page - STMicroelectronics AN4013 Datasheet HTML 16Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 12 / 37 page
background image
General-purpose timer modes
AN4013
12/37
DocID022500 Rev 4
The update event is generated also by:
Software, if the UG (update generation) bit is set in TIM_EGR register.
Update generation through the slave mode controller
As the buffered registers (ARR, PSC, CCRx) need an update event to be loaded with their
preload values, set the URS (Update Request Source) to 1 to avoid the update flag each
time these values are loaded. In this case, the update event is only generated if the counter
overflow/underflow occurs.
The update event can be also disabled by setting the bit UDIS (update disable) in the CR1
register. In this case, the update event is not generated, and shadow registers (ARR, PSC,
CCRx) keep their value. The counter and the prescaler are reinitialized if the UG bit is set, or
if a hardware reset is received from the slave mode controller.
An interrupt or/ and a DMA request can be generated when the UIE bit or/and UDE bit are
set in the DIER register.
For more details on using the timer in this mode, refer to the examples provided in the
STM32xx standard peripheral libraries in the /Project/STM32xx_StdPeriph_Examples/
TIM/TimeBase folder.
STM32Cube F3 firmware package includes examples in the following directories:
Projects\STM32F3348-Discovery\Examples\TIM\TIM_TimeBase,
Projects\STM32F302R8-Nucleo\Examples\TIM\TIM_TimeBase,
Projects\STM32F3-Discovery\Examples\TIM\TIM_TimeBase,
Projects\STM32373C_EVAL\Examples\TIM\TIM_TimeBase,
Projects\STM32303E_EVAL\Examples\TIM\TIM_TimeBase and
Projects\STM32303C_EVAL\Examples\TIM\TIM_TimeBase
2.3
Timer input capture mode
The timer can be used in input capture mode to measure an external signal. Depending on
timer clock, prescaler and timer resolution, the maximum measured period is deduced.
To use the timer in this mode:
1.
Select the active input by setting the CCxS bits in CCMRx register. These bits should
be different from zero, otherwise the CCRx register will be read only.
2.
Program the filter by writing the IC1F[3:0] bits in the CCMRx register, and the prescaler
by writing the IC1PSC[1:0] if needed.
3.
Program the polarity by writing the CCxNP/CCxP bits to select between rising, falling or
both edges.
The input capture module is used to capture the value of the counter after a transition is
detected by the corresponding input channel. To get the external signal period, two
consecutive captures are needed. The period is calculated by subtracting these two values.
Period = Capture(1) /(TIMx_CLK *(PSC+1)*(ICxPSC)*polarity_index(2))
The capture difference between two consecutive captures CCRx_tn and CCRx_tn+1:
If CCRx_tn < CCRx_tn+1: capture = CCRx_tn+1 - CCRx_tn
If CCRx_tn > CCRx_tn+1: capture = (ARR_max - CCRx_tn) + CCRx_tn+1
The polarity index is 1 if the rising or falling edge is used, and 2 if both edges are used.



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37


데이터시트 다운로드

Go To PDF Page


링크 URL



ALLDATASHEET 가 귀하에 도움이 되셨나요?  [ DONATE ] 

Alldatasheet는?   |   광고문의   |   운영자에게 연락하기   |   개인정보취급방침   |   링크 투 데이터시트    |   링크교환   |   제조사별 검색
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com