Visible to Intel only — GUID: GUID-A1A78D11-56F5-413A-B706-2CBEAAB957B2
Visible to Intel only — GUID: GUID-A1A78D11-56F5-413A-B706-2CBEAAB957B2
SPORT_WRITE_LINE
Serial Port I/O Function: Outputs data, followed by a record terminator, to the specified port. This routine is only available for Windows.
USE IFPORT
result = SPORT_WRITE_LINE (port,data[,count])
port |
(Input) Integer. The port number. |
data |
(Input) Character*(*). The data to be output. |
count |
(Input; optional) Integer. The count of bytes to write. If the value is zero, this number is computed by scanning the data backwards looking for a non-blank character. |
The result type is INTEGER(4). The result is zero if successful; otherwise, a Windows* error value.
After the data is output, a line terminator character is added based on the mode used during the SPORT_CONNECT( ) call.
When hardware (DTR, RTS, etc.) or software (XON/XOFF) flow controls are used, the functions SPORT_WRITE_DATA and SPORT_WRITE_LINE can write less bytes than required. When this occurs, the functions return the code ERROR_IO_INCOMPLETE, and the return value of parameter count contains the number of bytes that were really written.
USE IFPORT
INTEGER(4) iresult
iresult = SPORT_WRITE_LINE( 2, 'ATZ', 0 )
END
See Also
Communications and Communications Functions in the Microsoft* Platform SDK