Using Events And Handlers; Events And Attributes; Event Notification - Agilent Technologies E2094S User Manual

For io libraries suite 15.5
Table of Contents

Advertisement

3
Programming with VISA

Using Events and Handlers

Events and Attributes

NOT E
NOT E
46
This section provides guidelines to using events and handlers,
including:
• Events and Attributes
• Using the Callback Method
• Using the Queuing Method
Events are special occurrences that require attention from your
application. Event types include Service Requests (SRQs), interrupts,
and hardware triggers. Events will not be delivered unless the
appropriate events are enabled.
VISA cannot call back to a Visual Basic function. Thus, you can only
use the queuing mechanism in viEnableEvent. There is no way to
install a VISA event handler in Visual Basic.

Event Notification

There are two ways you can receive notification that an event has
occurred:
• Install an event handler with viInstallHandler, and enable one or
several events with viEnableEvent. If the event was enabled with a
handler, the specified event handler will be called when the specified
event occurs. This is called a callback.
VISA cannot call back to a Visual Basic function. This means that you
can only use the VI_QUEUE mechanism in viEnableEvent. There is
no way to install a VISA event handler in Visual Basic.
• Enable one or several events with viEnableEvent and call the
viWaitOnEvent function. The viWaitOnEvent function will
suspend the program execution until the specified event occurs or the
specified timeout period is reached. This is called queuing.
Agilent VISA User's Guide

Advertisement

Table of Contents
loading

Table of Contents