Jump to content
IGNORED

Did not know this about Wozniak


gnusto

Recommended Posts

If you happen to be a ycombinator reader, yes coming from there. But in an article linked from there earlier today I realized that Steve Wozniak wrote the initial Apple I and Apple II ROMs by hand. He wrote the opcodes out, and then translated the opcodes into machine code by reading through each line and typing in the binary, because he couldn't afford an interpreter program. I wonder how much this contributed to his oft-sited efficiency in 6502. When you are writing it all out on paper or whatnot, you would have a lot of incentive to be as brief as possible in terms of lines of code.

  • Like 2
  • Thanks 1
Link to comment
Share on other sites

Yep, that was common back then.
Compilers and assemblers were hard to come by, expensive or ran on expensive development systems.
So many hackers just did it by hand.

 

I was never able to memorise all the opcodes myself but I know others who could disassemble a ROM just by eyeballing it.

As in, he could look at a hex dump of a ROM, tell you what instructions were being called and (after a bit of thinking) tell you that it was a 16 bit multiple routine.

  • Like 1
Link to comment
Share on other sites

I used to know most of the common ones off by heart - sort of easy, the Ax are mostly loads, 8x mostly stores, all the branches have 0 as the second nybble.  60/20 for JSR/RTS, 4C for JMP.

 

I've done some hand assembly in that fashion but not really more than a few dozen instructions.  The hardest part IMO is dealing with the branches, the rest isn't too hard.

Edited by Rybags
Link to comment
Share on other sites

I actually did hand assembly (well, text file assembly) along with a hex editor for many of the recent Joy2B hacks.  It's still a useful technique if you want to replace small amounts of code in an existing binary, since you'll be counting opcode sizes to make sure everything fits.

 

Having to recount branches by hand is painful, as @Rybags said.  With that said, it can still easier than dealing with disassemblies that involve branches, JSRs and JMPs to locations that are dynamically remapped on load, and are thus near-impossible to follow without the assistance of a debugger...

Link to comment
Share on other sites

15 hours ago, gnusto said:

If you happen to be a ycombinator reader, yes coming from there. But in an article linked from there earlier today I realized that Steve Wozniak wrote the initial Apple I and Apple II ROMs by hand. He wrote the opcodes out, and then translated the opcodes into machine code by reading through each line and typing in the binary, because he couldn't afford an interpreter program. I wonder how much this contributed to his oft-sited efficiency in 6502. When you are writing it all out on paper or whatnot, you would have a lot of incentive to be as brief as possible in terms of lines of code.

I did this back when I was too cheap to splurge for a decent assembler.  

 

It was a pain in the ass to debug! so props to him for making it work!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...