Agilent Technologies 34420A User Manual page 234

Nano volt/micro ohm meter
Table of Contents

Advertisement

Chapter 6 Application Programs
C Language Programs
... continued
/**************************************************************************/
void meter_meas(void)
{
/* Configure the meter for 4-wire ohms measurements on channel 1
(default channel). The measurement is made on the 10 ohm range with
the least resolution. */
float ohm_rdg;
IOOUTPUTS(ADDR, "MEAS:FRES? 10, MAX", 18);
IOENTER(ADDR, &ohm_rdg);
printf("Reading: %f\n\n", ohm_rdg);
/* Call the function to check for errors */
check_error("meter_meas");
}
/**************************************************************************/
void check_error(char *func_name)
{
/* Read error queue to determine if errors have occurred */
char message[80];
int length = 80;
IOOUTPUTS(ADDR, "SYST:ERR?", 9);
IOENTERS(ADDR, message, &length);
while (atoi(message) != 0)
{
printf("Error %s in function %s\n\n", message, func_name);
IOOUTPUTS(ADDR, "SYST:ERR?", 9);
IOENTERS(ADDR, message, &length);
}
}
234
/* Configure channel 1 */
/* Enter reading */
/* Display reading */
/* Read the error queue */
/* Enter error string */
/* Loop until all errors are read */

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents