48 int main(
int argc,
char * argv[])
50 GReturn rc = GALIL_EXAMPLE_OK;
51 char buf[G_SMALL_BUFFER];
60 cerr <<
"Incorrect number of arguments provided\n";
61 cerr <<
"Usage: message_example.exe <ADDRESS>\n";
62 return GALIL_EXAMPLE_ERROR;
65 char* address = argv[1];
66 sprintf(buf,
"%s --subscribe MG", address);
75 GError(gr, buf, G_SMALL_BUFFER);
79 GSize size =
sizeof(buf);
80 GUtility(g, G_UTIL_ERROR_CONTEXT, buf, &size);
83 return GALIL_EXAMPLE_ERROR;
int main(int argc, char *argv[])
Main function for Message Example.
GReturn message(GCon g)
Demonstrates how to receive messages from the controller and detect differences in Trace and crashed ...
void e(GReturn rc)
A trivial, C++ style return code check used in Galil's examples and demos.