a few small tweaks #477
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Compile Examples | |
on: | |
pull_request: | |
paths: | |
- ".github/workflows/compile-examples.yml" | |
- "megaavr/libraries/**" | |
- "megaavr/cores/**" | |
- "megaavr/variants/**" | |
- "megaavr/*.txt" | |
push: | |
paths: | |
- ".github/workflows/compile-examples.yml" | |
- "megaavr/libraries/**" | |
- "megaavr/cores/**" | |
- "megaavr/variants/**" | |
- "megaavr/*.txt" | |
# workflow_dispatch event allows the workflow to be triggered manually | |
# See: https://docs.github.com/en/actions/reference/events-that-trigger-workflows#workflow_dispatch | |
workflow_dispatch: | |
# repository_dispatch event allows the workflow to be triggered via the GitHub API | |
# See: https://docs.github.com/en/actions/reference/events-that-trigger-workflows#repository_dispatch | |
repository_dispatch: | |
jobs: | |
compile-examples: | |
runs-on: ubuntu-latest | |
env: | |
platform-name: DxCore:megaavr | |
all-parts-sketch-paths: | | |
- megaavr/libraries/Comparator/examples/Hysteresis | |
- megaavr/libraries/Comparator/examples/Internal_reference | |
- megaavr/libraries/Comparator/examples/Interrupt | |
- megaavr/libraries/Comparator/examples/Simple_comparator | |
- megaavr/libraries/DxCore/examples/EnhancedIODemo | |
- megaavr/libraries/DxCore/examples/ModernRevSer | |
- megaavr/libraries/DxCore/examples/SAMPLENdemo | |
- megaavr/libraries/EEPROM/examples/eeprom_clear | |
- megaavr/libraries/EEPROM/examples/eeprom_crc | |
- megaavr/libraries/EEPROM/examples/eeprom_get | |
- megaavr/libraries/EEPROM/examples/eeprom_iteration | |
- megaavr/libraries/EEPROM/examples/eeprom_put | |
- megaavr/libraries/EEPROM/examples/eeprom_read | |
- megaavr/libraries/EEPROM/examples/eeprom_update | |
- megaavr/libraries/EEPROM/examples/eeprom_write | |
- megaavr/libraries/Logic/examples/Five_input_NOR | |
- megaavr/libraries/Logic/examples/Interrupt | |
- megaavr/libraries/Logic/examples/LatchNoSeq | |
- megaavr/libraries/Logic/examples/Three_input_AND | |
- megaavr/libraries/Logic/examples/Three_input_NAND | |
- megaavr/libraries/Logic/examples/Three_input_OR | |
- megaavr/libraries/Logic/examples/Modulate | |
- megaavr/libraries/Logic/examples/Oscillate | |
- megaavr/libraries/Logic/examples/Two_input_AND | |
- megaavr/libraries/Logic/examples/Two_input_NAND | |
- megaavr/libraries/Logic/examples/Two_input_OR | |
- megaavr/libraries/Servo/examples/Knob | |
- megaavr/libraries/Servo/examples/ServoMaxTest | |
- megaavr/libraries/Servo/examples/Sweep | |
- megaavr/libraries/Servo_DxCore/examples/Knob | |
- megaavr/libraries/Servo_DxCore/examples/ServoMaxTest | |
- megaavr/libraries/Servo_DxCore/examples/Sweep | |
- megaavr/libraries/SoftwareSerial/examples/SoftwareSerialExample | |
- megaavr/libraries/SoftwareSerial/examples/TwoPortReceive | |
- megaavr/libraries/SPI/examples/BarometricPressureSensor | |
- megaavr/libraries/SPI/examples/DigitalPotControl | |
- megaavr/libraries/tinyNeoPixel/examples/buttoncycler | |
- megaavr/libraries/tinyNeoPixel/examples/simple | |
- megaavr/libraries/tinyNeoPixel/examples/strandtest | |
- megaavr/libraries/tinyNeoPixel_Static/examples/buttoncycler | |
- megaavr/libraries/tinyNeoPixel_Static/examples/simple | |
- megaavr/libraries/tinyNeoPixel_Static/examples/strandtest | |
- megaavr/libraries/Wire/examples/digital_potentiometer | |
- megaavr/libraries/Wire/examples/master_read | |
- megaavr/libraries/Wire/examples/master_write | |
- megaavr/libraries/Wire/examples/pinswap_via_pins | |
- megaavr/libraries/Wire/examples/pinswap_via_swap | |
- megaavr/libraries/Wire/examples/SFRRanger_reader | |
- megaavr/libraries/Wire/examples/slave_read | |
- megaavr/libraries/Wire/examples/slave_write | |
- megaavr/libraries/Wire/examples/slave_secondary_address | |
- megaavr/libraries/Wire/examples/slave_address_mask | |
- megaavr/libraries/Wire/examples/master_multi_address_write | |
- megaavr/extras/ci/test-sketch/all/math_macros | |
- megaavr/extras/ci/test-sketch/all/test_analog | |
- megaavr/extras/ci/test-sketch/all/test_digital | |
- megaavr/extras/ci/test-sketch/all/test_tone | |
- megaavr/extras/ci/test-sketch/all/test_PWM | |
- megaavr/extras/ci/test-sketch/all/test_timekeeping | |
avr-da-series-sketch-paths: | | |
- megaavr/extras/ci/test-sketch/da/dummysketch | |
- megaavr/libraries/ZCD/examples/Interrupt | |
- megaavr/libraries/ZCD/examples/Read_state | |
- megaavr/libraries/ZCD/examples/Simple_ZCD | |
avr-db-series-sketch-paths: | | |
- megaavr/libraries/Opamp/examples/Inverting_amplifier | |
- megaavr/libraries/Opamp/examples/Inverting_amplifier_with_follower | |
- megaavr/libraries/Opamp/examples/Non_inverting_amplifier | |
- megaavr/libraries/Opamp/examples/Voltage_follower | |
- megaavr/libraries/ZCD/examples/Interrupt | |
- megaavr/libraries/ZCD/examples/Read_state | |
- megaavr/libraries/ZCD/examples/Simple_ZCD | |
- megaavr/extras/ci/test-sketch/db/dummysketch | |
#avr-dd-series-sketch-paths: | | |
#avr-ea-series-sketch-paths: | | |
optiboot-and-appspm-sketch-paths: | | |
- megaavr/libraries/Flash/examples/FlashDemo | |
not-on-tca0-millis-lowpin-false-sketch-paths: | | |
- megaavr/libraries/DxCore/examples/TCA0Demo | |
- megaavr/libraries/DxCore/examples/TCA0Demo2 | |
- megaavr/libraries/DxCore/examples/TCA0Demo3 | |
- megaavr/libraries/DxCore/examples/TCA0Demo4 | |
not-disabled-millis-sketch-paths: | | |
- megaavr/libraries/tinyNeoPixel/examples/RGBWstrandtest | |
- megaavr/libraries/Wire/examples/register_model | |
- megaavr/libraries/Wire/examples/register_model_master | |
#internal-osc-sketch-paths: | | |
both-twi-enabled-sketch-paths: | | |
- megaavr/libraries/Wire/examples/two_master_write | |
strategy: | |
fail-fast: false | |
matrix: | |
flash-class: | |
- 128 | |
- 64 | |
- 32 | |
- 16 | |
- 8 | |
device-family: | |
- da | |
- db | |
- dd | |
- ea | |
pincount: | |
- 64 | |
- 48 | |
- 32 | |
- 28 | |
- 20 | |
- 14 | |
clocksource: | |
- internal | |
- extclock | |
- crystal | |
# Filter out these matrix combinations | |
exclude: | |
- device-family: da | |
clocksource: crystal | |
- device-family: da | |
flash-class: 32 | |
pincount: 64 | |
- device-family: da | |
flash-class: 16 | |
- device-family: da | |
flash-class: 8 | |
- device-family: da | |
pincount: 20 | |
- device-family: da | |
pincount: 14 | |
- device-family: da | |
flash-class: 32 | |
pincount: 64 | |
- device-family: da | |
flash-class: 16 | |
- device-family: da | |
flash-class: 8 | |
- device-family: da | |
pincount: 20 | |
- device-family: da | |
pincount: 14 | |
- device-family: db | |
flash-class: 32 | |
pincount: 64 | |
- device-family: db | |
flash-class: 16 | |
- device-family: db | |
flash-class: 8 | |
- device-family: db | |
pincount: 20 | |
- device-family: db | |
pincount: 14 | |
- device-family: db | |
flash-class: 32 | |
pincount: 64 | |
- device-family: db | |
flash-class: 16 | |
- device-family: db | |
flash-class: 8 | |
- device-family: db | |
pincount: 20 | |
- device-family: db | |
pincount: 14 | |
- device-family: dd | |
flash-class: 128 | |
- device-family: dd | |
flash-class: 8 | |
- device-family: dd | |
pincount: 64 | |
- device-family: dd | |
pincount: 48 | |
- device-family: ea | |
flash-class: 128 | |
- device-family: ea | |
pincount: 64 | |
- device-family: ea | |
pincount: 20 | |
- device-family: ea | |
pincount: 14 | |
- device-family: ea | |
flash-class: 8 | |
- device-family: ea | |
flash-class: 16 | |
- device-family: ea | |
flash-class: 32 | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
# See: https://github.com/arduino/compile-sketches/README.md | |
- name: Compile examples (24 MHz, nothing weird) | |
uses: arduino/compile-sketches@main | |
with: | |
fqbn: ${{ env.platform-name }}:avr${{ matrix.device-family }}:chip=avr${{ matrix.flash-class }}${{ matrix.device-family }}${{ matrix.pincount }},clock=24${{ matrix.clocksource }},wiremode=mands | |
sketch-paths: | | |
# It's necessary to jump through some hoops to dynamically generate the env object keys to define the non-universal sketch paths | |
# https://docs.github.com/en/free-pro-team@latest/actions/reference/context-and-expression-syntax-for-github-actions#format | |
${{ env.all-parts-sketch-paths }} | |
${{ env[format('avr-{0}-series-sketch-paths', matrix.device-family)] }} | |
${{ env[format('not-on-tca0-millis-lowpin-{0}-sketch-paths', matrix.pincount < 28)] }} | |
${{ env.not-disabled-millis-sketch-paths}} | |
platforms: | | |
# Install DxCore via Boards Manager for the toolchain | |
- source-url: http://drazzy.com/package_drazzy.com_index.json | |
name: ${{ env.platform-name }} | |
# Overwrite the DxCore release version with the platform from the local path | |
- source-path: megaavr | |
name: ${{ env.platform-name }} | |
libraries: | | |
# The sketches don't have any external library dependencies, so just define an empty array | |
- | |
verbose: false | |
enable-deltas-report: true | |
enable-warnings-report: true | |
sketches-report-path: sketches-reports | |
- name: Compile examples (8 MHz, optiboot, tca0 millis, full printf, and manual attachInterrupt) | |
uses: arduino/compile-sketches@main | |
with: | |
fqbn: ${{ env.platform-name }}:avr${{ matrix.device-family }}opti:chip=avr${{ matrix.flash-class }}${{ matrix.device-family }}${{ matrix.pincount }},clock=8${{ matrix.clocksource }},millis=tca0,printf=full,attach=manual,wiremode=mands | |
sketch-paths: | | |
# It's necessary to jump through some hoops to dynamically generate the env object keys to define the non-universal sketch paths | |
# https://docs.github.com/en/free-pro-team@latest/actions/reference/context-and-expression-syntax-for-github-actions#format | |
${{ env.all-parts-sketch-paths }} | |
${{ env[format('avr-{0}-series-sketch-paths', matrix.device-family)] }} | |
${{ env.optiboot-and-appspm-sketch-paths }} | |
${{ env.not-disabled-millis-sketch-paths}} | |
platforms: | | |
# Install DxCore via Boards Manager for the toolchain | |
- source-url: http://drazzy.com/package_drazzy.com_index.json | |
name: ${{ env.platform-name }} | |
# Overwrite the DxCore release version with the platform from the local path | |
- source-path: megaavr | |
name: ${{ env.platform-name }} | |
libraries: | | |
# The sketches don't have any external library dependencies, so just define an empty array | |
- | |
verbose: false | |
enable-deltas-report: true | |
enable-warnings-report: true | |
sketches-report-path: sketches-reports | |
- name: Compile examples (32 MHz, tcb1 millis, minimal printf, old attachInterrupt, full appspm) | |
uses: arduino/compile-sketches@main | |
with: | |
fqbn: ${{ env.platform-name }}:avr${{ matrix.device-family }}:chip=avr${{ matrix.flash-class }}${{ matrix.device-family }}${{ matrix.pincount }},clock=32${{ matrix.clocksource }},millis=tcb1,printf=minimal,wiremode=mors,attach=oldversion,appspm=full | |
sketch-paths: | | |
# It's necessary to jump through some hoops to dynamically generate the env object keys to define the non-universal sketch paths | |
# https://docs.github.com/en/free-pro-team@latest/actions/reference/context-and-expression-syntax-for-github-actions#format | |
${{ env.all-parts-sketch-paths }} | |
${{ env[format('avr-{0}-series-sketch-paths', matrix.device-family)] }} | |
${{ env.optiboot-and-appspm-sketch-paths }} | |
${{ env[format('not-on-tca0-millis-lowpin-{0}-sketch-paths', matrix.pincount < 28)] }} | |
${{ env.not-disabled-millis-sketch-paths}} | |
platforms: | | |
# Install DxCore via Boards Manager for the toolchain | |
- source-url: http://drazzy.com/package_drazzy.com_index.json | |
name: ${{ env.platform-name }} | |
# Overwrite the DxCore release version with the platform from the local path | |
- source-path: megaavr | |
name: ${{ env.platform-name }} | |
libraries: | | |
# The sketches don't have any external library dependencies, so just define an empty array | |
- | |
verbose: false | |
enable-deltas-report: true | |
enable-warnings-report: true | |
sketches-report-path: sketches-reports | |
- name: Compile examples (20 MHz, disable millis, sized appspm) | |
uses: arduino/compile-sketches@main | |
with: | |
fqbn: ${{ env.platform-name }}:avr${{ matrix.device-family }}:chip=avr${{ matrix.flash-class }}${{ matrix.device-family }}${{ matrix.pincount }},clock=20${{ matrix.clocksource }},millis=disabled,appspm=24plus,wiremode=mors | |
sketch-paths: | | |
# It's necessary to jump through some hoops to dynamically generate the env object keys to define the non-universal sketch paths | |
# https://docs.github.com/en/free-pro-team@latest/actions/reference/context-and-expression-syntax-for-github-actions#format | |
${{ env.all-parts-sketch-paths }} | |
${{ env[format('avr-{0}-series-sketch-paths', matrix.device-family)] }} | |
${{ env.optiboot-and-appspm-sketch-paths }} | |
${{ env[format('not-on-tca0-millis-lowpin-{0}-sketch-paths', matrix.pincount < 28)] }} | |
platforms: | | |
# Install DxCore via Boards Manager for the toolchain | |
- source-url: http://drazzy.com/package_drazzy.com_index.json | |
name: ${{ env.platform-name }} | |
# Overwrite the DxCore release version with the platform from the local path | |
- source-path: megaavr | |
name: ${{ env.platform-name }} | |
libraries: | | |
# The sketches don't have any external library dependencies, so just define an empty array | |
- | |
verbose: false | |
enable-deltas-report: true | |
enable-warnings-report: true | |
sketches-report-path: sketches-reports |