Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Hook up with CDT UI

Hello, dear community!

First of all I'd like to thank Warren Paul for his great support so far! He was really trying to help me with my questions - so thanks again, Paul!

Unfortunately I still don't really know how to reach what I intend to do but after some more research I think I can describe what I need a little bit better. The attachment shows what already is implemented - except the "Debug Visualization" part.

Here are the three main parts of quiet huge interdisciplinary project:

1.      There is a server, let's call it µCCom-Server which communicates with a microcontroller via USB and allows setting breakpoints, read registers, program the microcontroller and all kind of other stuff that one could possibly want to do with it. This is a huge non-replaceable part.

2.      Then there is a dynamic link library which is nothing but an interface which gets bridged to the Eclipse Plug-in by creating a Java C# .NET bridge. This part also already works, whereas the bridge-part is also non-replaceable. This dll file uses .NET Remoting to communicate via TCP with the server (but this doesn't really matter to us here).

3.      Last but not least there is the Eclipse Plug-in built upon the CDT Plug-In. This plug-in implements the Standard Eclipse Debug Model. It is the same Debug Model which is also implemented by TCF and EDC.

Importand:
But it does not hook up an existing process or something like this, instead, it tells the µCCom-Server to set the breakpoints on specified addresses and then waits until a method e.g. myDevice.runUntil(new int[] { 0x4512, 0x4612 }); returns which indicates that the microcontroller has hit a breakpoint.

And this is where I stuck right now. The Debug Model seems to support a few things like displaying the stack frame (IStackFrame) or display some variables (IVariable) which works - by now only hard coded but it works. But there does not seem to exist something like a basic support for hooking up with the CDT UI. Speaking of the Current Instruction Pointer, I have no idea how I could simply tell which line has to be highlighted like the CDT does it when debugging a C program.

Is there an easy way which allows me to use this UI part of the CDT such that I am not forced to rewrite everything or use TCF or even EDC?

Why I don't want to use TCF or EDC:
Since all that is missing is just that part where Eclipse just highlights the currently executed line, switching to one of those frameworks seems to be a quiet radical step to me.

But long story short:
When the microcontroller hits a breakpoint and I'm back inside my Eclipse Plug-in which gets back in control of things: How can I hook up with the CDT Plug-in and tell it so highlight an arbitrary line?


Thank you and sorry for this long message!

Best regards, Stefan.



Attachment: Capture.PNG
Description: Capture.PNG


Back to the top