• Please review our updated Terms and Rules here

Debugging a KIM-1 computer

Hi
On a suggestion from another friend, I'm starting a new thread rather than
continuing an older thread started by another.
I've been debugging my KIM-1 and while doing so, hopefully helping others.
What does one do when it doesn't work?
One can check some obvious places like the clock signals, reset pulse,
interrupts and sync signal.
Beyond that there is little that one can do with the monitor code dead.
The problem could be any of the chips, from the simplest 7404 to one
of the RRIOT chips.
I've always said that one should write code and use an EPROM to test the
functions of the board.
Now I'm putting actions to these words.
First one needs to create a place to put an EPROM if there is no socket.
That is what I did for the KIM1. I have created a small board with a minimum
of parts on a prototype board.
Here is the schematic. I will post test in later messages.
It uses a 2764, 7404, 7402 and 7474.
Dwight
Hey Dwight,

I have an old KIM-1 that looks like it has multiple failures. It must have taken a pretty big shot, when it failed. I have replaced the failed 6530-002 with a Corsham 6532 replacement board. That did help, start to light up
one segment with a small c. I piggy backed all the memory and was able to get all the segments to light up, but just the lower half of the segments, although the C segment was not working. I could enter an address like 1111
and see the lower half of the 1's. If I entered a 6 or a D, segment C would not light up. I am unable to reproduce this by piggy backing all the memory again. So, now I am back to 1 small c, showing up.

With the Corsham 6532 replacement board. I am now seeing good signally coming coming out of U4. I am supper busy this week, but I want to start looking at U24 and U17 to start with. Any suggestions? I also suspect, that
the 6530-003 may be bad as well. As I had to replace the 6502 and the 6530-002, there is a good chance that the 6530-003 is also bad. Can I simply remove it while testing?
I did create a test board for the 6530-002 using a working KIM-1. I was able to access the I/O and ROM sections using K2 and K4. The ROM looked like possible A3 was bad, as it kept repeating good code every 8 bytes, replacing code that was supposed to be there.

I believe you worked on a diag board for the KIM-1. Do you still have one laying around? It might be fun to test this KIM-1 using a good diag board. I will not be able to do much until Next Sunday or Monday. Except maybe a quick fire up
from time to time.
6532 Replacement.jpg
 
Hey Dwight,

I have an old KIM-1 that looks like it has multiple failures. It must have taken a pretty big shot, when it failed. I have replaced the failed 6530-002 with a Corsham 6532 replacement board. That did help, start to light up
one segment with a small c. I piggy backed all the memory and was able to get all the segments to light up, but just the lower half of the segments, although the C segment was not working. I could enter an address like 1111
and see the lower half of the 1's. If I entered a 6 or a D, segment C would not light up. I am unable to reproduce this by piggy backing all the memory again. So, now I am back to 1 small c, showing up.

With the Corsham 6532 replacement board. I am now seeing good signally coming coming out of U4. I am supper busy this week, but I want to start looking at U24 and U17 to start with. Any suggestions? I also suspect, that
the 6530-003 may be bad as well. As I had to replace the 6502 and the 6530-002, there is a good chance that the 6530-003 is also bad. Can I simply remove it while testing?
I did create a test board for the 6530-002 using a working KIM-1. I was able to access the I/O and ROM sections using K2 and K4. The ROM looked like possible A3 was bad, as it kept repeating good code every 8 bytes, replacing code that was supposed to be there.

I believe you worked on a diag board for the KIM-1. Do you still have one laying around? It might be fun to test this KIM-1 using a good diag board. I will not be able to do much until Next Sunday or Monday. Except maybe a quick fire up
from time to time.
View attachment 1244805
As I recall, the -003 chip is only used for cassette I/O and expansion I/O. It is unlikely the source of your problems. Of course, there is the possibility of loading something on the bus but in general a lot would fail if the -003 chip was causing such problems. Pulling these chips off the board has a high risk of trace damage.
The diagnostic board has been recreated, if you look back to post 41.
Piggybacking RAM is not a the best method to finding bad RAMs. It is not always a sure way of testing RAMs. The problem with the 6502 is that it needs some working RAM 0000H to 0177H to do much of anything. The test have I put on the diag board is not real thorough but is about the best that can be done depending on only the registers in the processor ( I use all the registers, even using the stack pointer as temporary storage ). Without working RAM, one can't check the display or enter the keyboard data! Every thing depends on working RAM!
Without good RAM, trying to debug anything else is a waste of time.
The 7406 chips ( U17) are a notorious failure points but with non-working RAM, I wouldn't even bother looking at them yet.. I may have a blank diag board someplace but I'd have to check my storage.
Dwight
 
I did a massive write-up somewhere on VCFED about removing U2 and using a handful of resistors and some bits of wire to checkout U24, the LED driver transistors, the LEDs themselves, the driver logic gates and the keyboard.

I haven't got the time today to look for it, but I could recreate it (possibly tomorrow).

Basically, PA0 through PA6 drive the individual segments and PB1 through PB4 selects one of the seven-segment LEDs to display the segments on. By hardwiring these signals at the socket of U2 (either to +5V via a resistor or directly to 0V) permits you to select each digit and segment in turn.

Be aware though, that PA0 through PA6 are also used by the keyboard - so a faulty keyswitch or two could mess up the displays.

You can checkout the keyboard on the bench with no power and a multimeter though...

Dave
 
Last edited:
I was digging through my piles of stuff for the KIM-1. I found a box of stuff marked "KIM-1 project".
In it I found 6ea first pass diagnostic boards. They were functional but had two things wrong with them. I didn't mask the edge connector pins, on the bottom, so they all have solder mask on them. The other mistake was that I forgot the pullup resistors for the three wires that go to the P2 connector.
The edge connector pins that need to be connected can be easily scraped clean enough to solder a connector to. Hanso's schematic can be used to locate the parts, with a minor change:
U1 and U3 are swapped. ( easy to figure out a U3 on my board is a 28 pin EPROM and not a 74LS04. )
I don't have all the parts for it. You'll have to dig them up. I can send an EPROM for it but that will make the mailing cost higher for the package, instead of an envelop. You'll need a 27128 for that.
I don't have any extra edge connectors. These are a pain to locate. You need one for the P1 bus connector and one for the P2. If have a jumper wire, on P2K, to enable the KIM's onboard ROMs, to boot, you'll need to disconnect it ( most people solder a wire on the board, I don't know how you connected yours ). With the diagnostic board connected you can switch back and forth between booting to the diagnostic board or boot from the KIM's -002 ROM.
One other thing one could do is to use the diagnostic's EPROM for other things as well. It has several switch banks that are unused. One can also use the empty spaces on most of the diagnostic code banks for other, short code, like Butterfield's games ( may need slight address relocations, not particularly hard to do by hand or reassembling ). Most of the diagnostic codes are quite short and leave a lot of blank space in the 1K banks, they run in. I'd thought of using Peter Jennings' micro chess but that would take two banks as part goes in the RAM memory of the -002 ( or -003, I don't recall ). If one does add it to the diag ROM, one could also add the typical list of opening move setups ;)
This is why I keep the board connected to the KIM.
I would think $5 would cover the board and postage to any where in the USA. PM me with your address if you are interested.
Dwight
 
As I recall, the -003 chip is only used for cassette I/O and expansion I/O. It is unlikely the source of your problems. Of course, there is the possibility of loading something on the bus but in general a lot would fail if the -003 chip was causing such problems. Pulling these chips off the board has a high risk of trace damage.
The diagnostic board has been recreated, if you look back to post 41.
Piggybacking RAM is not a the best method to finding bad RAMs. It is not always a sure way of testing RAMs. The problem with the 6502 is that it needs some working RAM 0000H to 0177H to do much of anything. The test have I put on the diag board is not real thorough but is about the best that can be done depending on only the registers in the processor ( I use all the registers, even using the stack pointer as temporary storage ). Without working RAM, one can't check the display or enter the keyboard data! Every thing depends on working RAM!
Without good RAM, trying to debug anything else is a waste of time.
The 7406 chips ( U17) are a notorious failure points but with non-working RAM, I wouldn't even bother looking at them yet.. I may have a blank diag board someplace but I'd have to check my storage.
Dwight
This board probably suffers from multiple failures. I purchased a Corsham 6530-002 replacement board which corrected the signals that I was seeing at U4 74145 decoder. I am now seeing the left most display lighting up.
However the U24 74145 does not seem to be receiving the correct input signals to start with. Inputs A,B and C are signaling where as D is not. All 4 of these inputs should be signalling, for the Keypad and Displays to work. (I have replaced both 74145s - with no change.)
I have removed and socketted the RAM chip at U6 as it was producing a constant high on pin 12, Data Out. When I replace the chip, my display no longer showes up, but depending on the RAM chip that I insert, I do see what looks like the correct signally on both pins 11 and 12. I do not have a way to test the 2102s which would be helpful.
I will probably create a video today, using my logic probe. Showing a good working board and its signals and then show what I am seeing on the bad board. I will try to post the link here.
I do not seem to be receiving notifications. I just happened to take a look today, to find your comments. I do not know if private message will work any better, but you can try.

6532 Replacement.jpg
 
If you remove 6530 U2 - you are able to drive the four inputs to U24 (via PB1, PB2, PB3 and PB4) that would drive the individual digits.

Likewise, you can drive the seven inputs to U17 and U26A (via PA0 through PA6) that would drive the individual segments.

Use low-valued resistors (say 100 Ohms) to connect the port signals to either LOW (0V/GND) or HIGH (+5V/VCC).

A HIGH signal on PA0 through PA6 would drive the segment of the selected digit ON whereas a LOW signal would drive the segment of the selected digit OFF.

The encoding of PB1 (least significant bit) through PB4 (most significant bit) selects a specific digit. An encoded value of 4 (0100) through 9 (1001) would select the digits from U16 through U23 respectively.

This would fully check out the digit drive logic, the displays and the segment drive logic from U2.

As stated in my earlier post, if a key is shorted out - this would cause problems. Check these with a multimeter set to read resistance (with the power OFF) first to make sure each key is open circuit when not pressed (high resistance) and a low resistance when the key is pressed.

I am just going to state the obvious here - but you do have the DECEN signal on P2 pin K grounded don't you?

Dave
 
Last edited:
I have just uploaded a video to my Youtube channel that shows what good signals look like as well as what I am seeing on the board that I am trying to repair. At the very end of this video
I was able to get all the displays to light up temporarily. Which is pointing to the fact, that, at this point it maybe just down to a memory problem. So, like it or not, I will probably have to remove
and socket all the memory on board. Not something I am looking forward to !!! So watch to the end of this video.
 
I have just uploaded a video to my Youtube channel that shows what good signals look like as well as what I am seeing on the board that I am trying to repair. At the very end of this video
I was able to get all the displays to light up temporarily. Which is pointing to the fact, that, at this point it maybe just down to a memory problem. So, like it or not, I will probably have to remove
and socket all the memory on board. Not something I am looking forward to !!! So watch to the end of this video.
You really want to be using my diagnostic board. The 6502 depends quite a bit on the RAM. There is quite a bit that the diagnostic board can help with that a logic probe alone can't help with ( nice logic probe though ). I can see that you can get all the displays scanned. I go through different test with the diagnostic board, in sequence of what is needed to go to the next operation. I start with a simple processor test. It only needs the buss working and processor. It does not depend on any thing else. It doesn't do an exhaustive instruction test.
I next do a RAM test. It runs completely in the processors registers while testing the RAM. It will help you without having to socket the RAMs.
I do test of the display and the keyboard ( using code on the diagnostic to avoid issues with the machines ROMs ). I also do a CRC check of the onboard ROMs.
Your logic probe will be much more effective if you can run individual test instead of expecting the board to give you much help.
It is up to you.
Dwight
 
You really want to be using my diagnostic board. The 6502 depends quite a bit on the RAM. There is quite a bit that the diagnostic board can help with that a logic probe alone can't help with ( nice logic probe though ). I can see that you can get all the displays scanned. I go through different test with the diagnostic board, in sequence of what is needed to go to the next operation. I start with a simple processor test. It only needs the buss working and processor. It does not depend on any thing else. It doesn't do an exhaustive instruction test.
I next do a RAM test. It runs completely in the processors registers while testing the RAM. It will help you without having to socket the RAMs.
I do test of the display and the keyboard ( using code on the diagnostic to avoid issues with the machines ROMs ). I also do a CRC check of the onboard ROMs.
Your logic probe will be much more effective if you can run individual test instead of expecting the board to give you much help.
It is up to you.
Dwight
I really would have liked using your Diag board on this KIM-1 as it had multiple failures. I am currently in the process of removing all the ram chips and installing sockets. I am of course assuming, from what I have seen while piggy backing, that this may resolve the remaining problems that I am having with this board.

It took one heck of a shot, back in the day. I believe the owner had it hooked up to a few unprotected relays. That must of kicked back and fried almost everything on the board.

Even if I do get this working, it might be fun to try out your diag board. By placing all the old damaged chips, back in the sockets and running the diag from scratch. I have not tested the 6530-003, but I have removed it for now, as I do not need it and I am assuming that there is a good chance that it is bad as well.

I did build my own test board for the 6530-002, where I saw that the ROM was not working correctly. That is why it would not boot up correctly at all, before I replaced it with the Corsham board. I would like to eventually be able to replace the Corsham board with something that does not take up as much space on the board and look so ugly...
 
I really would have liked using your Diag board on this KIM-1 as it had multiple failures. I am currently in the process of removing all the ram chips and installing sockets. I am of course assuming, from what I have seen while piggy backing, that this may resolve the remaining problems that I am having with this board.

It took one heck of a shot, back in the day. I believe the owner had it hooked up to a few unprotected relays. That must of kicked back and fried almost everything on the board.

Even if I do get this working, it might be fun to try out your diag board. By placing all the old damaged chips, back in the sockets and running the diag from scratch. I have not tested the 6530-003, but I have removed it for now, as I do not need it and I am assuming that there is a good chance that it is bad as well.

I did build my own test board for the 6530-002, where I saw that the ROM was not working correctly. That is why it would not boot up correctly at all, before I replaced it with the Corsham board. I would like to eventually be able to replace the Corsham board with something that does not take up as much space on the board and look so ugly...
There are a number of the people that bought my original kit that after using the test board found no issue with the ROMs. The ROM replacement is made of two small PCBs that fit under the 6532. There are two active parts on it, one being a PAL for address decoding and an EEPROM to hold the ROM image. As shipped the EEROM is blank and one uses the Test board and KIM to program the EEPROM. There are two removable jumpers. One to select -002 or -003 usage for the address decoder in the PAL and one to disconnect the write enable of the EEPROM. One of the two boards deals with the PAL and EEPROM, while the other does the pin translation. It all fits under 6532 but adds about 3/8th of an inch to the height of the 6532. Putting one together can be a challenge of soldering. There area number of small wires that go from board to board and also a number of the device pins do not go from board to board. I can understand why it seems that no one built a board from the kit that didn't need it. I don't know if I have any second rev ( working ) PCBs left for that. I do have some of the EEPROMs but not sure if the PALs I have are blank or have working fuses blown. You'd need the diagnostic board to program the EEPROM or program it before mounting,
The best place to get one of the kits is to ask around for those that didn't build the ROM replacement board. They'd have all the needed parts.
You could always build your own from scratch. I don't think anyone else has made one small enough to fit under the 6532.
I suspect with as much of the board you have, working, that replacing the RAMs will likely get it running.
Of those reporting back what they replaced the most common was one or more of the RAMs. I think one had to replace a buffer chip for the RAM bank and another the address decoder.
Dwight
 
I was able to take a look at the failed 6530-002 by building a breadboard and connecting it to my working KIM-1 and addressing it, using K2 and K4. I saw the ROM starting at $1000 and the I/O starting at $0B40
I noticed that the ROM was repeating good code every 8 bytes, thereby constantly replacing 8 good bytes of code.
Including the code at $FFFC and $FFFD, or in my case $13FC and $13FD. Which should point to $1C22 the Reset Subroutine. That is why the system would not boot up correctly. Unfortunately I did not create a video on that process.
As it was a good learning experience for me.
 
After only having to replace the 6502 CPU, the 6530-002, all 8 - 2102 memory chips and the U17 7406 Inverter. This old KIM-1 is working again !!!
Thank you for all your help and support.

Working.jpg
 
Congrats!

As Dwight and I and others have seen often: memory faults.

But this KIM-1 took a real good hit, since 6502 and 6530-002 were also damaged.

Corsham boards are really worth it!

Hans
 
Well, I just re-inserted the 6530-003 and it appears that it was damaged as well. No surprise here... Not sure how I can replace both 6530's at the same time???
The Corsham board only allows you to replace one or the other, as far as I understand.
 
Well, I just re-inserted the 6530-003 and it appears that it was damaged as well. No surprise here... Not sure how I can replace both 6530's at the same time???
The Corsham board only allows you to replace one or the other, as far as I understand.
 
That sounds pretty messy... I am guessing at least 2 or 3 stacked sockets and two big Corsham boards stacked on top of each other. So much for being a single board computer, now it is a multi board computer... LOL!!!
I guess, I am just going to have to be happy that this old KIM-1 is booting up again. After sitting around for over 30 years of darkness... 😀

Thanks for the suggestion Dwight, I will pass it on to the owner and let him make that decision.
 
Back
Top