From d2c6164c71582ef11ca8097f13cc96f7dbf3a43e Mon Sep 17 00:00:00 2001 From: Andrew Featherstone Date: Sat, 31 Aug 2024 21:34:24 +0100 Subject: [PATCH] samples: rpi_pico2: Add ADC-related samples for rpi_pico2 The Raspberry Pi Pico 2's device is compatible with the existing Pico 1. The build system requires a `.overlay` file, but these use the pre-processing to #include the sibling rpi_pico.overlay files rather than duplicating the contents as an attempt to keep things DRY. Tested locally. Signed-off-by: Andrew Featherstone --- .../adc/adc_dt/boards/rpi_pico2_rp2350a_m33.overlay | 8 ++++++++ .../die_temp_polling/boards/rpi_pico2_rp2350a_m33.overlay | 8 ++++++++ 2 files changed, 16 insertions(+) create mode 100644 samples/drivers/adc/adc_dt/boards/rpi_pico2_rp2350a_m33.overlay create mode 100644 samples/sensor/die_temp_polling/boards/rpi_pico2_rp2350a_m33.overlay diff --git a/samples/drivers/adc/adc_dt/boards/rpi_pico2_rp2350a_m33.overlay b/samples/drivers/adc/adc_dt/boards/rpi_pico2_rp2350a_m33.overlay new file mode 100644 index 00000000000..8b83efe6ea0 --- /dev/null +++ b/samples/drivers/adc/adc_dt/boards/rpi_pico2_rp2350a_m33.overlay @@ -0,0 +1,8 @@ +/* + * SPDX-License-Identifier: Apache-2.0 + * + * Copyright (c) 2024 Andrew Featherstone + */ + +/* Pico 2 is compatible with the Pico 1, so reuse. */ +#include "rpi_pico.overlay" diff --git a/samples/sensor/die_temp_polling/boards/rpi_pico2_rp2350a_m33.overlay b/samples/sensor/die_temp_polling/boards/rpi_pico2_rp2350a_m33.overlay new file mode 100644 index 00000000000..0c8a120437b --- /dev/null +++ b/samples/sensor/die_temp_polling/boards/rpi_pico2_rp2350a_m33.overlay @@ -0,0 +1,8 @@ +/* + * SPDX-License-Identifier: Apache-2.0 + * + * Copyright (c) 2024 Andrew Featherstone + */ + +/* Pico 2 is compatible with the Pico 1, so reuse. */ +#include "rpi_pico.overlay"