From d1f7c182402ecc1a2e6a1eba95115d19e9d539aa Mon Sep 17 00:00:00 2001 From: jgromes Date: Tue, 27 Jun 2023 07:28:57 +0200 Subject: [PATCH] Added support for Arduino Uno R4 --- .github/workflows/main.yml | 1 + README.md | 1 + src/BuildOpt.h | 7 +++++++ 3 files changed, 9 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c75cdc6c..4bcb17b1 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -105,6 +105,7 @@ jobs: run: echo "index-url=--additional-urls https://mcudude.github.io/MegaCore/package_MCUdude_MegaCore_index.json" >> $GITHUB_OUTPUT - id: teensy:avr:teensy41 run: echo "index-url=--additional-urls https://www.pjrc.com/teensy/td_156/package_teensy_index.json" >> $GITHUB_OUTPUT + - id: arduino:renesas_uno:minima runs-on: ubuntu-latest name: ${{ matrix.id }} diff --git a/README.md b/README.md index 36228634..ede24434 100644 --- a/README.md +++ b/README.md @@ -50,6 +50,7 @@ SX127x, RFM9x, RF69, SX1231, CC1101, nRF24L01, RFM2x and Si443x * [__megaAVR__](https://github.com/arduino/ArduinoCore-megaavr) - Arduino Uno WiFi Rev.2 and Nano Every * [__SAM__](https://github.com/arduino/ArduinoCore-sam) - Arduino Due * [__SAMD__](https://github.com/arduino/ArduinoCore-samd) - Arduino Zero, MKR boards, M0 Pro etc. + * [__Renesas__](https://github.com/arduino/ArduinoCore-renesas) - Arduino Uno R4 * __Adafruit__ * [__SAMD__](https://github.com/adafruit/ArduinoCore-samd) - Adafruit Feather M0 and M4 boards (Feather, Metro, Gemma, Trinket etc.) diff --git a/src/BuildOpt.h b/src/BuildOpt.h index d0572f69..53d104d0 100644 --- a/src/BuildOpt.h +++ b/src/BuildOpt.h @@ -242,6 +242,13 @@ // Teensy #define RADIOLIB_PLATFORM "Teensy" +#elif defined(ARDUINO_ARCH_RENESAS) + // Arduino Renesas (UNO R4) + #define RADIOLIB_PLATFORM "Arduino Renesas (UNO R4)" + #define RADIOLIB_ARDUINOHAL_PIN_MODE_CAST (PinMode) + #define RADIOLIB_ARDUINOHAL_PIN_STATUS_CAST (PinStatus) + #define RADIOLIB_ARDUINOHAL_INTERRUPT_MODE_CAST (PinStatus) + #else // other Arduino platforms not covered by the above list - this may or may not work #define RADIOLIB_PLATFORM "Unknown Arduino"