Skip to content

Commit

Permalink
Merge pull request #601 from manuelbl/pio-5-workaround
Browse files Browse the repository at this point in the history
Workaround for bug in PlatformIO Core 5.0
  • Loading branch information
terrillmoore authored Sep 3, 2020
2 parents 500bc56 + 914d1d5 commit 89c28c5
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions ci/platformio.sh
Original file line number Diff line number Diff line change
Expand Up @@ -90,12 +90,12 @@ then
PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4 -D CFG_us915 -D CFG_sx1276_radio -D LMIC_DEBUG_LEVEL=1 -D LMIC_PRINTF_TO=Serial -D COMPILE_REGRESSION_TEST -D ARDUINO_LMIC_PROJECT_CONFIG_H_SUPPRESS' platformio ci --lib . --board heltec_wifi_lora_32 'examples/ttn-otaa-feather-us915/ttn-otaa-feather-us915.ino'

# Compile "ttn-otaa-feather-us915-dht22" example in all relevant regions
PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4 -D CFG_us915 -D CFG_sx1276_radio -D COMPILE_REGRESSION_TEST -D ARDUINO_LMIC_PROJECT_CONFIG_H_SUPPRESS' platformio ci --project-option="lib_deps=DHT sensor library, Wire" --lib . --board heltec_wifi_lora_32 'examples/ttn-otaa-feather-us915-dht22/ttn-otaa-feather-us915-dht22.ino'
PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4 -D CFG_au915 -D CFG_sx1276_radio -D COMPILE_REGRESSION_TEST -D ARDUINO_LMIC_PROJECT_CONFIG_H_SUPPRESS' platformio ci --project-option="lib_deps=DHT sensor library, Wire" --lib . --board heltec_wifi_lora_32 'examples/ttn-otaa-feather-us915-dht22/ttn-otaa-feather-us915-dht22.ino'
PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4 -D CFG_us915 -D CFG_sx1276_radio -D COMPILE_REGRESSION_TEST -D ARDUINO_LMIC_PROJECT_CONFIG_H_SUPPRESS' platformio ci --project-option="lib_deps=DHT sensor library, Adafruit Unified Sensor, Wire" --lib . --board heltec_wifi_lora_32 'examples/ttn-otaa-feather-us915-dht22/ttn-otaa-feather-us915-dht22.ino'
PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4 -D CFG_au915 -D CFG_sx1276_radio -D COMPILE_REGRESSION_TEST -D ARDUINO_LMIC_PROJECT_CONFIG_H_SUPPRESS' platformio ci --project-option="lib_deps=DHT sensor library, Adafruit Unified Sensor, Wire" --lib . --board heltec_wifi_lora_32 'examples/ttn-otaa-feather-us915-dht22/ttn-otaa-feather-us915-dht22.ino'

# Compile "ttn-abp-feather-us915-dht22" example in all relevant regions with sx1276
PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4 -D CFG_us915 -D CFG_sx1276_radio -D COMPILE_REGRESSION_TEST -D ARDUINO_LMIC_PROJECT_CONFIG_H_SUPPRESS' platformio ci --project-option="lib_deps=DHT sensor library, Wire" --lib . --board heltec_wifi_lora_32 'examples/ttn-abp-feather-us915-dht22/ttn-abp-feather-us915-dht22.ino'
PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4 -D CFG_au915 -D CFG_sx1276_radio -D COMPILE_REGRESSION_TEST -D ARDUINO_LMIC_PROJECT_CONFIG_H_SUPPRESS' platformio ci --project-option="lib_deps=DHT sensor library, Wire" --lib . --board heltec_wifi_lora_32 'examples/ttn-abp-feather-us915-dht22/ttn-abp-feather-us915-dht22.ino'
PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4 -D CFG_us915 -D CFG_sx1276_radio -D COMPILE_REGRESSION_TEST -D ARDUINO_LMIC_PROJECT_CONFIG_H_SUPPRESS' platformio ci --project-option="lib_deps=DHT sensor library, Adafruit Unified Sensor, Wire" --lib . --board heltec_wifi_lora_32 'examples/ttn-abp-feather-us915-dht22/ttn-abp-feather-us915-dht22.ino'
PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4 -D CFG_au915 -D CFG_sx1276_radio -D COMPILE_REGRESSION_TEST -D ARDUINO_LMIC_PROJECT_CONFIG_H_SUPPRESS' platformio ci --project-option="lib_deps=DHT sensor library, Adafruit Unified Sensor, Wire" --lib . --board heltec_wifi_lora_32 'examples/ttn-abp-feather-us915-dht22/ttn-abp-feather-us915-dht22.ino'

# COMMENTED BECAUSE build fails with
# src/raw-feather.ino:119:22: error: 'class HardwareSerial' has no member named 'dtr'
Expand All @@ -110,8 +110,8 @@ then
if [ "$(PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4' platformio ci --lib . --board heltec_wifi_lora_32 'examples/ttn-otaa-feather-us915/ttn-otaa-feather-us915.ino' 1>&2; echo $?)" -eq 0 ]; then echo "ERROR: Compilation did not fail!"; exit 1; fi
if [ "$( platformio ci --lib . --board heltec_wifi_lora_32 'examples/ttn-otaa/ttn-otaa.ino' 1>&2; echo $?)" -eq 0 ]; then echo "ERROR: Compilation did not fail!"; exit 1; fi
if [ "$( platformio ci --lib . --board heltec_wifi_lora_32 'examples/ttn-abp/ttn-abp.ino' 1>&2; echo $?)" -eq 0 ]; then echo "ERROR: Compilation did not fail!"; exit 1; fi
if [ "$(PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4' platformio ci --lib . --board heltec_wifi_lora_32 --project-option="lib_deps=DHT sensor library, Wire" 'examples/ttn-otaa-feather-us915-dht22/ttn-otaa-feather-us915-dht22.ino' 1>&2; echo $?)" -eq 0 ]; then echo "ERROR: Compilation did not fail!"; exit 1; fi
if [ "$(PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4' platformio ci --lib . --board heltec_wifi_lora_32 --project-option="lib_deps=DHT sensor library, Wire" 'examples/ttn-abp-feather-us915-dht22/ttn-abp-feather-us915-dht22.ino' 1>&2; echo $?)" -eq 0 ]; then echo "ERROR: Compilation did not fail!"; exit 1; fi
if [ "$(PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4' platformio ci --lib . --board heltec_wifi_lora_32 --project-option="lib_deps=DHT sensor library, Adafruit Unified Sensor, Wire" 'examples/ttn-otaa-feather-us915-dht22/ttn-otaa-feather-us915-dht22.ino' 1>&2; echo $?)" -eq 0 ]; then echo "ERROR: Compilation did not fail!"; exit 1; fi
if [ "$(PLATFORMIO_BUILD_FLAGS='-D ARDUINO_AVR_FEATHER32U4' platformio ci --lib . --board heltec_wifi_lora_32 --project-option="lib_deps=DHT sensor library, Adafruit Unified Sensor, Wire" 'examples/ttn-abp-feather-us915-dht22/ttn-abp-feather-us915-dht22.ino' 1>&2; echo $?)" -eq 0 ]; then echo "ERROR: Compilation did not fail!"; exit 1; fi

# Expect failure when compiling for more than one radio
if [ "$(PLATFORMIO_BUILD_FLAGS='-D CFG_sx1272_radio -D CFG_sx1276_radio' platformio ci --lib . --board heltec_wifi_lora_32 'examples/ttn-otaa/ttn-otaa.ino' 1>&2; echo $?)" -eq 0 ]; then echo "ERROR: Compilation did not fail!"; exit 1; fi
Expand Down

0 comments on commit 89c28c5

Please sign in to comment.