Slashdot Mirror


The Real Story of Hacking Together the Commodore C128

szczys writes "Bil Herd was the designer and hardware lead for the Commodore C128. He reminisces about the herculean effort his team took on in order to bring the hardware to market in just five months. At the time the company had the resources to roll their own silicon (that's right, custom chips!) but this also meant that for three of those five months they didn't actually have the integrated circuits the computer was based on."

24 of 179 comments (clear)

  1. Mind blowing by 50000BTU_barbecue · · Score: 4, Informative
    It's really cool to hear about this stuff. It's just sad to realize that the 128 was a terrible idea and Commodore spread itself too thin making all kinds of bizarre 8-bit computers around that time instead of making a true successor to the C64. The C65 should have been what made it to market, not the weird 128 with its obsolete the day it left the factory CP/M mode running at half the speed of its competitors.

    The people I knew with 128s back then all used the 64 mode but used the 128 as an excuse to buy a better monitor. I never knew anyone using the CP/M mode.

    --
    Mostly random stuff.
    1. Re:Mind blowing by Webcommando · · Score: 5, Interesting

      I went from a Vic20 to C128 instead of a C64. I was amazed that I could use CPM and a very advanced basic. The power of this machine enabled me and a good friend to build a robot in college made of nothing but old car parts, DC motors, relays, and plates with holes drilled in them for encoders. That directly led to my first job as an automation engineer.

      The C128 also was the last computer that fueled my dreams. I went to college to become a computer engineer so I could build what I called the "compatibility machine". This machine could execute all the major 8-bit computer software (they all had Z80's or 6502) without the user intervening or worrying what version of software they purchased. The C128 showed me it could be possible!

      By the time I left school the writing was on the wall that Mac / IBM style PCs would rule the world. It didn't stop me from getting an Amiga, but it was pretty clear that CBM was on the way out.

      --
      I love the sound of distortion in the morning -- webcommando
    2. Re:Mind blowing by Dogtanian · · Score: 4, Interesting

      The C65 should have been what made it to market, not the weird 128 with its obsolete the day it left the factory CP/M mode running at half the speed of its competitors.

      Whatever the merits or demerits of the two machines is irrelevant; the C128 came out in 1985, whereas the C65 wasn't developed circa 1990-91.

      C64 diehards have an obsession with the C65 and Commodore's perceived mistake in abandoning it, but despite the latter's numerous crap decisions, I'm sorry to say that in this case they were absolutely right.

      The C64 was still selling as a budget option circa 1991 (*) viable due to sheer momentum. The 16/32-bit Amiga was not only established as the successor, it had already taken over (in Europe, at least) and was already nearing *its* own commercial peak(!)

      Trying to release a (sort of) new 8-bit format by that point, even a very good one, would have made absolutely no sense, flopped horribly and stood on the low-end Amiga models' toes, mudding the waters pointlessly.

      They could have sold it as cheaply as the C64 (i.e. the high manufacturing costs of a new machine selling at the same price as a "wringing the last profit from established cash cow model"), but what would the point of that have been?

      The C128 at least came to market when there was still *possibly* a gap in the market for a high-end 8-bit machine between the C64 and the new (but still very expensive) Amiga.

      (*) Apparently C= were still making them when they went bankrupt circa mid-1994(!)

      --
      "Slashdot - News and Chat Sites Deviant". (Click "homepage" link above for details).
    3. Re:Mind blowing by 50000BTU_barbecue · · Score: 4, Informative

      Commodore didn't design the Amiga, they bought it.

      --
      Mostly random stuff.
  2. Learn electronics repair from Bil himself by Anonymous Coward · · Score: 3, Informative

    Bil will be teaching a class at the Vintage Computer Festival East next spring. He also lectured about the 128 and Commodore repair at the same event in 2012. Details are on c128.com.

  3. Hrmmmmm by Anonymous Coward · · Score: 3, Interesting

    He is claiming a lot of "firsts" that I would swear were in my Apple ][e prior to Winter '85...

  4. Re:Mistake by fisted · · Score: 3, Insightful

    Want to do a crazy program you can't write on modern computers?

    What?

    Simply loop through a sequence of poking two random numbers, and incrementing a number that you print.

    What?

    Every time, the system will do different things.

    What ?

    If you did this on a modern computer, eventually it'd corrupt system files and the thing wouldn't boot.

    WHAT?

    It makes you wonder why modern OSes aren't hardened with the theory: No matter what the user does, allow the computer to boot up safely next time.

    You're an idiot.

  5. Re:Mistake by GrahamCox · · Score: 4, Funny

    Ah, but you weren't a true C64 department-store hacker until you entered the couple of POKEs that disabled RUN/STOP and RESTORE keys before entering that loop.

  6. Re:Mistake by nedlohs · · Score: 4, Informative

    Want to do a crazy program you can't write on modern computers?

    What?

    Yeah, can't is a blatant lie.

    Yeah, that's trivial to do on a modern computer too. A trivial loadable kernel module in linux could do so, for example.

    Simply loop through a sequence of poking two random numbers, and incrementing a number that you print.

    What?

    That is what it says, write a random value to a random memory location in a loop.

    Every time, the system will do different things.

    What ?

    Of course it will. Sometimes you random memory location will be the memory mapped to the screen and a character will show up. Sometimes you'll change a return address on the stack and run some random code.

    If you did this on a modern computer, eventually it'd corrupt system files and the thing wouldn't boot.

    WHAT?

    That's true, eventually you'll write over some file data just before it is flushed to disk and trash a file required for booting. Or screw with memory the file system is using and mess that up on the next write (though given the use of checksums that's pretty unlikely). The key is eventually since you'll have to run it a *lot* of times before it does something like that before crashing itself.

    And of course not when running as a normal user process.

    It makes you wonder why modern OSes aren't hardened with the theory: No matter what the user does, allow the computer to boot up safely next time.

    You're an idiot.

    Yes he is.

    Computers that have the OS on ROM unsurprisingly aren't susceptible to making the system unbootable by screwing with boot files. The same is true of a modern computer hardwired to boot off of ROM as well though. And of course it makes upgrading that base OS essentially impossible (short of replacing the ROM, or actually using an EEPROM - and of course if software can do the upgrade then the random memory setting could also cause it to happen and screw up booting)

  7. Re:U.S. Navy? by wcrowe · · Score: 5, Interesting

    True. I was one of those guys initially. I was a CS major in 1985 and my computer experience consisted of mainframes, CP/M machines and IBM PCs. Anything else was a "toy". I had a new girlfriend who suggested I could do my CS homework at her house because her dad "had a computer". She didn't know what kind it was, but he was an engineer so I figured it was probably pretty nice. I took her up on her offer, figuring that the suggestion was nothing more than a ploy to get me to come over to her house. When we got to her house she took me to the room he used as his office and pointed. I literally guffawed. It was a Commodore 64. She was somewhat offended at my reaction and I quickly apologized. Over the next few weeks I was a frequent visitor to her house and I began playing with the C64. The more I worked with it, the more respect I had for the platform. I especially liked the serial interface and how components could be daisy-chained. Far from being a toy, the C64 had the capability to do some pretty advanced stuff. And it was a LOT less expensive than an IBM PC. Eventually, the girlfriend became my wife, and her dad gave me the Commodore after he moved on to a PC. The wife and I broke several years ago. I still have the C64.
       

    --
    Proverbs 21:19
  8. This quote is great by phantomfive · · Score: 4, Insightful
    You never know what marketing will do to you as an engineer.

    a couple of weeks later the marketing department in a state of delusional denial put out a press release guaranteeing 100% compatibility with the C64. We debated asking them how they (the Marketing Department) were going to accomplish such a lofty goal but instead settled for getting down to work ourselves.

    --
    "First they came for the slanderers and i said nothing."
  9. My dad bought me this as my first computer. by JoshDM · · Score: 5, Interesting

    I was in 5th or 6th grade, and I woke up to a new computer in my room. The printer immediately broke and I noticed the desk was half up-side down. My dad had assembled it and the desk in the dark, during the night, while I was asleep (I'm a heavy sleeper). He was no technician, but I appreciated the effort. I traded c64 games with kids at school and stacks of 5.25 floppies via mail. Commodore games were fantastic; much better than NES. Junior year of High School, I finally had the initiative to figure out what my dad had done to the printer, and it turned out to be a simple problem that I fixed. I used 80 column mode to type and print essays for school for the next two years. Much praise to my old man. Granted, first year of college and he helped me acquire a 386 with Windows 3.0, which I had for three years, then built my own. I'll never forget my C=128. Thanks, dad!

    1. Re:My dad bought me this as my first computer. by wcrowe · · Score: 3, Informative

      Just wanted to say that's a great story about your dad.

      --
      Proverbs 21:19
  10. Too little too late by RedMage · · Score: 3, Interesting

    I was a big fan, and a game developer for the C64. Those were the days that a machine could be fully understood by an untrained person with a knack for programming. When the C128 came out, I was interested, especially in the 80 column screen and CP/M software compilers. But there were too many limits on the machine (no hard drive easily added, no real OS, etc.) and it didn't feel like enough of an advancement over the C64. My grandfather did buy one, and I had some time with his, but that never really sparked much either. My next machine would be the Amiga, and as soon as that become somewhat affordable by a college student (the A500), I never looked back.

    RM

    --
    }#q NO CARRIER
  11. Megahertz myth and the 6502 by goombah99 · · Score: 4, Informative

    THe 6502 was an amazing processor. the Apple II was also a 6502. Unlike it's near contemporaries, the 8086 and Z-80 (and 6800), the instruction set was reduced. It had only 2 data registers (A,B) and two 8 bit address registers ( X Y) and fewer complicated ways to branch. Instead it effectively memory mapped the registers by using instructions like, offset Y by A, treat that as an address and get the byte at that location. Because it could do all that in one clock cycle, This effectively gave it 256 memory mapped registers. It also didn't have separate input lines for perifprials, and instead memory mapped those.

    Nearly every instruction took a microsecond. Thus while the clock rate was 1 Mhz, it was much faster than a 4 Mhz 8080 series chip since those could take multiple cycles to do one instruction. Few memory chips (mainly static memory) could keep pace with that clock rate so the memory would inject wait states that further slowed the instruction time. The 6502's leisurley microsecond time was well matched to meory speeds. Moreover, on the 6502 only half the clock cycle was used for the memory fetch. This left the other half free for other things to access memory on a regular basis.

    The regularity of that free memory access period was super important. it meant you could do two things. First you could backside the video memory access onto that period. On the 8080s using main memory you could often see gltiches on video displays that would happens when the video access was overridden by the CPU access at irregular clock cycles. As a result most 8080 series based video systems used dedicated video card like a CGA or EGA. Hence we had all these ugly character based graphics with slow video access by I/O in the Intel computer world. In the 6502 world, we had main memory mapped graphics. This is why the C64/Amiga/Apple were so much better at games.

    This regular clock rate on the main meory had a wonderful side effect. It meant you could use Dynamic memory which was faster, cheaper, denser, and MUCH MUCH lower power than static memory. With the irregular access rates of the 8080 refreshing a page of dynamic memory requird all sorts tricky circuitry that trried to opportunistically find bus idle times to increment the dynamic refresh address, occasionally having to halt the CPU to do an emergency refresh cycle before the millisecond window of memory lifetime expired. As a result, the 8080 seris computers like Cromenco, Imsai, altair and Northstar all had whopper power supplies and big boxes to supply the cooling and current the static memory needed.

    So the C64s and Apples were much nicer machines. However they had a reputation of being gaming machines. At the time that didn't mean "high end" like it does now. It mean toys. the Big Iron micros were perceived as bussiness machines.

    Oddly that was exactly backwards. But until Visicalc, the bussiness software tended to be written for the 8080 series.

    I think it was this memory mapping style rather than formal I/O lines to dedicated cards for periphrials (keyboard decoders, video, etc..) that lead apple to strive for replacing chips with software. they software decoed the serial lines (rather than using USART chips) they soft sectored the floppy drives rather than using dedicated controller chips, etc... And that was what lead to making the macintosh possible: less hardware to fit in the box, lower cost chip count, lower power more efficient power supplies.

    Eventually however the megahertz myth made the PCs seem like more powerful machines than the 68000 and powerPC.

    --
    Some drink at the fountain of knowledge. Others just gargle.
    1. Re:Megahertz myth and the 6502 by PhantomHarlock · · Score: 3

      And as a descendent to that is was amazing what the Amiga did with the 68000 and its custom graphics and sound chips, as you mention at the very end. you never saw smooth scrolling and sprite movement on a PC. The Amiga and the C=64 both had arcade quality graphics locked to a 60hz interlaced or 1/2 vertical res (single field) refresh rate of a standard NTSC television signal. Since the whole thing was timed to that frequency, you never got tearing. The only downside was interlace flicker without a frame doubler, but not a lot of applications used interlaced mode.

    2. Re:Megahertz myth and the 6502 by ewhac · · Score: 3, Interesting

      I don't have time to correct all the errors in the parent post. So very briefly:

      • The 6502 had three 8-bit registers: A, X, and Y. A was the accumulator, and received the result of all arithmetic operations. X and Y could hold temporary data, arithmetic operands, and be used as index registers for memory load/store. There was also an 8-bit stack pointer register, SP, hard-mapped to the range 0x0100 - 0x01FF.
      • The 8080 had the 8-bit registers A, B, C, D, E, H, L, and a 16-bit stack pointer. In addition, the registers B & C, D & E, and H & L could be used to hold 16-bit quantities for some instructions.
      • The Z80 had all the registers of the 8080, plus a shadow copy of the registers for quick use by interrupt service routines.
      • The 6502's zero page (0x0000 - 0x00FF) got special treatment by the CPU, using only a single byte to address a location. As such, zero page usually got treated by software as a pile of "slow registers."
      • No instruction on the 6502 executed in fewer than two clock cycles. The fastest 6502 I ever saw was 2 MHz.
      • By contrast, 4 Mhz Z80 chips were widespread.
      • The Z80 helped popularize dynamic RAMs by containing a very basic DRAM refresh counter. The 6502 had no such thing; DRAM refresh was usually provided by custom logic, usually part of the video controller.
      • S-100 machines had huge power supplies because they had huge numbers of slots (eight or more being common), and had to have enough reserve power for all of them.
      • There was nothing special about the 6502's memory access patterns, and 6502 would get starved out like any other CPU if another device held the bus. On the C-64 in particular, every eight video lines, the VIC would grab the bus for 40 uSecs to fetch the next row of character cells, holding off the 6502 the whole time. This led to all kinds of problems with timing-sensitive operations, and was directly responsible for transfers to/from the 1541 floppy drive to be glacially slow.

      Schwab

  12. Re:U.S. Navy? by bmajik · · Score: 4, Funny

    This is such a Slashdot story :)

    "A girl invited me to her house on several occasions. Each time, I spent more and more time being impressed with the Commodore 64"

    --
    My opinions are my own, and do not necessarily represent those of my employer.
  13. Re:U.S. Navy? by wcrowe · · Score: 3, Informative

    Well, you know, there was other stuff going on, as her father and step mother were out of town that winter, but this is Slashdot, not Penthouse forum, so...

    Hey, I eventually married the girl. ;-)

    --
    Proverbs 21:19
  14. About time by Tablizer · · Score: 4, Funny

    Excellent, my wife's been on me to upgrade my C64

  15. Wrong by Anonymous Coward · · Score: 4, Insightful

    Since I designed, wirewrapped, and programmed embedded 6502 and 8080 system in that era I am well prepared to assess your claims. In a nut shell you are an arrogant tard and the original poster is figuratively accurate inexact.

    Your post is really bizarre.

    THe 6502 was an amazing processor. the Apple II was also a 6502. Unlike it's near contemporaries, the 8086 and Z-80 (and 6800),

    Ok, with you there.

    Nearly every instruction took a microsecond. Thus while the clock rate was 1 Mhz, it was much faster than a 4 Mhz 8080 series chip since those could take multiple cycles to do one instruction.

    Well, that's just a bunch of crap: http://www.obelisk.demon.co.uk/6502/reference.html (look at the "Cycles" column.)

    What the original poster was likely saying, since it becomes clear later in the article, was that all the 6502 instructions were divided up into alternating cycles of memory fetches and internal calculations with an exact period of 1 microsecond for those. The 8080 series would use 1,2,3,4 and more with wait states cycles for an instruction with no regular pattern (in terms of future predictable times) of when the bus would be busy.

    So you are wrong, have a reading comprehension problem, and are an ass about it.

    Few memory chips (mainly static memory) could keep pace with that clock rate so the memory would inject wait states that further slowed the instruction time. The 6502's leisurley microsecond time was well matched to meory speeds.

    The Wikipedia article on the 6502 indicates that DRAM access times were on the order of 250ns - 450ns. In particular, 250ns access times are well-matched to 4 MHz clock rates; do the math. At 1 MHz, 250ns DRAM has time to go make a sandwich before it needs to supply the next memory cells.

    Sigh, again you have a reading comprehension problem. The original author was discussing static memory. Moreover, the cycle time for memory access always involves some overhead. The time when the CPU reads the data bus needs to occur after the bus has settled which is not at the start of the memories data valid period. But most of all 250ns memory was rare and expensive. Most computers in that time period did use wait states. Why do you think processors even allowed wait states?

    Again you are being an ass about this as well.

    On the 8080s using main memory you could often see gltiches on video displays that would happens when the video access was overridden by the CPU access at irregular clock cycles.

    No. Then, as now, video display glitches were caused by updating video RAM directly outside of a VSync pulse. You could just as easily get video glitches on 6502s as on 808x machines.

    that was an additional restriction on 8080 machines. But on 6502 machines one did not have to wait for the vertical sync to update the video memory. In fact that is EXACTLY what the original poster was pointing out, without trying to flaunt jargon like you.

    This makes you look stupid now.

    Which leads us to:

    As a result most 8080 series based video systems used dedicated video card like a CGA or EGA. Hence we had all these ugly character based graphics with slow video access by I/O in the Intel computer world. In the 6502 world, we had main memory mapped graphics.

    Patently false. Video memory on an 808x machine (even on CGA and EGA cards) was most certainly memory mapped.

    yes it could be done. But then you had the problem of glitches or waiting for VSYNC (or if you liked to live dangerously, HSYNC). It wasn't pretty to build hardware or write code for. Your interaction with it didn't treat it like main memory but rather so

  16. Re:Mistake by Neo-Rio-101 · · Score: 3, Interesting

    sorry it should be SYS64767
    Getting old here.

    --
    READY.
    PRINT ""+-0
  17. Re:U.S. Navy? by Dogtanian · · Score: 4, Insightful

    I called it "Commode-odor". I was an Atari fan, but most of my friends had C=64s. A few years later, though, I got an Amiga.

    Assuming you mean the 8-bit Atari 400 and 800 (and its compatible redesigns, the XL and XE series), I did pretty much the same thing- was an Atari fanboy, but ended up with an Amiga. When one knows a little more about the "Commodore" Amiga and "Atari", it all seems a bit silly.

    The major irony is that the Amiga developers included a number of ex-Atari staff- most significantly Jay Miner- who had worked on the 400/800 and the VCS/2600 before that. It represented (some have argued) a continued thread of architectural design that the 400/800 had significantly improved upon from the VCS, and had the same state-of-the-art custom chipset approach as its predecessors. (Indeed, just as happened with the 400 and 800, the Amiga was originally meant to be a console, before it evolved into a computer).

    Also worth noting that "Amiga" was originally an independent company and it was only later bought by Commodore (after some legal wrangling with Atari, who'd had some involvement with them).

    Meanwhile, Jack Tramiel had left Commodore (after falling out with the management), bought Atari Inc's computer and console division (i.e. the one that brought us the VCS and 400/800), which formed his new Atari Corp. The latter was a very different company to Atari Inc. (very obviously a much more shoestring operation). The Atari ST was designed by a different team after Tramiel had sacked most of the old Atari Inc. engineers, and very much reflected the "new" Atari; affordable, but much more off-the-shelf parts.

    Atari Corp continued selling the XL and XE (cost-reduced versions of the 400 and 800), but they didn't design it; they merely milked the profits from a design they'd inherited while they focused on *their* Atari ST.

    So... which was really the "true" successor to the Atari 400 and 800? By any measure, it was the "Commodore" Amiga. Who cares who made it? I briefly owned an ST because I couldn't afford an Amiga, but I ended up selling it and buying the latter a year later.

    --
    "Slashdot - News and Chat Sites Deviant". (Click "homepage" link above for details).
  18. Not the last 8-bit design by Wookie+Monster · · Score: 4, Informative

    Several times in the article, he mentions that the C128 was the last 8-bit computer to be designed. This isn't true -- a year later, Tandy announced the CoCo3, also with 128KB and capable of 80 column text display. It didn't run CP/M, but instead it ran Microware OS-9.