PN PIO-TEST ORG 0EB00H ; START: RST 020H DB 2 DB 'Befehls' DB 'kanal :' DB 0A0H RST 020H DB 16 LD DE,(016H) RST 020H DB 3 LD C,L LD A,15 OUT A RST 020H DB 2 DB 'Daten' DB 'kanal :' DB 0A0H RST 020H DB 16 LD DE,(016H) RST 020H DB 3 LD C,L PUSH BC RST 020H DB 2 DB 'Zeit (0' DB '.1 s) :' DB 0A0H RST 020H DB 16 LD DE,(016H) RST 020H DB 3 LD A,L OR A JRNZ ZOK-# INC A ZOK: LD (ZEIT),A POP BC LOOP: LD HL,PIO LD B,8 LNB: PUSH BC LD B,9 LD A,M LBY: OUT A PUSH AF CALL PAU RST 020H DB 4 CMP 3 JPZ 038H POP AF RLCA DJNZ LBY-# INC HL POP BC DJNZ LNB-# JR LOOP-# PAU: LD A,(ZEIT) PUSH BC LD B,A PA2: LD DE,01DFDH WAIT: DEC DE LD A,D OR E JRNZ WAIT-# DJNZ PA2-# POP BC RET PIO: DB 1,3,7,15,31 DB 63,127,170 ZEIT: DB 0 END ; END