Function 41h    Wait On External Event                          (Convertible) 

entry AH 41h

AL condition type

bits 0-2: condition to wait for

0 any external event

1 compare and return if equal

2 compare and return if not equal

3 test and return if not zero

4 test and return if zero

bit 3: reserved

bit 4: 1=port address, 0=user byte

bits 5-7: reserved

BH condition compare or mask value

condition codes:

0 any external event

1 compare and return if equal

2 compare and return if not equal

3 test and return if not zero

4 test and return if zero

BL timeout value times 55 milliseconds

0 if no time limit

DX I/O port address (if AL bit 4 = 1)

ES:DI pointer to user byte (if AL bit 4 = 0)