During December, I gave this plugin a spin. Once I got it set up, it definitely was preferable to using the Arduino IDE. However, getting it set up (more-or-less) correctly was quite difficult. Here are some of the problems I ran into. I would love it if the plugin handled more of these automatically so that new users weren't confused by these issues (and so they didn't have to follow a bazillion steps in setup instructions.)
First of all, it would be helpful to make clear that users of this plugin are not expected to download the C++ edition of Eclipse to install it into. I did this at first, and it really confused me. You should probably clearly state very clearly exactly what version of Eclipse to use with the plugin.
I found that in order to get my Arduino 1.0 code to compile properly, and also for many of its symbols to be resolved correctly in Eclipse as I was editing (otherwise they are marked as errors in edit windows), I needed to add some defined values to each of the following pages:
"Properties->C/C++ Build->Settings->Tool Settings->AVR Compiler->Symbols->Define Syms (-D)"
"Properties->C/C++ Build->Settings->Tool Settings->AVR C++ Compiler->Symbols->Define Syms (-D)"
Specifically, I added:
ARDUINO = 100
__AVR_ATmega328P__ = 1 (or whatever chip you are using) in GCC and/or G++
__IN_ECLIPSE__ = 1 (more on this later)
It would be nice if the plugin prompted for at least the first two of these in some obvious way (on a project configuration page?), so users didn't have to go digging into compiler options in order to set these values. Having to change them in two places is also annoying.
That helped, but I was still seeing symbols such as Arduino-specific methods marked as errors. Therefore, in each of the following pages:
"Properties->C/C++ Build->Settings->Tool Settings->AVR Compiler->Directories->Include Paths (-I)"
"Properties->C/C++ Build->Settings->Tool Settings->AVR C++ Compiler->Directories->Include Paths (-I)"
I added the following entries:
Again, it would be nice if the plugin automatically added these to the include paths, so users didn't have to go digging into compiler options in order to set these values.
This resolved most of the "red" text indicators. However, some were still left. It seems that Eclipse has some bugs in that if a file is imported via an #include which includes a relative path, such as '#include "avr/foo.h"', and it includes another include via the same relative path ("#include 'avr/bar.h") then at edit time, Eclipse doesn't seem to find and parse the most-deeply-nested included file. Among other things, this meant that my "Serial" object was always marked as an error. This resulted in me having to work around the problem by adding a few declarations into my source files that would only be processed when I was editing in Eclipse, thus quieting the error indicators. In one file, for instance, I added this at the top of the file:
extern HardwareSerial Serial;
static void eeprom_write_byte (uint8_t *__p, uint8_t __value);
I was still seeing Eclipse warning messages about constructs like:
const char helpText1 PROGMEM = "stuff";
which stated "only initialized variables can be placed into program memory area". Apparently this is a bug with avr-g++:http://www.avrfreaks.net/index.php?name=PNphpBB2&file=printview&t=57011
A bug report was filed against it, and is reported as "fixed" for version 4.6.2 of the gcc compiler:http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34734
It would be nice if the plugin could include this version of the compiler or later.
My main advice to you would be to automate as much of this kind of setup as possible, so that users will not have to figure out what's wrong and what to do about it. It took me a long time to figure out how to get this working, and judging from some of the recent comments to this forum, I'm not the only one. Having the plugin ask some questions at install time (or when requested) and then setting itself up automatically from those would be really helpful, especially to people who are unfamiliar with the intricacies of the Eclipse C++ build process.
Thanks very much for writing the plugin!