TITLE TurboDOS 19200 Baud Null Console Driver SUBTTL Intercontinental Micro Systems CPZ-48000 ; ; ; CONSK.MAC ; Intercontinental Micro Systems ; Null Console Driver ; ;Edit History: ;03-27-84 gwm Modified for INIT section and no AFF sequence. ; .Z80 ; Zilog mnuemonics ; NAME ('CONSK') ; Module Identification ; PUBLIC CONBR ; set CONBR to public ; DSEG ; Locate in Data Segment ; FFCHR:: DB 'E' ; form feed character INITC: DB 0 ; initialization complete flag ; COMMON /?INIT?/ ; place into common segment ; CONINIT:DEC (HL) ; set init complete flag PUSH DE ; save function number PUSH BC ; save chan number/character LD C,8EH ; baud rate code to C-REG CONBR EQU $-1 ; pointer back to baud rate byte LD E,3 ; set function number = 3 CALL SERIAL## ; set channel baud rate LD A,(FFCHR) ; get form feed character OR A ; form feed char = 0? JR Z,CONNITX ; if so, continue ; POP BC ; else, restore channel number PUSH BC ; save channel number LD C,27 ; form feed character to C-REG LD E,2 ; set function number = 2 CALL SERIAL## ; send form feed ld a,(ffchr) pop bc push bc ld c,a ld e,2 call serial## ; CONNITX:POP BC ; restore channel number/character POP DE ; restore function number RET ; CSEG ; locate in program area ; CONDR@::LD HL,INITC ; get initialization complete flag LD A,(HL) OR A ; initialization complete flag set ? CALL Z,CONINIT ; no...initialize console channel ; call noteck## ; check for twix LD A,E ; get function number SUB 8 ; function number = 8? JR Z,CONSO ; if so, error SHIFT out ; DEC A ; function number = 9? Jp NZ,serial## ; if not, enter serial routine ; CONSI: CALL DMS## ; position to next line SIPAT:: DB 0DH,0AH,80h,0,0,0,0,0,0,0,0,0,0,0,0,0 RET ; CONSO: CALL DMS## ; position to next line SOPAT:: DB 0DH,0AH,80h,0,0,0,0,0,0,0,0,0,0,0,0,0 RET ; END ; End of CONSK.MAC