
A while ago I wrote about how I’ve managed to get PIC programming working under Linux. I mentioned that I was seeing a lot of errors from the programmer, a Silicon Chip K 9505 kit that I bought 20 years ago. Well, the write errors were getting worse and worse, culminating in last night’s final straw of me repeatedly clicking on the program button and getting ‘verify error at 0000h’ over and over again.
I started looking around on the internet for a replacement. There are any number of eBay sites selling Pic programmers but I didn’t get a good vibe and I’d have to take a risk on the software working with my system.
While I was trying to get the programmer to work, I decided to check the programming voltage, vpp. I reasoned that because the programmer was reading the chips okay, maybe the problem was not with the serial communication, but to do with the programming side. Sure enough, vpp was hovering around 8v, instead of 13v, insufficient to enable programming of the Pic16F84A that I was trying to use. At this point I was fairly clueless about where to start looking for the problem.
I hunted around in my manuals file but the documentation for the programmer wasn’t there. Suddenly, by chance, I noticed something on the chest of drawers where I keep my components. It was an informational sheet about diodes and when I picked it up it turned out to be the very booklet I was looking for – the kit instructions for the programmer. It was late, so I took it to read in bed. The documentation included some handy tips for testing the voltages on the board, one of which was to check the cathode of D4. It was well off the 17.8v that the manual indicated, but more to the point I discovered that D4 was broken in half.
D4 is a key component in the voltage doubling circuit used to generate vpp. No wonder the programmer was not functioning very well.
I hunted around in my box of diodes and found a whole pile of 1N4148s. I decided to use a salvaged one, rather than chop up one of my new ones, so selecting a diode with leads of sufficient length I soldered it into the board and remounted the board on its perspex base. Hey presto! The chip programmed first time.
So there you have it. I think I’ve fixed my programmer, eliminated the frustrating errors and proven that on a long enough time scale a little diode salvaged from who knows what and kept in a box for who knows how long will actually be useful, in the end.