Agilent Technologies FS2010 Manual de servicio Pagina 275

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 396
  • Tabla de contenidos
  • SOLUCIÓN DE PROBLEMAS
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 274
Agilent Signal Generators Programming Guide 267
Creating and Downloading Waveform Files
Programming Examples
// as needed.
//**********************************************************************************
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include "visa.h"
//
// IMPORTANT:
// Configure the following three lines correctly before compiling and running
char* instOpenString ="TCPIP0::xxx.xxx.xxx.xxx::INSTR"; // your instrument's IP address
const char* localSrcFile = "\\Files\\IQ_DataC";
const char* instDestFile = "/USER/WAVEFORM/IQ_DataC";
const int BUFFER_SIZE = 100*1024;// Size of the copy buffer
int main(int argc, char* argv[])
{
ViSession defaultRM, vi;
ViStatus status = 0;
status = viOpenDefaultRM(&defaultRM);// Open the default resource manager
// TO DO: Error handling here
status = viOpen(defaultRM, instOpenString, VI_NULL, VI_NULL, &vi);
if (status)// If any errors then display the error and exit the program
{
fprintf(stderr, "viOpen failed (%s)\n", instOpenString);
return -1;
}
FILE* file = fopen(localSrcFile, "rb");// Open local source file for binary reading
if (!file) // If any errors display the error and exit the program
{
fprintf(stderr, "Could not open file: %s\n", localSrcFile);
Vista de pagina 274
1 2 ... 270 271 272 273 274 275 276 277 278 279 280 ... 395 396

Comentarios a estos manuales

Sin comentarios