View previous topic :: View next topic |
Author |
Message |
kitsh69
Joined: 13 May 2004 Posts: 2 Location: Montreal, canada
|
Cursor mouvement after compilation in MPLAB |
Posted: Thu May 13, 2004 7:52 pm |
|
|
Is there a way, in MPLAB, to prevent the cursor from jumping to the first line of the program after the compilation or to jump to the current excution line after a halt command ?
I want to be able to Compile, Run, Break, Reset without loosing the last line i've modified before compiling/running. Every time i'm doing a change and try the result, i have to reposition the cursur because MPLAB is jumping to the first line after compilation, and the "break line" after the break command..... it's VERY VERY time consuming to have to scan a file of 2000 or 2500 lines on every compilation. |
|
|
prwatCCS
Joined: 10 Dec 2003 Posts: 70 Location: West Sussex, UK
|
|
Posted: Fri May 14, 2004 3:48 am |
|
|
add a comment to the line you have just changed and use the find facility to jump immediately to that comment.
comments on code that is changing seems a good idea anyway! _________________ Peter Willis
Development Director
Howard Eaton Lighting Ltd UK |
|
|
Haplo
Joined: 06 Sep 2003 Posts: 659 Location: Sydney, Australia
|
|
Posted: Fri May 14, 2004 5:08 am |
|
|
It jumps to the first line of the code because after a reset PC points to the first instruction (address 0x0000), which according to MPLAB corresponds to the first line of the code. PCWIDE does the same thing. As suggested you have to use some searching method to go back to your last position. |
|
|
ckielstra
Joined: 18 Mar 2004 Posts: 3680 Location: The Netherlands
|
|
Posted: Fri May 14, 2004 11:52 am |
|
|
A file of 2000+ lines?????
It sounds like a hell to retrieve something in such a file....
Why don't you split the file into several files? This will help you a lot to keep the overview. Way more professional too....
And as a bonus: MPLAB still sets the program counter to the start of your program, but this will only affect the view of your main file! All other files keep their old view location. |
|
|
kitsh69
Joined: 13 May 2004 Posts: 2 Location: Montreal, canada
|
|
Posted: Tue May 18, 2004 8:11 pm |
|
|
It's already split in several files (1 for main, and 4 includes) all 5 files have more than 6000 lines totals.
Even if it's a small program... like 100 ou 200 lines... I find it totally ridiculous that there's not an option to prevent that "feature".
I've never seen that in every other high level compiler i've used. (C, C++, C#, Pascal, etc)
I'm going to look if i can incorporate the "find feature" in a macro to mark automatically the last position, compile, and go back automatically all in a single press of an "F" key. |
|
|
ckielstra
Joined: 18 Mar 2004 Posts: 3680 Location: The Netherlands
|
|
Posted: Wed May 19, 2004 12:38 am |
|
|
Instead of only complaining and trying to find a way around it, have you considered to report this to the developers of MPLAB (Microchip)? There is no garuantee they will implement it, but if you never ask.... |
|
|
|