![Cmsemicon BAT32G1 9 Series Скачать руководство пользователя страница 180](http://html1.mh-extra.com/html/cmsemicon/bat32g1-9-series/bat32g1-9-series_user-manual_2627609180.webp)
BAT32G1x9 user manual | Chapter 6 Universal timer unit Timer4/8
180 / 1149
Rev.1.02
6.6.2
Output setting of the TOmn pin
The steps and state changes from the initial setting of the TOmn output pin to the start of the timer run are
shown below.
Figure 6-32 The state change from setting the output of the timer to starting operation
TCRmn
(counter)
Timer multiplex pin
Timer output singal
TOmn write operation enable period
TOmn write operation disable period
(1)configure TOMmn
configure TOLmn
(2)configure
TOMmn
(3)configure
TOEmn
(4),(5)
Configure
Port to
output mode
(6)Timer start operating
Random value ( "FFFFH" after reset )
(1) Set the operating mode of the timer output.
•
TOMmn bits (0: master channel output mode, 1: slave channel output mode).
•
TOLmn bits (0: positive logic output, 1: negative logic output).
(2) Set the timer output signal to the initial state by setting the timer output register m(TOm).
(3) Write "1" to the TOEmn bit, allowing the timer output (it is forbidden to write the TOm register).
(4) Set the port as a digital input/output through the port mode control register (PMCxx) (refer to the
register of the "6.3.15 control timer input/output pin port function").
(5) Set the input/output of the port to the output (refer to "Registers for controlling the input/output pin
port function of the timer in 6.3.15").
(6) Enable the timer to run (TSmn=1).
Note: m: unit number (m=0,1)n: channel number (when m=0: n=0~3, m=1: n=0~7).