Vintage COSMAC Elf is Pretty Close to Original

Popular Electronics was famous for the article introducing the Altair 8800 back in 1975 (well, the cover date was 1975; it really came out in late 1974). That was so popular (no pun intended), that they ran more computer construction articles, including the SWTPC 680 late in 1975. But in 1976 a very popular article ran on building a very simple computer called the COSMAC ELF. [Youtubba] had an Altair, but always wanted a “cute” COSMAC ELF. Now, forty-something years later, he finally got around to it. He made the very detailed video about his experience, below.

Surprisingly, he didn’t have to look very hard for too many of the components as most of them were available from Digikey. He had to get compatible RAM chips, the 1802 CPU and LED displays. He also couldn’t find a look-alike crystal, so he used a fake one and a hidden oscillator. The result looks awfully close to the original. He even did a nice front panel using Front Panel Express.

It might be hard to understand why people got excited over a little computer with a handful of switches. Consider the Altair, though. For $439 you got a very basic machine with 256 bytes of RAM (upgradable to 1K, or beyond if you bought more boards). If you wanted to expand it to something really useful with RAM, disk drives, and a terminal you were still talking lots of cash. And that was 1975 cash. In equivalent terms, that Altair kit would cost $2000 today.

The ELF, on the other hand, could be put together on a piece of perf board. If you had to buy everything from scratch, it might cost $100 back then. If you had a well-stocked junk box, you could cut that down a good bit. The DMA onboard the 1802 chip made the front panel simple, and it facilitated a companion graphics chip that produced crude black and white graphics on a monitor or TV.

If you are too lazy to do the build, you can always play with the computer in your browser. If you don’t care about having an authentic look, there’s always the membership card.

22 thoughts on “Vintage COSMAC Elf is Pretty Close to Original

  1. Honest question… how does the 1802 stack up compared to, say, a 6502? I’m not just looking for raw performance, i.e. how fast it crunches numbers, but rather more of a “what can you do with it” sort of comparison. I can tell offhand, for example, that the 1802’s on-die DMA gives it at least /some/ advantage, but I can’t tell how much because I just plain don’t know.

    As an aside — I’ll check back tomorrow morning (I’m on East-Coast US time, FWIW) to see what you folks have to say — I don’t want my phone pinging all night and Hackaday’s “subscribe” doesn’t do just a single thread…

      1. It is not radiation hardened by design but by assembly technique. The silicon chip was monted on saphire and this was encased in cemaric instead of plastic. The cheap plastic version were not radiation hardened at all although it was the same chip.
        It was radiation hardened on purpose to be used on space probes and it was used on space probes because it was the first CMOS CPU available on market. It is compleletly static, meaning that its clock can be stopped without loosing the internal states reducing power consumption. But this CPU is rather slow it need 16 clocks per instruction or 24 for long jumps and branches. Compare it with an AVR core which only need 1 clock per instruction.

        The COSMAC ELF was running on a 3.579Mhz crystal which frequency was divide by 2 thus executing 111,860 instruction per second. SLOW!

    1. The COSMAC 1802 is all about it’s cool factor. It’s one of the first 8 bit CPU’s and Joseph Weisbecker (creator extraordinaire) had to invent *NEW* ideas from scratch. Today, there is nothing really new in technology, it’s the same as yesterday’s chips, only smaller, faster and cheaper.

      The 1802 is a great processor to play with. Like a Ford Model T this processor has it’s own unique style. One of the nice things about this processor is the multiple clocks required to complete each instruction. You can think of it as “seeing the moving parts”. I may be a little biased, since my first computer was a COSMAC ELF. The 1802 is nothing less than a treasure.

      To answer your question about 1802 vs 6502. While the 1802 has a lot more cool features, it lacks some of the advanced programming abilities that the 6502 has. The 6502 was an improved version of the 6500 which was modeled and made as a drop in replacement for the 6800. The 1802 stands in a class of it’s own.
      The bottom line, the 6502 is definitely much more suited to computing (better addressing modes) and easily out performs an 1802 with the right coding. The 1802 has some extra features that make it easier to use in a more minimal design, ie DMA, Direct Pin I/O (4 “EF” inputs, 1 “Q” output). Let me back up to where I spoke of “right coding”. The ComX-35 is an 1802 based system that runs BASIC and supports floppy drives and printers. It performs as well as the Ohio Scientific Superboard which runs a 6502. But the VIC-20 out performs both those computers with the same 6502. Perhaps I’ll display this comparison at VCF Midwest in Chicago this year.
      It should be said that the 1802 did advance to the 1805 processor which improved the instruction set. Being a 2nd generation 8 bit, I believe it would be more “fair” to compare the 6502 vs 1805.

      Josh Bensadon

      PS. I have found the best use of new technology is to preserve and illustrate the old technology. The best movies released on Blu-ray are the old classics.

      1. The original Cosmac Elf kit was my first. Clearly remember buying the IC sockets exactly doubled the price of the project. My “Hello World” program simply blinked the LED which of course had to be shown to the wife immediately. Big mistake. “You spent $$$ to just blink a light!!!?”. An excellent learning experience… never did let her know how much $$$ the soldering iron was. It’s still my front-line iron serving faithfully to this day.

        OSI Superboard II was the second… funded by converting tv sets to monitors… the Aim/Sym/Kim years.

    2. The 1802 is very simple to interface from a hardware point of view and has a very easy to learn machine language – a very small, very regular instruction set. It lends itself to simple, low power, controller applications with no, or limited RAM.
      By actual benchmark, in a complex programming environment, it’s about 20% the speed of a Z80 BUT, i was able to single-handedly adapt a compiler for it in a relatively short period. I’m pretty sure I’d still be working at it if i tried that with a 6502 or Z80.

    3. CMOS, not NMOS.
      Many registers, not “very few”.
      Beautifully symmetrical instruction set. I’ve only seen one other that was more pleasing.
      Fully static operation (you can single-step the clock, or freeze it).
      Boot time autoloader.

    4. The 1802 was an “interesting” chip — one of, if not the, first CMOS (and thus, very low power for the day) CPU. It had a huge number of registers for the day (16 x 16 bit registers), any of which could be used as the program counter, any of which could be used as a memory pointer. I’m aware of no other 8 bit CPU with that many on-board registers. Want to call a subroutine? Put it’s address in one of those registers, change the program counter to be that register, ta-da, you just called the subroutine. Return by changing the PC back to the old register.

      There were a lot of nifty features that made it easy to build such a simple machine. For example, on reset, R0 (one of those 16 sixteen bit registers) was the default program counter, but also the DMA register, and it was reset to 0000h. So to load data into RAM, you could just reset the machine, hold it in halt state, put data on the bus (toggle switches), and hit the DMA IN line. Data is written to RAM, the DMA register is incremented, and the system is ready for you to put the next value in RAM. Most other computers required either a set of address switches, or a ROM monitor to load data, greatly raising the price and/or difficulty in home-brew work.

      There are a few input lines and one output line that are easy to use in HW and software. People built serial interfaces out of one of the input lines and the output line.

      Performance … well, did we mention that the hw was easy to work with? :) Really, performance was not this chip’s goal, apparently. The 1802 had an 8 clock cycle “machine cycle”, and each instruction took two or three machines cycles, so 16 or 24 clock cycles. Compared to the 6502, which as I recall, could execute some instructions in one clock cycle (granted, the 6502 had a two-phase clock, and used all four transitions, so one could argue that a 1MHz 6502 was really a 4MHz device, but still, the throughput of the 1802 was SLOW by compared to anything else of the day).

      While jumping subroutines was easy by changing the PC to point to a different register, the 1802 lacked a real stack. There were a couple instructions that were close — something like “put data in D register into memory location pointed to by the active index register, then increment the index register” and an almost corresponding “get data from memory location pointed to by the active index register, put in D reg, then INCREMENT the index register”. So close, but one should be incrementing, other should be decrementing to really make it a stack-like operation.

      In short — probably a fantastic microcontroller for the day, but the 6502 (and most other 8 bit chips) were better general purpose devices. Chip count for the simplest system could be very low compared to almost any other CPU of the day, but performance and flexibility were a bit behind the competition.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s