数据搜索系统,热门电子元器件搜索
  Chinese  ▼
ALLDATASHEETCN.COM

X  

AN431 数据表(PDF) 7 Page - STMicroelectronics

部件名 AN431
功能描述  Using ST6 analog inputs for multiple key decoding
PDF  15 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
制造商  STMICROELECTRONICS [STMicroelectronics]
网页  http://www.st.com
标志 STMICROELECTRONICS - STMicroelectronics

AN431 数据表(HTML) 7 Page - STMicroelectronics

Back Button AN431 Datasheet HTML 3Page - STMicroelectronics AN431 Datasheet HTML 4Page - STMicroelectronics AN431 Datasheet HTML 5Page - STMicroelectronics AN431 Datasheet HTML 6Page - STMicroelectronics AN431 Datasheet HTML 7Page - STMicroelectronics AN431 Datasheet HTML 8Page - STMicroelectronics AN431 Datasheet HTML 9Page - STMicroelectronics AN431 Datasheet HTML 10Page - STMicroelectronics AN431 Datasheet HTML 11Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 7 / 15 page
background image
ANALOG KEYBOARD
7/15
;**************************************************************************
;*
*
*
;*
SGS-THOMSON GRAFING
*
;*
*
;*
APPLICATION NOTE 431
-
ST6
*
*
;*
*
;*
Use of ADC inputs for multiple key decoding
*
;*
*
*
;*
With the inbuilt A/D converter of any ST6 it is easy to
*
;*
implement a small routine which enables ONE port pin, con-
*
;*
figured as an ADC input, to decode up to ten different switches*
**
;*
All that is necessary is to set one port pin as an ADC input
*
;*
Then the program runs in an endless loop until one of the
*
*
;*
connected keys is pushed.
*
*
;*
The value from the ADC data register is then used to decide
*
;*
how the program will continue,on reaction to the key-push.
*
*
;*
*
;**************************************************************************
;***REGISTERS***
ddrpb
.def
0c5h
;port B data direction register
orpb
.def
0cdh
;port B option register
drpb
.def
0c1h
;port B data register
adr
.def
0d0h
;A/D data register
adcr
.def
0d1h
;A/D control register
a
.def
0ffh
;accumulator
;***CONSTANTS***
inpall
.equ
000h
;used for setting all pins input
peg1_2
.equ
00ch
;border to distinguish between switch1 and switch2
peg2_3
.equ
025h
;border to distinguish between switch2 and switch3
peg3_4
.equ
03eh
;border to distinguish between switch3 and switch4
peg4_5
.equ
058h
;border to distinguish between switch4 and switch5
peg5_6
.equ
072h
;border to distinguish between switch5 and switch6
peg6_7
.equ
08ch
;border to distinguish between switch6 and switch7
peg7_8
.equ
0a5h
;border to distinguish between switch7 and switch8
peg8_9
.equ
0beh
;border to distinguish between switch8 and switch9
APPENDIX A: Key Input by Polling



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15


数据表 下载

Go To PDF Page


链接网址



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