HP E1459A User Manual
Page 32
Using the HP E1459A Module
31
/*
Send the Self Test Command */
errStatus = viQueryf (E1459, "*TST?\n","%t",selftst_string);
if (VI_SUCCESS > errStatus){
printf("ERROR: viQueryf() returned 0x%x\n",errStatus);
return errStatus;}
printf("Self Test Result is %s\n",selftst_string);
/*
Query the ID string */
errStatus = viQueryf (E1459, "*IDN?\n","%t",id_string);
if (VI_SUCCESS > errStatus){
printf("ERROR: viQueryf() returned 0x%x\n",errStatus);
return errStatus;}
printf("IDN? returned %s\n",id_string);
/*
Close Sessions */
errStatus = viClose (E1459);
if (VI_SUCCESS > errStatus){
printf("ERROR: viClose() returned 0x%x\n",errStatus);
return 0;}
errStatusviClose (viRM);
if (VI_SUCCESS > errStatus){
printf("ERROR: viClose() returned 0x%x\n",errStatus);
return 0;}
}
/* End of main program */
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com