11 cout <<
"\n************************************************************************\n";
12 cout <<
"Example GArrayDownload(), GArrayUploadFile()\n";
13 cout <<
"GArrayDownloadFile(), and GArrayUpload usage\n";
14 cout <<
"************************************************************************\n";
25 x_e(
GArrayDownload(g,
"A",
G_BOUNDS,
G_BOUNDS,
"2,4,6,8,10,12,14,16,18,20"));
59 return GALIL_EXAMPLE_OK;
#define G_COMMA
For GArrayUpload(), use this value in the delim field to delimit with commas.
GCLIB_DLL_EXPORTED GReturn GCALL GArrayDownloadFile(GCon g, GCStringIn file_path)
Array download from file.
GCLIB_DLL_EXPORTED GReturn GCALL GArrayUploadFile(GCon g, GCStringIn file_path, GCStringIn names)
Array upload to file.
#define G_BOUNDS
For functions that take range options, e.g. GArrayUpload(), use this value for full range.
GCLIB_DLL_EXPORTED GReturn GCALL GArrayDownload(GCon g, const GCStringIn array_name, GOption first, GOption last, GCStringIn buffer)
Downloads array data to a pre-dimensioned array in the controller's array table.
void * GCon
Connection handle. Unique for each connection in process. Assigned a non-zero value in GOpen().
GCLIB_DLL_EXPORTED GReturn GCALL GCmd(GCon g, GCStringIn command)
Wrapper around GCommand for use when the return value is not desired.
GCLIB_DLL_EXPORTED GReturn GCALL GArrayUpload(GCon g, const GCStringIn array_name, GOption first, GOption last, GOption delim, GBufOut buffer, GSize buffer_len)
Uploads array data from the controller's array table.
GReturn vector(GCon g, char *file)
Puts controller into Vector Mode and accepts a file defining vector points.
int x_arrays(GCon g)
Example GArrayDownload() and GArrayUpload() usage.
void x_e(GReturn rc)
A trivial, C++ style return code check used in Galil's examples and demos.