參數(shù)資料
型號(hào): AN1775
廠商: 飛思卡爾半導(dǎo)體(中國)有限公司
英文描述: Expanding Digital Input with an A/D Converter
中文描述: 擴(kuò)展數(shù)字輸入與A / D轉(zhuǎn)換器
文件頁數(shù): 11/12頁
文件大?。?/td> 283K
代理商: AN1775
Application Note
Code Listings
AN1775 Rev. 1
;Check the entries in the table, to find the ADC value range
;that corresponds to the ADC data register value.
KeyLoop:
LDA
KeyTable+1,X
CMP
ADValue
BLS
Match
LDA
KeyTable,X
CMP
ADVAlue
BLS
Match
INCX
INCX
;Increment the key value, when a match is made,
;the variable will contain the key that was pressed.
INC
InKey
BRA
KeyLoop
;Check high range
;Within range
;Check low range
;Within range
;Point to next table record
; At this point, InKey variable holds keypress information
; One can arbitrate the key press here. For this simple example
; we just repeat the main loop
Match:
BRA
MainLoop
* ----------------------------------------------------------------------------------
; Key lookup table. Holds the minimum and maximum ADC values
; which identify a particular key in the resistor ladder
* ----------------------------------------------------------------------------------
KeyTable:
NoKey
FCB
$EF,$FF
Key1
FCB
$00,$0F
Key2
FCB
$0F,$2F
Key3
FCB
$2F,$4F
Key4
FCB
$4F,$6F
Key5
FCB
$6F,$8F
Key6
FCB
$8F,$AF
Key7
FCB
$AF,$CF
Key8
FCB
$CF,$EF
;No key pressed
* ----------------------------------------------------------------------------------
; Vector definitions
* ----------------------------------------------------------------------------------
ORG
$1FFE
FDB
Start
;Reset vector
F
Freescale Semiconductor, Inc.
For More Information On This Product,
Go to: www.freescale.com
n
.
相關(guān)PDF資料
PDF描述
AN1816 USING THE HC912B32 TO IMPLEMENT THE DISTRIBUTED SYSTEMS INTERFACE (DSI) PROTOCOL
AN2104 Using Background Debug Mode for the M68HC12 Family
AN2154FAP TV/Video Signal Processor
AN22011A For Video·Audio - MD
AN2241 Video Camera Circuit
相關(guān)代理商/技術(shù)參數(shù)
參數(shù)描述
AN17800A 制造商:Panasonic Industrial Company 功能描述:IC
AN17801A 制造商:Panasonic Industrial Company 功能描述:IC
AN17805A 制造商:Panasonic Industrial Company 功能描述:Audio Power Matsushita IC 12-Pin SIP-Hs
AN17807A 制造商:Panasonic Industrial Company 功能描述:IC
AN17808B 功能描述:IC AUDIO AMP 5W 2CH SIL-12 RoHS:是 類別:集成電路 (IC) >> 線性 - 音頻放大器 系列:- 標(biāo)準(zhǔn)包裝:2,000 系列:- 類型:AB 類 輸出類型:2 通道(立體聲) 在某負(fù)載時(shí)最大輸出功率 x 通道數(shù)量:- 電源電壓:4 V ~ 18 V 特點(diǎn):- 安裝類型:通孔 供應(yīng)商設(shè)備封裝:8-DIP 封裝/外殼:8-DIP(0.300",7.62mm) 包裝:管件