News:

PROTON pic BASIC Compilers for PIC, PIC24, dsPIC33

Main Menu

P-ICD manual

Started by puffeltje, May 23, 2021, 08:43 AM

Previous topic - Next topic

puffeltje

I want to debug my Protoncode. I know there is P-ICD. I have the plugin but i don't have the manual. Does someone have this manual?

Or are there better ways to debug protoncode?
I have a mind like a clock. And like a clock, it regularly goes cuckoo...!

TimB


I don't think P-ICD works anymore

Tim

puffeltje

At the moment i am debugging with MPLAB V8.91

When using the poickit2 most of the time it works, sometimes it doesn't. At the weekend testing if the ICD3 works better.
I have a mind like a clock. And like a clock, it regularly goes cuckoo...!

tumbleweed

The last version of MPLAB was MPLAB 8.92, so you might want to update it.

It's been a long time since I've used it, but the PK2 was pretty reliable from what I recall.

The ICD3 is a better tool if you have one. It'll do things the PK2 can't, like measure the execution time between two breakpoints.

okmn

is it possible using mplab 8.92 for proton codes debug tools ?
with pickit2 or pickit3 or pickit4 or icd 4? with mplab 8.92

tumbleweed

Yes, it is possible. MPLAB 8.92 can use the PK2, PK3, ICD2/3, or the MPSIM simulator to do source-level debugging.
MPLAB 8.92, the PK2, and PK3 are all getting pretty old so they don't support any devices added after 2013.

All you need is a .cof file.

To create a debugging file add:
Declare Create_Coff = On to your source .bas file.

There used to be instructions on installing the mplab files somewhere...

puffeltje

I  use the method from this russian site:

https://www.picbasic.ru/publ/proton_picbasic/rabota_s_kompiljatorom_proton_v_mplab/2-1-0-92

It isn't using a .coff file (afaik), but proton as a MTC suite.

I think i will try the method with the .coff file because i prefer the proton IDE.
I have a mind like a clock. And like a clock, it regularly goes cuckoo...!

tumbleweed

#7
Quote from: puffeltje on May 28, 2021, 09:57 PMIt isn't using a .coff file (afaik), but proton as a MTC suite.
I can't read russian, but in order to do source-level debugging you need a .cof file since that's the file that has all the symbolic information in it.

The MTC suite is just a set of files that allows you to use Proton to actually compile the file inside MPLAB8.
If you don't mind editing/compiling in the Proton/Positron Studio IDE and debugging in another (MPLAB8) then all you need is the .cof file.

You can even use this method to allow debugging in MPLABX. That would let you use the newer devices not supported by MPLAB8 and the PK4/ICD4.
You set up a "prebuilt project" and download the .cof file.
It works, but if you've never used MPLABX be prepared for a LOT of frustration. If you thought MPLAB8 was difficult just wait!

If you go down the MPLABX route I'd recommend that you stick to using the PK4/ICD4, and never let MPLABX see any of your older PK2/PK3/ICD3 tools.
MPLABX will reprogram them so that the old programmer and command-line apps won't be able to talk to them.

I've used MPLAB8 with the newer Positron v4 compilers and it works, but I haven't tried some of the newer features such as procedures yet with it,
so I don't know how well all that works.



tumbleweed

I might have spoken too soon...

Debugging seems to work ok for the 8-bit devices with Positron8, but not for the 16-bit ones.
Positron16 doesn't seem to be putting any of the library code into the .cof file (but it's in the .hex file).

Without that, it's pretty useless.

John Lawton

A little bird has told me that the P-ICD may be resurrected.

Don't tell anyone else.

John

Dompie

That would be very nice ........ I will wait until the little bird flies to this forum.

Johan

Dolci


DaveS

Quote from: Dolci on May 13, 2023, 10:49 AMI'm waiting ;D
I have found my latest source for P-ICD, however I have quite a few mods to-do, I used the Unicode version of the synedit V2 component, which is not actively maintained, I'm now using the one that installs from the Delphi Getit package manager, I have to make a new custom highlighter (Not an easy task) and there is also a couple of components I need to replace, could be a while, I have sorted out the lst file problem and I'm purchasing the latest compiler, to test it.

DaveS

JohnB

I have a load of RegEx expressions which I use in the highlighter for Positron Studio which I am happy to share with you.  I have the TurboPack SynEdit downloaded from github and I have been looking at the SynFacilSyn which is a configurable Highlighter for SynEdit.  Probably cheating and I doubt it will be as flexible or quick as writing one from scratch.  I would dearly like to dump the TMS ADVMemo component as it is so slow so do you think we could collaborate on the highlighter for P-ICD so that I can finally get rid of the ADVMemo component from Positron Studio.  I'm happy to make any of my code available as log as its a two way street.
JohnB

Dolci

@Dave-S and @JohnB never thought these thread will be alive again.. it just need a trigger to expload🤭

Be waiting for the good result.
Dolci

DaveS

Quote from: Dolci on May 14, 2023, 12:51 AM@Dave-S and @JohnB never thought these thread will be alive again.. it just need a trigger to expload🤭

Be waiting for the good result.
Dolci
If only!

John not saying no but need to get other things done, the highligher in PICD was a Chop and Cut job i did on SynGeneralSyn + a couple of other files, nowt special, rough and ready, I may have to go back to it and no code folding, which I don't need.
SynFacilSyn is for free pascal, it may convert, looking for something easier.
I have V3 of this http://www.econtrol.ru/syntedit.html it's good but not maintained, had to change bits of it because of updated versions of Delphi language changes, to much work to drop in to PICD.
Will look out for an easy route when I get time.
Just a thought have you tried out the TMS FNC Memo it maybe faster and an easier change over, forget that just checked the price €325 and yearly update fees.

DaveS

JohnB

Quotejust a thought have you tried out the TMS FNC Memo
DaveS
No point in going FMCMemo might just as well use @atomix IDE as it would look and a feel very similar.
JohnB

DaveS

John
Have been giving the synedit highlighter some thought and it should be a piece of cake, famous last words.
I wrote an editor eons ago using synedit but wasn't happy with it no code folding, then went on to ADVMemo then the Econtrols one, so had to dust off the memory banks to give it some thought.
So I'll give it ago when I get time.

DaveS

JohnB

I have sent you a PM.
JohnB

TimB

If this goes ahead then I will start work again on the code and hardware to enable an improved debugger code for the pic.

Perhaps use the MChip system as there is hardware inside to stop on a code address etc.

I kind of agree with Les in that the OnDebug system is very clunky.