In this short article I show you how to enable one of the hidden gems in Eclipse: how to get a description of the library function used in the code
Eclipse is great helping me writing code. One of the shortcuts I use most is <CTRL>+Space for ‘Code Completion’ which gives me suggestions what to write or complete:
It would be great if it could give me some more information about that function? Actually this is possible:
All what it needs is to install the Libhover plugins from the Eclipse Linux Tools project. The Eclipse Linux project is mostly used for Linux (hence the name), but some plugins are usable for any other embedded development.
To install it, use the menu Help > Install New Software and point to the following update site:
http://download.eclipse.org/linuxtools/update
and install the following three plugins
- C/C++ Library API Documentation Hover Help
- Libhover for Newlib Feature
- Library Hover help for devhelp documentation
After a restart of the IDE, I can use the feature, such as moving the mouse cursor over a library call:
Pressing F2 or clicking into the hover let me scroll down to see the full description including examples.
💡 The plugin includes documentation for the newlib library, and the plugin documentation explains how more information or libraries could be added.
Happy Hovering 🙂
Links
- Libhover project: https://www.eclipse.org/linuxtools/projectPages/libhover/
- Developer Guide: https://wiki.eclipse.org/Linux_Tools_Project/Libhover/Developers_Guide
I’d forgotten all about this! I found it before, but I think it wasn’t compatible with CodeWarrior’s version of Eclipse or something and I gave up on it. One of my favorite things about the Borland Turbo C++ IDE (where I got my start in C/C++ 26+ years ago) was its context-sensitive help system. All of the standard libraries and Borland’s libraries were documented there, and each function had *examples*. Also indexes for each header file, I think. I’ve never forgotten the example for the sound() function.
https://everything2.com/title/7+hertz+-+the+resonant+frequency+of+a+chicken%2527s+skull
LikeLike
Ah, that’s a great one 🙂
LikeLike
Hello.
There is some option to modify the font of Code completion, mine is very small. I have access to General> Appearance> Colors and fonts, but I did not find any to modify the Code completion font.
And a request, could you make an article about the DMA? It is something that I do not know much about, and I think it is very important, I am now reading the RT1020 Reference Manual and seeing the SDK examples, I still see it as complex due to the amount of parameters that exist. Nor do I find any tutorial or any book that deals in depth with the DMA.
Specifically, I need the DMA for a program that receives data through SPI in slave mode, and also to transfer data in parallel through several GPIO ports to one or more arrays, automatically increasing the destination address in the array with each data entry. The handling by SPI, more or less I see it clear, but the reading of several data in parallel by GPIO ports still seems complicated to me.
Best Regards
LikeLike
Not sure if there is a way to change the font size of that code completion, I have not found anything.
About DMA: I have not touched the DMA of i.MX RT, but I assume it is similar to the one used for Kinetis, so you could have a read at my tutorials for that DMA peripheral. The principle should be the same.
I did use there GPIO DMA to drive WS2812B LED arrays.
I hope this helps,
Erich
LikeLiked by 1 person
Ok, thanks.
LikeLike
Pingback: New NXP MCUXpresseo IDE V10.3.0 Release | MCU on Eclipse