Direct Memory Access Possibilities on the TANDY Color Computer

As part of my continuing efforts to understand direct memory access (DMA) capabilities of various 80’s home computer systems, I decided I should figure out what, if any, DMA capabilities are possible on the TANDY Color Computer systems. There are 3 essential models in the lineup, though from a technical perspective, I feel there are 2 main variants: The CoCo1 and 2, which share very similar features and capabilities (mainly, the difference is in some cost reduced circuitry in the 2 and more memory in the later machines) and the CoCo3, which contains a more capable video processor, substantially more memory, and a memory management unit (MMU). Most folks also consider the Dragon Data Dragon machines as part of this lineup, and those are roughly similar to the CoCo1/2 systems (both systems seem to be based on a Motorola reference design. The CP1400 might also qualify, but I don’t have one and know little about the design, so I will consider the 4 above machines inclusively

A pre-requisite for DMA operation is an ability to stop the running CPU in some fashion and a way to access internal memory and/or IO from the cartridge or expansion port. The VIC-20, for example, has no way to stop the running CPU, so DMA is not possible. However, TANDY (and Dragon Data) helpfully provided a pin on the expansion port that will temporarily shut off the internal Motorola M6809E CPU and remove its address and data signals from the system bus (this part is essential, because if the CPU is not running but it still outputs address and data on the system bus, the bus is not available for other users). On the M6809E, that signal is called !HALT and is active low. To “halt” the 6809 CPU, simply bring this line low on the expansion port during a cycle. Of course, nothing is that simple, so here’s some more detail:

Figure 8: HALT behavior

!HALT can be pulled low anytime, but will only take effect if it falls 200nS or more before the falling edge of Q (Q is 1 half of the 4 phase clock system used by the 6809 and typically is high during the middle of the CPU clock “cycle”). This consideration is called tPCS on the timing diagram, and is 200nS for a 1MHz CPU, 140nS for a 1.5MHz, and 100nS for a 2MHz CPU. As well, one can bring !HALT high at a later time, but it again must occur tPCS nS before the fall of the Q clock signal. Still, if one adheres to those rules, the entire address and data bus (on the CoCo1 and 2, anyway) is available at the expansion port for reading from and writing data to the internal memory.

One must crawl, then walk, and then run in these efforts, so the first thought is to figure out the !HALT signalling and attempt to transfer a single value from the expansion port to an internal memory location. Testing would then involve setting the internal memory location to a value other than the one expected, triggering the DMA functionality, and then looking at the internal memory location. If the value has been changed, one can be confident a DMA transfer has occurred. Once that is in place, it can be used as a foundation to expand the functionality to support the transfer of many data values to many locations, and then digress into the various useful DMA use cases (fast floppy emulator, extra memory on demand, feeding audio data to a DAC, etc.). But, it’s a tall order to transfer that first byte, so let’s focus on the task at hand.

Many years ago, I would approach this by grabbing a perfboard and wiring up some 74LS TTL logic ICs on the board to approximate the functionality desired. Of course, it would be wrong, so many hours of rewiring and soldering up new ICs would be involved. Now, though, as much as some retro enthusiasts object, I utilize a suitable Complex Programmable Logic Device (CPLD) attached to a small cartridge PCB to efficiently design the required logic. While soldering and deciding on the correct TTL IC has value, if you’re trying to make something work, those activities can get in the way of the design process. A CPLD allows one to change the design simply by modifying the “software”, downloading it into the IC, and testing. Once the design is working, one can translate back into TTL ICs if desired, or (in many of my recent designs), simply continue to utilize a CPLD. CPLDs are the children of PLDs like the 16v8 PAL used in the 1980’s, and some CPLD variants were available in the era of these machines. These complex devices can replace dozens of ICs in a design, decreasing finished unit costs consderibly and bringing these types of functions well within the grasp of hobbyists to manufacture and enthusiasts to buy. Since I’ve always desired to create economical solutions for these classic machines, the CPLD provides significant value. Still, for the moment, I’m most interested in the design efficiencies, especially since there’s no guarantee anything will work in the end.

RAM Expansion for the C64

RAM expansion was a common topic in the Commodore 64 community in the 1980’s.  Everyone seemed to need or want more RAM:

  • Soon after the unit arrived in stores, Paul Bosacki published a way to upgrade the unit to 512kB
  • Later, he pushed the expansion to 1MB
  • Berkeley Softworks (later GeoWorks), jumped into the fray with the 512kB GeoRAM
  • After the C128 arrived, Commodore got in the act, coming out with the 1700, 1764, and 1750 RAM Expansion Units, providing 128kB, 256kB, and 512kB of RAM, respectively.
  • Lots of people soon determined all 17XX units could be upgraded to 512kB
  • And, then, Andrew Mileski furthered that idea by piggybacking DRAM and pushing the 17XX to 2MB

Over time, RAM expansion options for the C64 have coalesced around two types: REU and GeoRAM.  The REU is much faster, but the GeoRAM is easier to create and use.

Still, both suffer from a serious issue.  Neither one makes RAM immediately available.  Both contain RAM outside the CPU’s direct access.  The Commodore REU can transfer memory from the unit to main system RAM around 1 million bytes/sec, while the GeoRAM has more humble speeds around 125KB/sec.  Sometimes, though, one would like RAM to be instantly available.

Cartridges like EasyFlash and EasyFlash 3 map FLASH ROM directly into the C64 memory map to simplify writing cartridge data.  Along those lines, it should be possible to map RAM directly into the C64 memory map as well, using the impressively capable and mysterious “Ultimax” mode.

The idea:

  • Treat the C64 memory map as 16 slices of memory, each 4KB in size. 
  • Allow the developer to select which portion of external RAM will “reside” in each 4kB slice.
  • If the developer maps a slice of RAM, any read or write access to that RAM will trigger Ultimax mode and place the external RAM onto the system bus during a CPU cycle.

The functionality shares a lot with UltiMem, a product we offer for the VIC-20.  But, the programmer can grow weary of manually configuring and reconfiguring each 4kB slice each time he/she wants to move to a different piece of RAM.  For that, we should take a page from the C128 MMU and create the idea of a “mapping set”.  A mapping set comprises 16 values, one for each slice of main memory.  The C128 supports 4 different mappings, which makes the developer’s job easier.  Set up the mapping and then just use it when needed.

So, let’s add a few more features:

  • Support a “mapping set” of 16 values
  • Support multiple mapping sets, which can be selected by storing a value into a specific register to denote the mapping set “ID”

Finally, though the Commodore REU may be too complicated to implement:

  • Support GeoRAM registers for backwards compatibility

One should be wary of announcing success too early, but initial development shows this functionality is possible.  At this point, the following functionality appears to be working:

  • 512kB of SRAM
  • GeoRAM register support
  • Support for 128 “mapping sets”
  • All memory slices except slice 0 and slide ‘D’ can reside externally

Of course, at this point, once something works, one needs to determine if anyone cares 🙂 

VCF-MW/ECCC

RETRO Innovations Booth
Glenn Holmer captured me talking to friends about something of interest at the ECCC 2014 show

It’s interesting to be a part of the continuing “growth” of the classic computer scene.  And, perhaps it is just me, but it does appear the classic machines are seeing more interest now than since they were first placed on the market.  It has been over 25 years, which is a common metric for “classic” status in other arenas (cars, coins, etc.), so perhaps this is the new reality.

Back in the day, I lived too far away from a metropolitan area that held computer shows, so I missed out on the thrill of those years.  And, after passing into adulthood, I had only previously attended 1 show, around 1997, put on by a Commodore user group in Lansing, MI.  While Maurice Randall showed off GeoFAX or some new GEOS app, another exhbitor showed off a way to control audio CDs from the 64, and everyone picked through the consignment table, I hawked printed copies of “Commodore Hacking”, an online magazine I was editing at the time.  As I recall, I did not sell many, and for good reason.  Why buy something you can dload online for free (true, the Internet was not as ubiquitous as today, but Compuserve, Delphi, GEnie, and others had copies, and the mag was in ASCII text, a mere few hundred K of data).

Yet, as I re-invested myself in these machines around 2004, I was invited to attend Commodore computer shows, including the World of Commodore 2004 in Toronto, ON, CA, LUCKI Expo 2005 near Louisville, KY, the C=4 (CCCC) Expo south of Cincinnati, OH, and SWRAP Expo 2005 in Chicago, IL.  As a new attendee, I was surprised so many people remembered me from the Commodore Hacking and even earlier Commodore FAQ days.  I also met luminaries like Jim Butterfield and Jeri Ellsworth.

Sadly, it appears some of the shows were not to continue.  LUCKI shut down first, as I recall, while SWRAP discontinued its show soon thereafter, and CCCC continued on for a few years and then folded when their “castle” venue closed its doors.  I worried I had witnessed the end of the show scene, just as I was starting to enjoy the friendships and witness all of the great hardware and software projects.

Luckily, World of Commodore continued on, while Jason Compton and a group of friends decided they needed to have a time each year to come together and enjoy friendship over Commodore computer discussions, and so the Emergency Chicagoland Commodore Convention (ECCC) came into being on the heels of SWRAP’s decision to forego another show.

ECCC, in particular, was somewhat the “anti-show”.  No table fees, no concrete organization, owing to the primary goal of just having a place for Commodore enthusiasts to hang out and enjoy company.  But, all things change, and a few years back, Jason Timmons asked if other computing platforms could co-located with the ECCC show under the Vintage Computer Festival – Midwest (VCF-MW) banner. There was already a well established VCF-East show in New Jersey, and there had been previous attempts for a VCF-MW in Indianapolis, as I recall. West Lafayette. But, VCF-MW had withered, and so it came to Chicago.

At first, VCF-MW was a small portion of the complete show, but each year, the VCF-MW contigent grew and brought more exhibits and attendees to the combined event.  At other shows, I suspect the primary sponsors would have either disallowed sharing the event date and location, or the organizers would have grown significantly concerned about the changing dynamic of the show, but Jason and the initial contributors seemed unconcerned about such things, probably owing to the fact that the ECCC show was created to enable a meeting place for enthusiasts, not as a formal marketing effort or a club sponsored idea.  I’m not sure a dual show idea would not have been as successful elsewhere, but it thrived in Chicago.

For the last few years, VCF-MW has continued to grow, but there’s still a significant Commodore presence.  While there’s value in having single-platform shows like World of Commodore, KansasFest, or CocoFEST!, such shows can be somewhat insular, as all of the attendees are already aligned with the platform.  And, though one hopes we’ve all matured a bit, there’s some fun in crowing about platform features or enduring a bit of ribbing over platform weaknesses among friends who own competing systems.  More importantly, there are some classic machines too obscure to command a full community, and shows like VCF allow those folks to show off these all-but-forgotten gems (or stinkers, but they are always interesting).

Thus, my hat is off to those who organize the various shows; truly unsung heroes doing lots of work so lazy bums like myself can drive in, grab a room, shoot the breeze, sell a few things, pack up, and leave.  And, thanks to those folks who take the time to document the events, via photos or video, or both.  It’s nice to be able to look back and see how far we have come. Finally, thanks for Jason Timmons and Jason Compton, for ensuring VCF-MW/ECCC continues.

RETRO Innovations will be once again exhibiting and offering products for sale at VCF 12, September 9-10, 2017

Glenn Holmer’s Galleries:  http://www.lyonlabs.org/commodore/

VCF-MW Galleries: http://vcfmw.org/past.html

 

 

 

Back from the Vintage Computer Festival – East 9.1!

I just returned from a 2102 mile roundtrip excursion to the Vintage Computer Festival – East 9.1 at InfoAge in Wall Township, NJ.  Having been prevented from holding the show in 2013, the VCF-E organizers went all out for the 2014 show, supporting 2 exhibit halls and a separate speaker presentation tent.  I camped out in the vendor hall with our products on display.

IMG_6555 (Large)IMG_6556 (Large)Though this is the first VCF-E I have attended, others remarked that this was the largest Expo they have held.  Thus, I am glad I was able to participate.  Unlike the other shows I have attended, VCF-E is much more structured.  Vendor tables are in their own room, the mornings are dedicated to speaker presentations and vendor sales, and the show floor does not open until the afternoon. Like many of the other more recent events, VCF-E is a 2-day event (Saturday and Sunday), and they even created a special VCF University event on the Friday before the main event.  I didn’t specifically count, but I was told 26 different exhibits were available for viewing in the 2 (yes, two) exhibit halls.

As you can see, I spruced up the vendor tables with some colorful tablecloths, and I brought a vintage CMD-era JiffyDOS wall poster (I purchased it from Click Here SW a few years back).  I brought all of the main store items, though I left some of the more esoteric adapters and such behind as they rarely sell. Sales were not overwhleming, but were satisfactory, especially in light of the fact that most of the day’s action revolved around the “consignment” tables.  I loved the consignment idea (VCF even accepts items for sale, with pricing information from the owners.  They then handle the financial aspects and man the sales table, taking 15% of the sales value).  One individual made over $1600 in sales through this solution.  I even joined in the rush, picking up a TRS80 MC-10 and a Compaq luggable.

Concerning exhibits, there were too many to mention.  I’m not that much into the 60-80’s DEC HW, but it was well represented at the show.  The early microcomputer options were on display, along with some early UNIX workstation options.  Closer to my world, Jeff Brace and Dan Roganti borrowed a number of uIEC/SD and 64NIC+ devices to present their “Artillery Duel”-like multi-player C64 game.  The graphics and such looked awesome, but they were plagued by code issues through the weekend.  They kept the loaner items in hopes of better luck during a June exhibition.  Elsewhere, Michau Pleban and Rob Clarke (An Australian Brit from Switzerland, no joke) were on hand to show off a Commodore 264, a 232, a 116, a Max Machine, and their new cartridge for it called “MultiMax”.  Rob also tried to talk Bil Herd (on site over the weekend) into firing up the V364 Prototype board that Bil had delivered to Rob at the show.  Rob talks more about the unit in his Youtube smoke test for the unit, but it was Bil’s dev board back in the day.

It’s not the same as being there, but here are some galleries to show what was on display and the participants who gathered in NJ:

Heading to the Vintage Computer Festival East!

The ninth “annualish” Vintage Computer Festival East will be held April 4-6, 2014, at the InfoAge Science Center, in Wall, New Jersey.

VCF East is a celebration of computer history from the 1940s-1980s. The schedule includes a hands-on exhibit hall, technical workshops, lectures, a marketplace, tours of the InfoAge museum complex, a dollar-per-pound book sale, prizes, more.

This year’s show will be bigger than ever. New attractions include Friday’s “VCF East University” which is a full day of technical classes. Friday attendees can win an oscilloscope courtesy of Tektronix!

The main show on Saturday-Sunday will have lectures/workshops and dozens of exhibits.

Keynotes include former IBM archivist Paul Lasewicz and IEEE 802 LAN/MAN committee founder Maris Graube. Other lectures topics include software preservation, the history of Franklin Computer Corp., and many more, all scheduled for the morning. In the workshops you can learn hands-on vintage computer repair skills or even build a working replica of something exotic.

This year there will be two exhibit halls instead of one. Exhibits open in the afternoon – imagine an antique car show, but instead of “no touching” signs, everyone has to take you for a ride! Registered exhibits so far cover everything from a real Apple 1 to the M.I.T.S. Altair to DEC minicomputers. In addition, the event’s main sponsor MARCH (Mid-Atlantic Retro Computing Hobbyists) will debut its UNIVAC 1219-B military mainframe computer, circa 1965.

Tickets for VCF East University are just $20 and include a pizza lunch. Tickets for the main show are $15/day and $25/both days. Saturday/Sunday tickets are free for ages 17 and younger. A three-day adult admission is $40.

Proceeds benefit MARCH. Official sponsors include the InfoAge Science Center, VintageTech, Tektronix, the Trenton Computer Festival, Eli’s Software Encyclopedia, and Vintage-computer.com. Archive.org, IBM, and the IEEE History Center are providing informal assistance.

• Steve Wozniak, co-founder of Apple: “Seeing the early equipment at VCF is an amazing experience. For many of us, it’s better than a museum. It touches on all the hopes and dreams of the time and the many efforts to achieve what others thought would never happen. It brings back memories of a revolution in the making. … The people you meet at the VCF are amazing.”

• Lee Felsenstein, moderator of the legendary Homebrew Computer Club and creator of the Osborne 1 portable computer: “In 35 years the personal computer grew from nothing into the most important device shaping everyday life. It should be part of everyone’s education to see how it grew and to learn from the people who grew it in ways they wanted to see it grow. VCF is the place to be where not only the equipment can be seen and tried out but, perhaps more importantly, where the people who rose to the challenge offered by these machines can be met and heard from.”

• Gordon Bell, top DEC engineer and co-founder of the Computer History Museum: “As a speaker at the first September 1998 VCF, I have been delighted to see it grow and flourish. The Vintage Computer Festival is an important institution for computing history simply by getting everyone together for collecting, sharing, and trading all form of bits. Having a forum, gathering, and market for old stuff a.k.a. vintage computers and the software that made them live is an essential way to preserve and expand the history of computing — for some of us, the greatest invention.”

• Dave Ahl, founder/editor, Creative Computing magazine: “Vintage Computer Festival East celebrates the hard work and vision of all the volunteers who have made the InfoAge Science Center –- now a National Historic Landmark — a place where one can learn from the past to live for the future. Oh, and it’s great fun too!”

Full details are online at http://www.vintage.org/2014/east/ and http://www.facebook.com/vcfeast. Contact: Evan Koblentz (President, MARCH; VCF East Producer): evan@snarc.net / (646) 546.9999(646) 546.9999 …. thank you and happy computing!

New(ish) Project: VIC-MIDI

VIC-MIDI Prototype
VIC-MIDI Prototype

This project had its start in a late 2009 discussion between Leif Bloomquist, a Canadian Commodore enthusiast and musician, and myself.  Leif had been playing with a hand-built 6850-based VIC-20 MIDI cartridge designed off a 1980’s era Maplin “Electronics” article, and wondered if a production run could be arranged.  I took a look at the design, and noted that the 6850 UART would be hard to source.  I suggested some design changes to bring costs down, and plans were made to refine the design.

To further the design, I wired up a newer UART (16450-based) to a daughtercard that could plug into the 6850 socket on the original board.  That allowed Leif to refine the software, and provide out the redesign.  Once that was done and successful, we discussed a final production version.  Changes included offering a built-in user-flashable ROM function.

That brings us up to late 2012.  I purchased the parts for a completely new prototype board, but could not get it assembled by World of Commodore, so I brought the parts to the show and hired the assembly done.

Well, the assembly resource took longer than expected to finish the construction, but I did receive this same exact board mid-Feburary 2013.  I fixed a few small design issues, only to discover the board expansion port was wired 100% backwards.  Commodore, for reasons known to them only, named the pins on the VIC-20 expansion port in reverse from the industry standard.  Since the prototype PCB pins were named according to the standard, every one would need modification.

I packaged up the board and sent it back to the assembler, but I must have messed up the address, as it did not arrive in a timely fashion.  Since I had shipped it from the Post Office directly, I didn’t get tracking information, and thus had no idea of its location.  After a few weeks, I resigned myself to the loss of the unit, and started gathering parts for a second unit to be shipped via trackable shipment to the assembler.  As it turns out, the assembler and I were both planning to attend the 2013 Midwest Gaming Classic in WI, so I made plans to transfer a new set of parts during the show.

No sooner than the show ended and parts were transferred, the original package showed up at my office, undeliverable.  I quickly saw the addressing issue, created a new trackable label with the correct address, and sent it on its way.  Which brings us to last week, when the unit arrived, after the rewiring effort.

After all of that effort, I could now begin the potentially laborious task of debugging a “paper design”.  I had designed the entire unit on paper, but had not previously proven out any of the elements on a breadboard.  Though the original UART design was working on Leif’s PCB, the new design was marked different, owing to the additional decoding logic needed for the FLASH ROM.  As such, it was almost a completely new design.   I’m not sure if credit is deserved and who deserves it, but the UART and FLASH ROM read access worked out of the box.  Bank selection for the FLASH ROM did not work, but that’s a minor issue.

And, we’re almost to the point of creating a VIC-20 MIDI production design.

New Project: IECSwitch

IECSwitch v0.1
IECSwitch v0.1

I can’t claim a significant amount of creativity, but over the past few years, two folks have dropped off “VIC-Switch”-like devices in hopes that I could reverse engineer them.  THese are devices used back in the day (typically in schools) to share a single disk drive or disk and printer with up to 8 computers. I long ago drew up schematics of the existing designs, but wanted to freshen up the solution instead of just creating a replica.

Well, as it goes, finding time takes time, but I decided to try my hand at a new design, and here is the current result.  It’s not much at present, though I can enable/disable IEC ports, and “hold” the 64 from timing out the bus request.  Yes, that’s an LCD there.  I found a great price on them, and I think that’ll be in the final design.  It’s only marginally cheaper than a 7 segment LED or two, and much more interactive then a few LEDs.

It’s been awhile since I developed firmware, and this gave me a chance to clean the cobwebs off my programming skills.

Coming Soon: SuperOS/9 MMU Kit

SuperPET OS/9 MMU
SuperPET OS/9 MMU

In the “another project that has been long in gestation” category comes a niche offering for those with Commodore SuperPET machines and a desire to run the OS/9 operating system.  OS/9, a multi-tasking, multiuser, realtime OS with UNIX-like qualities, was popular in the 1980’s and ran on machines with the Motorola 6809.  In addition to the small TRS80 Color Computer, the SuperPET includes a 6809, but the standard memory map of the SuperPET does not lend itself to OS/9 operation.  That is where this little board comes in.  Installation does not affect normal SuperPET operation, but extends it with OS/9 compatibility.

The SuperPET, a variant of the Commodore 8032 that included additional boards designed by the University of Waterloo, did not sell well, as far as I can tell, and limited (though not ultra-rare) numbers exist.  Still, for those lucky enough to own one, OS/9 can truly turn the SP9000 (another name for the SuperPET) into the MicroMainFrame (another name for the SuperPET).

The project has been gestating since 2008 in some fashion.  Late that year, TPUG member Golan Klinger asked if I could reproduce the SuperPET MMU board, which TPUG members created in 1985. for a possible club fundraising activity.  I dutifully created a new layout of the design, and awaited next steps.  Around the same time, Mike Naberezny (of 6502.org fame) started discussing the board, and we eventually compared notes.  Over time, it became evident that TPUG was not going to pursue offering the unit for sale, and Mike performed a significant amount of legwork obtaining permission to replicate the software from Radisys (who purchased the OS/9 rights) and permission from TPUG leadership to offer the PCB.  Thus, the majority of credit for this offering goes to Mike, who has a web site devoted to this impressive little board.  I’ll put one in due time, but it won’t provide any more detail than Mike’s.  I should also give a shout out to Steve Gray, who helped with information and PCB scans.

Currently, due to the low volumes, the unit will be available in kit form only for approximately $30.00.  Thus, break out your soldering iron and a weekend of time to add this capability to your SuperPET!

C4 EXPO 2013 No More

Regrettably, I found out today that the upcoming C4 EXPO (which was going to be a all encompassing retro convention) has been cancelled for 2013.  We last attending C4 EXPO in 2011 when it was held in The Drawbridge Inn in KY.  In addition to the reasons given on the web site,  I think the combination of the venue closure and the fact that the event was being managed by a single person contributed to the cancellation.

With the cancellation, CommVEX appears to be the next Commodore conference event.  I’m not sure if RETRO Innovations can make the trip, but I am considering it.  It would be nice to meet some of the west coast and southwest enthusiasts.

QuadPortIEC Arriving!

QuadPortIEC FInished Unit
QuadPortIEC Finished Unit

Sometimes, a product gets lost on the way to final production.  Our QuadPortIEC 4 port IEC bus hub is one such product.  After announcing the design here and showing off completed boards here, we focused our attention on the recently introduced ZoomFloppy and then the EasyFlash 3.  Finally, we sent the boards off for assembly, but still felt a bare board with wires would simply not work as a product.  Finally, about a year or so ago, Commodore enthusiast Jim Peters in Iowa requested some bare PCBs and assembled units for personal use, which we supplied.  He took it upon himself to machine finished cases for the units, with fabulous results.  Thus, we hired him to supply finished cases for the remaining stock, and now can offer them in the store.

The design has not changed; QuadPortIEC is nothing more than a “dumb” IEC hub.  ATN switches on the front for each port allow “silencing” of each bus segment, but that’s the only functionality exposed.

Still, we are glad to finally put the units in the store, where they will sell for USD$30.00.  Since the units fill out a small flat rate box, we may need to adjust shipping charges for buyers.