Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] Project to replace CY7C64613 in the ICD2

Status
Not open for further replies.
KaZaaD, if you read the 'desc.txt' file included in the zip for the PiCS rev B design, it says to make sure you disable MCLR in the configuration settings when you are programming the boot firmware onto the 18F4550, and as long as you do that you don't need the pullup resistor on the pin. I don't know why they didn't just disable it when making the hex file, but that's the way it currently is...

Note: for anyone who wishes to make this change so you don't have to worry about forgetting to disable MCLR (especially helpful if you are having trouble getting MPLAB to recognize the ICD2 and need to re-program the chip a few times just in case), the following simple change to the HEX file will set it disabled by default:

Open the HEX file in a text editor (ie - notepad) and look way down at the bottom for these lines:
Code:
:020000040030CA
:0E000000240F3900008180000FC00FE00F4078
and change that second line to: (just need to edit 2 digits - one in the middle to change the setting, and one at the end to fix the checksum for the line)
Code:
:0E000000240F3900000180000FC00FE00F40F8

It would be nice if this change made its way into the HEX files being distributed in the PiCS design ZIP file...
 

Beowolf said:
Hi, Daemons.
PGM was used on old ICD, not on ICD2. you can see it from the manual..
I read the manual, and I found it too.

So why is the PGM circuit still on many ICD2 Clones? Thats kinda odd.
I guess I can leave it out then.

Daemons
 

MY Pics icd2 is working partly. I can read and write target and can debug it without any problems. But i cant download operating system in MPLab. I have to programm the operating system with lpt programmer. :(
 

Just wondering, when all of you perfect your ICD2 with 18F4550 USB do you actually have a project in mind or just want to build a USB ICD2?

PS powering your ICD2 from USB is good. Powering your target project from USB is bad. (One short and poof goes the fuse on your motherboard)
 

blueroomelectronics said:
Just wondering, when all of you perfect your ICD2 with 18F4550 USB do you actually have a project in mind or just want to build a USB ICD2?
It's a great tool to design with. The debugger is very helpful, but serial is WAY too slow. Thats why I'm making the USB one.

PS powering your ICD2 from USB is good. Powering your target project from USB is bad. (One short and poof goes the fuse on your motherboard)
Thats why the design is using a Mosfet to switch the power. Microchip already thought of that. Plus you can always add your own fuse on the ICD2 output itself (smaller than the USB port, obviously). I use a seperate PS for my projects myself. I only need the ICD2 power for programming PICs on their own (with a header board), which would never use enough current to cause a problem.

Daemons
 

Is there any update on the Potyo vn2.0 Eagle CAD files on page 28? Has anyone done a summary of issues / errors?

Thanks.
 

I wonder what's happening inside the target pic while debugging!!!
anybody can explain?
what's the speed(baud rate) of a usb based ICD2?
I recently assambled the inchworm ICD2 and it's working very slow.
The speed I selected is 57600 and still it's slow.
while running the debugger, it's working properly but when removed the ICD2 connection and allowed the pic to work, it's not working. why?
thanx in advance for your valuable comments and answers.
 

Gandalf_Sr said:
Is there any update on the Potyo vn2.0 Eagle CAD files on page 28? Has anyone done a summary of issues / errors?
I know one error: the USB led was connected to the RC2 instead of RC1 pin. I've fixed this, and updated the schematic and pcb.

Added after 7 minutes:

16F676 said:
I wonder what's happening inside the target pic while debugging!!!
anybody can explain?
I don't know, try to search Microchip's site for more information.
16F676 said:
what's the speed(baud rate) of a usb based ICD2?
I recently assambled the inchworm ICD2 and it's working very slow.
The speed I selected is 57600 and still it's slow.
Yes, it is very slow, USB is much faster (approx. 1Mbps).
16F676 said:
while running the debugger, it's working properly but when removed the ICD2 connection and allowed the pic to work, it's not working. why?
You must select Programmer-->ICD2, rebuild the project, and reprogram the target to work without ICD2.
 

Hello all. I need help.
Microchip has been made with R3 edition new ICD-2 ("P/N xx-xxxxx-R3"). Where programmed USB-controller Cypress (CY7C64603) changed by PIC18F4550.
I need the scheme of the new ICD-2 - R3 and 4550.hex file for PIC18F4550.

Somebody can help me?
 

16F676 said:
I wonder what's happening inside the target pic while debugging!!!
anybody can explain?
It's all explained inside the ICD2 User's Guide. Just download it from the Microchip Website.
while running the debugger, it's working properly but when removed the ICD2 connection and allowed the pic to work, it's not working. why?

Thats because MPlab adds things to the program to allow the use of the debugging module inside the chip. If you're not using the ICD2, these additions need to be removed by reprogramming the chip as Potyo indicated above.

This is ALL in the MPLAB ICD 2 User’s Guide.pdf you NEED to download from Mchip's website.

How can anyone use this debugger without first reading the guide? 8O

Daemons
 

Hi,

I have a problem tying to program with my new icd2 clone Rev B.

When i connect to ICD i first have a warning:

ICDWarn0020: Invalid target device id (expected=0xD4, read=0x0)

Then when i want to program or debug i have another warning during the verifying operation then two errors during the memroy programmation:
ICDWarn0052: MPLAB ICD 2 cannot validate a target device. Please make sure that the target device is connected and properly powered. Select "OK" to continue, or "CANCEL" to abort the operation
ICD0161: Verify failed (MemType = Program, Address = 0x0, Expected Val = 0xEFEB, Val Read = 0x0)
ICD0275: Programming failed.

Do you know how to solve this problem?

For information when i try to program the same target device with an official ICD2 it works...

Regards.
 

Maybe its a well known issue with PiCs ICD2 Clone... but I don´t know why it happens.

Sometimes when I hot-plug the ICD2 the PIC18F4550 get Flash corrupted and I have to flash it again.
Maybe its related with the power line inductor, I added a resistor in parallel with it (still not working)
I read some post that says that it´s related to long USB cables but it´s not my case.
If some one knows the reason, I would be great.

Thanks and excuse my rusted english.
 

skb4 said:
I need the scheme of the new ICD-2 - R3 and 4550.hex file for PIC18F4550.

Somebody can help me?
You can find it in this topic.»
 

KaZaaD said:
Hi,

I have a problem tying to program with my new icd2 clone Rev B.

When i connect to ICD i first have a warning:

ICDWarn0020: Invalid target device id (expected=0xD4, read=0x0)

Then when i want to program or debug i have another warning during the verifying operation then two errors during the memroy programmation:
ICDWarn0052: MPLAB ICD 2 cannot validate a target device. Please make sure that the target device is connected and properly powered. Select "OK" to continue, or "CANCEL" to abort the operation
ICD0161: Verify failed (MemType = Program, Address = 0x0, Expected Val = 0xEFEB, Val Read = 0x0)
ICD0275: Programming failed.

Do you know how to solve this problem?

For information when i try to program the same target device with an official ICD2 it works...

Regards.

In fact it was an hardware problem... So the ICD works well now! Thanks a lot again!
 

Hi

I have the same problem than KaZaaD when i connect ICD2 clone rev B.

Auto-connect not enabled - Not connecting (Try enabling auto-connect on the ICD2 settings pages.)
Connecting to MPLAB ICD 2
ICDWarn0059: About to re-program ICD2 USB Boot firmware code. Please do NOT disconnect the ICD2 or interrupt this operation!
...Connected
Setting Vdd source to target
ICDWarn0020: Invalid target device id (expected=0x71, read=0x0)
...Reading ICD Product ID
Running ICD Self Test
... Failed Self Test. See ICD2 Settings (status tab) for details.
MPLAB ICD 2 Ready



What's the hardware problem?

I just connect ICD2 clone and i don't connect a pic with icd2 clone. Perhap's, it must to connect target?

Thank you.
 

Hi to all.

I succesfuly finished my copy of Potyo's design. i had some issues which were indeced by malfunctioning 16F877A. I suspect that during programming i placed it in socket in reverse position, which resulted in frying one of the data lines of SPP with 13volts of Vpp.

Now it works!.. well almost. It can't debug ;(

It downloads OS, can program and read memory of two different PICs, but can't debug.
Target has Vdd, the cable is goot I suppose (as it can read/write to PIC).
Could it be the clock, or some other thing?
I haven't compared my clone with oroginal ICD2 yet.
 

16F676 said:
I wonder what's happening inside the target pic while debugging!!!
anybody can explain?
what's the speed(baud rate) of a usb based ICD2?
I recently assambled the inchworm ICD2 and it's working very slow.
The speed I selected is 57600 and still it's slow.
while running the debugger, it's working properly but when removed the ICD2 connection and allowed the pic to work, it's not working. why?
thanx in advance for your valuable comments and answers.

The debug mode is for debugging only, you have to have the Inchworm (ICD2) in debug mode to use it. Debug mode uses special hardware inside the PIC (not all PICs have it) to set a breakpoint and view / modify SFRs. It's very simple and the tradeoff is it's not exactly fast. The new R3 ICD2 from Microchip uses two PICs and it is much faster than the standard ICD2. Neither are anywhere as fast as a $2000 ICE though.

When you want stand alone operation just select programmer / ICD2 and program it. It will remove the debug kernel and allow stand alone operation.

The key to proper use of any ICD is to
1. use breakpoints instead of animate.
2. use watch windows sparingly, (approx 1sec more per SFR watching)
3. use the simulator when watching raw code, you can switch between ICD2 & SIM on the fly
4. don't forget to program the chip when your done (removes the kernel)
5. don't put your code in the upper 256byte of memory
6. use the _DEBUG_ON config option.

The SIM mode is faster than any ICD or even ICE. Use it when you can.
 

Roque, those errors at the end are what happens when you don't have a target device connected. It is failing the target device ID because there is no target (of course), and failing the self test because it's trying to measure some voltages from the target board. If you go into the settings you should be able to see all the self tests there and see which ones are failing, it should be "target Vdd" and "MCLR Vdd". Once hooked up to a target PIC of course, those errors shouldn't occur.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top