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] pickit 2 problem. please help!!!

Status
Not open for further replies.

hemnath

Advanced Member level 3
Joined
Jun 24, 2012
Messages
702
Helped
61
Reputation
120
Reaction score
57
Trophy points
1,308
Location
Chennai
Activity points
6,588
im using mplab 8.56 and pickit 2 programmer. First, it was working correctly. Suddenly i dont know what had happened, it shows error as "PKWarn0003: unexpected device id : Please verify that a PIC18F2520 is correctly installed in the application. (Expected ID = 0x1100, ID Read = 0x0)". how to fix this problem? Please help.
 

The ICD2 & PICkit2 both have 4.7K pulldowns on the PGC & PGD pins so a disconnected target will read 0x00
Make extra sure that all the programming connections are still there.
It will also fail if you accidently protected the device.
 

Hi,

What is your 2520 in, a dedicated socket, a breadboard or 'in circuit' with other components ?

Are you using a cable between the Pk2s output and the 2520, any longer than 150mm and you may expereince problems.
 

i ve checked . all the connections are correct.

my 2520 in a dedicated socket. now it shows "PK2Error0027: Failed verify (Address = 0x30000C - Expected Value 0x0 - Value Read 0xF)"
 

i ve checked . all the connections are correct.

my 2520 in a dedicated socket. now it shows "PK2Error0027: Failed verify (Address = 0x30000C - Expected Value 0x0 - Value Read 0xF)"



Hi,

I use the Pk2 and 2520 chips regularly, they work fine.

What have you done to change from error 3 to error 27 ?

Have you got pins 8 and 20 connecred to Pk2 Vdd and pin 19 to 0v ?

The connection between the Pk2 and the 2520 chip is less than 150mm ?

Perhaps post the .hex file you are trying to program and I will try it on mine, you might have something wrong there....
 

sorry .. again the error3 shows. check my code .if anything wrong, please correct me.

HTML:
#include "18F2520.h"
#fuses HS, NOPROTECT, INTRC_IO
#use delay(clock=4000000)

#define RS PIN_A0
#define EN PIN_A1

void lcd_data(char z)
{
output_b(z);
output_high(EN);
output_high(RS);
delay_ms(5);
output_low(EN);
}

void lcd_cmd()
{
output_high(EN);
output_low(RS);
delay_ms(5);
output_low(EN);
}

void lcd_init()
{
delay_ms(1000);
output_b(0x30);		//	8 bit, 1 1ine, 5 x 8 dots
lcd_cmd();
output_b(0x0c);		//	Restore the display(with cursor hidden)
lcd_cmd();
output_b(0x06);		//	display shift off, increment address counter
lcd_cmd();
output_b(0x80);		//	starting address of lcd
lcd_cmd();
output_b(0x01);		// clear display
lcd_cmd();
delay_ms(5);
}

void main()
{	
setup_oscillator(OSC_4MHZ);
set_tris_b(0x00);			//	all pins in PORT B are outputs
lcd_init();
lcd_data("LCD");
delay_ms(10);
}
 

sorry .. again the error3 shows. check my code .if anything wrong, please correct me.


Hi,

I cannot properly check your code as I do not do C; thats why I asked for the .hex file you are trying to program.

Have you tried programmning using the independant Pk2 program V2.61 ? ( microchip pk2 download)

Have you got another chip to try in case you have damaged the 2520 ?

You could try programming this file, its well proven.
 

Attachments

  • v792520.rar
    15.7 KB · Views: 109
  • Like
Reactions: PA3040

    PA3040

    Points: 2
    Helpful Answer Positive Rating
Program compiles successfully.

yes i have checked with new 18F2520. and also installed mplab in another system. it shows the same error.

i have windows xp 64 bit. so i'm programming directly from mplab. i have installed PK2 program v2.61. But its not working.
 

Hi wp100,

It would be much appreciated, If you can explain the procediar to trace the problem using HEX file.

Thanks in advance
 

Program compiles successfully.

yes i have checked with new 18F2520. and also installed mplab in another system. it shows the same error.

i have windows xp 64 bit. so i'm programming directly from mplab. i have installed PK2 program v2.61. But its not working.


If you run V2.61 ensure the PK2 Programmer option is turned off in MPlab, or MPlab closed down.

Why does not V2.61 run ? - I have always found it a much more stable program than the one in Mplab and as it has inbuilt diagnostics its worth getting it to work.

A picture of your actual PK2 and target board might help identify your problem
 

im surprised that my pickit works normally again.. I didnt do anything. thank you so much :) :) :) ...
 

PK2Error0027: Failed verify (Address = 0x0 - Expected Value 0x40200 - Value Read 0x40A540)

- - - Updated - - -

Hi: dude could u find my error in pickit2
PK2Error0027: Failed verify (Address = 0x0 - Expected Value 0x40200 - Value Read 0x40A540)
 

describe the way you connected the pickit. Are there any other components conneced to the ICSP pins of the PIC?

pityu
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top