Panasonic MN103S manual End, Flowchart

Page 17

Chapter 3

Microcomputer Basics 1

Flowchart

main ()

Initialize CPU

Set P44 output

Set Timer 1 input pin

Set the base register

Set count clock source

Initialize Timer 1

Select Timer 1 normal operation

Set an interrupt level

Enable the interrupt

Start event

Binary counter underflow

int_timer1 ()

P44 state

Low (LED off)

High output (LED on)

High (LED on)

Low output (LED off)

END

8-bit timer operation

III−41

Image 17
Contents MN103S927/92A/F92G LSI Application Notes Excerption Page Page About This Manual Format used for sample program explanations About This Manual3 Page Table of Contents Microcomputer Basics Chapter overview Appendix Table of Contents Hardware allocation list Counting rising edges using the event countOverview Timer 1 Base Register TM1BR 0x0000A149 Port 3 I/O Control Register P3DIR 0x0000A023 Timer 1 Binary Counter TM1BC 0x0000A151Timer 1 Mode Register TM1MD 0x0000A141 Port 3 Output Mode Register P3MD 0x0000A033 END FlowchartExample program Enable the interruptCpum URL http//panasonic.co.jp/semicon/e-micom/inquiry InquiriesSales Offices