◆ Open()

int CSeaMaxLin::Open ( char *  filename)

Open a SeaIO module. This function will attempt to open a specified SeaIO module. The method of specification is a string formatted like "sealevel_rtu://dev/[your_serial]" or "sealevel_tcp://x.x.x.x:y" where x's represent ip address and y the port. If you leave out the port, 502 will be used as the default. You may also enter the device's DCHP name like: "sealevel_tcp://Samwise". For SeaDAC Lite modules use sealevel_d2x://xxxx where xxxx=8112 or 8115 etc..

Parameters
[in]*filenameFilename to open.
Returns
int Error code.
Return values
0Successfully opened device.
-ENAMETOOLONGToo many characters in filename string.
-EINVALUnallocated pointer.
-EBADFInvalid filename.
-EBUSYCommunications medium busy.
-EXDEVUnable to initialize communications.
-ENOMEMLow memory.
-EPERMUnable to retrieve current communication settings.

References SeaMaxLinOpen().

 
 
Generated on Tue Sep 19 2017.