• Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Programming the 16F628

Status
Not open for further replies.

rewguy

New Member
I've had plenty of success programming the 16F84A with my extremely cheap Olimex PG2C programmer. However, before I start to program my 16F628, I noticed that IC-Prog tells me to pull RA4 to ground.

My first question is simply, how the hell do I do that? If my programmer runs on power from the COM port of my computer, does this mean that I need to rewire my programmer so that RA4 goes straight to the ground of my comp port?

Secondly, is this absolutely necessary? I read that the chip will go into low voltage programming mode if this is not selected, and the JDM programmer option for IS-Prog will not work. Is there any software that will allow me to program the 16F628 without making such a modifcation?

Thanks for your help, and I'm sorry for being so ignorant.

Andrew
 

Exo

Active Member
Its just a precaution, Its been known that some chips capable of low voltage programming have problems with the normal programming (high voltage) if their PGM pin isn't pulled down.

Try it first... It might as wel work, it really varies from one chip to another. If it doesn't then connect the pin to ground trough a resister (10K or something)
 

ldril

New Member
If you use the JDM programmer you should pull the pin to the programmer ground and not to the computer's port ground. That is connect the pin to the PIC's Vss (pin 5) instead of the Vdd. The computer ground is actually the +5V for the PIC so don't connect the pin there since this will surely make the PIC enter LVP.

Also note that it's the pin RB4 (pin 10) and not RA4!!!

I don't know how the Olimex programmer is structured, but if possible you should make the same change - connect in some way the two pins together (5 and 10).

I have programmed 16F628 with JDM with this change and had no problems.

BR
 

rewguy

New Member
Thanks

Thanks a lot-

One question: Should I use a resistor in connecting pin 5 and 10? Thanks-

Andrew
 

ldril

New Member
I don't think a resitor is needed. I can't tell for sure. Anyway I didn't use one and didn't have problems.

Another thing - this may be needed only for the first programming since there is a fuse (control bit) that controls the programming mode. This fuse allows by default LVP. If at the first programming you disable LVP from the fuse then the RB4 to ground is not needed anymore. But if you erase the device the fuse will be reset, so I think it's better to just keep it grounded.

BR
 
Status
Not open for further replies.

Latest threads

EE World Online Articles

Loading
Top