PDA

View Full Version : Microcode studio problem with include



Marcick
- 4th January 2018, 07:42
Hy guys, hope this is the correct section where to post.
Bored of the funny color coding of PBP inside MPLAB, I'm giving a chance to Microcode Studio.
It works, but I encounter a big trouble:

I have a Main.pbp where I include several modules. As you can see in the picture1 attached, I have many modules opened, each one has a tab over the editor window so it's easy to jump from one to the other.
When I compile the code, if there is an error in one module, Microcode jumps to the error and show you in red color, but add a new tab of the same module.
Look at picture2. I wrote an error in module nmea.bas and after compiling Microcode opened a second nmea.bas to show the error.
This create a big confusion, because (if you don't realize this) you correct the error in one module, but the other one is still opened and after some time you can continue coding in the wrong module ....
Hope I have explained well. This bug happens very often, but not always.
Anyone has this trouble too ?

mpgmike
- 4th January 2018, 23:11
Absolutely. I suppose I never gave it much thought, but it fooled me a couple of times before I figured it out. Did you correct the problem?

Marcick
- 5th January 2018, 07:42
Absolutely. I suppose I never gave it much thought, but it fooled me a couple of times before I figured it out. Did you correct the problem?

I would like to know how to ....
Every time I have a compile error, I check first now if a secon module with the same name has been opened and close it.
But what a poor solution. It’s a paid software ! (Pro version).

AvionicsMaster1
- 9th January 2018, 14:29
It would be nice if there were and option when you compiled a program MCS would compile a one up version and display it in the filename.

That could create more confusion but for me it would attempt to ensure I was fixing the last attempt to compile a program. I'd also be able to back track to see what worked or how I made it not work. Maybe in practice this wouldn't work so well but I think it would be helpful.

Marcick
- 9th January 2018, 15:27
Looks like Mecanique is not interested to maintain its product good and constantly updated.
I've spent a bunch of dollars but I definitely stop to use it. I can't see these awful behaviours.
One new, just found a few days ago: a good search tool should show all the occourences in all modules of the keyword. But not pretending too much, at least it should find what you are looking inside a module .. look to the picture, it is self-explained ....

8577

mpgmike
- 9th January 2018, 19:09
I've seen this where there is an obvious label, yet I get a compile error like the one above. It is almost always something totally unrelated, like a DO without a LOOP, or an IF without an ENDIF. When this happens, I have to pore over the code one line at a time to try to figure it out. It would be nice if the accused (LABEL not found) were the culprit every time, but the diagnostics in the IDE are limited. There will be something in your code that doesn't 100% follow the rules, and it isn't the lack of Debug_SMS_OutBuffer.

Marcick
- 9th January 2018, 19:33
I've seen this where there is an obvious label, yet I get a compile error like the one above. It is almost always something totally unrelated, like a DO without a LOOP, or an IF without an ENDIF. When this happens, I have to pore over the code one line at a time to try to figure it out. It would be nice if the accused (LABEL not found) were the culprit every time, but the diagnostics in the IDE are limited. There will be something in your code that doesn't 100% follow the rules, and it isn't the lack of Debug_SMS_OutBuffer.

in this case I have no compile error. I was just searching for that label and that poor IDE is not able to find it ... close to unbelievable ! (Thinking that all modules are plain text)

Just to continue the discussion, migrating to OT I know, I can’t explain why a nice tool like PBP is not able to perfectly integrate in MPLAB without that funny color coding (this is the reason I gave MCD a chance)

HenrikOlsson
- 9th January 2018, 21:32
1) I don't think it searches all open files, just the active tab. You can say that's a bug or feature or missing feature or whatever. Personally I'm fine with that but an option to search all open files couldn't hurt I guess.
2) When you search for something you have the option to search from the cursor and "down" or from the cursor and "up". Is it possible that your label was on "the wrong side" of the cursor combined with your selection? Again, I guessa message box popping up asking if you want to "wrap around" could be useful.

As for the error messages, they don't come from the IDE, they come from the compiler. Make sure you look at the last error and not just the first.

I totally agree that by now we should have a better IDE - but we don't.

Marcick
- 10th January 2018, 07:42
Well, I was searching inside a specific module and I'm quite sure about the UP and DOWN rule, but maybe I was wrong, I can't confirm it because now it works .....

I'm often tempted to move to MPLABX and XC, I've played a bit with some tutorials and it looks really powerful. But a lot of stuff to study and probably there are a lot of bugs there too ....