Last active
November 28, 2017 14:59
-
-
Save digarok/0ea5e5073c816be6348b6322201e2427 to your computer and use it in GitHub Desktop.
prints out the base addresses of the apple ii hi res screen
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
addrs = [0x2000, 0x2028, 0x2050] # 3) 'top','middle','bottom' base addresses | |
for addr in addrs: | |
for b in range(0, 8): # 2) and those 8-line bars are striped each 0x80 bytes | |
lineaddr = addr | |
for l in range(0, 8): # 1) 8 consecutive lines are spaced by 0x400 bytes | |
print(hex(lineaddr)) | |
lineaddr = lineaddr + 0x400 | |
addr = addr + 0x80 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
this makes sense to me, I never saw it this simply before