利用74LS244作为输入接口连接8个开关K0~K7,用74LS273作为输出接口连接8个LED.

2024-12-16 14:22:43
推荐回答(2个)
回答1:

慢慢弄呗

回答2:

START:
MOV DX,01F2H IN AL ,DX CMP AL ,0 JZ ZREO TEST AL , 0F0H JZ HIGH TEST AL ,0FH JZ LOWW JMP START
ZERO: MOV DX,01F3H MOV AL, 0FFH OUT DX, AL
HIGH: MOV DX,01F3H MOV AL, 0F0H OUT DX, AL
LOWW: MOV DX,01F3H MOV AL, 0FH OUT DX, AL