Author Topic: PICkit 3 Won't Talk To MPLABX IPE  (Read 20042 times)

0 Members and 1 Guest are viewing this topic.

Online EEVblog

  • Administrator
  • *****
  • Posts: 30597
  • Country: au
    • EEVblog
PICkit 3 Won't Talk To MPLABX IPE
« on: January 17, 2016, 12:25:00 am »
As the title says, my old PicKit 3 won't connect to the MPLABX IPE.
Can't download new firmware or program.
I've never used it with MPLABX or IPE before, just the old stuff.
It obviously detects it and the serial number.
Any suggestions?

 

Online EEVblog

  • Administrator
  • *****
  • Posts: 30597
  • Country: au
    • EEVblog
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #1 on: January 17, 2016, 01:16:33 am »
I've never gotten that specific message before. Have you gone into advanced settings and selected "Power Target From Tool"?

I believe the IPE is trying to connect to the PICkit3 itself, not the device.
e.g. trying to download the latest firmware to the PICkit it says connection failed, obviously the PICkit itself.
But I have tried several target devices and they don't work either.
 

Online EEVblog

  • Administrator
  • *****
  • Posts: 30597
  • Country: au
    • EEVblog
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #2 on: January 17, 2016, 01:22:33 am »
Seems I'm not the only one:
http://www.microchip.com/forums/m860324.aspx

I didn't know the  PK3 had "modes". In any case my PIckit3 software doesn't even load!  :palm:
 

Online Monkeh

  • Super Contributor
  • ***
  • Posts: 6090
  • Country: gb
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #3 on: January 17, 2016, 01:42:00 am »
By 'modes', they mean 'totally different firmware images we want you to flash for using this software or these targets'.

It's really quite a mess.
 

Online EEVblog

  • Administrator
  • *****
  • Posts: 30597
  • Country: au
    • EEVblog
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #4 on: January 17, 2016, 01:44:20 am »
By 'modes', they mean 'totally different firmware images we want you to flash for using this software or these targets'.
It's really quite a mess.

No kidding.
I can't even flash new firmware into my PICkit, as both the older PICkit programmer sofwtare does not talk to it, neither MPLABX IPE.
Maybe some version of older MPLAB?
My latest product has a PIC and I don't even have a usable tool to talk to it.

« Last Edit: January 17, 2016, 01:49:08 am by EEVblog »
 

Online Monkeh

  • Super Contributor
  • ***
  • Posts: 6090
  • Country: gb
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #5 on: January 17, 2016, 01:46:04 am »
Well, the thread you linked suggests MPLab 8.92 might manage to update it. I have no idea on a sane upgrade path to get MPLab X to work, though. Only have a PICKit 2 (clone) myself.
 

Offline jpmkm

  • Contributor
  • Posts: 20
  • Country: us
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #6 on: January 17, 2016, 04:05:37 am »
Try using the MPLAB X IDE to update the firmware on your pickit3:

http://microchip.wikidot.com/pickit3:firmware-to-load

On my system, the firmware file is "PK3FW_013915.jam", but it might be different in 3.20.  You can import and program .hex files in the IDE just like you can in the IPE, but there are a few more steps involved.  But if you get it working in the IDE, then it *should* start working in the IPE. 
 

Offline Emil

  • Regular Contributor
  • *
  • Posts: 156
  • Country: no
    • ZeptoBit
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #7 on: January 17, 2016, 08:40:36 am »
I also had some problems updating the firmware. Solution in this thread: www.eevblog.com/forum/microcontrollers/pic24k50-programming-problems/25/
 

Offline hans

  • Super Contributor
  • ***
  • Posts: 1046
  • Country: nl
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #8 on: January 17, 2016, 09:09:40 am »
Some ancient versions of PICKIT3 firmware only work with the also ancient MPLAB IDE (not MPLAB X).

You can download the older software packages from http://www.microchip.com/pagehandler/en_us/devtools/mplabxc/ and go to "Downloads Archive" tab.
On the bottom of the page you also have the "Stand Alone Programmer App v1.0" and "Programmer App v3.10". From memory both will download a seperate PICKIT OS to work with them. There is also a revert OS button, but that obviously requires a connection first.
I'm pretty certain MPLAB IDE and MPLAB X share the same OS firmware, but MPLAB X doesn't work/connect with the really old OS'es.

I bought a PICKIT3  through Farnell 1 year back, and it still had this firmware. I had to install MPLAB IDE first in order for the PICKIT3 to be recognized by MPLAB X.

IMHO this firmware switching rubbish is big PITA. Although the PK3 supports programming PIC10s through to the new PIC32MZ, switching OS and AP profiles is slow and more complicated than it should have been (especially with backwards compatibility problems)
« Last Edit: January 17, 2016, 09:12:48 am by hans »
 

Online jaromir

  • Supporter
  • ****
  • Posts: 269
  • Country: sk
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #9 on: January 17, 2016, 09:11:00 am »
I remember having similar problem once - solution was not to use MPLABX IPE, but MPLABX IDE, created bogus C project with empty main file, compiled, hit program button, MPLABX IDE uploaded new firmware into PK3, then uploaded bogus firmware into target MCU. Then, PK3 was accessible from both IDE and IPE. Perhaps it was only my brain fart.
 

Offline diyaudio

  • Frequent Contributor
  • **
  • Posts: 672
  • Country: za
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #10 on: January 17, 2016, 03:50:05 pm »
By 'modes', they mean 'totally different firmware images we want you to flash for using this software or these targets'.
It's really quite a mess.

No kidding.
I can't even flash new firmware into my PICkit, as both the older PICkit programmer sofwtare does not talk to it, neither MPLABX IPE.
Maybe some version of older MPLAB?
My latest product has a PIC and I don't even have a usable tool to talk to it.



Have you tried a different computer?

OR

Get an ICD3
 

Offline Howardlong

  • Super Contributor
  • ***
  • Posts: 4814
  • Country: gb
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #11 on: January 17, 2016, 05:36:49 pm »
Completely obscure, but these are some solutions that have worked for me with the PICkit 3...

O switch debugger onto a different USB port (really, this sometimes works)

O create a random project in MPLAB 8.92, force a firmware update in the debugger settings, choosing the latest 8.92 pickit 3 firmware (.JAM file), then close MPLAB 8.92. Open up MPLAB X IDE/IPE, allowing it to update the firmware, then try it.*

* When downloading new debugger firmware, if it appears to hang for more than a couple of minutes in the Bootloader, RS or AP phases, physically remove the debugger and re-attach it a few seconds later.

I have just tried connecting to a quick breadboarded PIC24EP256GP202 which I had in stock (same device, but more memory) and it works with MPLAB X 3.15 both in the IDE and the IPE, and I can erase the device and program a blinky successfully in both IDE and IPE.
 

Offline krish2487

  • Frequent Contributor
  • **
  • Posts: 437
  • Country: dk
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #12 on: January 17, 2016, 08:02:10 pm »
Just a stab in the dark, what windows version are you using dave?
(Not windows 8 or 10 by any chance??)
I vaguely seem to remember reading a thread on the microchip forums, where a similar issue was reported.
Compatibility mode did nothing to help the issue and the only fix was to revert to a windows 7 machine.


Of course, a moot point if you are running windows 7.
If god made us in his image,
and we are this stupid
then....
 

Offline bktemp

  • Super Contributor
  • ***
  • Posts: 1623
  • Country: de
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #13 on: January 17, 2016, 08:35:55 pm »
Maybe the PICkit3 is broken?
A friend had a similar problem with a new PICkit3: It was detected but no version of MPLAB or IPE could connect. He tried to reprogram the firmware using an ICD2 but it did not help. He finally bought another one and it worked without any problems.
 

Offline KL27x

  • Super Contributor
  • ***
  • Posts: 3808
  • Country: us
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #14 on: January 17, 2016, 08:39:27 pm »
There is firmware, proper. The firmware image, which you do not need to change.
Then there is firmware suite. 01.xx.xx. This firmware suite is different between versions of X/IPE and it is stored as a jam file, and in MPLAB X the jam file is further zipped in a JAR file in the PK3 folder.

The PK3 will come with a certain JAM/FW suite preinstalled, which is most certainly not up to date with your version of X. Even recently shipped PK3's are coming with 01.29.xx, and 01.34.11 was the firmware suite with the two year old X/IPE 2.26. 01.40.xx is the most recent one in the latest X/IPE (AFAIK).  And there are some conflicts where if the fw suite on the PK3 and IPE/X do not match, the autoupdate between device families will repeatedly fail. You plug the device in, hit connect, it downloads new firmware, but it is broken. Each time you do that, it repeats this fail all over again.

Is it absolute horseshit that this isn't explained in some easily accessed document or even Microchip PK3 forum sticky/FAQ? Yes, I think it is complete and utter horseshit.

There is a way to manually download the firmware suite if the autodownload fails. You cannot do it in IPE. I don't know how to do this in X. But you can definitely do it in 8. I use 8 and IPE, but not X. So this is one really stupid sounding way to do it. And it goes like this....

So I had to find the PICKIT3.JAR (something like that) file in the PK3 folder in X.  Unzip it with WinZip to extract the more recent PK3FW_01.xx.xx.jam file. And then put that in my MPLAB 8 PK3 folder (where there already resided an older version). In 8, you select PK3, then settings > config> manual download, which opens the PK3 folder and you select the FW suite to install. X must have an analogous manual method... Or maybe not. The strange thing is on the Microchip forums no one seems to explicitly mention this, and more than a couple people have resorted to using 8 in order to get their PK3 updated, similar to the way I have explained it. It would be even more horseshit if there is not a way to do this in X.

BTW, the standalone PK3 app takes a completely unique firmware suite, all its own. I believe you manually switch the suite when changing between PK3 standalone and IPE/X/8. So if you wish to continue using standalone, you might just want to buy a second PK3 to avoid some hassle.

Seems like if you dig deep enough, you may possibly find this information on the Microchip forum. Every few years, someone takes the time to explain it. And then the thread drifts off into the abyss, to confound new PK3 users, all over again.

Once I got my PK3's to do what I needed, I stopped updating X. I hope that the newer FW suites remain backward compatible with 8. I'm using FW suite 01.34.11 with IPE 2.26, and this works fine on my IDE 8.9. Until I find some official documentation on this issue, I am actively avoiding making any changes. It took me 20 hours to figure out this steaming pile.
Quote
O create a random project in MPLAB 8.92, force a firmware update in the debugger settings, choosing the latest 8.92 pickit 3 firmware (.JAM file), then close MPLAB 8.92. Open up MPLAB X IDE/IPE, allowing it to update the firmware, then try it.*
Howardlong solution same, except 1. You don't need to do the fake project. You can just manually download as I showed. 2. the FW suite in your version of 8.9 PK3 folder is NOT the latest one and not the same as with any recent version of X. (8.92 comes with 01.29.xx, and that has been superceeded many times). It might work by changing the firmware on your pickit to a more recent version that can bridge the gap, so to speak, allowing the autoupdate in X to succeed (eventually; it may take as many as 3-4 connections/fails before the update totally completes, and I suspect there could still be some bugs in the process). The definitive solution appears to be the way I stated. When you do that, it will work first time in IPE/X.
« Last Edit: January 17, 2016, 09:46:57 pm by KL27x »
 

Online EEVblog

  • Administrator
  • *****
  • Posts: 30597
  • Country: au
    • EEVblog
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #15 on: January 17, 2016, 09:36:33 pm »
 

Offline KL27x

  • Super Contributor
  • ***
  • Posts: 3808
  • Country: us
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #16 on: January 17, 2016, 09:37:55 pm »
With ICD3, you need to change drivers when switching between 8 and X/IPE. There's a driver changer app that comes with X. |O

Read my wall o text, and I think your problems are solved.
 

Offline Howardlong

  • Super Contributor
  • ***
  • Posts: 4814
  • Country: gb
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #17 on: January 17, 2016, 09:44:51 pm »
FWIW, my IPE tests were in Windows 10 x64.

Microchip is not alone in flakey hardware debuggers. They're all at it. I spent three hours on Saturday trying to get an LPC-Link2 to talk to an LPC810 (on my own board). I did succeed, but it's painful. Similarly, I've spent hours with TI debuggers on their Tiva dev boards too. It now turns out that when it switches from HID bootloader into its debug mode, it re-enumerates and demanded excessive USB bandwidth which in some situations, say when I had a couple of other USB devices installed, it wouldn't work.

In my experience all hardware debuggers have problems of one sort another. The ICD3 and Real ICE have their own problems too so throwing money at the problem isn't necessarily going to help, you just end up with a slightly different set of problems to deal with.

What I would say though is that a common problem with debuggers is the descriptor switching and re-enumerating. That, together with trying to talk to debugger hardware through loosely coupled software interfaces like JNI or RPC seems to be a common and recurrent  theme of unreliability.

In short, hardware debuggers are one of the weakest link in most toolchains. No wonder Arduino is so popular, there's no debugging facility in Sketch!
 

Offline Howardlong

  • Super Contributor
  • ***
  • Posts: 4814
  • Country: gb
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #18 on: January 17, 2016, 09:46:45 pm »
With ICD3, you need to change drivers when switching between 8 and X/IPE. There's a driver changer app that comes with X. |O

Read my wall o text, and I think your problems are solved.

You must run the driver switcher as Administrator, with the debugger plugged in and without any IDEs open. And you must stand on one leg with you right index finger in your left ear while singing Waltzing Matilda.
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8229
  • Country: 00
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #19 on: January 17, 2016, 09:58:49 pm »
The PICkit 3 was announced back then, I ordered myself a couple spare PICkit2.

Looking at this thread, I couldn't have been happier about my purchase then, :)
================================
https://dannyelectronics.wordpress.com/
 

Offline Howardlong

  • Super Contributor
  • ***
  • Posts: 4814
  • Country: gb
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #20 on: January 17, 2016, 10:53:44 pm »
One further thought. The PK3 is Full Speed USB, if you are running this off a USB 2.0 hub with a single transaction translator but multiple full speed devices on the same hub, this can cause a bandwidth problem as the maximum aggregate bandwidth for all FS devices even on an HS USB 2.0 hub with single TT is 12Mbps. Simplest thing is to put it on its own USB 2.0 hub which will have its own TT. This can sometimes fix weird problems with USB FS devices.

Some pics & screen shots of my working environment.



Code: [Select]
#include <xc.h>

#define FCY (7370000/2)
#include <libpic30.h>

#pragma config FWDTEN=OFF
#pragma config ICS=PGD3

int main(void)
{
    ANSELA=0;
    ANSELB=0;
    TRISA=0;
    TRISB=0;
   
    while (1)
    {
        LATAbits.LATA0=1;
        __delay_ms(500);
        LATAbits.LATA0=0;
        __delay_ms(500);
    }
    return 0;
}






Code: [Select]
2016-01-17T22:29:19+0000- Completed loading IPE.


*****************************************************

Connecting to MPLAB PICkit 3...

Currently loaded firmware on PICkit 3
Firmware Suite Version.....01.40.05
Firmware type..............dsPIC33E/24E

Target voltage detected
Target device PIC24EP256GP202 found.
Device ID Revision = 4003
2016-01-17T22:31:50+0000- Loading hex file. Please wait...
Loading code from C:\myprojects\PIC24\24ep256GP202 001\24ep256GP202 001.X\dist\default\production\24ep256GP202_001.X.production.hex...
2016-01-17T22:31:50+0000- Hex file loaded successfully.

2016-01-17T22:32:06+0000- Programming...

The following memory area(s) will be programmed:
program memory: start address = 0x0, end address = 0x3ff
configuration memory

Device Erased...

Programming...
Programming/Verify complete
2016-01-17T22:32:11+0000- Programming complete
Pass Count: 1

 

Offline KL27x

  • Super Contributor
  • ***
  • Posts: 3808
  • Country: us
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #21 on: January 17, 2016, 11:17:38 pm »
Quote
The PICkit 3 was announced back then, I ordered myself a couple spare PICkit2.

Looking at this thread, I couldn't have been happier about my purchase then, :)
If you successfully update your PK3, the PK3 has some nice advantages.

Personally, I still use PK2 for dev for some very specific reasons, only. For most people who code in MPLAB, I don't see a good reason to prefer PK2 over PK3, once the initial nightmare is over, except maybe for the standalone software of PK2, which is sometimes quite handy. (I know PK3 has an unsupported and buggy version of standalone, yeah...)

PK3, I mostly use for P2G, because it has some advantages in addition to device support. So I put up with the sluggish IPE interface for this. It takes 5-10 minutes to set up the PK3 in IPE on my computer, though. Compared to about 30 seconds with the PK2. If Microchip had finished PK3 implementation in 8, that would have been nice. (It seems like PK3 works fine in 8, except for P2G; it does "something" but it doesn't work). I hear the latest version of X isn't bad, and I might try it soon enough.
« Last Edit: January 17, 2016, 11:26:11 pm by KL27x »
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8229
  • Country: 00
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #22 on: January 17, 2016, 11:26:35 pm »
I don't know what Microchip's rationale is to go with Pickit3 but just look at this thread and one has to ask what did Microchip gain that is worthwhile to put their customers through this man-made hell? All for what?

The whole firm's strategy + software side is messed up. Without their large installed base, I have a hard time imagining them surviving long.
================================
https://dannyelectronics.wordpress.com/
 

Offline tech5940

  • Supporter
  • ****
  • Posts: 85
  • Country: ca
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #23 on: January 17, 2016, 11:57:29 pm »
You should try your PICkit 4 [emoji12]


Sent from my iPad using Tapatalk
 

Offline Howardlong

  • Super Contributor
  • ***
  • Posts: 4814
  • Country: gb
Re: PICkit 3 Won't Talk To MPLABX IPE
« Reply #24 on: January 17, 2016, 11:58:19 pm »
The whole firm's strategy + software side is messed up. Without their large installed base, I have a hard time imagining them surviving long.

Yep. I guess they don't subscribe to the old adage "if it ain't broke don't fix it".

I had the PK3 working reasonably well, then I did something stupid, I updated MPLABX now it's slow as hell. I have an i7 with 8GB of ram and this machine has very little on it other then Adobe and CAD tools.

Which compiler version are you on? Something went wrong in one of the compiler distributions a year or so ago to do with the licensing nonsense which made the edit-compile-program-debug cycle terribly painful on node locked licences as the licence checker attempted to find a non existent licence server.

One further thing, there is a setting in the embedded options for MPLAB X to reduce the amount of nonsense the debugger goes through each time it connects, perhaps they were set differently in your earlier MPLAB X version.

In general I do agree though, it is indeed a steaming pile of unreliable bollocks.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf