Agilent Technologies Infiniium 90000 Series Programmer's Manual page 1116

Oscilloscopes
Hide thumbs Also See for Infiniium 90000 Series:
Table of Contents

Advertisement

38
Sample Programs
}
/* Send a command to the instrument.
* --------------------------------------------------------------- */
void do_command(command)
char *command;
{
}
/* Command with IEEE definite-length block.
* --------------------------------------------------------------- */
int do_command_ieeeblock(command, num_bytes)
char *command;
int num_bytes;
{
}
/* Query for a string result.
* --------------------------------------------------------------- */
void do_query_string(query)
char *query;
{
1116
/* Output waveform data in CSV format. */
for (i = 0; i < num_values - 1; i++)
{
/* Write time value, voltage value. */
fprintf(fp, "%9f, %6f\n",
x_origin + ((float)i * x_increment),
((float)ieeeblock_data_words[i] * y_increment) + y_origin);
}
/* Close output file. */
fclose(fp);
printf("Waveform format WORD data written to ");
printf("c:\\scope\\data\\waveform_data.csv.\n");
char message[80];
strcpy(message, command);
strcat(message, "\n");
iprintf(id, message);
check_instrument_errors();
char message[80];
int data_length;
strcpy(message, command);
strcat(message, " #8%08d");
iprintf(id, message, num_bytes);
ifwrite(id, ieeeblock_data, num_bytes, 1, &data_length);
check_instrument_errors();
return(data_length);
char message[80];
strcpy(message, query);
Agilent Infiniium 90000 Series Oscilloscopes Programmer's Reference

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents