Skip to content

variants: Add support for Arduino Uno Q#198

Open
soburi wants to merge 3 commits into
zephyrproject-rtos:nextfrom
soburi:unoq
Open

variants: Add support for Arduino Uno Q#198
soburi wants to merge 3 commits into
zephyrproject-rtos:nextfrom
soburi:unoq

Conversation

@soburi

@soburi soburi commented Jul 4, 2026

Copy link
Copy Markdown
Member

Add configuration files for Arduino Uno Q.

We have confirmed that these compiles when used in combination with
https://github.com/arduino/zephyr/tree/zephyr-arduino-v4.2.0.
We will incorporate the changes for the migration to version 4.4 separately in the near future.
arduino#522 (comment)

I verified this on the Arduino Uno Q.

Copilot AI review requested due to automatic review settings July 4, 2026 02:51

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a new arduino_uno_q_stm32u585xx variant to ArduinoCore-zephyr, providing the Zephyr overlay/Kconfig and variant glue needed to build sketches for the Arduino Uno Q (STM32U585), plus a small SPI header tweak to avoid macro/name collisions when multiple SPI instances are present.

Changes:

  • Added a full Uno Q variant directory (overlay, Kconfig .conf, flashing cfgs, example skip lists, RouterBridge handling).
  • Added an Uno Q-specific analogReference() override.
  • Updated libraries/SPI/SPI.h to #undef SPI1..SPI8 before declaring SPI1, SPI2, etc.

Reviewed changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
variants/arduino_uno_q_stm32u585xx/variant.h Defines board-specific pins/macros and RouterBridge Serial support flags
variants/arduino_uno_q_stm32u585xx/postvariant.h Forces RouterBridge header discovery during library discovery phase
variants/arduino_uno_q_stm32u585xx/analogReference.cpp Overrides weak core analogReference() for Uno Q
variants/arduino_uno_q_stm32u585xx/arduino_uno_q_stm32u585xx.overlay Zephyr devicetree overlay defining peripherals, pins, PWM/ADC mappings
variants/arduino_uno_q_stm32u585xx/arduino_uno_q_stm32u585xx.conf Variant-specific Zephyr Kconfig settings
variants/arduino_uno_q_stm32u585xx/flash_sketch.cfg OpenOCD script to flash user sketch region
variants/arduino_uno_q_stm32u585xx/flash_bootloader.cfg OpenOCD script to flash bootloader
variants/arduino_uno_q_stm32u585xx/scripts/set-to-ram-mode.sh Helper script to put the board into RAM upload mode
variants/arduino_uno_q_stm32u585xx/skip_these_examples.txt CI/core example exclusions for this variant
variants/arduino_uno_q_stm32u585xx/known_example_issues.txt Placeholder for known failing examples (regex-based)
libraries/SPI/SPI.h Avoids macro collisions for SPI1..SPI8 declarations

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread variants/arduino_uno_q_stm32u585xx/variant.h
Comment thread variants/arduino_uno_q_stm32u585xx/scripts/set-to-ram-mode.sh Outdated
Comment thread variants/arduino_uno_q_stm32u585xx/scripts/set-to-ram-mode.sh Outdated
Comment thread libraries/SPI/SPI.h
#include <zephyr/drivers/spi.h>

#undef SPI
#undef SPI1

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we guard these with ifdefs? This will cause some unexpected issues if not guarded later on

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for a lot of reviews!

Fixed it.

soburi and others added 3 commits July 24, 2026 22:13
Since SPI<n> might be defined externally, we undefine it to
avoid conflicts.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Allows compatibility with a broad set of libraries, like Adafruit's NeoPixel

Note: Cherry-picked only under variants/common/.

Co-authored-by: Martino Facchin <m.facchin@arduino.cc>
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Add configuration files for Arduino Uno Q.

We have confirmed that it compiles when used in combination with
https://github.com/arduino/zephyr/tree/zephyr-arduino-v4.2.0.

Co-authored-by: Daniele Cloralio <d.cloralio@arduino.cc>
Co-authored-by: Giovanni Bruno <g.bruno@arduino.cc>
Co-authored-by: JoanVC <github-91yu@joanvc.cat>
Co-authored-by: Kurt Eckhardt <kurte@rockisland.com>
Co-authored-by: Luca Burelli <l.burelli@arduino.cc>
Co-authored-by: Martino Facchin <m.facchin@arduino.cc>
Co-authored-by: Mattia Pennasilico <m.pennasilico@arduino.cc>
Co-authored-by: Sebastian Romero <s.romero@arduino.cc>
Co-authored-by: Shin Taeha <mirinae3145@g.skku.edu>
Co-authored-by: lucarin91 <lucarin@protonmail.com>
Co-authored-by: maidnl <d.aimo@arduino.cc>
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants