OK,
As a newbie here I am just learning the Web IDE and learning how to build apps. I decided to tackle adding a display to a Particle Photon or Boron, Xenon Argon etc. In this case I am using the Photon. I bought an OLED white monochrome display from DIY More 128 x 64 display. It uses the SPI Serial For Arduino C51 STM32.
[https://www.diymore.cc/products/2-42-inch-12864-oled-display-module-iic-i2c-spi-serial-for-arduino-c51-stm32-green-white-blue-yellow?variant=17060396433466](http://DISPLAY I AM USING)
I have the device wired on a particle dev board with the Photon. Here is what I have tried to do:
1.) Open the WEB IDE and created a new App called Demo_display
2.) Tried to add the libraries for the Adafruit_SSD1306 & Adafruit_GFX because I understand that these are required.
3.) I tried to load one of the examples in the libraries. EXAMPLE: ssd1306_128x64_spi.ino
4.) Click Include in Project, select the project and click confirm.
5.) when I do, the save button is grayed out and I cannot save anything.
6.) I expected to see multiple tabs in the project for the Adafruit_GFX.cpp, Adafruit_GFX.h, Adafruit_SSD1306.cpp & Adafruit_SSD1306.h however, the only thing that is added is the include to call the library like this:
// This #include statement was automatically added by the Particle IDE.
#include <Adafruit_SSD1306.h>
The code will NOT compile.
I noticed that the Code from the Demo file ssd1306_128x64_spi.ino included the following includes declared:
#include <Adafruit_GFX.h>
#include <Adafruit_SSD1306.h>
But the app also added this at the very top:
// This #include statement was automatically added by the Particle IDE.
#include <Adafruit_SSD1306.h>
The save button is STILL grayed out.
I refreshed the screen and the save button became usable again. I saved the display_demo project.
Only 1 tab is visible: demodisplay.ino.
The code will not compile:
I get two errors:
lib/Adafruit_SSD1306/Adafruit_SSD1306.h:109:7: redefinition of 'class Adafruit_SSD1306â
lib/Adafruit_SSD1306/Adafruit_SSD1306.h:109:7: previous definition of âclass Adafruit_SSD1306â
It is VERY frustrating when example libraries will not compile that are pulled directly from the Particle IDE. Why is this happening???
Help!