Page 1 of 1

New to PicKit 3

Posted: Wed Jul 31, 2019 4:32 pm
by JLeith
Hi all
My PicKit 3 just arrived and with the help of Benj I was able to get the PicKit 3 program loaded.

After that I was not getting any programming of PIC18F26K80.

The standalone loader says it can't find the PIC18. I had to do a "manual Select". I found the PIC18.



Here is the Flowcode Compiler settings



I had this sort of problem when back in the day with Pickit 2 and Martin help.

When I load the Pic18 from Flowcode I get .......................endless

I google PicKit 3 settings and I think they are the same. Also I printed off the Pickit 3 manual.

I have attached my Flowcode design

I have the PicKit 3 connect to my pic
Pin 1 - MCLR with a 10K to VCC
Pin 2 - VCC
Pin 3 - GRD
Pin 4 - Data
Pin 5 - Clock
Pin 6 - X

John

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 8:32 am
by medelec35
Hi John,
I believe the issue is with that programming PICkit stand-alone software.
What you can try is running the programming software.
Select Tools, Revert to MPLAB mode.
Download latest MPLABx from here (5.20 at the time of writing).
When installing, on the Setup screen, only have MPLAB IPE and 8bit selected.
When the installation has finished, it will notify you about using the switcher.
If you not used MPLAB before then you can ignore that message.
Run IPE, in the Device window, enter 26k80 then select Apply.
You should see your PICkit listed in the Tool: part.
Select connect.
If you see Connection failed in the output window, then make sure you have reverted back MPLAB mode as described above, Quit IPE, then reload.
If all is up an running you should see:
IPE1.png
(128.43 KiB) Downloaded 3633 times
You can use Hex File: Browse to load the hex file generated by Flowcode.
There is help here on setting up PICkit 3 (PICkit3 - IPE (NEW)) with Flowcode.
Best to make sure IPE can program your microcontroller first.

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 9:29 am
by Benj
Hi John,

Yes use the IPE settings with a fresh copy of MPLABX installed.

I also notice in the compiler options that you have changed the Compiler Tab settings rather than the Programmer Tab settings. This is not going to work :(

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 5:23 pm
by JLeith
Thank you Martin & Ben for your help.

As i thought I would crash and burn going into the new world of PicKit 3.

I down loaded MPLAB x IDE V5.20

Yes I have not worked with MPLAB in the Pickit 2 time.

For the Flowcode I can't seam to find the correct settings to capture HEX

Here is my not so perfect settings
Compiler and Programmer PICkit3.png
(33.67 KiB) Downloaded 3610 times
From Google I see screens that have the Pickit 3 listed in the "PIC Default" area not below PicKit 2.

I'm off to see if I can get MPLAB X to work.

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 5:32 pm
by medelec35
Hi John,
You just want to try with IPE.
Although its apart of MPLABx download. you don't want to run MPLABx as that is when you use C code and not Flowcode.
Therefore you should have un-selected the box so that it did not install?
To Run IPE just click on 'Type here to search' next to the windows icon, bottom left and enter ipe:
ipe2.png
(75.78 KiB) Downloaded 3608 times
Then you just click on the IP icon.

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 5:41 pm
by JLeith
I'm trying to find the IPE version

The notes say IDE is the version that is more powerful,

I will try again

John

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 5:45 pm
by JLeith
Hers is the link I get routed to

https://microchipdeveloper.com/ipe:installation

John

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 5:56 pm
by JLeith
I might be in luck with the download
I see a option in step 5
IPE.png
(37.64 KiB) Downloaded 3605 times
John

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 6:25 pm
by medelec35
Hi John, Not sure about that site.
The link I posted above is for the genuine Microchip website.
JLeith wrote:I see a option in step 5

Yes, that is when you just have just the IPE selected.

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 7:02 pm
by JLeith
I have Step 1 finally running
x IPE.png
(11.63 KiB) Downloaded 3603 times
Now to set up Flowcode to get Hex File

John

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 7:30 pm
by JLeith
This is all new to me.

I have the IPE loaded.

The actions look like I need to have the PicKit3 connect to my PIC18F26K80 before I can generate my Hex file from my FC project.

Back in PICKit 2 I could generate hex without being connected to the PIC directly

All new information for me

These are my settings in FC
Under Compiler connection
C:\Program Files (x86)\Microchip\MPLABX\v5.20\mplab_platform\mplab_ipe\ipecmd.exe
/P$(chip) /F"$(outdir)$(target).hex" /TPPK3 /M /OL /W5



Compiler Message
Target folder: C:\Users\jleit\Desktop\Carter
Source name: C:\Users\jleit\Desktop\Carter\OLED July 22 Version 2019.fcfx
Title:
Description:
Device: PIC.18F.18F25K80
Generated by: Flowcode v6.1.4.0
Date: Thursday, August 01, 2019 11:23:42
Users: 1
Registered to: Default Flowcode Name
Licence key: EA6R55
http://www.matrixtsl.com
Launching the compiler...
C:\Program Files (x86)\Microchip\MPLABX\v5.20\mplab_platform\mplab_ipe\ipecmd.exe /P18F25K80 /F"C:\Users\jleit\Desktop\Carter\OLED July 22 Version 2019.hex" /TPPK3 /M /OL /W5
....
*****************************************************
Connecting to MPLAB PICkit 3...
Invalid command response (sent 0x41, received 0x3f)
The target circuit may require more power than the debug tool can provide. An external power supply might be necessary.
Connection Failed.
.
*****************************************************
Connecting to MPLAB PICkit 3...
Invalid command response (sent 0x41, received 0x3f)
The target circuit may require more power than the debug tool can provide. An external power supply might be necessary.
Connection Failed.
Programming Target Failed.
.
C:\Program Files (x86)\Microchip\MPLABX\v5.20\mplab_platform\mplab_ipe\ipecmd.exe reported error code 7


FINISHED


John

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 7:50 pm
by medelec35
JLeith wrote:The actions look like I need to have the PicKit3 connect to my PIC18F26K80 before I can generate my Hex file from my FC project.
No not true.
Flowcode is independent of PICkit, so can generate hex file whether PICkit is connected or not.
You must compile to hex, not compile to target!
The way is works is Run IPE, load with the hex file generated by Flowcode.
When you modify flowchart, IPE window will pop up stating Hex fie has been modified, Reload?
Only when you can load and program via IPE you can then try to change settings so you can compile to target.

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 7:53 pm
by JLeith
When I have the PICkit 3 not connected and try to generate Hex. FC says target not found

Here is the Mplab finding of the design chip

Connecting to MPLAB PICkit 3...

Currently loaded firmware on PICkit 3
Firmware Suite Version.....01.56.00
Firmware type..............PIC18F
Target voltage detected
Target device PIC18F26K80 found.
Device Revision ID = 6

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 7:55 pm
by JLeith
Yes I would like to generate HEX only

But FC won't cooperate

I took of the W5 seeing I'm using the breadboard 4.8v power

John

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 7:57 pm
by JLeith
Here is the FC message with MPLAB not running

Target folder: C:\Users\jleit\Desktop\Carter
Source name: C:\Users\jleit\Desktop\Carter\OLED July 22 Version 2019.fcfx
Title:
Description:
Device: PIC.18F.18F25K80
Generated by: Flowcode v6.1.4.0
Date: Thursday, August 01, 2019 11:56:18
Users: 1
Registered to: Default Flowcode Name
Licence key: EA6R55
http://www.matrixtsl.com
Launching the compiler...
C:\Program Files (x86)\Microchip\MPLABX\v5.20\mplab_platform\mplab_ipe\ipecmd.exe /P18F25K80 /F"C:\Users\jleit\Desktop\Carter\OLED July 22 Version 2019.hex" /TPPK3 /M /OL
.......
*****************************************************
Connecting to MPLAB PICkit 3...
Currently loaded firmware on PICkit 3
Firmware Suite Version.....01.56.00
Firmware type..............PIC18F
....
Target voltage detected
Target Device ID (0x6120) is an Invalid Device ID. Please check your connections to the Target Device.
*****************************************************
.
Connecting to MPLAB PICkit 3...
Currently loaded firmware on PICkit 3
Firmware Suite Version.....01.56.00
Firmware type..............PIC18F
.
Target voltage detected
Target Device ID (0x6120) is an Invalid Device ID. Please check your connections to the Target Device.
Programming Target Failed.
........
C:\Program Files (x86)\Microchip\MPLABX\v5.20\mplab_platform\mplab_ipe\ipecmd.exe reported error code 7


FINISHED

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 8:00 pm
by JLeith
This is with the PICkit 3 not connect to the laptop

FC compile to hex

Target folder: C:\Users\jleit\Desktop\Carter
Source name: C:\Users\jleit\Desktop\Carter\OLED July 22 Version 2019.fcfx
Title:
Description:
Device: PIC.18F.18F25K80
Generated by: Flowcode v6.1.4.0
Date: Thursday, August 01, 2019 11:58:56
Users: 1
Registered to: Default Flowcode Name
Licence key: EA6R55
http://www.matrixtsl.com
Launching the compiler...
C:\Program Files (x86)\Microchip\MPLABX\v5.20\mplab_platform\mplab_ipe\ipecmd.exe /P18F25K80 /F"C:\Users\jleit\Desktop\Carter\OLED July 22 Version 2019.hex" /TPPK3 /M /OL
Programmer not found.
.........
C:\Program Files (x86)\Microchip\MPLABX\v5.20\mplab_platform\mplab_ipe\ipecmd.exe reported error code 9


FINISHED

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 8:02 pm
by JLeith
Note: mplab_platform

The word Platform is not listed in the literature for FC settings but maybe that path was not in V3 but is in V5.2.

Not sure where this might be ( Target Device ID (0x6120) )

What target would this be ?

John

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 8:22 pm
by JLeith
Just noticed something odd in MPLAB

Not sure if this might be the problem
Power Settings.png
(6.8 KiB) Downloaded 3596 times
John

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 8:29 pm
by Benj
Hi John
Launching the compiler...
C:\Program Files (x86)\Microchip\MPLABX\v5.20\mplab_platform\mplab_ipe\ipecmd.exe /P18F25K80
 
You're options in flowcode. The compile tab has not been reset to default and so when you compile it tries to call the pickit command you have entered.

Re: New to PicKit 3

Posted: Thu Aug 01, 2019 10:20 pm
by JLeith
Thank you all for your support in making it happen
Hooray.png
(17.45 KiB) Downloaded 3587 times
With setting FC default OFF I was able to generate a Hex file.

Then I used MPLAB and it loaded my design. My Design needs a little work but I have a plan.

All the best to all.

John