HP 9000 Series 300 Tutorials Manual page 113

Device i/o and user interfacing hp-ux concepts and tutorials
Hide thumbs Also See for HP 9000 Series 300:
Table of Contents

Advertisement

The following code segment prints a message indicating whether the interface is
System Controller:
#include <dvio.h>
#include <fcntl.h>
#include <errno.h>
mainO
{
}
int eid. status;
if ((eid
=
open("/dev/raw_hpib". O_RDWR»
==
-1) {
printf(" open failed. errno
=
%d\n". errno);
exit(2);
}
io_reset(eid);
io_timeout_ctl(eid. 1000000);
if ((status
=
hpib_bus_status(eid. SYS_CONT_STATUS»
==
-1)
printf("Error occurred during bus status subroutine\n");
else if (status
==
1)
printf("Interface is the System Controller\n");
else
printf("Interface is not the System Controller\n");
Controlling the HP-IB Interface
3-53

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Hp 9000 series 800

Table of Contents