Skip to content

Add ESP32 board to "Compile Examples" CI workflow #49

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jan 13, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 17 additions & 3 deletions .github/workflows/compile-examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ jobs:
LIBRARIES: Arduino_DebugUtils WiFi101 WiFiNINA MKRGSM MKRNB MKRWAN
ARDUINOCORE_MBED_STAGING_PATH: extras/ArduinoCore-mbed
ARDUINOCORE_API_STAGING_PATH: extras/ArduinoCore-API
SKETCHES_REPORTS_PATH: sketches-reports
strategy:
matrix:
board:
Expand All @@ -43,6 +44,8 @@ jobs:
platform-name: arduino:mbed
- fqbn: "esp8266:esp8266:huzzah"
platform-name: esp8266:esp8266
- fqbn: "esp32:esp32:esp32"
platform-name: esp32:esp32

# Make board type-specific customizations to the matrix jobs
include:
Expand All @@ -65,6 +68,12 @@ jobs:
# Install ESP8266 platform via Boards Manager
- name: esp8266:esp8266
source-url: https://arduino.esp8266.com/stable/package_esp8266com_index.json
- board:
platform-name: esp32:esp32
platforms: |
# Install ESP32 platform via Boards Manager
- name: esp32:esp32
source-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json

steps:
- uses: actions/checkout@v1
Expand Down Expand Up @@ -95,18 +104,23 @@ jobs:
run: |
mv "${{ env.ARDUINOCORE_API_STAGING_PATH }}/api" "${{ env.ARDUINOCORE_MBED_STAGING_PATH }}/cores/arduino"

- name: Install ESP32 platform dependencies
if: matrix.board.platform-name == 'esp32:esp32'
run: pip3 install pyserial

- name: Compile examples
uses: arduino/actions/libraries/compile-examples@master
uses: arduino/compile-sketches@main
with:
platforms: ${{ matrix.platforms }}
fqbn: ${{ matrix.board.fqbn }}
libraries: ${{ env.LIBRARIES }}
size-report-sketch: 'ConnectionHandlerDemo'
enable-size-deltas-report: 'true'
sketches-report-path: ${{ env.SKETCHES_REPORTS_PATH }}

- name: Save memory usage change report as artifact
if: github.event_name == 'pull_request'
uses: actions/upload-artifact@v1
with:
name: 'size-deltas-reports'
path: 'size-deltas-reports'
name: ${{ env.SKETCHES_REPORTS_PATH }}
path: ${{ env.SKETCHES_REPORTS_PATH }}
2 changes: 1 addition & 1 deletion src/Arduino_ConnectionHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@

ConnectionHandler::ConnectionHandler(bool const keep_alive)
: _keep_alive{keep_alive}
, _current_net_connection_state{NetworkConnectionState::INIT}
, _lastConnectionTickTime{millis()}
, _current_net_connection_state{NetworkConnectionState::INIT}
{

}
Expand Down