Arduino Eclipse Plugin <Update>

Ken
Is there some doc that explains the feature that you describe?
Best regards
Jantje

Johan
Please don't crosspost. You posted this message on 3 different locations with 3 times different levels of details.

Best regards
Jantje

Hi Jantje,

My apologies.

Please find attached my debug from the console during build time.

**** Build of configuration Release for project Testing ****

make all
Building file: /Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP/uip/unix/clock-arch.c
Invoking: AVR Compiler
avr-gcc -I"/Applications/Arduino.app/Contents/Resources/Java/hardware/arduino/cores/arduino" -I"/Applications/Arduino.app/Contents/Resources/Java/hardware/arduino/variants/standard" -I"/Users/johansmit/Documents/workspace/Testing" -I"/Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP" -D__IN_ECLIPSE__=1 -DARDUINO= -DUSB_PID= -DUSB_VID= -Wall -Os -g -mmcu=atmega328p -DF_CPU=16000000UL -MMD -MP -MF"NanodeUIP/uip/unix/clock-arch.d" -MT"NanodeUIP/uip/unix/clock-arch.d" -c -o "NanodeUIP/uip/unix/clock-arch.o" "/Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP/uip/unix/clock-arch.c"
/Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP/uip/unix/clock-arch.c:42:22: warning: sys/time.h: No such file or directory
/Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP/uip/unix/clock-arch.c: In function 'clock_time':
/Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP/uip/unix/clock-arch.c:48: error: storage size of 'tv' isn't known
/Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP/uip/unix/clock-arch.c:49: error: storage size of 'tz' isn't known
/Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP/uip/unix/clock-arch.c:51: warning: implicit declaration of function 'gettimeofday'
/Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP/uip/unix/clock-arch.c:49: warning: unused variable 'tz'
/Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP/uip/unix/clock-arch.c:48: warning: unused variable 'tv'
make: *** [NanodeUIP/uip/unix/clock-arch.o] Error 1

**** Build Finished ****

Regards,
John

John

As I see it the time.h file should define some stuff. Due to the absence this generates errors later on.
If this compiles fine in the Arduino IDE there must be a different command line between the arduino IDE and eclipse.
I would advice to look at the Arduino IDE verbose build output and see the compile instruction used to compile clock-arch.c. There must be a difference in the command line. If you want me to have a closer look please post the Arduino IDE command to compile clock-arch.c.
What I can see from the eclipse output is:

-DARDUINO=

The Arduino version is unknown. This points to a problem in your configuration. Please check the windows->preferences->arduino->arduino settings. This may explain your problem.

/Applications/Arduino.app/Contents/Resources/Java/libraries/NanodeUIP/uip/unix/clock-arch.c:

I don't know this environment but you are on a mac and you are using unix code. This may be perfectly alright but it is not a standard arduino ide installation. Currently the eclipse plugin only supports the standard Arduino IDE. If you installed extensions they may not work "out of the box".

Best regards
Jantje

Hi Jantje,

Thank you. I do agree that it must be something to do with the command line. Please have a look at the attached Arduino IDE debug output. I do not see any compilation for clock-arch.c.

All these files come standard with the NanodeUIP library, and I do not think that I have anything out of the ordinary in my installation. I have fixed the -DARDUINO=1.01 tag as well, with no success.

It seems that the ArduinoIDE is omitting compiling the unix stuff, I just don't know why.

Perhaps you can try to build this library with your setup just by including NandodeUIP? GitHub - sde1000/NanodeUIP: Port of uIP library to Nanode

debug_outout.txt (27.9 KB)

John
The Eclipse plugin does not care about makefiles. It makes it's own makefilesfor each and every folder in the project.
To exclude a folder from the build: right click the folder->Resouce configurations->exclude from build and make sure release (there should ony be release) is selected.
Best regards
Jantje

Jantje:
John
The Eclipse plugin does not care about makefiles. It makes it's own makefilesfor each and every folder in the project.
To exclude a folder from the build: right click the folder->Resouce configurations->exclude from build and make sure release (there should ony be release) is selected.
Best regards
Jantje

Hi Jantje,

Thank you, I excluded one or two folders and my code is now building successfully. I'm also able to upload with my serial port set as /dev/tty.PL2303-00002014 with no problems.

Next, I'm trying to get the serial monitor to work, however the port selection dropdown is empty. I tried to add this to the eclipse config but it did not work so I removed it again.

Any ideas?

Thank you

aquadat0r:
Any ideas?

I updated the FAQ.
I also closed the issue you created on Github

Jantje

I am using Eclipse C++ Juno as well and I successfully uploaded a blink sketch to my Arduino Nano 328. I can change the blink interval. However, it was a long and arduous setup process. I followed this tutorial but after the build process was finished, I believe it succeeded but it gives

Errors occurred during the build.
Errors running builder 'CDT Builder' on project 'Basic_blink_eclipse'.
Internal error building project Basic_blink_eclipse configuration Release
java.lang.NullPointerException
Internal error building project Basic_blink_eclipse configuration Release
java.lang.NullPointerException

When I want to upload, I hit the Upload to AVR button, then it complains that the serial port is in use when it really is not. I press OK then it uploads fine. Overall it works but having to click four buttons to upload code is a bit annoying.

orangeLearner
I'm sorry to hear you had such a hard time to install the plugin. Not sure what has cost you so much effort as most people succeed in installing the plugin in less than half an hour. Mac 64 bit with Juno is the most challenging environment though.
About the 2 remaining issues.
The error during build.
As you are running eclipse Juno you should upgrade to the latest version of the plugin. That should fix the issue. Note that you will need to create new projects as the existing ones contain "a bug" which is not cleaned.
To clear "the bug" manually see the comment of bgolenko at Odd Build Error When Using Eclipse Juno · Issue #12 · Sloeber/arduino-eclipse-plugin · GitHub

The upload problem.
This is a pure mac related problem where Peter send me a good solution.
I've added the solution to my FAQ which you can find at This page has been moved

Best regards
Jantje

Jante,

There's a thread over on the Leaflabs forum discussing using eclipse for the Maple IDE, and it occurred to me that your plug-in might be useful in that context as well:

http://forums.leaflabs.com/topic.php?id=681#post-3846

Goede dag Jante,

Just posting in here to say a really big thank you for the work you have put in to make this plugin for Eclipse.

I have been using the standard Arduino IDE for some time now and wanted to move to an IDE that would provide more features for me.
I had looked at Eclipse a long while ago, but it was quite complicated to have it working with Arduino at that time.

So, the other day, I installed on my mac mini the 64 bit Eclipse Juno version 4.3.0 with CDT, followed by your plugin version 1.2.5.5.
The installs went well, as did the configurations once I figured out a few things.

I initially had problems with all sorts of errors coming up at build time and no hex file being made, my project uses Ethernet, SPI and TimerOne libraries.
I wanted very much that it would compile without errors, so that as I further develop my code using Eclipse as my IDE, any real problems would be highlighted, an no phantom errors.
After going carefully through my project and noticing what I had done incorrectly, I was rewarded with a successful build and could upload to a board, in this case a Freetronics EtherMega EtherMega (100% Arduino Mega 2560 compatible with onboard Ethernet) | Freetronics.

My other platform is Linux, ubuntu, so I will in time install the same setup on there as well.

Two questions though, if I could;

  • As stated in this thread I believe, when including a library which contains a utility folder, such as Ethernet or SD or Wire, I also need to add the library paths to the project properties, section, C/C++ : Paths and Symbols.
    Is this something that might be rectified in your plugin at some point in the future?

[br /]

  • You mentioned a while back at reply #49

However I found out lately that also adding "cstdio.h" to the "files to index upfront'" -as described in the faq -fixes the Serial problem.

I assume this is in project properties, section, C/C++ : Indexer : Files to Index upfront?
In the version of Eclipse I have, Juno 4.3.0, this option appears not to exist. In your opinion, is this an important setting to have?

I have installed CoolTerm as my serial monitor now and it seems to be a great app for any serial comms. Plus I can configure it the way I like, in terms of gui style.

Again, Jante, bedankt voor de plugin,

Paul :slight_smile:

Paul
Nice to hear you like the plugin.
As to your 2 questions:

Is this something that might be rectified in your plugin at some point in the future?

it is on my big todo list. Your only impact on the priority in this list is via http://eclipse.baeyens.it/donate.html 8)

In your opinion, is this an important setting to have?

Not at all. It is just annoying that the indexer does not recognize Serial. Because of that typing "Serial."+ctrl space will not show you a list of options.
It does not impact the compiler outcome. The indexer behavior is inconsistent or hard to predict, this setting may or may not help; only the indexer may know. ]:smiley:
You can read more at This page has been moved

lastly: you say you use CoolTerm as serial monitor. Have you tried the one in the plugin? It allows for 3 serial connections at the same time.
See a demo at http://eclipse.baeyens.it/serial_demo.wmv (It may take some time to load)

Best regards
Jantje

Hi Jantje
Any idea how to use ATTINY on the ECLIPSE with the plugin? I noticed a lot of approaches but no final solution.
Excuse my ignorance.
Regards
Nico

nicoverduin:
Hi Jantje
Any idea how to use ATTINY on the ECLIPSE with the plugin? I noticed a lot of approaches but no final solution.
Excuse my ignorance.
Regards
Nico

I have no experience with the attiny at all. But My guess is that the best way is to use Arduino IDE 1.5.2 and modify or add the boards.txt and platform.txt. That should make it work in the Arduino IDE and the eclipse plugin.

Best regards
Jantje

Thanks
I'll upgrade first.
Regards
Nico

Got it fixed. Load the ATTiny master (on github) and added the boards to the master board file and the correct folders into hardware etc. Restarted Eclipse and now I have te correct ATTIny boards supported as well. I have to add the include folders manually in properties but that is all.

great
Thanks for the update