My early interest in electronics (1970's) was in stereo and amateur radio, not computers. Remember the line in the movie "Pirates of Silicon Valley" where the executive, puzzled and tapping his pencil on the desk, said slowly, "What would the common man want with a computer?" (They must have had some good laughs making the movie.) Back then, computers were rare, huge, and expensive, and people who worked with them seemed next to God or something.
I've been inactive in amateur radio since 1984, but I've maintained my license only in case I'd want to make my own radar or missile-guidance system to take out an ice-cream truck or something exciting.
I got mildly interested in computers when I wanted to do audio and RF circuit calculations that took thousands of iterations. I got a TI-58c programmable calculator in Dec '81. The next year, I took a class on 6502 which used AIM 65 computers, and a Fortran IV class which required doing our practice on the school's IBM 360 mainframe computer. You'd transfer your hand-written program onto cards at a big card-punch machine so the dresser-sized card reader could accept it, then rubber-band the cards together with a paper having your account number and put it in a cubby, and come back two hours later for a printout of all the reasons it wouldn't run.
I worked as a repair tech at TEAC in Southern California in '82-83. There were about 120 employees, and only one computer in the building, occupying its own special holy room, off limits to all but two or three people, and all the sales and accounting people had terminals hooked into it. It was only for data processing, not at all for embedded control which would soon become my greatest interest. By then some of the tape recorders I worked on there had microcontrollers (with bugs), although microcontrollers were definitely not ubiquitous yet.
A friend had an HP-41 programmable calculator with powerful (albeit slow) I/O but I didn't initially think I could justify the expense. When I worked in applications engineering in '84-85 at a VHF/UHF power transistor manufacturer, having an ultra-portable hand-held unit to control repetitive processes with the lab equipment became quite attractive, and the HP-41 calculator fit the bill. It could be taken from your desk to your workbench and back, much more easily than laptops (which didn't really exist yet). In 1986 I was the only engineer working at a much smaller company and, having gotten an HP-41 by then, I set up our first automated testing of products with it. The I/O programming on it was much easier than doing it on a PC. People would nearly wet their pants when they saw a hand-held unit controlling a stack of lab test equipment.
There was a ton of wonderful IEEE-488 test equipment to drool over in the thick, hard-bound Hewlett-Packard catalog that came out every year. I couldn't afford it, but it didn't take a genius to see the possibilities with making my own computer and rigging up inexpensive substitutes with A/D and D/A converter ICs, relay outputs, etc.. Soon I wanted microsecond control of the pins, something I couldn't get with the HP-41 or 71 (even programming them in assembly), and I was dreaming of something like my workbench computer. Although my first one (1985) worked, it was far bigger and more complex than it needed to be, and wasn't much good for anything. I did learn a lot about what would be good though.
In 1986, my employer came to me with an idea for a timer to put in an ear cup of an aircraft headset to beep you when it was time to switch fuel tanks, arrive at a waypoint, etc.. No one had such a product. His idea of how to work it was totally impractical though, and I thought, "If we used a 6502, the capabilities could be vastly expanded without adding much hardware complexity." I was very green at making computers, and at how a project like this ought to be managed, but the boss didn't know any better either, so he set me to work on it. Now it was to go in the intercom (instead of a headset) and to display checklists, hold flight plans, etc.. He frequently came to me asking, "Can we do such-and-such too?" and I'd immediately envision how, and tell him yes. "Feature creep" set in like crazy. Every few days he came to me with a new wish list for Santa Claus, and I obliged. For awhile it even had a very compact cassette drive that the computer could control, and we put data on one track and voice on the other. I designed a tape modem we could make for under a dollar. Someone else was in charge of packaging and mostly killed the product before it was solidly launched, because they made it too labor-intensive to assemble. I learned a ton though.
Of a later set of automated test equipment I set up there, there were initially supposed to be seven sets, so "rack-and-stack" IEEE-488 equipment would then be too expensive, especially if a deal turned sour and one of our Korean suppliers kept our hardware (which did happen later). So since the programming and design time could be amortized over plenty of sets if we made our own, that's what we did. STD bus (which stands for "simple to design," not "standard") was chosen for its low cost and wide range of available boards, and I designed several more custom boards. The computer board used a 6502, and I programmed it in Forth.
I had a couple of false starts on making a nicely packaged workbench computer with an ABS plastic box that could be thrown in the attaché case, then in just one week in 1992, built the original form of the 6502 workbench computer I use now. Every few years, I've added something to it. It has proved incredibly valuable for controlling experiments and processes on the workbench, trying new ICs we would put in products, and programming PIC microcontrollers for several products. It actually has a 65802 now, not 65c02, and I developed my bank-0-only '816 Forth on it.
These are some my articles on this website and my own:
- unsigned division of a 32-bit dividend by a 16-bit divisor, resulting with a 16-bit quotient and a 16-bit remainder. Presented for the 65C02 (with changes for use on 6502) and 65816, with notes of interest to Forth users. Corrects a bug in the public-domain 6502 Forth division.
- unsigned multiplication (on forum), with 16-bit factors and 32-bit result, correcting a bug in the public-domain 6502 Forth multiplication, as the division article above
- Hex-to-decimal base conversion (8- and 16-bit)
- Investigating Interrupts An introduction and discussion on interrupts on the 6502, with examples and performance comparisons
- Servicing interrupts on a 6502 in high-level Forth, with zero overhead!
- Tip of the Day column on the forum
- RS-232 primer (a recent forum topic showed the need)
- 6502 PRIMER: Building your own 6502 computer, in 22 sections, including (but not limited to) why a 6502, addr decoding, memory-map requirements, clock, RST, construction, interfaces, wire-wrap, troubleshooting & debugging without expensive equipment, steps for a successful project, beginning program-writing, programming tips, common beginners' programming errors, and supporting circuits for lots of I/O types
- large look-up tables for hyperfast, accurate, 16-bit fixed-point/scaled-integer math, with explanations. In some cases, the look-up can be nearly a thousand times as fast as actually calculating the function, and it will be accurate to all 16 bits. No interpolation needed. The article on the front page of the section also shows how even without using the tables, scaled-integer math is very capable of doing things that most people think you can't do without floating-point. (Notice I did not say "fixed-point," which is a limited subset of scaled-integer.) There's further discussion on it in the RPN operations chapter of the stacks treatise.
- program structures in 65c02 assembly, using macros. These have been wonderful to work with. I wish I had done them 20+ years earlier.
- simple methods of doing multitasking without a multitasking OS
- why assembly language is still relevant today
- the many differences between the NMOS 6502 and the CMOS 65c02
- treatise on stacks (plural, not just the hardware stack that 6502 puts in page 1), starting with the basics and working its way up, including virtual stacks, stack addressing, passing parameters, inlined data, RPN, synthesizing instructions, self-relocatable code, local variables, recursion, compiling or assembling program structures by using stacks, and more, in 19 chapters plus appendices.
- self-modifying code on 65xx
- The 65816 microprocessor: Common Misunderstandings, Plus Attractions
I started some others years ago and was delinquent about finishing them (hopefully I can still get to them in the future):
- Primer on synchronous serial: dumb shift registers, I²C, SPI, Microwire, 1-Wire, SMBus (I do have a brief comparison of them though, here)
- primer on multiple-precision, scaled-integer, and fixed-point math in place of floating point which incurs a much heavier runtime overhead and is totally unnecessary for most applications, even scientific! (I later summarized much of the planned material in the explanations on the front page of the section of my website on large look-up tables though.)
- publish my '02 and '816 Forths
I would like someone else to write 65-related articles on:
- file systems, kernels, and OSs
- multitasking OSs, coöperative and preëmptive (coöperative is very easy on the 6502 in Forth), multithreading
- multiprocessing
- DMA
- video
- MMUs
- using DRAM
