F17__PUT__BUFFER (AX
=
6F02H)
This function transmits data from a buffer as long as there is data in the buffer and no error is
encountered. Valid data is set up on the printer interface for at least 900 nanoseconds. If the
BUSY signal indicates that the device is busy, it executes an INT 15H function F15_DEV__BUSY.
When it returns from F15__0EV__BUSY, the function waits until the BUSY signal indicates the
device is not busy. The function generates a 500 nanosecond data strobe and holds the data
valid for at least 900 nanoseconds. The function returns with the port status in the AH register.
On Entry:
AX
=
F17_PUT_BUFFER (6F02H)
CX
=
Number of characters in the data buffer
DX
=
Port number (a, 1, 2, 3)
ES:OI
=
Pointer to a data buffer of characters
On Exit:
AH
=
Printer port status (see table 7.8)
Normal Completion:
CX
=
Number of bytes transferred successfully
ES:DI
=
Base of data buffer
Error Completion (bit
a
of AH register non-zero):
CX
=
Number of bytes transferred successfully
ES:OI
=
pointer to next byte to be transferred
Reg isters Altered:
AH, CX, 01, ES
Example:
STRING
DB
'Hello'
END---:-STRING:
START:
MOV AX, seg STRING
; set pointer
to
string
MOV ES,AX
MOV
01,
offset STRING
,
MOV AX, F17_PUT_BUFFER
; (AX
=
6F02H)
MOV
CX, END_STRING-STRING
; length of character
; string
MOV
O)(~
0
; Port
0
specification
,..
INT
INT_PRINTER
; Call printer driver (lNT 17H)
TEST
AH, 00000001 B
; Ltst for errors
JNZ
short ERRORJUT__STRING
Serial and Parrallel I/O
235
Need help?
Do you have a question about the Vectra and is the answer not in the manual?
Questions and answers