I didn't have many books, but I did have the BBC Advanced User Guide. That's the one with all those VDU codes and ∗FX commands.
Near the back there was a two page table containing a dense opcode map (the byte values) of the 6502, its mnemonics, and a tiny notation hinting what they might do.
I've just looked it up. It's the "old" book of that name, not the "new" one. See pages 502-503 of this scan: http://bbc.nvg.org/doc/BBCUserGuide-1.00.pdf Poorly scanned, but I recognise the table.
I stared at that table, intrigued, not really knowing what it was, until I started guessing what the mnemonics stood for. Gradually it made sense - after months!
Eventually I was able to guess enough to write 6502 inside BBC Basic, and some time after that I was able to disassemble binaries in 6502 and Z80 (I had a Z80 second processor), and eventually graduated to hacking games to modify them, give them infinite lives, change the keys, things like that. No doubt there was the occasional bit of assembly language in magazine listings to provide a guide to the syntax.
I don't remember having a 6502 disassembler, but I don't remember writing one either. I did receive a lot of games and utilities so I might have received a disassembler too. Hacking games that don't want to be hacked required a fair amount of dedication though, so I might have written one among the other tools needed for hacking; I don't remember.
My favourite BBC Micro hacks were:
- Poking the ULA with a non-standard palette bit pattern, allowing me to produce a 7-colour mode in high resolution (contradicting the received wisdom about what was possible to pack into the pixel bytes), and similar colour graphics quality to a ZX Spectrum. I ported a game from the Spectrum using this technique, but never published it.
- Pixel-smooth vertical scrolling by poking the CRTC on timed interrupts to modify the character height dynamically, so as to squash a row at the top and expand a row at the bottom to shift the image with pixel precision (contradicting the received wisdom that the CRTC could only scroll character cells).
- "Super mode 7", running the Teletext mode with the pixel clock set to double frequency like in mode 0. This caused the Teletext character generator to process 80 characters per line instead of 40. But instead of showing 80 characters, it showed every alternate character, while still updating the colours or other attributes from the hidden characters. This allowed clean coloured text to be displayed without gaps between different colours as Teletext normally required. Proper syntax highlighting :-)
- Mixing graphics and Teletext on different rows using timed interrupts, so as to render something like a text editor with pixel graphics in between blocks of text. This is a variation of the technique used by Elite to show a colourful status area with a higher-resolution main 3d area.
- Modulating the volume on the sound channel at high speed, to turn the sound chip into a DAC, and therefore any audio waveform we wanted.
I miss those fun days, where we could prod and poke at things and all sorts of useful magic happened.
These are some good hacks and tricks!
The good news is that these fun days are still upon us. I'm a member of the Bitshifters collective: https://bitshifters.github.io/
If only there had been an internet then, rather than just me with my books and a few years to spare :-) I guess most of us were like that at the time.
I see the 6845 still has surprises yet. Now you've made me read the Wikipedia article on it, and I learned something new, that it can be tricked into reloading the display address in the middle of a frame. If only I'd figured that out that back in the day, that would have been very handy!
I wish there was an internet back then too, one that was fast, had a good search engine or directory ... and was only online for 2 hours a day for research purposes. A 24x7x365 internet would have gotten in the way of my tinkering which was mainly driven by boredom.
We had a classroom full of networked BBC Micros in high school. I remember that the teacher had the big one with the floppy drives (BBC Master System?) which acted as a fileserver for the smaller beebs with less RAM.
One of the students in the upper year levels gave a friend and I some POKE style commands that could be used to remotely reset the fileserver. We got immense joy out of resetting the fileserver when the teacher had his back turned away from us since it would prevent disk access for the entire class.
We would then chuckle to ourselves quietly while all the other students complained to the teacher that they couldn't load/save files over the network for a minute or two. The poor teacher became more and more exasperated, but never understood or figured out what was going on. This was very funny to my friend and I, being the immature 13 year olds that we were.
We had a classroom like yours, with BBC Micros and special BBC fileserver computer of some kind, with the important school stuff on it.
My fun command was a one-liner that repeatedly remote-PEEKed the server's keyboard buffer memory and displayed it on one of the classroom computers.
One day, when the teacher went over to the special server corner to type in the server password, I quickly entered this one-liner into a computer in the main area, and lo as teacher typed the password thinking it was all very private and special, it appeared key by key on my screen. Of course all the children were watching my screen, "hey watch this...".
Yes, the folly of youth :-)
That got me permanently banned from the computer room. I didn't expect that, I thought we'd all laugh it off and tell me not to do it again. Ironically, knowing more about computers than anyone else in the school, I wasn't allowed to study computers at school or use them.
Still won a programming competition there anyway, for making a pretty demo to tell a story :-)
Oh you too! My ban came from discovering where the station number (the 8 bit number uniquely identifying each BBC Micro on the Econet network - like a MAC address) was stored in memory. I did this by the obvious technique of searching memory for this number on several machines and comparing the addresses - it was address 3361. Then I found that by changing this you could impersonate the credentials of the person logged in to the other machine, although it worked better if you also had a co-conspirator turn off their machine at the same time.
The other hack which possibly contributed was writing a kind of "broadcast NOTIFY" that sent your keystrokes to all of the other machines on the network, allowing the user to remote control all the things. The service manual I just found online says that *NOTIFY is a dangerous command which the operator might want to remove - but in fact there was a system call which did the same thing and I used that instead.
I recall the hex address being D22 (so 3362) although it's been 30-cough-something years so I could be misremembering.
I built a full-on remote hacking utility that got to the point where it would download the remote victim's RAM, upload the infamous laugh sound, play it, then restore the RAM so the victim was - usually - back to before they got freaked out.
A small group of us built a multi-screen text scrolling and image display sequencing tool for the various school open days. I still recall the nervous look on the teacher's face as we deconstructed the computer lab to get all the Microvitec Cub's lined up! Those were fun times.
I got banned a little later (in the 90s) for writing a QBasic "chat app" that worked across the school network by way of a public NetWare shared drive. I didn't even take IT as a GCSE option because having arguments with teachers who thought a PC's base unit was "a CPU" didn't seem worth it, and my disdain for "IT" (as opposed to software engineering) unfairly remains to this day :-D
Bizarrely, at University in the UK, we had a student TV station and it used a BBC Micro for caption generation. My ZX Spectrum had a microdrive attached (the new hotness, flaky as hell but much much faster than loading from tape) I remember writing something that let the Spectrum act as a fileserver for the BBC micro over its serial port. Good times.
Similar story, just replace the BBC with another national project, the ABC 800 Z80 computer. I would change the source code of programming examples on “the Winchester” which was a huge hard drive on a cart connected to the teachers master computer.
People like me never have to poke around to find anything. Everything is either answered by a Youtube video or Stackoverflow, but it only gives a surface level understanding of everything, and we become clueless when something breaks.
The computer manuals in those days were excellent, especially the more advanced manuals.
They included circuit diagrams, data sheets for individual chips, just about every detail of how the system worked.
You'd still have to figure out a lot just to understand those reference manuals, and guess a lot, especially with no internet and no good library (my local library did not have books like this!).
I only had a very small number of books. But I did have the Advanced Guide. Having so much detail available in reference manuals was great for a young mind!
Also when I was like 7-8 (edit: previously wrote 10) I was given the Ladybird book for young children: "The Computer (How It Works)".[1] A tiny book. In retrospect I learned a lot of great grounding from that book even though I hadn't yet seen an actual computer. I guess it gave me an appreciation for the video games I played with on show in the supermarket, and the pictures of minicomputers and microcomputers I saw in hand-me-down computer magazines.
I'm occasionally asked, by people who find learning this stuff frustrating, where did I learn about logic circuits, where did I learn about assembly, where did I learn about RAM and ROM, etc. and for a long time I couldn't put my finger on it. I think it started with being exposed to that book and some early computer magazines at a young age, without even seeing or touching a real machine for a year or so afterwards.
I don’t remember when the last time I worked with a computer that even had a manual as such. I think it was my TI-99/4A, but it could have been the Tandy 1000HX.
Edit: wrongola! Turns out, the last machine I worked with that had a real manual was either a MicroVAX, or a PDP-11, both of which I used in college. Writing ASM for the PDP-11 was great! I just wish I was better at program then, lol. :)
> "Cover: Schematics for a 5V, 3A regulated power supply and a
1K x 8 read/write memory block. The power supply and three
such memory blocks can be added to the basic KIM-l microcomputer
to provide the 4K RAM required by this assembler. Parts are
available from Jameco Electronics."
Cool! That's pretty impressive. The 6502 is a beautifully simple processor. I recently started learning about it from Ben Eaters youtube series[1], and have a printout of the W65C02S (a more modern variant with optional 16bit support, but full backwards compatibility) datasheet beside my bed[1]. Tables 5-1, 5-2 and 6-4 might bring back some memories :)
> Pixel-smooth vertical scrolling by poking the CRTC on timed interrupts to modify the character height dynamically, so as to squash a row at the top and expand a row at the bottom to shift the image with pixel precision (contradicting the received wisdom that the CRTC could only scroll character cells).
How frustrating that even today that is very hard for quite a few environments. I am working on something that requires a very smooth horizontal scroll of a large canvas in the browser. So far jagged edges are my lot, most tricks only work in a small subset of the cases.
Ah, browsers. Vsync timing is basically impossible to guarantee with them. It's dependent on which browser, browser version, which OS, and I suspect even which graphics card and driver (because OpenGL is affected by those).
Thank you for that, I wasn't aware that site existed, already confirmed some of my worst suspicions. What we are working on is a music application that horizontally scrolls a score drawn on a canvas. Smooth scrolling is quite essential to be able to keep to the beat (see: https://news.ycombinator.com/item?id=24615125)
Near the back there was a two page table containing a dense opcode map (the byte values) of the 6502, its mnemonics, and a tiny notation hinting what they might do.
I've just looked it up. It's the "old" book of that name, not the "new" one. See pages 502-503 of this scan: http://bbc.nvg.org/doc/BBCUserGuide-1.00.pdf Poorly scanned, but I recognise the table.
I stared at that table, intrigued, not really knowing what it was, until I started guessing what the mnemonics stood for. Gradually it made sense - after months!
Eventually I was able to guess enough to write 6502 inside BBC Basic, and some time after that I was able to disassemble binaries in 6502 and Z80 (I had a Z80 second processor), and eventually graduated to hacking games to modify them, give them infinite lives, change the keys, things like that. No doubt there was the occasional bit of assembly language in magazine listings to provide a guide to the syntax.
I don't remember having a 6502 disassembler, but I don't remember writing one either. I did receive a lot of games and utilities so I might have received a disassembler too. Hacking games that don't want to be hacked required a fair amount of dedication though, so I might have written one among the other tools needed for hacking; I don't remember.
My favourite BBC Micro hacks were:
- Poking the ULA with a non-standard palette bit pattern, allowing me to produce a 7-colour mode in high resolution (contradicting the received wisdom about what was possible to pack into the pixel bytes), and similar colour graphics quality to a ZX Spectrum. I ported a game from the Spectrum using this technique, but never published it.
- Pixel-smooth vertical scrolling by poking the CRTC on timed interrupts to modify the character height dynamically, so as to squash a row at the top and expand a row at the bottom to shift the image with pixel precision (contradicting the received wisdom that the CRTC could only scroll character cells).
- "Super mode 7", running the Teletext mode with the pixel clock set to double frequency like in mode 0. This caused the Teletext character generator to process 80 characters per line instead of 40. But instead of showing 80 characters, it showed every alternate character, while still updating the colours or other attributes from the hidden characters. This allowed clean coloured text to be displayed without gaps between different colours as Teletext normally required. Proper syntax highlighting :-)
- Mixing graphics and Teletext on different rows using timed interrupts, so as to render something like a text editor with pixel graphics in between blocks of text. This is a variation of the technique used by Elite to show a colourful status area with a higher-resolution main 3d area.
- Modulating the volume on the sound channel at high speed, to turn the sound chip into a DAC, and therefore any audio waveform we wanted.
I miss those fun days, where we could prod and poke at things and all sorts of useful magic happened.