Provided by: libgpib-doc_4.3.7-5_all bug

NAME

       ibevent - get events from event queue (board)

SYNOPSIS

       #include <gpib/ib.h>

       int ibevent(int ud, short *event);

DESCRIPTION

       ibevent() is used to obtain the oldest event stored in the event queue of the board specified by the
       board descriptor ud. The EVENT bit of ibsta indicates that the event queue contains 1 or more events. An
       event may be a clear command, a trigger command, or reception of an interface clear. The type of event is
       stored in the location specified by event and may be set to any of the following values:

       Table 8. events
       ┌─────────────┬───────┬──────────────────────────────┐
       │ constantvaluedescription                  │
       ├─────────────┼───────┼──────────────────────────────┤
       │ EventNone   │ 0     │ The board's event queue is   │
       │             │       │ empty                        │
       ├─────────────┼───────┼──────────────────────────────┤
       │ EventDevTrg │ 1     │ The board has received a     │
       │             │       │ trigger command from the     │
       │             │       │ controller-in-charge.        │
       ├─────────────┼───────┼──────────────────────────────┤
       │ EventDevClr │ 2     │ The board has received a     │
       │             │       │ clear command from the       │
       │             │       │ controller-in-charge.        │
       ├─────────────┼───────┼──────────────────────────────┤
       │ EventIFC    │ 3     │ The board has received an    │
       │             │       │ interface clear from the     │
       │             │       │ system controller.           │
       │             │       │      Note, some models of    │
       │             │       │ GPIB interface board lack    │
       │             │       │ the ability to report        │
       │             │       │ interface      clear events. │
       └─────────────┴───────┴──────────────────────────────┘

       The event queue is disabled by default. It may be enabled by a call to ibconfig(). Each interface board
       has a single event queue which is shared across all processes and threads. So, only one process can
       retrieve any given event from the queue. Also, the queue is of finite size so events may be lost
       (ibevent() will return an error) if it is neglected too long.

RETURN VALUE

       The value of ibsta is returned.

COPYRIGHT

       Copyright © 2003-2006, 2008 Frank Mori Hess

linux-gpib 4.3.7                                   11/28/2025                                         IBEVENT(3)