Simple serial ICSP PIC programmer

Oh dear, it seems my parallel port LVP programmer was somewhat fragile - I'll skip the details but suffice to say it doesn't work any more. The silver lining to this sad story is that it led me to build a really simple and cheap ICSP (In Circuit Serial Programmer) which connects to the serial port and only uses 3 resistors.

ICSP, as the name suggests, allows programming of a PIC 'in circuit', avoiding the need to constantly take it in and out of the programmer and the subsequent bending of pins. This programmer works with any standard serial port (1) and successfully programs my 16F628 PICs in HVP (high voltage programming) mode giving me an extra pin on PORTB - which is handy. As with the LVP programmer, it draws power for the PIC's main supply voltage (Vdd) from a USB port. Here's the circuit:

icsp_prog.png

And here's a photo of the finished item with globs of "hot glue" (marvelous stuff!) to prevent cable breakage:

05170002.JPG

Software is IC-Prog - again, a Windows program but it has its own I/O driver for Windows 2000/XP which avoids all the arseing about with GiveIO.sys. As for the hardware settings in IC-Prog, programmer type is "JDM" using direct I/O; all other boxes are unchecked. I have yet to try this programmer with my Linux machine as that has low power serial ports (see 1 below) but it works well on Windows.

  1. On my desktop machine, measuring the voltage across pins 5 and either 3, 4 or 7 on the 9 pin D-type serial connector with a multimeter shows just over 10V. On my Linux machine (somewhat akin to a laptop) the same pins show around 5V which seems not to be enough to raise the programming voltage (Vpp) on the PIC to the required level for HVP. I haven't tried it in LVP mode (+5V on PGM) which may work if it happens in the right sequence. It may also be possible to overcome this voltage deficit by boosting the voltage to RS-232 levels using a MAX232 chip but I haven't tried this.

 

Stuart Metcalfe (not verified) on March 23rd 2008

I don't think it'll work with a USB adaptor - as I understand it, they don't generate the required voltages. That said, you might as well try it once just in case. I had an idea (although never tried it) of using a MAX232 to step up the voltages as my old laptop only generated 5V so wouldn't work with this. This programmer should work with most PICs although you'll need to ensure you use the right pins, obviously. I've since moved to using AVR/Arduino on my MacBook with a simple USB programmer so I don't do PICs any more.

tyeo098 (not verified) on March 22nd 2008

Will it work with a usb adapter? And any pic with those pins?

Stu (not verified) on March 13th 2008

In some ways, it is! It's a bit hit and miss but if you're lucky enough to have a system which does work with it then it's a great solution.

Tyler (not verified) on March 12th 2008

It looks too simple to work...

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Post new comment

  • Allowed HTML tags: <a> <p> <span> <div> <h1> <h2> <h3> <h4> <h5> <h6> <img> <hr> <br> <br /> <ul> <ol> <li> <dl> <dt> <dd> <table> <tr> <td> <em> <b> <u> <i> <strong> <font> <del> <ins> <sub> <sup> <quote> <blockquote> <pre> <code> <cite> <strike> <caption>
  • Web page addresses and e-mail addresses turn into links automatically.

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.