HP (Hewlett-Packard) E1432A Graphics Tablet User Manual


 
HP E1432A Interrupt Handling
To make the HP E1432A module do the interrupt, both a mask and a VME
Interrupt line must be specified, by calling e1432_set_interrupt_mask and
e1432_set_interrupt_priority respectively. Once the mask and line have
been set, and an interrupt occurs, the cause of the interrupt can be
obtained by reading the E1432_IRQ_STATUS_REG register (using
e1432_read_register). The bit positions of the interrupt mask and status
registers match so the defines can be used to set and check IRQ bits.
Once it has done this interrupt, the module will not do any more VME
interrupts until re-enabled with e1432_reenable_interrupt. Normally, the
last thing a host computers interrupt handler should do is call
e1432_reenable_interrupt.
Events that would have caused an interrupt, but which are blocked because
e1432_reenable_interrupt has not yet been called, will be saved. After
e1432_reenable_interrupt is called, these saved events will cause an
interrupt, so that there is no way for the host to miss an interrupt.
However, the module will only do one VME interrupt for all of the saved
events, so that the host computer will not get flooded with too many
interrupts.
For things like E1432_IRQ_BLOCK_READY, which are not events but are
actually states, the module will do an interrupt after
e1432_reenable_interrupt only if the state is still present. This allows the
host computers interrupt handler to potentially read multiple scans from an
HP E1432A module, and not get flooded with block ready interrupts after
the fact.
Host Interrupt Setup
The HP E1432A Host Interface library normally uses the SICL I/O library to
communicate with the HP 1432A hardware. To receive VME interrupts, a
variety of SICL setup calls must be made. The examples directory of the
HP E1432A distribution contains an example of setting up SICL to receive
interrupts from an HP E1432A module.
This is a summary of how to set up SICL to receive an HP E1432A
interrupt:
q Query SICL for which VME interrupt lines are available, using ivxibusstatus and
ivxirminfo.
q Tell the HP E1432A module to use the VME interrupt line found in step one,
using e1432_set_interrupt_priority.
q Set up an interrupt handler routine, using ionintr and isetintr. The interrupt
handler routine will get called when the interrupt occurs.
q Set up interrupt mask in the HP E1432A module, using
e1432_set_interrupt_mask.
HP E1432A User's Guide
The C-Language Host Interface Library
4-27