Renesas M16C Series User Manual page 275

16-bit single-chip microcomputer
Hide thumbs Also See for M16C Series:
Table of Contents

Advertisement

M30245 Group
w w w . D a t a S h e e t 4 U . c o m
Figure 2.14.6. Set-up procedure of key-input interrupt
Rev.2.00 Oct 16, 2006
REJ09B0340-0200
Setting key input mode register
b7
b0
Key input mode register [Address 03F9
0 0
1
1
0 0
KUPM
P10 Key-input edge select bit 0
P10 Key-input edge select bit 1
b1 b0
0 0 : Falling edge
P10
1 : Enabled
P10
1 : Enabled
P10
1 : Disabled
P10
1 : Disabled
Setting port P10 direction register
b7
b0
Port P10 direction register [Address 03F6
1 1
1 1
0 0
0 0
PD10
0 : Input mode (Functions as an input port)
1 : Output mode (Functions as an output port)
Setting pull-up control register 2
b7
b0
Pull-up control register 2 [Address 03FE
1
PUR2
P10
1 : Pulled high
Setting key input interrupt control register
b7
b0
Key input interrupt control register [Address 0041
0
KUPIC
Interrupt priority level select bit
b2 b1 b0
0 0 0 : Level 0 (interrupt disabled)
0 0 1 : Level 1
0 1 0 : Level 2
0 1 1 : Level 3
1 0 0 : Level 4
1 0 1 : Level 5
1 1 0 : Level 6
1 1 1 : Level 7
Interrupt request bit
page 266 of 354
and P10
Key-input enable bit
0
1
and P10
Key-input enable bit
2
3
and P10
Key-input enable bit
4
5
and P10
Key-input enable bit
6
7
to P10
0
3
0 : Interrupt not requested
2. Key-Input Interrupt
]
16
]
16
]
16
]
16

Advertisement

Table of Contents
loading

Table of Contents