3 ms·
Smart American kids my age had C64s and Apple IIs. We all entered 6502 machine code into DATA statements in BASIC programs. Yeah, but (similarly to the 'enviro
by Lagged2Death 13y ago
Smart American kids my age had C64s and Apple IIs. We all entered 6502 machine code into DATA statements in BASIC programs.
Yeah, but (similarly to the 'environment' that is the subject of the post) those DATA statements contained the output of some sort of tool. Nobody wrote machine code this way.
- vidarh 13y ago> Nobody wrote machine code this way. I'd be careful about that claim. It was not that unusual to "hand assemble" programs, as it was not that unusual to remember the codes. The 6502 has less than 60 documented opcodes (and quite a few undocumented ones with various weird but in some cases somewhat usable behaviour) and only a few addressing modes, and all opcodes are single byte, so knowing most or even all of them doesn't take that much exposure. Some of those values are so ingrained that I still remember the decimal values, despite the fact that the moment I started using tools to work with assembly on the C64, it was all hex e.g. 169 decimal is "load accumulator immediate" (LDA #[8 bit operand) on the 6502. (or A9 in hex)
- Lagged2Death 13y agoIt was not that unusual to "hand assemble" programs, as it was not that unusual to remember the codes. Yeah, I grew up with 6502s, too. You'll think I'm weaseling out here, but "hand assembly" isn't what I was talking about. I feel the original comment implies that some people, intending to write significant machine code, sat down with BASIC and started typing in DATA statements. And I don't think that happened to any significant degree. As in the case of the "programming environment" under discussion, machine language routines force-fed into BASIC DATA statements were the output of another tool or process -- whether assembled by hand or by machine -- and were an intermediate form that was never intended to be editable.
- cabalamat 13y ago> Nobody wrote machine code this way. Not true. I personally did in Z80.
- gamache 13y agoI hand-assembled machine code for the 6502 for a couple of years in my youth. I was 12, couldn't afford an assembler, and my school wouldn't pay for one. I wasn't exactly writing VisiCalc, so a notebook and a pencil were plenty good enough.
- mgkimsal 13y agoChiming in with the others - I did. I didn't do a lot with it, but I did. Didn't even know what an assembler was - I just though everyone did it by hand. I'd read some code that showed JMP $5000 and LDY 32 and figured people just knew that JMP was a particular byte, and LDY was a different one, and you just did it. While it did seem cumbersome, I didn't have much else to compare it to. I wrote some small screen animation utilities (ASCII screencast recorders, essentially) and later some C128 'enhanced graphic mode' stuff, moving a pointer with a mouse. I think by that point I'd learned the C128 had a small assembler tool built in, so that made things easier.
- cunac 13y agoactually I wrote 6502 and Z80 with opcodes also if you look up for http://en.wikipedia.org/wiki/KIM-1 http://en.wikipedia.org/wiki/KIM-1 you will see how I entered code, all with calculating jumps and branches in head. It is actually fun exercise
- jloughry 13y agoI can't express how startled I was when one lone teacher (thanks, Professor Nutt!) taught me how simple an assembler was to write, that the inner workings of a CPU can be understood by mortals, and bootstrapping a monitor and language interpreter atop bare metal is a thing you can do.
- CmdrKrool 13y agoYou've been contradicted a number of times now so sorry to pile on but here's a nice webpage about a classic videogame (in the UK in the 80s, at least) with an example halfway down the page of (literally) hand-written/assembled code: http://sandywhite.co.uk/fun/ants/ http://sandywhite.co.uk/fun/ants/