Hi community
As an old Eclipse (Java) Buff I wanted to give the Platformio Eclipse Integration a try. Now I am struggling with the following statement:
const char ArialMT_Plain_10 PROGMEM = {…};
Which gives me a syntax error. When I remove the PROGMEM statement it compiles just fine. I followed the instructions on the setup page but still can’t get the code to compile. I suspect that the compiler doesn’t know about the PROGMEM keyword. How can I teach it?
BTW: I just love the platformio stuff. It makes me a lot more at home than the Arduino IDE…
Hm, I tried that now but the problems are still there. And since I am developing for the ESP8266 platform it would also feel a bit wrong to include something avr specific or am I wrong?
My bad I didn’t mention the platform. The PROGMEM statement is also known to the ESP8266/espressif platform. It works fine in the Atom IDE and the Arduino IDE. Just in Eclipse I get the Syntax error which later leads to an unknown symbol when I try to use that declaration. I also included the ESP8266 statement
You guys are really responsive! Awesome community!
OK, I tried to update an example project:
I got confused about two things: I tried to install my oled library with
platformio lib install 562
And the command line tool said it was already installed, but Eclipse didn’t find the includes. And suddenly the board type nodemcuv2 seems to have disappeared?
OK, running platformio init after adding libraries in platformio.ini solved the library issue. I updated now the above repository and I get an error in the line
display.setFont(ArialMT_Plain_10);
because the font from the library has the mentioned syntax error due to the progmem issue…
Description Resource Path Location Type
Symbol ‘ArialMT_Plain_10’ could not be resolved main.cpp /esp8266-ci-ota/src line 43 Semantic Error
In SSD1306Fonts.h is only a warning “Syntax error”, but by removing the PROGMEM statement the two above errors disappear… And I should mention that I’m using Eclipse on Mac OS X
Feeling very stupid:-( While my Atom IDE was up to date with the latest version of platformio the version used by Eclipse wasn’t. So the initialisation for the IDE obviously used an old version which resulted in the mentioned errors.
So, for anybody having similar issues: MAKE SURE YOUR COMMAND LINE VERSION IS UP TO DATE!!!
Thank you guys for your help and sorry for having wasted your time…
Thanks Ivan, I will clean up my CLI mess:-). One more question: is there an easy way to have a serial monitor in Eclipse as there is in the Atom IDE, which preferably even opens automatically after an upload?
This is impossible in the current configuration We don’t have own plugin for Eclipse. We propose integration with “customization” which we do on “init” process.