pre-processing of plugin ino file screwing up the build process

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
dony71
Normal user
Posts: 16
Joined: 25 Apr 2018, 20:01

pre-processing of plugin ino file screwing up the build process

#1 Post by dony71 » 31 May 2018, 01:07

I make plugin _P134_PPD42.ino but platformio reports tons of error while compiling
If I include this _P134_PPD42.ino in src directory, don't know why platformio trying to convert
this _P134_PPD42.ino to *.cpp instead of ESPEasy.ino and this mess up the build process.
Can anybody help me?

_P134_PPD42.ino file :
http://www.mediafire.com/file/k44xjgxhv ... 2.ino/file

Error :
PS F:\Users\donyo\Documents\GitHub\ESPEasy> pio run -v -e dev_ESP8266_4096
>>

[05/30/18 19:06:05] Processing dev_ESP8266_4096 (framework: arduino; lib_deps: ; build_flags: -D BUILD_GIT='""' -Wl,-Tesp8266.flash.4m1m.ld -D PLUGIN_BUILD_DEV; lib_ignore: ESP32_ping, ESP32WebServer; platform: espressif8266@1.5.0; upload_speed: 460800; board: esp12e; board_flash_mode: dio; lib_ldf_mode: chain)

-----------------------------------------------------------------------------------------------------------
PLATFORM: Espressif 8266 > Espressif ESP8266 ESP-12E
SYSTEM: ESP8266 80MHz 80KB RAM (4MB Flash)
xtensa-lx106-elf-g++ -o "F:\Users\donyo\Documents\GitHub\ESPEasy\src\_P134_PPD42.ino.cpp" -x c++ -fpreprocessed -dD -E "c:\users\donyo\appdata\local\temp\tmpb8dicv"
Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF MODES: FINDER(chain) COMPATIBILITY(light)
Ignored library F:\Users\donyo\Documents\GitHub\ESPEasy\lib\ESP32_ping
Ignored library F:\Users\donyo\Documents\GitHub\ESPEasy\.piolibdeps\ESP32WebServer_ID2007
Collected 44 compatible librariesMore details about "Library Compatibility Mode": http://docs.platformio.org/page/library ... ompat-mode

Scanning dependencies...
Dependency Graph
|-- <ESP8266HTTPUpdateServer> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266HTTPUpdateServer)
| |-- <ESP8266WebServer> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WebServer)
| | |-- <ESP8266WiFi> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WiFi)
| |-- <ESP8266WiFi> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WiFi)
|-- <SparkFun APDS9960 RGB and Gesture Sensor> v1.4.2
(F:\Users\donyo\Documents\GitHub\ESPEasy\lib\SparkFun_APDS-9960_Sensor_Arduino_Library)
| |-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
|-- <SD(esp8266)> v1.0.5 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\SD)
| |-- <SPI> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\SPI)
|-- <CHT16K33 LED Matrix Library> v0.0.1 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\HT16K33)
| |-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
|-- <LiquidCrystal_I2C> (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\LiquidCrystal_I2C)
| |-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
|-- <PubSubClient> v2.6 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\pubsubclient)
|-- <Servo(esp8266)> v1.0.2 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Servo)
|-- <IRremoteESP8266> v1.2.0 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\IRremoteESP8266)
|-- <Adafruit Motor Shield V2 Library> v1.0.4 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\Adafruit_Motor_Shield_V2)
| |-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
|-- <ESP8266WebServer> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WebServer)
| |-- <ESP8266WiFi> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WiFi)
|-- <ESPEasy_ESP8266Ping> v1.0 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\ESPEasy_ESP8266Ping)
| |-- <ESP8266WiFi> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WiFi)
|-- <Adafruit Unified Sensor> v1.0.2 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\Adafruit_Sensor)
|-- <Adafruit TCS34725> v1.0.1 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\Adafruit_TCS34725)
| |-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
|-- <DNSServer> v1.1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\DNSServer)
| |-- <ESP8266WiFi> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WiFi)
|-- <ESP8266_SSD1306> v3.2.7 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\esp8266-oled-ssd1306)
| |-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
| |-- <SPI> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\SPI)
|-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
|-- <Adafruit TSL2591 Library> v1.0.2 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\Adafruit_TSL2591)
| |-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
| |-- <Adafruit Unified Sensor> v1.0.2 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\Adafruit_Sensor)
|-- <ArduinoOTA> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ArduinoOTA)
| |-- <ESP8266mDNS> (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266mDNS)
| | |-- <ESP8266WiFi> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WiFi)
| |-- <ESP8266WiFi> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WiFi)
|-- <MechInputs> v0.0.1 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\MechInputs)
|-- <ESP8266mDNS> (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266mDNS)
| |-- <ESP8266WiFi> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WiFi)
|-- <NewPing> (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\NewPing)
|-- <Adafruit NeoPixel> v1.0.6 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\Adafruit_NeoPixel)
|-- <Json> v5.6.4 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\ArduinoJson)
|-- <Adafruit MPR121> v1.0.0 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\Adafruit_MPR121)
| |-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
|-- <SerialSensors> v0.0.1 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\SerialDevices)
| |-- <ESPeasySoftwareSerial> v3.3.1 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\ESPEasySoftwareSerial)
|-- <AS_BH1750> (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\AS_BH1750)
| |-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
|-- <AM2320> (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\AM2320)
| |-- <Wire> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire)
|-- <ESPeasySoftwareSerial> v3.3.1 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\ESPEasySoftwareSerial)
|-- <ESP8266WiFi> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WiFi)
|-- <SPI> v1.0 (C:\Users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\SPI)
|-- <HLW8012> v1.0.0 (F:\Users\donyo\Documents\GitHub\ESPEasy\lib\HLW8012_1.0.0_1281)
xtensa-lx106-elf-g++ -o .pioenvs\dev_ESP8266_4096\src\_P134_PPD42.ino.cpp.o -c -fno-rtti -fno-exceptions -std=c++11 -Os -mlongcalls -mtext-section-literals -falign-functions=4 -ffunction-sections -fdata-sections -DARDUINO=20300 -DLWIP_OPEN_SRC -DF_CPU=80000000L -D__ets__ -DICACHE_FLASH -DPLATFORMIO=30502 -DESP8266 -DARDUINO_ARCH_ESP8266 -DARDUINO_ESP8266_ESP12 -DBUILD_GIT=\"\" -DPLUGIN_BUILD_DEV -U__STRICT_ANSI__ -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\tools\sdk\include -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\tools\sdk\lwip\include -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\cores\esp8266 -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\variants\nodemcu -Isrc -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WiFi\src -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266WebServer\src -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266HTTPUpdateServer\src -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Wire -Ilib\SparkFun_APDS-9960_Sensor_Arduino_Library\src -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\SPI -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\SD\src -Ilib\HT16K33 -Ilib\LiquidCrystal_I2C -Ilib\pubsubclient\src -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\Servo\src -Ilib\IRremoteESP8266 -Ilib\Adafruit_Motor_Shield_V2 -Ilib\Adafruit_Motor_Shield_V2\utility
-Ilib\ESPEasy_ESP8266Ping\src -Ilib\Adafruit_Sensor -Ilib\Adafruit_TCS34725 -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\DNSServer\src -Ilib\esp8266-oled-ssd1306 -Ilib\Adafruit_TSL2591 -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ESP8266mDNS -IC:\users\donyo\.platformio\packages\framework-arduinoespressif8266\libraries\ArduinoOTA -Ilib\MechInputs -Ilib\NewPing -Ilib\Adafruit_NeoPixel -Ilib\ArduinoJson -Ilib\Adafruit_MPR121 -Ilib\ESPEasySoftwareSerial -Ilib\SerialDevices -Ilib\AS_BH1750 -Ilib\AM2320 -Ilib\HLW8012_1.0.0_1281\src src\_P134_PPD42.ino.cpp
xtensa-lx106-elf-ar rc .pioenvs\dev_ESP8266_4096\libb05\libSD.a .pioenvs\dev_ESP8266_4096\libb05\SD\File.cpp.o .pioenvs\dev_ESP8266_4096\libb05\SD\SD.cpp.o .pioenvs\dev_ESP8266_4096\libb05\SD\utility\Sd2Card.cpp.o .pioenvs\dev_ESP8266_4096\libb05\SD\utility\SdFile.cpp.o .pioenvs\dev_ESP8266_4096\libb05\SD\utility\SdVolume.cpp.o
....
....
....
*** [.pioenvs\dev_ESP8266_4096\src\_P134_PPD42.ino.cpp.o] Error 1
======================================= [ERROR] Took 21.29 seconds =======================================

================================================ [SUMMARY] ================================================
Environment esp32dev [SKIP]
Environment normal_ESP8266_1024 [SKIP]

Environment normal_ESP8285_1024 [SKIP]
Environment normal_WROOM02_2048 [SKIP]
Environment normal_ESP8266_4096 [SKIP]
Environment test_ESP8266_1024 [SKIP]
Environment test_ESP8285_1024 [SKIP]
Environment test_WROOM02_2048 [SKIP]
Environment test_ESP8266_4096 [SKIP]
Environment test_ESP8266_4096_VCC [SKIP]
Environment dev_ESP8266_1024 [SKIP]
Environment dev_ESP8285_1024 [SKIP]
Environment dev_WROOM02_2048 [SKIP]
Environment dev_ESP8266_4096 [ERROR]
Environment dev_ESP8266PUYA_1024 [SKIP]
Environment dev_ESP8266PUYA_1024_VCC [SKIP]
Environment hard_SONOFF_POW [SKIP]
======================================= [ERROR] Took 21.31 seconds =======================================

TD-er
Core team member
Posts: 8739
Joined: 01 Sep 2017, 22:13
Location: the Netherlands
Contact:

Re: pre-processing of plugin ino file screwing up the build process

#2 Post by TD-er » 31 May 2018, 20:23

Not the cause of your problems, but there is at least this error in the linked _P134_PPD42.ino file:

In byte P134_getCountryType(struct EventStruct *event), you're missing a break at the end.

You're also implementing a function loop().
Maybe try to prefix these functions with "P134_"

That may cause these strange build issues.

dony71
Normal user
Posts: 16
Joined: 25 Apr 2018, 20:01

Re: pre-processing of plugin ino file screwing up the build process

#3 Post by dony71 » 31 May 2018, 21:19

Thanks for letting me know
I clean up the code but still platformio converting _P134_PPD42.ino to _P134_PPD42.ino.cpp
Puzzling.....

Update code :
http://www.mediafire.com/file/gqqq4huw4 ... 2.ino/file

Post Reply

Who is online

Users browsing this forum: No registered users and 54 guests