EasyManua.ls Logo

Keysight Technologies N5172B EXG - Page 137

Keysight Technologies N5172B EXG
398 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Keysight CXG, EXG, and MXG X-Series Signal Generators Programming Guide 137
Programming Examples
LAN Programming Interface Examples
/* indefinite block ... dump til we can an extra line
feed */
do
{
if (recv_line(sock, result, maxLength) == NULL)
break;
if (strlen(result)==1 && *result == '\n') break;
resultBytes += strlen(result);
result += strlen(result);
} while (1);
}
}
else
{
/* ASCII response (not a binary block) */
*result = (char)ch;
if (recv_line(sock, result+1, maxLength-1) == NULL)
return 0;
/* REMOVE trailing newline, if present. And terminate
string. */
resultBytes = strlen(result);
if (result[resultBytes-1] == '\n') resultBytes -= 1;
result[resultBytes] = '\0';
}
} while (0);
return resultBytes;
}
/******************************************************************
*

Table of Contents

Other manuals for Keysight Technologies N5172B EXG

Related product manuals