Windows Standard
Serial Communications
Reference Library
(WSC_REF)
Version 3.0
July 10, 2000 Revised July 26, 2000
This software is provided as-is.
There are no warranties, expressed or implied.
Copyright (C) 2000
All rights reserved
MarshallSoft Computing, Inc.
Post Office Box 4543
Huntsville AL 35815 USA
Voice : 256-881-4630
FAX : 256-880-0925
email : info@marshallsoft.com
web : www.marshallsoft.com
MarshallSoft is a member of the Association of Shareware Professionals
MARSHALLSOFT is a registered trademark of MarshallSoft Computing.
1 Introduction
1.1 General Remarks2 WSC Functions
1.2 Documentation Set
1.3 Declaration Files
1.4 Language Notes
2.1 SioBaud3 Modem I/O Functions
2.2 SioBrkSig
2.3 SioCTS
2.4 SioDCD
2.5 SioDone
2.6 SioDSR
2.7 SioDTR
2.8 SioEvent
2.9 SioFlow
2.10 SioGetc
2.11 SioGets
2.12 SioInfo
2.13 SioMessage
2.14 SioParms
2.15 SioPutc
2.16 SioPuts
2.17 SioRead
2.18 SioReset
2.19 SioRI
2.20 SioRTS
2.21 SioRxClear
2.22 SioRxQue
2.23 SioStatus
2.24 SioTimer
2.25 SioTxClear
2.26 SioTxQue
2.27 SioUnGetc
2.28 SioWinError
3.1 mioBreak4 XYDRV Functions
3.2 mioDriver
3.3 mioQuiet
3.4 mioResult
3.5 mioSendTo
3.6 mioWaitFor
4.1 xyAbort5 Error Codes
4.2 xyAcquire
4.3 xyDebug
4.4 xyDriver
4.5 xyGetFileName
4.6 xyGetMessage
4.7 xyGetParameter
4.8 xyRelease
4.9 xySetParameter
4.10 xyStartRx
4.11 xyStartTx
5.1 WSC Error Codes
5.2 XYDRV Error Codes
All functions return an integer code. Negative values are always errors. See "WSC Error Codes" in Section 5.1. Non-negative return codes are never errors.
Each function argument is marked as:
Refer to the declaration files (see Section 1.3 below) for the exact syntax of each WSC function. Also note that the example programs show exactly how WSC functions are called.
The complete set of documentation consists of four manuals in three formats. This is
the third manual
(WSC_REF) in the set.
Each manual comes in three formats:
The exact syntax for calling WSC functions are specific to the host language (C/C++, Delphi, VB, etc.) and are defined for each language in the "WSC declaration files". Each WSC product comes with the appropriate declaration file for the supported language. For example,
WSC4C C/C++ WSC.H WSC4VB Visual Basic WSC16.BAS and WSC32.BAS VBA (EXCEL,ACCESS,etc.) WSC16.BAS and WSC32.BAS WSC4PB PowerBASIC WSC32.PBI WSC4D Borland Delphi WSC16.PAS and WSC32.PAS WSC4CB Fujitsu COBOL WSC32.CBI WSC4FP Visual FoxPro WSC32.FOX WSC4DB Visual dBase WSC16.CC and WSC32.CC WSC4XB Xbase++ WSC32.CHAll WSC functions are used in one or more example programs.
None.
All strings passed to WSC functions must be prefixed with the '@' character.
None.
SioBaud(Port, Baud) Port : (I) -1 or port selected. Baud : (I) Baud code or actual baud rate.
The SioBaud function sets the baud rate without resetting the port. It is used to change the baud rate after calling SioReset. SioBaud may be called with either the actual baud rate value or one of the baud rate codes as follows:
[VALUE] [RATE] [NAME] 0 300 Baud300 1 600 Baud600 2 1200 Baud1200 3 2400 Baud2400 4 4800 Baud4800 5 9600 Baud9600 6 19200 Baud19200 7 38400 Baud38400 8 57600 Baud57600 9 115200 Baud115200
SioBrkSig(Port, Cmd) Port : (I) Port selected. Cmd : (I) ASSERT, CANCEL, or DETECT.
The SioBrkSig function controls the BREAK bit in the line status register. The legal commands are:
[NAME] : [FUNCTION] WSC_ASSERT_BREAK : to assert BREAK WSC_CANCEL_BREAK : to cancel BREAK WSC_DETECT_BREAK : to detect BREAKWSC_ASSERT_BREAK, WSC_CANCEL_BREAK, and WSC_DETECT_BREAK are defined in the language declaration file (see Section 1.3).
Code = SioBrkSig(Port, WSC_ASSERT_BREAK)
SioCTS(Port) Port : (I) Port selected.
The SioCTS function is used to detect if CTS (Clear To Send) is set (1) or clear (0). Some Windows Win16 COMM drivers cannot read the CTS bit correctly!
The CTS line is used by some error correcting modems to implement hardware flow control. CTS is dropped by the modem to signal the computer not to send data and is raised to signal the computer to continue.
Refer to the RS232/485 Serial Communications Users Manual (ASYNC.DOC) for a discussion of flow control.
Code = SioCTS(Port)
See SioFlow and SioRead.
SioDCD(Port) Port : (I) Port selected.
The SioDCD function is used to read the Data Carrier Detect (DCD) modem status bit. Also see SioStatus.
SioDCD is normally used after connecting to check that the carrier has not been dropped.
Code = SioDCD(Port)
See SioRead.
SioDone(Port) Port : (I) Port selected.
The SioDone function terminates further serial processing, allowing other applications to use the port. SioDone should always be the last function called before exiting an application.
Code = SioDone(Port)
See SioReset.
SioDSR(Port) Port : (I) Port selected.
The SioDSR function is used to detect if DSR (Data Set Ready) is set (1) or clear (0). Some Windows Win16 COMM drivers cannot read the DSR bit correctly!
Modems normally set DSR as soon as they are powered up.
Code = SioDSR(Port)
See SioRead.
SioDTR(Port, int Cmd) Port : (I) Port selected. Cmd : (I) DTR command (see below).
The SioDTR function controls the Data Terminal Ready (DTR) bit in the modem control register. DTR should always be set when communicating with a modem.
[NAME] : [FUNCTION] WSC_SET_LINE : to set DTR (ON) WSC_CLEAR_LINE : to clear DTR (OFF) WSC_READ_LINE : to read DTR
Code = SioDTR(Port, WSC_SET_LINE)
SioRead.
SioEvent(Port, DWORD Mask) Port : (I) Port selected. Mask : (I) Event Mask (see below).
The SioEvent function (WIN32 only) waits (blocks) until the condition specified in 'Mask' is satisfied. Multiple conditions can be OR'ed together. The event masks are:
[NAME] : [FUNCTION] EV_RXCHAR : A character was received. EV_BREAK : A break signal was received. EV_CTS : The CTS line changed states. EV_DSR : The DST line changed states. EV_ERR : An error was detected. EV_RLSD : The DCD line has changed states. EV_RING : The RI line has been set. EV_TXEMPTY : The TX queue has become empty.
Code = SioEvent(Port)
SioMessage.
SioFlow(Port, Cmd) Port : (I) Port selected. Cmd : (I) Class of flow control (see below).
The SioFlow function is used to enable or disable hardware flow control. Hardware flow control uses RTS and CTS to control data flow between the modem and the computer. To enable flow control, call SioFlow with 'Cmd' set to:
[NAME] : [FUNCTION] WSC_HARDWARE_FLOW_CONTROL : Hardware (RTS/CTS) flow control. WSC_SOFTWARE_FLOW_CONTROL : Software (XON/XOFF) flow control. WSC_NO_FLOW_CONTROL : No flow control [default].
Code = SioFlow(Port, WSC_HARDWARE_FLOW_CONTROL)
SioPutc
SioGetc(Port) Port : (I) Port selected.
The SioGetc function reads the next byte from the receive queue of the selected serial port. WSC_NO_DATA (-100) is returned if no byte is available.
Code = SioGetc(Port)
SioUnGetc and SioGets.
SioGets(Port, String, Cnt) Port : (I) Port selected. String : (P) Pointer to receive buffer. Cnt : (I) Number of bytes to read.
The SioGets function reads the smaller of the number of bytes wanted (Cnt) and the number of bytes in the receive buffer. A zero is returned if no bytes are read.
char Buffer[128]; Code = SioGets(Port, (LPSTR)Buffer, 128)
Dim Buffer As String * 128 Code = SioGets(Port, Buffer, 128)
SioUnGetc and SioPutc.
SioInfo(Cmd) Cmd : (I) Command (See below)
The SioInfo function returns an integer code corresponding to the Cmd as follows.
[NAME] : [FUNCTION] WSC_VERSION : Library version number [3 hex digits].SioInfo(WSC_VERSION) will return the 3 digit version number embedded in WSC16.DLL and in WSC32.DLL. The 3 digit version number is formatted as the rightmost 3 nibbles (4 bits per nibble) of the return value. Refer to the WSCVER program for an example.
SioMessage(Port, Handle, Message, Mask) Port : (I) Port selected. Handle : (S) Window handle (HWND). Message: (I) Message (Usually WM_USER). Mask : (L) Event mask (see SioEvent).
The SioMessage function will post the message 'Message' to the window handle 'Handle' when event 'Mask' occurs. SioMessage does not block.
Call SioMessage(Port, 0, 0, 0) in order to cancel a previous event.
Refer to SioEvent for a list of mask values.
See remarks above.
Code = SioMessage(Port, hWnd, WM_USER, EV_RXCHAR)
SioEvent
SioParms(Port, Parity, StopBits, DataBits) Port : (I) -1 or port selected. Parity : (I) Parity code. StopBits : (I) Stop bits code. DataBits : (I) Word length code.
The SioParms function sets the parity, stop bits, and word length values.
SioParms can be called either before or after calling SioReset. Call SioParms with Port set to -1 before calling SioReset to make the passed parameters the default. Use the constant values defined in the WSC declaration file (see Section 1.3) to minimize the chance of passing an incorrect parameter value.
[PARITY] [STOPBITS] [DATABITS] NoParity OneStopBit WordLength7 OddParity One5StopBits WordLength8 EvenParity TwoStopBits -- SpaceParity -- -- MarkParity -- --
Code = SioParms(Port, WSC_NoParity, WSC_OneStopBit, WSC_WordLength8)
SioReset.
SioPutc(Port, char Ch) Port : (I) Port selected. Ch : (I) Character to send.
The SioPutc function copies the character to the transmit queue for subsequent transmission by the UART.
Code = SioPutc(Port, 'A')
Code = SioPutc(Port, ASC("A"))
SioGetc and SioFlow.
SioPuts(Port, String, Count) Port : (I) Port selected. String : (P) Pointer to string of bytes to transmit. Count : (I) Number of bytes to transmit.
The SioPuts function copies 'Count' bytes from 'String' to the transmit queue for subsequent transmission. The 'String' can contain any ASCII or binary values.
char Buffer[128]; Code = SioPuts(Port, (LPSTR)Buffer, 128)
Dim Buffer As String * 128 Code = SioPuts(Port, Buffer, 128)
SioGetc and SioFlow.
SioRead(Port, Reg) Port : (I) Port selected. Reg : (I) UART register (0 to 7).
SioRead is NOT for Win32 applications running under Windows NT or 2000. The SioRead function reads any of the 7 I/O ports directly, by-passing the Windows API. The line status and the modem status registers can be read by (in C/C++):
#define SioLine(Port) SioRead(Port,5) #define SioModem(Port) SioRead(Port,6)Note that all modem and/or line status bits can also be read using SioDTR, SioRTS, SioDCD, SioRI, SioDSR, and SioCTS. Refer to the RS232/485 Serial Communications Users Manual (ASYNC.DOC) for a discussion of the UART registers.
Code = SioRead(Port, 5)
SioStatus.
SioReset(Port, RxQueSize, TxQueSize) Port : (I) Port selected (or -1: see below). RxQueSize : (I) Receive queue size. TxQueSize : (I) Transmit queue size.
The SioReset function initializes (opens) the selected serial port. SioReset should be called before making any other calls to WSC except for setting default behavior (port=-1). SioReset uses the parity, stop bits, and word length value previously set if SioParms was called, otherwise the default values (19200, no parity, 8 data, 1 stop) are used.
SioReset can be called with Port set to -1 in order to specify the behavior of DTR and
RTS at port
initialization:
SioReset(-1, DTR_Default, RTS_Default)
DTR will be set at port initialization if DTR_Default is 1, else DTR will be cleared. Similarly for RTS_Default.
Code = SioReset(Port, 1024, 1024)
SioBaud, SioParms, and SioDone.
SioRI(Port) Port : (I) Port selected.
The SioRI function is used to read the Ring Indicator (RI) modem status bit. It is recommended that incoming rings be detected by looking for the text "RING" in the input stream rather than the RI signal since some modems do not set the RI reliably.
Code = SioRI(Port)
SioRead.
SioRTS(Port, Cmd) Port : (I) Port selected. Cmd : (I) RTS command (SET, CLEAR, or READ).
The SioRTS function controls the Request to Send (RTS bit in the modem control register).
The RTS line is used by some error correcting modems to implement hardware flow control. RTS is dropped by the computer to signal the modem not to send data and is raised to signal the modem to continue. RTS should be set when communicating with a modem unless flow control is being used.
Refer to the RS232/485 Serial Communications Users Manual (ASYNC.DOC) for a discussion of flow control. Commands (defined in WSC declaration file [Section 1.3]) are:
[NAME] : [FUNCTION] WSC_SET_LINE : set RTS (ON) WSC_CLEAR_LINE : clear RTS (OFF) WSC_READ_LINE : read RTS
Code = SioRTS(Port, WSC_CLEAR_LINE)
SioFlow and SioDTR.
SioRxClear(Port) Port : (I) Port selected.
The SioRxClear function will delete any characters in the receive buffer (not the UART) for the specified port. After execution, the receive buffer will be empty.
Code = SioRxClear(Port)
SioRxQue.
SioRxQue(Port) Port : (I) Port selected.
The SioRxQue function will return the number of bytes in the receive queue (not the UART) at the time of the call.
Code = SioRxQue(Port)
See SioTxQue
SioStatus(Port, Mask) Port : (I) Port selected. Mask : (I) Error mask.
The SioStatus function returns the serial port error status corresponding to the mask argument.
[MASK NAME] : [FUNCTION] WSC_RXOVER : The receive queue overflowed. WSC_OVERRUN : An incoming byte was overwritten. WSC_PARITY : A parity error was detected (incoming byte) WSC_FRAME : A framing error was detected (incoming byte) WSC_BREAK : A break signal was detected. WSC_TXFULL : The transmit queue is full.
Code = SioStatus(Port, WSC_FRAME)
SioRead.
SioTimer()
The SioTimer returns the system time in milliseconds. SioTimer calls the Windows API function GetCurrentTime. This function is provided as a convenience since GetCurrentTime could be called directly.
The system time in milliseconds.
TimeNow = SioTimer()
SioTxClear(Port) Port : (I) Port selected.
The SioTxClear function will delete any characters in the transmit buffer (not the UART) for the specified port.
Once this function is called, any character in the transmit buffer (put there by SioPutc or SioPuts) will be lost and therefore not transmitted.
Code = SioTxClear(Port)
SioTxQue.
SioTxQue(Port) Port : (I) Port selected.
The SioTxQue function will return the number of characters in the transmit queue (not the UART) at the time of the call.
Code = SioTxQue(Port)
SioRxQue.
SioUnGetc(Port, Ch) Port : (I) Port selected. Ch : (I) Character to unget.
The SioUnGetc function returns ("pushes") the character back into the serial input buffer. The character pushed will be the next character returned by SioGetc. Only one character can be pushed back. This function works just like the "ungetc" function in the C language.
Code = SioUnGetc(Port)
SioReset.
SioWinError(Buffer, Size) Buffer : (P) Pointer to messages buffer. Size : (I) Size of buffer.
The SioWinError is a Win32 ONLY function that returns the last Win32 error code. If 'Buffer' is not NULL, it will also copy the corresponding text message into 'Buffer' of maximum size 'Size'
char Buffer[128] Code = SioWinError((LPSTR)Buffer, 128)
Dim Buffer As String * 128 Code = SioWinError(Buffer, 128)
The Win32 numeric error code.
mioBreak(Port) Port : (I) Port selected.
Forces the MIO driver to the IDLE state, abandoning any work in progress (if any). Used to abort mioSendTo, mioQuiet, and mioWaitFor functions.
Return = MIO_IDLE.
Code = mioBreak(Port)
mioDriver(Port) Port : (I) Port selected.
Executes the next state of any previously started MIO function such as mioSendTo, mioWaitFor, and mioQuiet. Returns MIO_IDLE (defined in MIO.H) if idle (not running), MIO_RUNNING if running, and anything else that is a character from the modem that can be displayed if wanted.
Code = mioDriver(Port)
mioQuiet(Port, Wait) Port : (I) Port selected. Wait : (L) Wait in milliseconds.
The mioQuiet function waits for continuous quiet [no incoming serial data] of 'Wait' milliseconds before returning. Any incoming characters while mioQuiet is running are lost.
Return = TRUE.
Code = mioQuiet(Port, 1000)
mioResult(Port) Port : (I) Port selected.
The mioResult function returns the result of the last mioWaitFor function. This function should not be called until the driver returns MIO_IDLE. See the remarks section of the mioWaitFor function for an example.
Code = mioResult(Port)
mioWaitFor.
mioSendTo(Port, Pace, Text) Port : (I) Port selected. Pace : (L) The inter-character delay in milliseconds. String : (P) The string to send.
The mioSendTo function sends the characters in the string 'Text' to serial output. There is a delay of 'Pace' milliseconds between characters. Three characters in 'Text' are interpreted as:
[NAME] : [FUNCTION] char is '^' : next character is control char (^A for 0x01) char is '!' : replaced with carriage return. char is '~' : removed from string (delay 1/2 second).
mioWaitFor(Port, Wait, Text) Port : (I) Port selected. Wait : (L) Total time to wait for response (milliseconds). Text : (P) The expected response string.
The mioWaitFor function waits for characters from serial input that match the string 'Text'. A total of 'Wait' milliseconds are allowed before timing out and returning FALSE (0). The string comparison is NOT case sensitive.
The function mioDriver() must be called until MIO_IDLE is returned. Then mioResult() is called to get the result of the mioWaitFor. Looking at the example below, a value of 0 indicates that neither "CONNECT", "BUSY", nor "NO CARRIER" was received. A non-zero value indicates that one of the three sub-strings was received. A '0' is returned if "CONNECT" was seen, '1' is returned if "NO CARRIER" was seen, and '2' is returned if "BUSY" was seen.
A character as described above.
Code = mioWaitFor(Port, 60000, "CONNECT|NO CARRIER|BUSY")
mioResult.
xyAbort(Port) Port : (I) Port selected.
The xyAbort function forces the driver to IDLE, terminating any file transfer which may be in progress.
Return = XY_NO_ERROR (0).
Code = xyAbort(Port)
xyAcquire(FirstPort, LastPort) FirstPort : (I) First port selected. LastPort : (I) Last port selected.
The xyAcquire function initializes the driver for subsequent use. This should be the first driver function called.
Code = xyAcquire(COM1, COM1)
xyRelease.
xyDebug(Level) Level : (I) Debug level value.
The xyDebug functions sets the driver debug level as follows:
[LEVEL] [FUNCTION] Level is 0 : Only error messages are generated (default). Level is 1 : Minimal debug messages are generated. Level is 2 : Maximal debug messages are generated.
xyDriver(Port) Port : (I) Port selected.RETURNS
o Return = XY_IDLE : A transfer is not underway. o Return = XY_RUNNING : A transfer is underway.
The xyDriver function drives the state engine. It is normally called within a timer loop. Note that xyDriver never returns an error code.
xyDriver can be called as often as wanted whether or not a file transfer was initiated.
Code = xyDriver(Port)
xyStartTx and xyStartRx.
xyGetFileName(Port, Buffer, Size) Port : (I) Port selected. Buffer : (P) Filename buffer. Size : (I) Size of Filename buffer.
The xyGetFileName function gets the current filename. This function is designed for use on the receive side YMODEM protocol, where the filename is received as part of the first packet (packet #0). See the TERM example program.
char Buffer[40] Code = xyGetFileName(Port, (LPSTR)Buffer, 40)
Dim Buffer As String * 40 Code = xyGetFileName(Port, Buffer, 40)
xyGetParameter.
xyGetMessage(Port, Buffer, Size) Port : (I) Port selected. Buffer : (P) Message buffer. Size : (I) Size of message buffer.
The xyGetMessage function retrieves the next message from the driver message queue. Refer to the TERM example program for an example of using xyGetMessage.
char Buffer[40] Code = xyGetMessage (Port, (LPSTR)Buffer, 40)
Dim Buffer As String * 40 Code = xyGetMessage(Port, Buffer, 40)
xyDebug.
xyGetParameter(Port, Parm) Port : (I) Port Selected. Parm : (I) Parameter to return.
The parameter value corresponding to the following table is returned.
[NAME] : [FUNCTION] XY_GET_VERSION : Returns XYDRV version (a.b.c). XY_GET_ERROR_CODE : Driver error code (see XYDRIVER.H) XY_GET_ERROR_STATE : Error state (if in error). XY_GET_PACKET : Current packet number. XY_GET_STATE : Current state (see XYDRIVER.C). XY_GET_FILE_SIZE : File size. XY_GET_NBR_NAKS : Number of packets ACKed. XY_GET_LAST_GET : Last incoming (serial) character. XY_GET_LAST_PUT : Last outgoing (serial) character. XY_GET_GET_COUNT : Number of incoming characters (bytes). XY_GET_PUT_COUNT : Number of outgoing characters (bytes). XY_GET_DRIVER_COUNT : Number times xyDriver() was called. -1 : Cannot recognize parameter.The xyGetParameter function can be used to check the state of the driver. For example:
See above.
Code = xyGetParameter(Port, XY_GET_VERSION)
xyRelease()
The xyRelease function releases the ports that were previously acquired with xyAcquire. This function should be called before calling the WSC function SioDone.
Code = xyRelease()
xyAcquire.
xySetParameter(Port, ParmName, ParmValue) Port : (I) Port Selected. ParmName : (I) Parameter Name. ParmValue : (L) Parameter Value.
The ParmValue corresponding to the following table is set.
[NAME] : [FUNCTION] ParmName = XY_SET_NAK_RATE : Sets the prompt delay (in seconds). ParmName = XY_SET_EOF_CHAR : Sets the XMODEM pad character. ParmName = -1 : Cannot recognize parameter.The XY_SET_NAK_RATE parameter sets the delay (in seconds) between prompts that the receiver transmits to the sender to start the file transfer. The legal range is 1 to 10 seconds. The XY_SET_EOF_CHAR parameter sets the pad character used by XMODEM in padding the last packet to 128 bytes. The normal value is control-Z (hex 1A).
xyStartRx(Port, Filename, NCGchar, Batch) Port : (I) Port to use. Filename : (P) File to receive (XMODEM only). NCGchar : (I) NAK, 'C', or 'G'. Batch : (I) YMODEM flag (T/F).
The xyStartRx starts the XMODEM or YMODEM file receive. Once started, calls to xyDriver are made to execute the next state (or states). The xyStartTx function returns immediately. The protocols supported and their parameters are as follows:
[Protocol] : [NCGchar] [BatchFlag] XMODEM : NAK FALSE (Standard XMODEM) XMODEM/CRC : 'C' FALSE XMODEM/1K : 'C' FALSE YMODEM : 'C' TRUE (Standard YMODEM)
Code = xyStartRx(Port, "MYFILE.ZIP", 'C', 1)
Code = xyStartRx(Port, "MYFILE.ZIP", ASC("C"), 1)
xyStartTx and xyDriver.
xyStartTx(Port, Filename, OneK, Batch) Port : (I) Port to use. Filename : (P) File to send. OneK : (I) Want 1K blocks (T/F). Batch : (I) YMODEM flag (T/F).
The xyStartTx starts the XMODEM or YMODEM file send. Once started, calls to xyDriver are made to execute the next state (or states). The xyStartTx function returns immediately. The protocols supported and their parameters are as follows:
[Protocol] : [OneKflag] [BatchFlag] XMODEM : FALSE FALSE Standard XMODEM XMODEM/CRC : FALSE FALSE XMODEM/1K : TRUE FALSE YMODEM : TRUE TRUE Standard YMODEM
Code = xyStartTx(Port, "MYFILE.ZIP", 0, 1)
xyStartRx and xyDriver.
[NAME] : [FUNCTION] WSC_IE_BAUDRATE : Unsupported baud rate. WSC_NO_DATA : No incoming serial data is available. WSC_RANGE : A parameter is out of range. WSC_ABORTED : The shareware version of WSC corrupted. WSC_WIN32ERR : Win32 system error. WSC_IE_BADID : No such port. WSC_IE_OPEN : Port already opened. WSC_IE_NOPEN : Port not opened. Call SioReset first. IE_MEMORY : Cannot allocate memory for queues. IE_DEFAULT : Error in default parameters. IE_HARDWARE : Hardware not present. IE_BYTESIZE : Unsupported byte size.The WSC_ABORTED error occurs in the shareware version only if there is a problem displaying the shareware screen. The WSC_WIN32ERR error code is returned only for Win32 system errors. Call SioWinError to retrieve the error message.
[NAME] : [FUNCTION] XY_NO_ERROR : No error. XY_UNKNOWN_ERROR : Unknown error. XY_ALREADY_ACTIVE_ERROR : Port already acquired. XY_CANNOT_OPEN_ERROR : Cannot open specified file. XY_EMPTY_FILE_ERROR : Specified file is empty. XY_NO_STARTUP_CHAR_ERROR : Must specify NAK, 'C', or 'G'. XY_NOT_NCG_ERROR : Expected NAK, 'C', or 'G'. XY_DISK_READ_ERROR : Error reading disk. XY_NO_EOT_ACK_ERROR : EOT was not ACKed. XY_INTERNAL_ERROR : Internal error! XY_CANCELLED_ERROR : Other side canceled. XY_OUT_OF_SYNC_ERROR : Protocol has lost synchronization. XY_RETRIES_ERROR : Packet retry limit was exceeded. XY_BAD_PACKET_NBR_ERROR : Incorrect packet number. XY_TIMED_OUT_ERROR : Timed out waiting for other side. XY_NO_SUCH_FILE_ERROR : No such file. XY_NOT_ACTIVE_ERROR : Port not acquired by xyAcquire. XY_PORT_RANGE_ERROR : Port number out of range.