1 title 'Character I/O Module for the Modular CP/M 3 BIOS'
7 public ?cinit,?ci,?co,?cist,?cost
17 include modebaud.inc ; define mode bits and baud equates
21 ;--------------------------------------------------------------
29 db 'ASCI0 ' ; device 1
30 db mb$in$out+mb$serial+mb$soft$baud
33 db 'ASCI1 ' ; device 2
34 db mb$in$out+mb$serial+mb$soft$baud
37 db 0 ; table terminator
39 ;--------------------------------------------------------------
52 max$devices equ ($-xctbl)/2
58 ;--------------------------------------------------------------
68 ;--------------------------------------------------------------
69 ; Init character device
73 ?cinit: ; init devices
84 ;--------------------------------------------------------------
91 ?ci: ; character input
100 ;--------------------------------------------------------------
104 ; a: 0ffh if char available, else 0
107 ?cist: ; character input
112 _cist: ; character input status
116 ;--------------------------------------------------------------
124 ?co: ; character input
129 _co: ; character output
134 ;--------------------------------------------------------------
138 ; a: 0ffh if device ready for next output char, else 0
142 ?cost: ; character input
147 _cost: ; character output status
151 ;--------------------------------------------------------------
153 ; hl: function table index (offset)
155 ; c: output char or ioctl #
156 ; de: ioctl arg pointer
158 ; Calls funtion xctbl[offset] with
159 ; b,c,de unchanged and hl = ptr to drivers local data
163 push de ;save arg ptr 11
190 ;--------------------------------------------------------------
221 ;--------------------------------------------------------------