CODE SEGMENT
ASSUME CS:CODE,DS:CODE,ES:CODE,SS:CODE ;

PPIC_C EQU 1FH	
PPIC EQU 1DH
PPIB EQU 1BH
PPIA EQU 19H

	ORG 1000H
	MOV AL,10000000B
	OUT PPIC_C,AL
	
	MOV AL,11111111B
	OUT PPIA,AL
	
	MOV AL,00000000B
	OUT PPIC,AL
	
L1: 	MOV SI,OFFSET ROT	
L2:		MOV AL,BYTE PTR CS:[SI]
		CMP AL,0FFH
		JZ L1
		OUT PPIB,AL
		INC SI
		CALL TIMER
		JMP L2
		

TIMER:	MOV CX,1
TIMER2:	PUSH CX
		MOV CX,0H
TIMER1:	NOP
		NOP
		NOP
		NOP
		LOOP TIMER1
		POP CX
		LOOP TIMER2
		RET

ROT:	DB	11101110B
		DB	10111011B
		DB	11011101B
		DB	01110111B
		DB	0FFH
		
CODE ENDS
END