Arduino with multiple libraries in Eclipse IDE - eclipse

I have an Arduino code and want to continue programming in Eclipse IDE. Basically it consists of 2 main projects which use a lot of common, mostly self-written libraries and structs.
I want to include the two main projects and the libraries in Eclipse.
The problem is, that the compiler can't find the Libraries.
I already Googled a lot but didn't come to a working solution yet.
There are many possible solutions to this problem:
- Move the libraries to C:\Users\Andreas.arduinocdt\libaries - does not work.
- The best one: Set the Arduino Sketchbook location of the Eclipse Arduino IDE. But I can't find the location of this setting.
- Tell the compiler all location of the libraries.
- Write something ugly like this: #define INCLUDE_PATH(N) - But it doesn't work with external (downloaded) libraries or libraries consisting of multiple files.
But I didn't get any Solution to work.
Eclipse Version: 2020-03 (4.15.0)
Can you help me, please! Thank you very much!
Andreas
The current structure of the project. The SettingsGateway is one of many libraries.

Hi I ditched Eclipse for Arduino (microcontroller) development. I use a combination of ArduinoIDE wirh notepad++ as Editor (with plugins) and doxygen for documentation. I write code in C, C++, Javascript CSS, HTML so pretty different code bases. The "problem" with eclipse: it saves the libs woth the project, so if I change something in a lib I have found so far no easy way to automaticlly distribute it to the other projects using the same lib.>br>I am sure there is some plugin, but my job is to code and not to readd ocumentation of an ever changing IDE. If you stay with eclipse for Arduino Sloeber is your easiest option: http://eclipse.baeyens.it/index.shtml Everything together in a central place, you can then install other modules if needed

Related

Netbeans + Codename One - Avoid importing packages or classes not suitable for CN1

I'm using Netbeans IDE. It's quite annoying and it's a cause of errors the import of Java packages and/or classes that are not provided by Codename One. (Codename One use its own implementation of a subset of Java8 and it cannot support the full Java API).
For example, sometimes Netbeans imports automatically wrong packages (such as "java.awt.BorderLayout" instead of "com.codename1.ui.layouts.BorderLayout"), other times it shows me methods and Javadocs that are not available in Codename One.
Is it possible to force Netbeans to show me only packages, classes, methods and javadocs that are supported by Codename One? It could be useful to avoid errors.
We'd love to but unfortunately the only way NetBeans allows you to do that is if you build your own Java language package. That's what some other plugins like NBAndroid did AFAIK but when we implemented the plugin we didn't want to create something too complex.
If NetBeans supported a "bootclasspath" option for the JDK it would have solved everything. It does have support for plugging in an alternative JDK which can be a micro-profile but because we don't comply with the micro-profile spec I'm not sure if that will work.
At times, NetBeans suggests to import more than one package from the drop-down list. When you check carefully before pressing ENTER this might avoid importing the wrong package.
I use NetBeans for quite a while with CN1 and faced the same problem at the beginning.

IDE for existing Makefile's on Linux

What would be the best/quickest way to have a IDE-type setup when I have existing C/C++ source with several Makefiles (library, executable etc.).
I need to work with compiler errors in the IDE and preferably navigate the code.
In the past I have used Emacs/Xemacs, and it is OKish, but I am not sure about the best way to set it up.
The Eclipse CDT plugin is a pretty decent IDE for C/C++.
I've found the code navigation features good for small-to-medium projects (the indexer becomes slower with very large projects). Eclipse has its share of detractors for being bulky and Java-based, but it works fine for me.
KDevelop and Netbeans might be worth looking at as alternatives, if you want this kind of GUI-based IDE. As you've said, Emacs (or Vim) can be used to get the same functionality with more of a keyboard-based approach, with the right setup.

Eclipse Helios plug in behemoth (I like to write behemoth on everything)

just changed from Netbeans to Eclipse just for fun (Only developer on the company, So I can code on whatever and with whatever I feel like.) That's why I liked the new version of netBeans over vim, it could load resources or plugins, I am not quite aware of their naming conventions, on demand. For example if you were working on a Grails project it would only load grails related resources.
On Eclipse I have a gazillion plugins installed. Some to emulate Netbeans functionality (Grails, JavaFX, Ruby, PHP, CSS, Python, etc.) And some others Netbeans lacks (Android, Vaadin, SpringRoo, Git and some others) But I am not sure how Eclipse handles this plug in behemothing
Does it load them on demand? Do I have to manually disable the ones I am not using? Do I have to have different installs for each language I work on? Or do I have to learn how to live with this big mess of plugins in order to have everything I need at hand??
Thank you very much for your time.
Basically Eclipse loads the plug-in codes lazily. On the other hand, the menu/toolbar contributions are loaded at the start of the platform.
If the plug-ins are written correctly, they should not interfere with each other, and the unnecessary elements should be few in the context menus.
My suggestion is to try this installation, and look for potential problems. If you have problems with the environment, only then try to identify and remove the plug-ins. But it should be ok.

How do I get support for GPB in Eclipse?

I'm trying to use Google Protocol Buffers in my project and I'd like to have some tooling support from Eclipse. In particular, I want Eclipse to call protoc every time I make changes to the .proto files and then rebuild all code that depends on the generated code.
I tried to set up a Custom Builder but it keeps bugging me with errors I don't understand, most often it complains that the .proto file is not on the path given by --proto-path, which it should be by all I can tell. Also, because I use ${build_files}, Eclipse passes all changed files to the compiler (instead of those that I have configured to trigger the build).
NetBeans seems to have a protobuf-Plugin, but I can't find one for Eclipse. Is there one?
Theres a protoclipse plugin on googlecode, which is in the initial stages:
http://code.google.com/p/protoclipse/
Not sure if there is a builder, but I did find a plugin for syntax highlighting for protocol buffers.
You can define an external builder on the plugin that invokes an ant task. It is an ugly kludge, but until there is a better solution this may serve your purposes.
In practice, syntax highlighting turned out to not be that important, I hardly edit these files, and they tend to be very small. Maven and the m2eclipse plugin handle the building side of things great.
I recommend using Google's "Protocol Buffers Development Tools". It is a plugin for Eclipse that features automagic regeneration and error checking, among other things. It's available here: http://code.google.com/p/protobuf-dt/ .
While this question is close to other Eclipse plugin for working with protobuf, answers here are different.
Well, yes, if you use maven/gradle to invoke protoc (Protobuf compiler), than you may need no Eclipse plugin at all.
Colorizing editor helps for long file or with many comments. Know there are 2 editor plugins for Eclipse.

How does Qt Creator shape up against Eclipse CDT?

Qt Creator looks like a good IDE. I've been using Eclipse CDT and while a little buggy, it does the job.
Does Qt Creator have the same capabilities as Eclipse CDT?
Qt Creator uses MinGW under the hood, so it only makes sense that it would be able to compile without using any Qt headers. Simply uncheck all of the headers when making the project and you can code just like you would in any other IDE.
I took an example shot for you to see:
Dead link
Edit: Ahh you edited your question.
Yes of course! Qt is a great environment and can sure hold it's own against competitors like Eclipse in C++. Although keep in mind Eclipse satisfies a myriad of developers, from Java to C++ to Python among many others. Typically an IDE specializing in one language will be more catered to that language, but Eclipse sure does one hell of a job catering to developers of multiple languages with it's vast amount of plugins. If you're comfortable with Eclipse CDT, I think you will feel right at home with Qt Creator, better yet, pampered.
such a great piece of software.
Well, QTCreator does exactly what a Linux C++/C dev (i assume you are a linux dev from what i read) would want from an IDE. Neither too much nor too little features. The problem of feature rich IDEs like Eclipse is that you might loose control of your project since it pretty much handles everything. If something goes south you have to take the features/plugins you used into consideration during the debugging process.
But overall, eclipse is (imho) the better choice since it makes sense to get used to one IDE that can pretty much handle every language. At work i use eclipse CDT for exactly this reason. For private projects i use QTCreator, because C/C++ are the only languages i use for these projects.
I hope this helps
Since you mentioned nothing about Qt, I assume that you plan to use QtCreator for a non-Qt C++ project, with its own custom Makefiles, not qmake-based, not Eclipse-CDT-based.
After I switched to QtCreator (now working on the same project, same code) I noticed the following advantages of QtCreator:
QtCreator moves faster than EclipseCDT for the same C/C++ project.
EclipseCDT is harder to config with custom Makefiles. QtCreator is easier. This is the case when you checkout a project with its own custom Makefiles, not IDE-generated ones, and you need to map that project's build targets to EclipseCDT build targets/configurations.
It's easier to deal with .pro(ject) files in QtCreator than workspaces in EclipseCDT.
In my case, the EclipseCDT memory footprint after indexing is about ~2GB. For QtCreator, it is only ~600MB, for the same project.
Source indexing in EclipseCDT takes a lot of time - when I start EclipseCDT, my computer is frozen for about 20 minutes due to indexing. In QtCreator it takes a quarter of that time, and the computer is responsive during it.
Of course there are a lot of advantages that EclipseCDT offers like the plethora of plugins (EGit, Subclipse, cppcheclipse, etc), but it depends if you really use them.
In the end, I think it's a matter of personal taste and habit, as you can achieve your goals with each of them.