Seamax api – Impulse 463E User Manual
Page 68

© Sealevel Systems, Inc.
- 65 -
SeaI/O User Manual
SeaMAX API
A functional description of each method in the class, including the possible return
values, is provided. All return values less than zero are standard error codes listed
and defined in the standard C library header file
Object-Oriented model, the Visual C++ DLL is designed as a single class. This class
has the following model:
Open
CSeaMaxW32::Open( unsigned char* filename )
Description
Opens the specified resource. The filename parameter can be one
of two different types, Modbus RTU or Modbus TCP.
To specify a Modbus RTU connection (used for all non-Ethernet
enabled modules) the string “sealevel_rtu://COMx” should be
used, where x is a valid COM port number.
To specify a Modbus TCP connection (used only for Ethernet
enabled modules) the string “sealevel_tcp://x.x.x.x” should be
used, where x’s represent the valid IP address of the module to be
accessed.
Parameters
unsigned char* filename
Return Codes
-38
ENAMETOOLONG
The length of the filename is
greater than 256 characters.
-22
EINVAL
The specified protocol is invalid,
or, the module could not be
contacted.
-9
EBADF
The specified location is invalid
0
Success
Close
CSeaMaxW32::Close( )
Description
Closes a previously opened SeaIO module resource.
Parameters
None
Return Codes
0
Success