Keysight CXG, EXG, and MXG X-Series Signal Generators Programming Guide 133
Programming Examples
LAN Programming Interface Examples
}
ptr++;
}
*ptr = '\0';
if (err) {
return NULL;
} else {
return result;
}
#else
/******************************************************************
* Simpler UNIX version, using file I/O. recv() version works
too.
* This demonstrates how to use file I/O on sockets, in UNIX.
******************************************************************/
FILE * instFile;
instFile = fdopen(sock, "r+");
if (instFile == NULL)
{
fprintf(stderr, "Unable to create FILE * structure : %s\n",
strerror(errno));
exit(2);
}
return fgets(result, maxLength, instFile);
#endif
}
/******************************************************************
Summary of Contents for X-Series
Page 4: ...4 ...
Page 10: ...10 Contents ...