ASCII Hex Equivalents

Program to print ASCII HEX equivalent of any keyboard character

AttachmentSize
ascii.txt181 bytes

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Error in code

There is a mistake in the code in ascii.txt - it seems is reading $D811 when it is wanting to read KBDCR - ie. $D011. There is also an extraneous line at the top of the file (09f0: 20).

I think the program should be:

<br />
0700: A9 8D     ; LDA $8D   == newline char<br />
0702: 20 EF FF  ; JSR $FFEF == ECHO<br />
0705: AD 11 D0  ; LDA $D011 == KBDCR<br />
0708: 10 FB     ; BPL -5    == 0705<br />
070A: AD 10 D0  ; LDA $D010 == KBD<br />
070D: AA        ; TAX<br />
070E: 20 EF FF  ; JSR $FFEF == ECHO<br />
0711: A9 A0     ; LDA $A0   == space char<br />
0713: 20 EF FF  ; JSR $FFEF == ECHO<br />
0716: 8A        ; TXA<br />
0717: 20 DC FF  ; JSR $FFDC == PRBYTE<br />
071A: 4C 00 07  ; JMP $0700 == start<br />

PS: sorry for the formatting - seems that applefritter doesn't honour the code tags.