7

The Vic-20 used two 6522 VIA chips for I/O. I asked why it had two of them but thanks to a comment from Bruce Abbott, I now think that wasn't quite the question I needed to ask.

What I really need to ask is why it needed any at all? For example, the ZX Spectrum had no equivalent chips, and seemed to communicate with its keyboard and peripherals just fine without them. The Vic was supposed to minimize cost. The designers wouldn't have spent money on extra chips for no reason. They must have seen some advantage to be gained by including those chips.

What advantage did the Vic gain from the VIAs, relative to machines like the Spectrum that lacked them?

7
  • 1
    ZX Spectrum (at least 48K) had like 1 port to read/write, sure it could go away with no dedicated IC.
    – Vlad
    Dec 18, 2020 at 9:51
  • 5
    The ZX Spectrum used a 'ULA' for at lest part of the keyboard handling.
    – UncleBod
    Dec 18, 2020 at 11:05
  • 2
    The 6522 seems to be an upgraded 6520 specific to Commodore, but there was an entire line of general purpose peripheral interface ICs, like the 6520 PIA (Peripheral Interface Adapter), the 68xx equivalent 6821 PIA and the 6532 RIOT (RAM / IO / Timer) that could interface with the 65xx or 68xx line of microprocessors. They were used in all kinds of systems based on these processors.
    – StarCat
    Dec 18, 2020 at 11:22
  • 3
    @StarCat BBC Micro also had a couple of 6522 chips.
    – richardb
    Dec 18, 2020 at 12:44
  • 2
    @Vlad I see no reference in the question about anything but ZX Spectrum. No clone was sold under that name.
    – UncleBod
    Dec 18, 2020 at 21:55

3 Answers 3

12

Commodore owned MOS technologies, who made the VIA chips. Although the VIC-20 might have been able to replace a VIA chip with a 4051, a 74LS139, a couple of 74LS373s, and eight resistors, I don't know that doing so would have really saved anything compared to the in-house cost of the VIA. Further, using a second VIA made it possible for them to have one timer tick feed the IRQ while the other fed NMI. Not essential, but nice nonetheless.

8
  • 4
    I'll also point out that the 6522 was a fairly inexpensive option during the period that the VIC-20 was manufactured.
    – jwh20
    Dec 18, 2020 at 10:25
  • 11
    "a 4051, a 74LS139, a couple of 74LS373s, and eight resistors" - Integrated circuits are more than just speed - the fewer separate components, the faster/easier/ cheaper it is to assemble a device, particularly a mass-market consumer device. Dec 18, 2020 at 15:10
  • 2
    @manassehkatz-Moving2Codidact: A company that has no affiliation with the maker of something like the VIA may not want to trust that it's going to continue to be available as long as they need, but if a design uses commonplace parts like the 74LS series, substitutes would likely be available from multiple sources.
    – supercat
    Dec 18, 2020 at 15:53
  • 7
    adding to what @manassehkatz-Moving2Codidact wrote: board area costs money, too Dec 18, 2020 at 15:53
  • @supercat If one has to trust the same company to continue the CPU, saving a VIA does not change the situation.
    – Raffzahn
    Dec 18, 2020 at 17:22
8

Sinclair was a company particularly sensitive to BOM¹ costs. They were willing to put in quite a lot of development effort to have a machine that was a cheap as possible to manufacture, and selling computers at low cost was their main competitive advantage.

Commodore, on the other hand, was not terribly sensitive to BOM costs. (Compare, for example, the Apple 5.25" diskette system to Commodore's drives; Commodore drives had a lot more parts, including a CPU, I/O chip, RAM, and ROM where Apple got by with a handful of small-scale integration 7400-series parts and a ROM or two.) And Commodore didn't have to be quite as sensitive since they owned a chip manufacturer (MOS).

Where Commodore was quite sensitive was development cost and speed: read up on the history of almost any Commodore computer product and you'll see that Tramiel was always pushing hard to get a product developed and out for demos at the next trade show.

For the VIC-20, using a couple of 6522 VIA chips offered several advantages in this regard:

  1. Using a more sophisticated chip driven by software makes for easier, faster and cheaper development than building the same functionality out of more basic electronic building blocks.
  2. In the case of the VIC-20, they already had a computer (the PET) that used the same chip² and had software written for it. Thus they could re-use much of the existing hardware design work and software (e.g., for the keyboard, cassette tape and "user port" expansion interfaces) rather than having to develop the hardware and software from scratch.
  3. Since Commodore owned the company that produced the chips, they effectively bought them at cost, rather than at cost plus a substantial markup to allow the chip vendor to pay off development costs and make a profit.

Essentially, being able to reuse much of the PET design saved a lot of development time and got the computer done sooner, and the additional BOM cost didn't hurt Commodore as much as it would have hurt another company that did not manufacture the chips in house.


¹ "BOM" refers to the "bill of materials," which is the cost of all the components used to build one unit of the product.
² Actually, the VIC-20 used just one 6522 VIA and two 6520 PIAs. However, the VIA was basically just a PIA with a few more features added. Especially if you're the manufacturer of them, they probably weren't significantly more expensive.

2
  • 1
    Not to forget that MOS/Commodore's designers came from a background using these systems, not reinventing the wheel. Reusing existing designs (chips as well as software) is a key point to short time to market and low upfront cost. Quite important in a fast changing market. Likewise the reduced BOM due less chips and lower cost boards (the VC20 was a quite cost sensitive design). So it's a clear Win-Win.
    – Raffzahn
    Jun 22, 2022 at 19:02
  • 2
    I suspect one of the big savings of using 16 bits of a VIA for keyboard I/O is that I don't think there were any commonplace 74LS chips that were like a 74LS373 but with pull-ups on the inputs or open-collector outputs. If such chips existed, using one of each along with a single 74LS373 to handle a few other I/O functions, and adding a logic gate (e.g. an OR) to free up four outputs on an existing 74LS138 (UD2 in the rev E schematic) could have eliminated the need for one of the VIA chips, but as it is the VIA replaces not just the 74LS373 chips but also eight pull-up resistors.
    – supercat
    Jun 23, 2022 at 16:49
3

Sinclair's goal was always to cut down costs at the expense of quality - reason why it has a flimsy membrane. They also saved components by performing partial decoding, which is inneficient and cause issues when expanding the system with third-party addons. They also integrated most of their functionality in the form of an ASIC made by Ferranti. But that does not relate with why the VIC-20 has two VIAs.

After the PET/CBM 4032/8032 Commodore had no clear direction. Their goal was to introduce a color machine and therefore made some colour PET prototypes; they even started the final family of PET, later recalled, called CBM II. But this was not enough.

Before the production of the PET, Commodore bought MOS Semiconductor Group and was able to produce its own chips. This enabled them to produce the 6502 microprocessor and many of their by then standard support chips: the 6520/6521 PIA, the 6522 VIA and,the 6532 RIOT, the ROM-based 6530 RRIOT and the 6545 CRTC. All those chips were being made by MOS, and Rockwell, Synertek and others under the same reference, Motorola as 6820/6821, 6822, 6845 and also Japanese companies such as Hitachi.

The original VIC ic was not meant for a microcomputer as it was thought to be used in medical equipment as display controller but the preproduction batch was left without buyers. As far as I know, an engineer smuggled a VIC ic out from the company and brought it at his home, bought the CPU and VIAs from electronics stores and built a computer which would become the VIC-20 prototype. To save time he reused code from the 40 column PETs but maintained the separation between Kernal, Editor and BASIC. He then submitted the computer at his office where it was examined and a a project approved.

To sum it up:

  • There was reuse from the PET both from a hardware and a software point of view.
  • The engineer that designed the VIC-20 had experience with the 65xx family of peripherals.
  • It was (and still is) easy to find brand-new 6522. They were sure they wouldn't have shortage of parts.
  • It is not a system integrated into an ASIC, but a system built around an already existing ASIC.
  • They were making the VIAs, therefore they could get them at lower costs.
  • If they wanted just I/O ports they would have used a 6520/6521 PIA, but used the 6522 VIA because each unit also contains a programmable timer.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .