Figure 11-10 Control Circuit In External Clock Mode 1; Figure 11-11 External Trigger Input Block Diagram - Nations N32G43 Series User Manual

32-bit arm cortex-m4f microcontroller
Table of Contents

Advertisement

Timer clock = CK_CNT=CK_PSC
Counter register
External clock source mode 2
This mode is selected by TIMx_SMCTRL .EXCEN equal to 1. The counter can count on every rising or falling edge
of the external trigger input ETR.
The following figure is a schematic diagram of the external trigger input module in External clock source mode 2
Polarity Selection
TIMx_SMCTRL.EXTP
ETR pin
Prescaler
/1,/2,/4,/8
TIMx_SMCTRL.EXTPS[1:0]
For example, use the following configuration steps to make the up counter count every 2 rising edges on ETR.
Since no filter is needed in this case, make TIMx_SMCTRL .EXTF[3:0] equal to '0000'
Configure the prescaler by making TIMx_SMCTRL.EXTPS[1:0] equal to '01'
Select the polarity on ETR pin by setting TIMx_SMCTRL.EXTP equal to '0', The rising edge of ETR is valid

Figure 11-10 Control circuit in external clock mode 1

CNTEN
TI2
64
TITF

Figure 11-11 External trigger input block diagram

ETRP
f
DTS
Filter Down counter
TIMx_SMCTR.EXTF[3:0]
65
Write TITF=0
TI1F rising or falling
or
TI2F rising or falling
TRGI rising
ETRF rising
CK_INT rising
238 / 631
Nations Technologies Inc.
Tel:+86-755-86309900
Email:info@nationstech.com
Address: Nations Tower, #109 Baoshen Road, Hi-tech Park North.
Nanshan District, Shenzhen, 518057, P.R.China
66
Encode mode
External clock
mode 1
External clock
mode 2
Internal clock
mode
TIMx_SMCTRL.EXCE
N
TIMx_SMCTRL.SMSE
L[2:0]

Advertisement

Table of Contents
loading

Table of Contents