Pages

Tuesday, March 14, 2006

First Microchip PIC16F628 for Godzilla project programmed...

This ought to keep everyone laughing at my expense for a week. Have fun and welcome to it! :-D
I built the JDM PIC chip programming board more than a month ago, but just got around to trying to program a 16F628 chip on it this weekend. This is an important thing to be able to do because the 16F628 is the core of all the controller boards for the Godzilla prototyping machine. Simon, Vik and Adrian have been moving towards a final design for all the boards for the past month and it is looking like I'll be able to start building them in a week or two.

Anyway, the first bit of drama was finding the proper software to drive the board and program the 16F628's. As usual it was right in front of my nose and Simon kindly showed me the link. He then told me the settings to use to get it to work.

I plugged the board into my PC, fired up IC-Prog and had a go... nothing. For the next several hours I played chimpanzee on a keyboard trying things to see if I could get it rolling... nothing.

Simon began to suspect that my ancient skills with soldering iron and PC board had maybe slipped a bit. Given that it had been 25 years since I'd last personally built one it sounded reasonable but annoying all the same. I considered just buying a premade, cheap programmer board.

Simon finally ran me through the troubleshooting protocol on the wiki site. The voltage numbers that I got made absolutely no sense whatsoever. I was going blind with fatigue when I finally crawled under my desk and had another look at the back of my PC. 25 pin cannon female connector for Com1, 9 pin cannon male connector for Com2... I'd rigged mine to use the 25 pin connector, just like the old days.

Wait a minute. Where was the printer connector? In the old days we used a Centronics connector, but those had fallen by the wayside some years back and NOW we used a... 25 pin cannon connector... female. It was still confusing because when I checked mode I had 2 serial ports. If that 25 pin cannon female connector was a printer cable where the hell was the other serial coms port? I've been using USB ports for peripherals for some years now so this was all remembering how to read ancient Egyptian for me.

I finally decided that I didn't know where the other coms port was but that the one I had had to be a 9 pin male cannon connector. This morning I went down to Radio Shack and bought a 9 pin female connector. I hooked it up ran IC-prog with the settings Simon talked about yesterday.

It wrote to the 16F628 and verified perfectly the first time out. I read it back into buffer 2 and compared buffer 1 and buffer 2 and it gave me a thumbs up.

No comments:

Post a Comment