8bit-times Ep.24: The VIA Shift Register Bug
Update: I have done a followup with the response from WDC about this situation, and other interesting use cases for the VIA! • 8bit-times Ep. 25: VIA shift register bug ... --- In this video we take a technical deep dive into the VIA 6522 Shift Register Bug - the cause why the Commodore (serial) disk drives like the 1541 were so slow. We look at the bug, the conditions it happens, and test it out with various types of VIAs we have available. We also look at how to prevent it. We reached out to Western Design Center about the bug, to see what they have to say to it. Unfortunately they said they need more time, so I'll keep you updated here when we get it. Note that I cooperated with Dave McMurtie from the @Commodore International channel, who at the same time publishes a video on the historical aspects of the topic why Commodore disk drives are so slow. I recommend you watch it: Dave's companion video: • Why Was the Commodore 1541 disk drive so s... Dave's channel: @commodorehistory PS: Martin Thierer pointed me to a test he did where he generated synthetic control signals for a 6522 using an STM32F4, and could reproduce the bug. It consistently happens when the positive CB2 edge happens 90-40ns (in his tests) before the negative edge of Phi2. Here's the (German) writeup: https://www.forum64.de/index.php?thre... PPS: yes, the Apple // did NOT have a VIA ... Sections: 00:25 Introduction 01:40 Commodore IEEE vs serial bus 02:00 Shift register use in the Commodore serial bus 02:54 The Shift register bug 03:43 PET Shift register sound demo 04:18 Shift register serial communication and how the bug affects it 06:50 The Commodore "Fix" 07:11 Testing the bug 07:58 Test program and errors detected 08:49 My test setup 09:47 VIA variants tested and how to run the tests 10:33 Test variations 11:42 How to fix the shift register bug 12:55 Dave's tests on the VIC-20 16:19 Test results 21:06 Verifying the schematics 22:34 Test results summary 23:00 Consequences 25:50 Epilogue - two days later Links: Synertek SY6522 datasheet with shift register warning: https://web.archive.org/web/202207081... W65C22 datasheet at the WDC website https://www.westerndesigncenter.com/w... The test programs we used: https://github.com/fachat/via-sr-bugtest Reversed engineered VIA internal schematics: http://forum.6502.org/viewtopic.php?f... VIA shift register bug Fix: http://forum.6502.org/viewtopic.php?p... VIA differences and Fixed VIAs: http://archive.6502.org/datasheets/ro... CIA 6526 datasheet: https://web.archive.org/web/201811260... Western Design Center https://www.westerndesigncenter.com/ PET sound demos: https://shiru8bit.bandcamp.com/album/... https://retrocomputingforum.com/t/bac... • No Pets Allowed (Speaker & SID Versions) -... (Sound first with Shift register, then with SID)

8bit-times Ep.23: Micro-PET and Ultra-PET updates

8bit-times Ep. 25: VIA shift register bug followup

This Computer is from a Defunct Supercomputer Company

XGecu T48 EPROM Programmer Box Opening & Linux Testing

This Commodore 1541 hides a terrible secret.

Adding 1MB to an 8-bit Computer!

6502 Turns 50! The BEST 6502 Computer of 2025 is here!

27c3: Reverse Engineering the MOS 6502 CPU (en)

Can you replace your C64 PLA for under $3?

8bit-times Ep.26: The GeckOS operating system!

Wait, you can overclock the NES CPU?

Is this the FASTEST and CHEAPEST 8-Bit Computer Ever?

DesTestMAX: A revolutionary new diagnostic ROM for the C64

Meet my new Litton Minicomputer (it has Drum Memory)!

The mistake that destroyed ESCOM | Germany's PC empire fell in seconds

What Happened to the Zilog Z80? Why Modern Microcontrollers Killed the Legend

The SID: Classic 8-bit sound

Looking at my C64 Ultimate and trying to fix the keyboard flex (Ep.38)

Considerations for making a Commodore 1581 Disk Drive

