欢迎访问ic37.com |
会员登录 免费注册
发布采购

AN1950 参数 Datasheet PDF下载

AN1950图片预览
型号: AN1950
PDF下载: 下载PDF文件 查看货源
内容描述: 水位监测 [Water Level Monitoring]
分类和应用: 监控
文件页数/大小: 24 页 / 298 K
品牌: FREESCALE [ Freescale ]
 浏览型号AN1950的Datasheet PDF文件第12页浏览型号AN1950的Datasheet PDF文件第13页浏览型号AN1950的Datasheet PDF文件第14页浏览型号AN1950的Datasheet PDF文件第15页浏览型号AN1950的Datasheet PDF文件第17页浏览型号AN1950的Datasheet PDF文件第18页浏览型号AN1950的Datasheet PDF文件第19页浏览型号AN1950的Datasheet PDF文件第20页  
lsr DC  
ror DB  
ror DA  
lda NA  
add DA  
sta NA  
lda NB  
adc DB  
sta NB  
lda NC  
adc DC  
sta NC  
lsla  
;divide DC:DB:DA by 2  
;and add into NC:NB:NA  
bcs nornd  
lda RA  
add #$01  
sta RA  
lda RB  
adc #$00  
sta RB  
;if carry=1 then remainder<1/2 of dividend  
;otherwise add 1 to result  
nornd: rts  
;__________________________________________________________  
;__________________________________________________________  
UNITS: brclr 2,porta,UNITS ;let go of ENT first  
lda #$01  
jsr lcdcmdo  
;===UNITS=== Allows user to select units: inches or cm  
;clear screen  
ldhx #msg03  
jsr lcdstro  
jsr del100ms  
clr RA  
lda #$0D  
jsr lcdcmdo  
;Unit Choice menu  
;menu choice=0 to begin with  
;blink cursor on menu choice  
;get current menu choice  
uluke: ldx RA  
clrh  
lda menupos,x  
jsr lcdcmdo  
;and look up corresponding LCD address  
;reposition cursor  
uwarm: brclr 1,porta,uPB1 ;check for SEL  
brclr 2,porta,uPB2 ;or for ENT  
bclr 4,porta  
bset 5,porta  
jsr del100ms  
bset 4,porta  
bclr 5,porta  
jsr del100ms  
bra uwarm  
;otherwise  
;turn on "SEL" LED  
;delay  
;toggle LEDs  
;"ENT" now on: means choice is SEL ***or*** ENT  
;delay and repeat until SEL or ENT  
uPB1: inc RA  
lda RA  
;***SEL*** toggles menu choices  
;menu choices are $00 and $01  
cmp #$02  
bne uPB1ok  
clr RA  
;back to $00 when all others have been offered  
uPB1ok: bclr 4,porta  
bclr 5,porta  
;LEDs off  
jsr del100ms  
;wait a little bit  
brclr 1,porta,uPB1ok ;make sure they let go of SEL  
bra uluke  
AN1950  
Sensors  
16  
Freescale Semiconductor  
 复制成功!