Problems with the 16F818 & VELLEMAN

Status
Not open for further replies.
I've been learning the basics of PIC programming using assembly language and have had no problems, then today while trying to debug a bit of code I tried to write to a 16F818 chip with my Velleman P8048 board and ProgPic2 2.6.0. It failed to write and then subsequaently when I tried to write or erase from the chip I got the message :

**broken link removed**

I thought I may of just had a faulty chip, so stuck another in and the same happenned, So I picked another chip and changed the code again, re-compiled and wrote to it no problem.

Can the ICs be broken by incorrect code? Are these ICs now useless or is there something I can try to erase them?

Incidentaly the board is in PGM mode, and the pic type isn't mismatched with the software, the board (which has test LEDs on) runs through the program sequence with no problems.


Malc
 
Last edited:
incorrect code will surely damage your IC when put to application, like a supposed to be low input pin (directly connected to ground without pulldown) was programmed as high output.
 
I suspect that you are using the internal oscillator and your code starts to run before the chip goes into program mode. This happens between programming and verifying and it appears to fail programming but as you say, the code still works OK.

The only ways I know to fix this is,
Don't use the internal oscillator.
I'm not familiar with the Velleman kit but with other programmers the following worked. Disconnect the Vdd pin, connect a 5.1V zener from the Vdd pin (cathode) to ground (anode) and a 1K resistor from MClr to Vdd. This work because Vdd doesn't get powered until after Vpp is applied therefore ensuring the chip goes into program mode. This isn't the correct way to enter program mode but has worked for me on other programmers.

HTH

Mike.
 
Thanks for the replies,

The code change that was made wasn't that drastic it was just a section of a larger code removed and put on it's own. I've just tried the diode and resistor but it didn't work. Thanks anyway.
 
spondootre said:
Is that it then?? Are the chips I have totally useless now? Is this a "normal" thing to happen to them?

Assuming that's what's happened?, you need a decent programmer, any decent programmer should be able to program a PIC with the internal oscillator selected - poor ones won't, because they don't have the hardware to do so (the hardware either has to have switched Vdd, or the capability of reseting the PIC - by holding MCLR low).
 
Thanks for the reply, what sort of programmers should I be looking at as a replacement for the velleman one? One that doesn't cost the earth but is capable of not writing off PICs !!
 
spondootre said:
Thanks for the reply, what sort of programmers should I be looking at as a replacement for the velleman one? One that doesn't cost the earth but is capable of not writing off PICs !!

The P16PRO40 is fine, but probably a better idea is an ICD2 clone?, this keeps up to date with new PIC's far better. Check the posts in this forum for a really nice one (with a blue PCB).
 
Is this a good price for and ICD2 clone??

**broken link removed**

or can I get one from the UK cheaper without producing my own
 
note that programmer is a serial programmer and uses the USB for power only. I suppose it will work but it's kind of odd. Also, be aware that the seller is located in Hong Kong. I've bought items from there so it's not an issue for USA shipping but you might want to be sure about it for UK (assuming that's where you are).
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…