Commodore 64 Repair

Commodore 64 motherboard Assy No. 250407
Commodore 64 motherboard model 250407

While I wait for parts for my recalcitrant ZX Spectrum, I turned my attention to a sick Commodore 64 bread bin model 250407 that I picked up from a friend. As with the ZX, this C64 doesn’t boot at all. No black screen with the white line on the left, just… nothing.

At least this C64 does not look like it had any work done internally. The soldering on the bottom looks factory, and there’s no messy flux residues. Both the SID and VIC chips are socketed, but I think this generation all came this way.

I have a loaned power supply for this board, which is a dodgy original outputting 10.6VAC on the 9VAC line, and +5.2V on the 5V DC line. Not great, not terrible, and it’s definitely going to be replaced with a modern version down the line. For now, and for testing, it will do…


Good Power Supply, Bad Voltages

Testing for voltages revealed that the 7805 was outputting a perfect +5v, and likewise the 7812 was producing +12v. Leaving the C64 on for a bit, the VIC chip got warm, as expected, but it was the only one. Everything else was as cold as my ZX Spectrum series 2. Hmm….

Probing every chip for voltage revealed that the SID chip was the only one getting power, and it was only getting some of the volts, but not all of the volts. 12v on Vdd (pin 28), but nothing on Vcc (pin 25) where +5v is expected. It was really odd that the voltage regulators were working but, none of the +5v were making it upstream.

My biggest clue to fixing this came from a thread on https://www.lemon64.com/forum/viewtopic.php?t=64491 with someone having a similar issue. One poster suggested checking the system led at CN10. (Both outer pins on this connector are +5v.) If the LED wasn’t lighting up, it could only be the power supply, the power switch, the LED or, least likely, the filter choke.

Testing CN10, I found there was no voltage on either of the +5v pins, so at least I knew the LED wasn’t faulty. (whew!) The next easiest culprits to check was the power connector and power switch. The power connector was all good, delivering the +5.2V and 10.6VAC I had seen when measuring the power supply directly. However, I noticed the switch only had power and continuity on the pins on the right side, which deliver the 9VAC from the power supply.


Bad Switch

I desoldered the switch from the motherboard, did additional continuity testing, flicked the switch back and forth a bunch of times, sprayed some deoxit in there, but nothing worked. So I opened up the switch by lifting the metal tabs on each side, and lifted off the top metal part. Inside, everything looked ok, no corrosion and still a little bit of lube left. The switch contains two loose metal tabs that rock back and forth, and make/break the connection when pushed by a rubber pad connected to the switch mechanism. Nothing looked broken, but to test it out, I swapped the metal tabs inside the switch.

I provisionally but things back to together, did the continuity test and everything worked. Both sides of the switch now conducted when flicked on. I didn’t take any pictures of this process, but Retro64 has a great post with lots of pics describing how to restore these switches:

https://retro64.altervista.org/blog/commodore-64-fix-restore-key-and-power-switch/

After soldering the switch back in, I now get the expected voltages on the memory, PLA, CPU, CIA’s, etc. Woohoo! Time to plug this into a monitor!

And… I get a black screen with the vertical white line on the left.


Black Screen of Bad Boot

So… We know the power supply is ok-ish, voltages from the regulators are good, ICs are getting the right voltage levels on the right pins, and the system LED even lights up now. The #1 culprit at this point is the PLA and that’s where I’m going next. Desolder the current one, add in a socket and order a modern CPLD based PLA replacement.

I ordered one of the cheaper ones ($15) from eBay. Hopefully it will get here soon and the fun can continue. Stay tuned!

New PLA and Misbehaving Multiplexers

So the new PLA finally arrived. I excitedly plugged it in and… blank screen. Even with a deadtest ROM. *sad face*

So I went back to the drawing board, did some research and learned a few new tricks…

I left the C64 running for a bit and then checked the temperature on various chips. I have never had a C64 before, so I wasn’t sure what was “normal” and had to go on what I read online… On my board, the SID and PLA chips were the hottest, the CPU was warm, and the ROMs were a little cooler. Both CIA chips and all of the memory chips were barely warm. As far as I could tell, all of this was looking normal…

Until I noticed that U13 was unusually warm, while its twin for the second bank of memory, U25 was room temp. Closer inspection revealed that U13 had a MOS 7708, and U25 had a 74LS257BI. So it appears that something was replaced on this board at some time it its history.

U13 and U25 are multiplexers (commonly now 74LS257AN chips) that route the address lines from the microprocessor to the RAM. If these fail, it may result in anything from a black screen to garbled text, etc.

I desoldered them and tested both ICs in the TL866+ using the handy logic test function. The LS257 passed the logic test, but the 7708 failed repeatedly.

TL866+ IC Logic Tester
7708 go whomp-whomp


I added sockets to the motherboard for these ICs, and replaced the chips as they were before, (7708 in U13), and I got the blank screen again. Then I swapped U13 with U25, tried again and… got a blue screen. Then restarted and got a blue screen with garbage characters. Restarting only resulted in these two outcomes but this was still progress. When I swapped the ICs back, the C64 went right back to booting to a blank screen. Finally convinced this was the issue, I ordered some replacement 74LS257AN’s and resigned myself to waiting another couple of weeks…

Garbage screen when U13 and U25 are swapped.


PLA testing with the TL866+

In the meantime, I found a GitHub site with an import file for the the TL866+ which would allow it to test PLA chips! Here is the link to the GitHub page: https://github.com/ktelep/C64_PLA_Logic_Test_Xgpro

The instructions are straightforward, in Xgpro, click Device > Logic IC Test, and use the Import button to load the custom logic file. Once imported, you should see User-C64PLA_2 at the end of the ICs list. Select that, drop your PLA into your TL866+ (mind the orientation!) and click TEST. To no ones amazement, the original PLA failed testing with the TL866+.



C64 Diagnostic ROMs and DesTestMax to the rescue!

Throughout all of this testing on the C64, none of the usual diagnotic ROMs worked. Every one I tried, all gave a blank screen. The dead test ROM gave an all white screen when I swapped U13 and U25, but that was about it… Then, thanks to a YouTube video on Adrian’s Digital Basement, I discovered the DesTestMax diagnostic ROM: https://factorofmatt.com/destestmax

This diagnostic BIOS is amazing! It works differently from other diag ROMs, and it was the first time I got anything legible from this C64.

Pertinent bits from the DesTestMAX web page:

The DesTestMAX project aims to improve upon Commodore’s Dead Test cartridge by using a more comprehensive memory test strategy and provide easier to interpret diagnostic output.

DesTestMAX utilizes the MAX (or ULTIMAX) cartridge mode as it allows us to place code directly in the $E000-$FFFF block of memory that gets executed as soon as the system resets. Such a situation allows the DesTestMAX code to take complete control of the system right from the get-go. Unlike the regular Commodore 64 boot process, DesTestMAX makes very few assumptions about the state of the machine and can produce usable results even with a severely broken machine.

The 6510 CPU, VIC-II and PLA need to be functional, though the ROMs, CIA’s and SID are not required and can be removed if socketed.

So even with U13/U25 in an unhealthy state, DesTestMAX (while giving some odd results) was still able to output some useful data. Since the 6510 CPU, VIC-II and PLA need to be working for the DesTestMAX ROM to load, I was able to test the original PLA on the C64. This confirmed that the original PLA was indeed faulty, and it only produced a black screen even with DesTestMAX.



Enter the 74LS257AN

So after 2 weeks of waiting the 74LS257AN chips arrived from AliExpress. I grabbed 2, tested them in the TL866+, and after a clean bill of health, dropped both into the C64 and… IT LIVES!

C64 boot screen

It booted straight into the C64 welcome screen and reported the normal 88,911 bytes of available memory. After this the DesTestMAX ROM was able to complete testing and all systems passed. Then the DeadTest ROM was also able to complete memory testing, and confirmed all RAM was good. Finally, the C-64 Diags ROM was also able to complete testing and verified that everything (that you don’t need a testing harness for – those are the ones reporting as “bad” below) was working perfectly.

DesTestMAX ROM
DesTestMAX
C-64 DIAG ROM
C-64 DIAG


Time for some Space Taxi!!!!




Here are some handy URLs that helped me troubleshoot this C64

Show 2 Comments

2 Comments

  1. Luka NIrvan

    Amazing save, Luis!
    Congrats!

    Very best,
    Luka

Leave a Reply

Your email address will not be published. Required fields are marked *

 

This site uses Akismet to reduce spam. Learn how your comment data is processed.