Manual ME-5001
Rev. 1.1E
Meilhaus Electronic
Page 27
Programming
4.2
Interrupt Operation
On the ME-5001 you can monitor the bit-pattern of a subdevice
configured as an input for changes in one or more masked bits. As soon
as the first edge that meets the trigger condition arrives, an interrupt is
generated and passed directly to the PC.
The programming the digital input/output is carried out in the single
operation mode. The subdevice must be of type ME_TYPE_DIO. The
interrupt handling is done by the
meIOIrq…
functions.
Diagram 9: Interrupt options
Please observe the ME-iDS manual and the ME-iDS help file (*.chm) for
the
procedure
. You can open both of these documents through the
"ME-iDS Control Center“ or through the Windows Start menu.
4.2.1
Bit-pattern Change
In the bit-pattern change mode, one or more bits that are to be monito-
red for a change of state can be defined (masked). A 32-bit wide
argument per subdevice contains the mask. For each input pin both one
bit for rising edge and one bit for falling edge are available. If the state of
at least one bit masked with a "1" changes (0
→
1 or 1
→
0), an interrupt
is issued (see diagram 10 on page 28).
ME-5001
4
IRQ to PC
OR
DIO_0..7
Bit-pattern change
8
DIO_8..15
Bit-pattern change
8
DIO_16..23
Bit-pattern change
8
DIO_24..31
Bit-pattern change
8
DIO_32..39
Bit-pattern change
8
DIO_40..47
Bit-pattern change
8