Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Unable to program PIC18F45K50 with PICkit2
12-08-2015, 08:32 AM,
#11
RE: Unable to program PIC18F45K50 with PICkit2
The schematic is the same but you need to adapt the program.
I wrote something more universal some time ago. I can share it with you. Just send me an email.
It is easier to complain than it is to do, but it is better to do than it is to complain.
Reply
12-08-2015, 12:16 PM,
#12
RE: Unable to program PIC18F45K50 with PICkit2
From the PICkit2 README:


Quote:Display of HEX file Code / Data Protect settings
 When a hex file with Code Protect and/or Data Protect bits
 asserted in the Configuration bits is loaded, this is noted
 by displaying "Code/Data/All Protect" next to the Configuration
 Word(s) display.  Similarly, the protect settings are noted for
 Configuration read from a device.  Note that protection
 settings in an imported hex file or read from a device may not
 be turned off in the application.

Code protection is enabled via the config words on the chip which is why you can't write to it.

Solution: Erase the chip (and make sure you're not setting the config words with the PICkit2).
Reply
14-08-2015, 12:53 AM,
#13
RE: Unable to program PIC18F45K50 with PICkit2
(12-08-2015, 12:16 PM)Pinguino Wrote: Solution: Erase the chip (and make sure you're not setting the config words with the PICkit2).

Sorry, but I have tried it thousands of times and no effects. It's definetely some kind of strange bug, maybe with pickit, or maybe the chips are somehow flawed. But this chip is not officialy supported by pickit2, so I think it's the pickit2.
Reply
04-09-2015, 11:45 AM,
#14
RE: Unable to program PIC18F45K50 with PICkit2
All your screenshots show that the PIC is "All protect" -> completely Code protected. You cannot overwrite it without erasing it first. If the code protect bits are being reset after that, check your configuration words (and in the PICkit2 program which can also set them).

Yes, I'm familiar with this issue - I once spent an entire day trying to program a chip because the PICkit2 software was setting the code protect bits and I hadn't noticed. Erasing the chip, if successful, will unset those bits and then the chip can be written.

Not sure what you mean by the chip not being supported... it shows up in your screenshots as identified.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)