U, I, P Measurement Over Rs-232 Interface Without Visa Library - Fluke Norma 4000 User Manual

Guide for remote control for power analyzer
Hide thumbs Also See for Norma 4000:
Table of Contents

Advertisement

/* SYNC source = voltage phase 1: */
socket_puts(s,"SYNC:SOUR VOLT1");
/* Set voltage range on voltage channel 1 to 300 V: */
socket_puts(s,"VOLT1:RANG 300.0");
/* Set current channel 1 to autorange: */
socket_puts(s,"CURR1:RANG:AUTO ON");
/* Set averaging time to 1 second: */
socket_puts(s,"APER 1.0");
/* Select U, I, P measurement: */
socket_puts(s,"FUNC \"VOLT1\",\"CURR1\",\"POW1:ACT\"");
/* Run continuous measurements: */
socket_puts(s,"INIT:CONT ON");
Delay(2.0);
socket_puts(s,"DATA?");
memset(buffer,0,sizeof(buffer));
socket_gets(s,buffer);
puts(buffer);
socket_cleanup();
return 0;
}
/****************************************************************************
**/
U, I, P Measurement over RS-232 Interface without VISA
Library
This example will configure the instrument to measure power, voltage and current on
three-phase system 3 x 400V/50Hz and reads the measurements.
/*
* MEASURE U, I, P (wait synchronously)
*
* This example will configure the instrument to measure power, voltage
* and current on three-phase system 3 x 400V/50Hz and reads the measurements.
*
* The time it will take to finish the measurement is 1 s (averaging time).
* The query DATA? does not wait for the measurement to be completed, so it
* would return whatever values are available at a moment. The delay of 2
* seconds gives the instrument enough time to finish the measurement before
* reading data.
*/
#if WIN32
#define WIN 1
#endif
#if WIN
#if !defined(_MFC_VER)
#include <windows.h>

U, I, P Measurement over RS-232 Interface without VISA Library

/* Wait 2 seconds */
/* Query the measurement */
/* Clear buffer */
/* Read values */
/* Print the value on the screen */
/* !MFC (!<afx.h>) */
Programming Examples
6
6-19

Advertisement

Table of Contents
loading

This manual is also suitable for:

Norma 5000

Table of Contents