The IN instruction is used to move data from an I/O port into the accumulator.
The OUT instruction is used to move data from the accumulator to an I/Oport.
The IN and OUT instructions are used only on microprocessor, which usea separate address space for interfacing.