![]() | ![]() | ![]() |
| | |||||||
| Micro Controllers Discuss all aspects of micro controllers - building them, coding them, etc. All controllers are welcome - PIC, BASIC, Z8 Encore!, etc. |
| | LinkBack | Thread Tools | Display Modes |
| | (permalink) |
| Got what seems to be a rather curious issue, using an Inchworm (not the + version... thats another story!) and MPLAB 7.60 I can't seem to program 16F627 chips, they fail with the message "ICD0161: Verify failed (MemType = Program, Address = 0x0, Expected Val = 0x2861, Val Read = 0x3FFF) ICD0275: Programming failed." If I read it back, it does indeed differ from what I imported into mplab, but its not still blank or anything. I have no problems programming and verifying 16F84A, 16F628A and 16F877 chips, basically anything other than the '627 I've thrown at it has worked fine, which is rather annoying as I tend to use the 627 as a general purpose chip in most things I play with. I've tried a brand new chip fresh out the packageing as well as 2 out the parts box, same result all the time The other thing is, is MPLAB supposed to redownload the OS to the INCHWORM every time you change device, I thought it was only if you changed it to a different family or something dramtically different? not if you changed from 627 to 628A, etc? Thanks in advance | |
| |
| | (permalink) |
| You don't mention how the chip is connected?, is it in circuit, and if so how is it connected. The error you're getting looks like the chip isn't getting switched to programming mode. | |
| |
| | (permalink) |
| Thanks for your response Its just on a programming adapter I made, piece of strip/vero board, with an 18 pin DIL socket, power LED, matching header to inchworm and some links, this works for the 84A and the 628A, I beleive the pinout is the same on the 627? Programming the 877 (backup for inchworm) was interesting tho!, had it on a piece of solderless breadboard with wire links to the 18pin DIL socket on the programming adapter Not played with incircuit programming yet, that would mean breaking the habbits I developed when I used a JDM and icprog | |
| |
| | (permalink) |
| If the 627/628 has been programmed to use the internal oscillator you can't reprogram it with the standard Inchworm, because it doesn't switch Vdd. | |
| |
| | (permalink) |
| I thought you could as long as you made sure MCLR was enabled? And as far as I know I haven't programmed it to use anything but a HS crystal as the osc, but when I read it back, I got some strange config values read back, osc was 'ER clockout' :S EDIT: Just blanked it and read it back and sure enough, the spurious program data that was in there has gone, I presume this means inchworm is suceeding in putting it in write mode? Last edited by Adam; 27th September 2007 at 10:43 PM. | |
| |
| | (permalink) |
| Hmm, I'll have to get a 16F627 (the A rev is all that's available) As for OS download that's odd. It should not do it that often. Cable length can be a problem. Last edited by blueroomelectronics; 27th September 2007 at 10:49 PM. | |
| |
| | (permalink) | ||
| Quote:
Quote:
| |||
| |
| | (permalink) |
| Just an additional thought, if you have a spare 16F877 or 16F877A reprogram it with the Inchworms firmware and try it. Make sure you program the entire range (FLASH) and use the correct bootloader. | |
| |
| | (permalink) |
| been playing some more, and by programming and reading back and looking closly, didn't realise before, but at least some of the time what it looks like is happing is there is something inserted at the beggining of the program space (normally blank) and the whole program is shifted down one (though sometimes, it can be like 6!) It varies a bit I suppose it could be what bill said due to the cable being too long? but its only the short bit that DIPmicro supply with their kits unless you been the serial cable from the pc?, and why would it only happen with this chip? | |
| |
| | (permalink) |
| Tough to say, the programming (ribbon) cable is best under 8" Is there anything connected to PGC & PGD (aside from the Inchworm?) Are there any caps on MCLR? | |
| |
| | (permalink) | |
| Quote:
Could it be a corrupt operating system file MPLAB keeps loading onto it? Have you got a known good one you could send me please? | ||
| |
| | (permalink) | |
| Quote:
PGD and PGC go straight from INCHWORM to the 627 on the programming adapater (so no ICP), nothing else, same for MCLR, no caps, but due to board layout, it reaches the 627 via some wire links, rather then a stripboard track (the PGD and PGC go straight in via tracks) | ||
| |
| | (permalink) |
| Hmm I'll try to get a 16F627 and try it. I've got lots of 628A and 88 PICs | |
| |
| | (permalink) |
| Thanks, and I'll have to get some 627A chips, its no big deal if I cant program 627 devices, as long as I can do 627A, because he 627A are cheaper than the 627 these days (just looked), the 628A is a tad more expensive, but not as much as I remember it being. All less then 2 quid though , remember paying almost 5 for my first F84 5 years ago :P | |
| |
| | (permalink) |
| The full range is a option to override the smart MPLAB settings. It will force programming the entire chip (it's a programmer status setting) | |
| |