Omega Vehicle Security OMB-NETSCAN 1500 User Manual Page 194

  • Download
  • Add to my manuals
  • Print
  • Page
    / 256
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 193
nIOLock
Function: int nIOLock (long session, short iotype, short channel, short lock);
Parameters:
Long session The session handle of the NetScan
Short iotype Always a 9
Short port The serial port being locked (1 for the netscan,
0 for the AUX port)
Short lock 0 to unlock, 1 to lock
Returns: 0 if successful, error code if not.
Description: This function is used to lock the serial port of the NetScan adapter so that another session cant have
access to it. If a serial port is left unlocked, then another session could gain access to that port, causing unpredictable
results.
Example:
ErrVal = nIOLock(session, 9, 1, 1);
nSERIALConfigure
Function: int nSERIALConfigure (long session, short port, long baudrate, short parity,
short databits, short stopbits, short flowctrl, long reserved);
Parameters:
Long session The session handle of the NetScan
Short port The serial port being configured
Long baudRate The baud rate to be used
Short parity The parity setting to be used
Short databits The number of data bits to be used
Short stopbits The number of stop bits to use
Short flowControl The handshaking method to use
Long reserved Always 0
Parameter Values:
Port: Aux = 0
NetScan = 1
Baud Rates: 300, 1200, 2400, 4800, 9600, 19200, 28800, 38400, 57600,
115200.
Parity Settings: odd = 79
Even = 69
None = 78
Data Bits: 7, 8
Stop Bits: 1,2
Flow Control: none = 0
Xon/Xoff = 1
Dtr/Dsr = 2
Rts/Cts = 3
Returns: 0 if successful, error code or warning if command not completed.
Description: This function is used to configure the selected serial port parameters of the NetScan ethernet interface.
The parameters used must match the NetScan serial port configuration switches on the rear of the unit. Because this
function may take some time to complete, the return value must be tested to see if the command has completed. The
return value for command pending is 801.
Example:
Do {
ErrVal = nSERIALConfigure(session, 1, 38400, 78, 8, 1, 3, 0);
} while (errVal == -801);
Page view 193
1 2 ... 189 190 191 192 193 194 195 196 197 198 199 ... 255 256

Comments to this Manuals

No comments