Electronics‎ > ‎

RCA 1802 Micro

May 2010 (updated October 2016)

It's hard to believe it's been 30+ years since I started learning about and working with microprocessors. Back in 1985 I attended a night school class taught by the late Dave Lang at the Community College in Wanganui, New Zealand. We built a "trainer" which Dave designed around the RCA COSMAC CDP1802 microprocessor. Dave was a real 1802 enthusiast. He often told us there was a version that was "radiation hardened" and it was being used in satellites and MinuteMan guided missiles (ICBM's). Apparently there are multiple 1802's in the Galileo spacecraft.

Sadly, Dave passed away in 2009. The other day I got thinking about Dave and all the stuff we did in his classes. This made me want to get the old trainer out again and re-live some of that time. I'm documenting the exper
ience here, kind of in honour of Dave's efforts also. So I dusted off the trainer and powered it up. I had to repair a couple of connections but that's all that seemed wrong. Wow it still works!  I found a EPROM containing a monitor program Dave wrote. The EPROM is a 2716, which holds a whopping 2k bytes! I had never used this EPROM. I soldered up a 3-wire serial cable, fired up TeraTerm on an EeePC netbook, plugged the EPROM into the trainer -> Reset, Run and....
It didn't work. I had some suspicions, so I got the trusty 'scope out and found the trainers' clock circuit was a bit flaky. I replaced the pot, adjusted for 2MHz (whoa, too fast!) then tried again - this time it worked! Serial out at 2400 bps by bit-banging the 1802's Q line, then polling the EF4 line for incoming. This seems to work well enough and I've since discovered this method was quite common on 1802 systems. It's funny how things change, these days PC's don't even have serial ports. I used a $10 USB-to-Serial adapter on the Netbook.

I delved into the old night school notes including my original copy of Tom Swan's book, "Programmer's Guide to the 1802", and started to re-learn it all. I found a circuit and a bag of parts I hadn't used, for a "multiplexed, multi-digit display", also from Dave's night school classes. This uses two CDP1852 chips (byte-wide I/O port). I built the circuit on Veroboard (strip board), over a couple of days, following Dave's original design. Last night I finally reached the telling moment,
where I would connect it to the trainer, plug in some op-codes and see if it...  - it works! Now I've got Dave's original monitor and the multiplexed display working together - too good.

During this little journey down memory lane, I came across all kinds of useful things from all around the Internet. The Internet is the one thing that has dramatically changed things since 1985. Among the goodness, I found 1802 tools like cross assemblers, disassemblers, compilers, documents and data sheets. I even found some free 1802 simulators! One simulator I downloaded (emma02) was very useful for helping me re-learn 1802 machine code. Also, I was able to load, run and single-step through Dave's monitor code. This was great for examining how that works. I've since created my own 1802 simulator.



The Tera Term image above shows Dave's monitor running, with a hex dump of a machine code program to display "HELLO" on the multiplexed display. Directly above is the multiplexed display with the program running. Below are some closeup shots of the trainer. Left is the hex keypad, which is an ex-calculator keypad Dave supplied to the class as a kit we had to modify. Centre is the mode jumper, system clock, and 1802 micro.Right is the Serial port and status LEDs.  Click images for full-size view.







Block Diagram of "Commander" 1802 Trainer. (hand drawn by Dave Lang)

Documents, Code and other links

The following are scans of the original documents about the trainer as provided to the night school class of 1985. Some of them may have notes I added.
Most are typed (on a typewriter!) and some were hand written by Dave Lang.

1802 Expanding the Trainer (pdf)
The 1802 for Beginners (pdf)  Dave's night school notes about the 1802.
1802-Mon-1.0 Commands (pdf)  Dave's monitor commands and instructions. Includes a hex listing of Dave's monitor.
1802mon.rom  Dave's monitor in a file format compatible with Emma02 emulator and my 1802sim.

My 1802 Simulator  I developed this 1802 simulator which can run Dave's monitor program. It includes serial terminal simulation to support the monitor.


If by some chance, you are one of the people who attended Dave's classes and built one of these "Dave Lang specials" - it would be nice to hear from you. 


Click for full size.  (6th August 2003)


My real name is Greg Newton and I'm in Sydney, Australia. If you want to contact me, or you want more information, you can email me at: greg dot newton dot oz at gmail dot com (written like that to avoid spam bots).

Comments