home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CP/M
/
CPM_CDROM.iso
/
cpm
/
22rsx
/
byestuff.ark
/
DCDCHECK.MAC
< prev
next >
Wrap
Text File
|
1985-11-28
|
1KB
|
88 lines
; user control of carrier detection. BYERSX Auxiliary
;
bdos equ 5
fcb equ 05ch
;
aseg
org 0100h
;
lxi h,0
dad sp
lxi sp,stack
push h
mvi c,87
lxi d,0
call bdos
ora a
lxi d,norsx
jz exit
mvi c,84; system state
mvi e,0ffh; enquiry
call bdos
sta state
lxi h,fcb
mov a,m
ora a
jnz help
inx h
mov a,m
cpi 'O'
inx h
mov a,m
jnz help
inx h
cpi 'F'
jz off
cpi 'N'
jz on
; " "
; give help
help: lxi d,hlpmsg
; " "
; message and exit
exit: mvi c,9
call bdos
pop h
sphl
ret
;
; suppress carrier checks
off: mov a,m
cpi 'F'
jnz help
inx h
mov a,m
cpi ' '
jnz help
lda state
ani NOT 010h; disable checks
mov e,a
mvi c,84
call bdos
lxi d,offmsg
jmp exit
;
; enable DCD checks
on: mov a,m
cpi ' '
jnz help
lda state
ori 010h
mov e,a
mvi c,84
call bdos
lxi d,onmsg
jmp exit
;
hlpmsg: db 'usage: DCDCHECK [ON|OFF] (controls DCD monitoring)$'
offmsg: db 'Not '
onmsg: db 'Checking for carrier$'
norsx: db 'BYERSX not running$'
;
state: ds 1; BYERSX input state
;
ds 48
stack: ds 0
;
end
}*