You are here : assembly8086IN

IN - 8086

Input from port into AL or AX.
Second operand is a port number. If required to access port number over 255 - DX register should be used. 


Syntax

IN AL, im.byte
IN AL, DX
IN AX, im.byte
IN AX, DX


Example

IN AX, 4  ; get status of traffic lights.
IN AL, 7  ; get status of stepper-motor.

MOV DX,0A400h	;port number in dx
IN AX,DX


Output / Return Value


Limitations


Alternatives / See Also


Reference