diff --git a/.github/workflows/action.yml b/.github/workflows/action.yml index 2af404fba5a60a4b3a91c8462680decc90d2a40b..af88f765a9b5a987fc400ee1b980c5ad439aa65a 100644 --- a/.github/workflows/action.yml +++ b/.github/workflows/action.yml @@ -130,6 +130,7 @@ jobs: - {RTT_BSP: "at32/at32f403a-start", RTT_TOOL_CHAIN: "sourcery-arm"} - {RTT_BSP: "at32/at32f407-start", RTT_TOOL_CHAIN: "sourcery-arm"} - {RTT_BSP: "smartfusion2", RTT_TOOL_CHAIN: "sourcery-arm"} + - {RTT_BSP: "raspberry-pico", RTT_TOOL_CHAIN: "sourcery-arm"} steps: - uses: actions/checkout@v2 - name: Set up Python diff --git a/bsp/raspberry-pico/.config b/bsp/raspberry-pico/.config index 200215d311aa0139d031f831f03edfd247453053..043db406f4953aeb3ddf161923da78bfb7e6d6db 100644 --- a/bsp/raspberry-pico/.config +++ b/bsp/raspberry-pico/.config @@ -123,7 +123,7 @@ CONFIG_RT_SERIAL_RB_BUFSZ=64 # CONFIG_RT_USING_CPUTIME is not set # CONFIG_RT_USING_I2C is not set # CONFIG_RT_USING_PHY is not set -# CONFIG_RT_USING_PIN is not set +CONFIG_RT_USING_PIN=y # CONFIG_RT_USING_ADC is not set # CONFIG_RT_USING_DAC is not set # CONFIG_RT_USING_PWM is not set @@ -274,7 +274,6 @@ CONFIG_RT_LIBC_USING_TIME=y # CONFIG_PKG_USING_PDULIB is not set # CONFIG_PKG_USING_BTSTACK is not set # CONFIG_PKG_USING_LORAWAN_ED_STACK is not set -# CONFIG_PKG_USING_WAYZ_IOTKIT is not set # # security packages @@ -314,8 +313,6 @@ CONFIG_RT_LIBC_USING_TIME=y # CONFIG_PKG_USING_RDB is not set # CONFIG_PKG_USING_QRCODE is not set # CONFIG_PKG_USING_ULOG_EASYFLASH is not set -# CONFIG_PKG_USING_ULOG_FILE is not set -# CONFIG_PKG_USING_LOGMGR is not set # CONFIG_PKG_USING_ADBD is not set # CONFIG_PKG_USING_COREMARK is not set # CONFIG_PKG_USING_DHRYSTONE is not set @@ -328,11 +325,6 @@ CONFIG_RT_LIBC_USING_TIME=y # CONFIG_PKG_USING_URLENCODE is not set # CONFIG_PKG_USING_UMCN is not set # CONFIG_PKG_USING_LWRB2RTT is not set -# CONFIG_PKG_USING_CPU_USAGE is not set -# CONFIG_PKG_USING_GBK2UTF8 is not set -# CONFIG_PKG_USING_VCONSOLE is not set -# CONFIG_PKG_USING_KDB is not set -# CONFIG_PKG_USING_WAMR is not set # # system packages @@ -370,12 +362,6 @@ CONFIG_RT_LIBC_USING_TIME=y # CONFIG_PKG_USING_UC_COMMON is not set # CONFIG_PKG_USING_UC_MODBUS is not set # CONFIG_PKG_USING_PPOOL is not set -# CONFIG_PKG_USING_OPENAMP is not set -# CONFIG_PKG_USING_RT_PRINTF is not set -# CONFIG_PKG_USING_RT_MEMCPY_CM is not set -# CONFIG_PKG_USING_QFPLIB_M0_FULL is not set -# CONFIG_PKG_USING_QFPLIB_M0_TINY is not set -# CONFIG_PKG_USING_QFPLIB_M3 is not set # # peripheral libraries and drivers @@ -384,7 +370,6 @@ CONFIG_RT_LIBC_USING_TIME=y # CONFIG_PKG_USING_REALTEK_AMEBA is not set # CONFIG_PKG_USING_SHT2X is not set # CONFIG_PKG_USING_SHT3X is not set -# CONFIG_PKG_USING_AS7341 is not set # CONFIG_PKG_USING_STM32_SDIO is not set # CONFIG_PKG_USING_ICM20608 is not set # CONFIG_PKG_USING_U8G2 is not set @@ -434,10 +419,6 @@ CONFIG_RT_LIBC_USING_TIME=y # CONFIG_PKG_USING_SSD1306 is not set # CONFIG_PKG_USING_QKEY is not set # CONFIG_PKG_USING_RS485 is not set -# CONFIG_PKG_USING_NES is not set -# CONFIG_PKG_USING_VIRTUAL_SENSOR is not set -# CONFIG_PKG_USING_VDEVICE is not set -# CONFIG_PKG_USING_SGM706 is not set # # miscellaneous packages @@ -447,7 +428,6 @@ CONFIG_RT_LIBC_USING_TIME=y # CONFIG_PKG_USING_FASTLZ is not set # CONFIG_PKG_USING_MINILZO is not set # CONFIG_PKG_USING_QUICKLZ is not set -# CONFIG_PKG_USING_LZMA is not set # CONFIG_PKG_USING_MULTIBUTTON is not set # CONFIG_PKG_USING_FLEXIBLE_BUTTON is not set # CONFIG_PKG_USING_CANFESTIVAL is not set @@ -483,11 +463,9 @@ CONFIG_RT_LIBC_USING_TIME=y # # CONFIG_PKG_USING_THREES is not set # CONFIG_PKG_USING_2048 is not set -# CONFIG_PKG_USING_SNAKE is not set # CONFIG_PKG_USING_TETRIS is not set # CONFIG_PKG_USING_LWGPS is not set # CONFIG_PKG_USING_TENSORFLOWLITEMICRO is not set -# CONFIG_PKG_USING_STATE_MACHINE is not set # # Privated Packages of RealThread @@ -525,10 +503,6 @@ CONFIG_RT_LIBC_USING_TIME=y # CONFIG_PKG_USING_EMQ is not set # CONFIG_PKG_USING_CFGM is not set # CONFIG_PKG_USING_RT_CMSIS_DAP is not set +# CONFIG_PKG_USING_VIRTUAL_DEVICE is not set # CONFIG_PKG_USING_SMODULE is not set -# CONFIG_PKG_USING_SNFD is not set -# CONFIG_PKG_USING_UDBD is not set -# CONFIG_PKG_USING_BENCHMARK is not set -# CONFIG_PKG_USING_UBJSON is not set -# CONFIG_PKG_USING_DATATYPE is not set CONFIG_SOC_RP2040=y diff --git a/bsp/raspberry-pico/README.md b/bsp/raspberry-pico/README.md index 43a51a89c940134695436e5eee9e157777b07a15..a06ca393d16a2ae5e895ad0ef4d0953a7cb3036e 100644 --- a/bsp/raspberry-pico/README.md +++ b/bsp/raspberry-pico/README.md @@ -1,6 +1,37 @@ # Raspberry PICO -## Build +## Introduction + +**Raspberry Pi Pico is a low-cost, high-performance microcontroller board with flexible digital interfaces.** + +**Key features include:** + +- RP2040 microcontroller chip designed by Raspberry Pi in the United Kingdom +- Dual-core Arm Cortex M0+ processor, flexible clock running up to 133 MHz +- 264KB of SRAM, and 2MB of on-board Flash memory +- Castellated module allows soldering direct to carrier boards +- USB 1.1 with device and host support +- Low-power sleep and dormant modes + +- Drag-and-drop programming using mass storage over USB +- 26 × multi-function GPIO pins +- 2 × SPI, 2 × I2C, 2 × UART, 3 × 12-bit ADC, 16 × controllable PWM channels +- Accurate clock and timer on-chip +- Temperature sensor +- Accelerated floating-point libraries on-chip +- 8 × Programmable I/O (PIO) state machines for custom peripheral support + + + +![Pico-R3-Pinout](figures/Pico-R3-Pinout.svg) + +## Supported compiler + +Support GCC 6 and above compilers. + +## Program firmware + +### Step 1: build ``` scons -c @@ -9,16 +40,20 @@ scons **gcc version >= 6.x.x** -## Flash +### Step 2: flash + +Run the following command in the linux environment. ``` -./Libraries/generated/elf2uf2 rtthread-pico.elf rtthread-pico.uf2 +./libraries/generated/elf2uf2 rtthread-pico.elf rtthread-pico.uf2 ``` - Copy the rtthread-pico.uf2 file to the "RPI-RP2" disk - Then led blink. -## Run +## Running Result + +The output information on serial port should be like this: ``` \ | / @@ -29,3 +64,16 @@ Hello, RT-Thread! msh > ``` +## Peripheral Condition + +| Drive | Support | Remark | +| ----- | ------- | ------ | +| UART | Support | UART0 | +| GPIO | Support | 0-29 | +| I2C | - | - | +| RTC | - | - | +| SDIO | - | - | +| SPI | - | - | +| TIMER | - | - | +| WDT | - | - | + diff --git a/bsp/raspberry-pico/SConstruct b/bsp/raspberry-pico/SConstruct index 5fa1ce567bbceda66c617eec8c15d86cac513b02..94b0d327ca82d005386b66324efeaf581247799d 100644 --- a/bsp/raspberry-pico/SConstruct +++ b/bsp/raspberry-pico/SConstruct @@ -27,11 +27,5 @@ Export('rtconfig') # prepare building environment objs = PrepareBuilding(env, RTT_ROOT) -#if GetDepend('RT_USING_RTGUI'): -# objs = objs + SConscript(RTT_ROOT + '/examples/gui/SConscript', variant_dir='build/examples/gui', duplicate=0) - -# libc testsuite -# objs = objs + SConscript(RTT_ROOT + '/examples/libc/SConscript', variant_dir='build/examples/libc', duplicate=0) - # make a building DoBuilding(TARGET, objs) diff --git a/bsp/raspberry-pico/applications/main.c b/bsp/raspberry-pico/applications/main.c index f1792ed83614c9faf9d28776718ee98867306d37..e954b3b742f506f188f1b047c9b1450870f68b30 100644 --- a/bsp/raspberry-pico/applications/main.c +++ b/bsp/raspberry-pico/applications/main.c @@ -1,24 +1,29 @@ -/** - * Copyright (c) 2020 Raspberry Pi (Trading) Ltd. +/* + * Copyright (c) 2006-2021, RT-Thread Development Team * - * SPDX-License-Identifier: BSD-3-Clause + * SPDX-License-Identifier: Apache-2.0 + * + * Change Logs: + * Date Author Notes + * 2021-01-28 flybreak first version */ #include +#include -#include "board.h" - -int main() { - const uint LED_PIN = 25; +#define LED_PIN 25 +int main(void) +{ rt_kprintf("Hello, RT-Thread!\n"); - gpio_init(LED_PIN); - gpio_set_dir(LED_PIN, GPIO_OUT); - while (true) { - gpio_put(LED_PIN, 1); + rt_pin_mode(LED_PIN, PIN_MODE_OUTPUT); + + while (1) + { + rt_pin_write(LED_PIN, 1); rt_thread_mdelay(1000); - gpio_put(LED_PIN, 0); + rt_pin_write(LED_PIN, 0); rt_thread_mdelay(1000); } } diff --git a/bsp/raspberry-pico/drivers/board.c b/bsp/raspberry-pico/drivers/board.c index e4db84bdad0c2a847d6a98158b3c57c7aa1bb963..af8bcb4f80546ce943b311441e266f8ae83568ba 100644 --- a/bsp/raspberry-pico/drivers/board.c +++ b/bsp/raspberry-pico/drivers/board.c @@ -1,11 +1,11 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: - * Date Author Notes - * 2009-01-05 Bernard first implementation + * Date Author Notes + * 2021-01-28 flybreak first version */ #include diff --git a/bsp/raspberry-pico/drivers/board.h b/bsp/raspberry-pico/drivers/board.h index 725ce1e4c2e2a95254f7b408dafc8ef8f737f0e0..e762b479f8f53559cc42fd3c26294a49ab809efb 100644 --- a/bsp/raspberry-pico/drivers/board.h +++ b/bsp/raspberry-pico/drivers/board.h @@ -1,14 +1,13 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: - * Date Author Notes - * 2009-09-22 Bernard add board.h to this bsp + * Date Author Notes + * 2021-01-28 flybreak first version */ -// <<< Use Configuration Wizard in Context Menu >>> #ifndef __BOARD_H__ #define __BOARD_H__ diff --git a/bsp/raspberry-pico/drivers/drv_gpio.c b/bsp/raspberry-pico/drivers/drv_gpio.c new file mode 100644 index 0000000000000000000000000000000000000000..2d9382ffb85d67cdcf5cf071bf80c348229b5cc4 --- /dev/null +++ b/bsp/raspberry-pico/drivers/drv_gpio.c @@ -0,0 +1,67 @@ +/* + * Copyright (c) 2006-2021, RT-Thread Development Team + * + * SPDX-License-Identifier: Apache-2.0 + * + * Change Logs: + * Date Author Notes + * 2021-01-28 flybreak first version + */ + +#include "drv_gpio.h" + +static void pico_pin_mode(struct rt_device *dev, rt_base_t pin, rt_base_t mode) +{ + RT_ASSERT((0 <= pin) && (pin < N_GPIOS)); + + gpio_init(pin); + switch (mode) + { + case PIN_MODE_OUTPUT: + gpio_set_dir(pin, GPIO_OUT); + break; + case PIN_MODE_INPUT: + gpio_set_dir(pin, GPIO_IN); + break; + case PIN_MODE_INPUT_PULLUP: + gpio_pull_up(pin); + break; + case PIN_MODE_INPUT_PULLDOWN: + gpio_pull_down(pin); + break; + case PIN_MODE_OUTPUT_OD: + gpio_disable_pulls(pin); + break; + } +} + +static void pico_pin_write(struct rt_device *dev, rt_base_t pin, rt_base_t value) +{ + RT_ASSERT((0 <= pin) && (pin < N_GPIOS)); + gpio_put(pin, value); +} + +static int pico_pin_read(struct rt_device *device, rt_base_t pin) +{ + RT_ASSERT((0 <= pin) && (pin < N_GPIOS)); + return (gpio_get(pin)? PIN_HIGH : PIN_LOW); +} + +static const struct rt_pin_ops ops = +{ + pico_pin_mode, + pico_pin_write, + pico_pin_read, + RT_NULL, + RT_NULL, + RT_NULL, + RT_NULL, +}; + +int rt_hw_gpio_init(void) +{ + rt_device_pin_register("gpio", &ops, RT_NULL); + + return 0; +} +INIT_DEVICE_EXPORT(rt_hw_gpio_init); diff --git a/bsp/raspberry-pico/drivers/drv_gpio.h b/bsp/raspberry-pico/drivers/drv_gpio.h new file mode 100644 index 0000000000000000000000000000000000000000..69e29171567605f0693ef21e2d5e22cffe75475e --- /dev/null +++ b/bsp/raspberry-pico/drivers/drv_gpio.h @@ -0,0 +1,21 @@ +/* + * Copyright (c) 2006-2021, RT-Thread Development Team + * + * SPDX-License-Identifier: Apache-2.0 + * + * Change Logs: + * Date Author Notes + * 2021-01-28 flybreak first version + */ + +#ifndef __DRV_GPIO_H__ +#define __DRV_GPIO_H__ + +#include +#include + +#include "board.h" + +int rt_hw_gpio_init(void); + +#endif /* __DRV_GPIO_H__ */ diff --git a/bsp/raspberry-pico/drivers/drv_uart.h b/bsp/raspberry-pico/drivers/drv_uart.h index 73aa03683357e0b067f9cafb23241c3147bc70b3..ac49a4c8fc0fe0936f43ba2266071e63e76077c1 100644 --- a/bsp/raspberry-pico/drivers/drv_uart.h +++ b/bsp/raspberry-pico/drivers/drv_uart.h @@ -1,11 +1,11 @@ /* - * Copyright (c) 2006-2018, RT-Thread Development Team + * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: - * Date Author Notes - * 2009-01-05 Bernard the first version + * Date Author Notes + * 2021-01-28 flybreak first version */ #ifndef __USART_H__ diff --git a/bsp/raspberry-pico/figures/Pico-R3-Pinout.svg b/bsp/raspberry-pico/figures/Pico-R3-Pinout.svg new file mode 100644 index 0000000000000000000000000000000000000000..2b09ce37022459b3dd576f6e8fee9d9d90bbcfe0 --- /dev/null +++ b/bsp/raspberry-pico/figures/Pico-R3-Pinout.svg @@ -0,0 +1,5457 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/bsp/raspberry-pico/libraries/SConscript b/bsp/raspberry-pico/libraries/SConscript index 055c58dc596ffe1396bde35248091eec5853d5f0..8d45dee783e238ce3852be0b6a4da7c330ad3ddc 100644 --- a/bsp/raspberry-pico/libraries/SConscript +++ b/bsp/raspberry-pico/libraries/SConscript @@ -55,19 +55,6 @@ pico-sdk/src/rp2_common/pico_standard_link/crt0.S generated/bs2_default_padded_checksummed.S """) -# # starupt scripts for STM32F2xx -# startup_scripts = 'startup_stm32f2xx.s' - -# # add for startup script -# if rtconfig.CROSS_TOOL == 'gcc': -# src = src + ['CMSIS/CM3/DeviceSupport/ST/STM32F2xx/startup/gcc_ride7/' + startup_scripts] -# elif rtconfig.CROSS_TOOL == 'keil': -# src = src + ['CMSIS/CM3/DeviceSupport/ST/STM32F2xx/startup/arm/' + startup_scripts] -# elif rtconfig.CROSS_TOOL == 'iar': -# src = src + ['CMSIS/CM3/DeviceSupport/ST/STM32F2xx/startup/iar/' + startup_scripts] - -# /home/henson/Documents/rasp-pico/pico/pico-examples/build/generated/pico_base - path = [ cwd + '/pico-sdk/src/common/pico_stdlib/include', cwd + '/pico-sdk/src/rp2_common/hardware_gpio/include', @@ -106,14 +93,6 @@ path = [ cwd + '/generated/pico_base' ] -# path += [cwd + '/CMSIS/CM3/CoreSupport', -# cwd + '/CMSIS/Include'] - -# if GetDepend('RT_USING_LWIP') == True: -# src = src + ['STM32F2x7_ETH_Driver/src/stm32f2x7_eth.c'] -# path = path + [cwd + '/STM32F2x7_ETH_Driver/inc'] - - CPPDEFINES = [ 'PICO_NO_BINARY_INFO', 'PICO_NO_PROGRAM_INFO', diff --git a/bsp/raspberry-pico/rtconfig.h b/bsp/raspberry-pico/rtconfig.h index 1875dbc4573812a7d36c3279d01fe1eb47f5ca9d..507deb48a67dd7a15d89c2049b086254e5c349ed 100644 --- a/bsp/raspberry-pico/rtconfig.h +++ b/bsp/raspberry-pico/rtconfig.h @@ -80,6 +80,7 @@ #define RT_USING_SERIAL #define RT_SERIAL_USING_DMA #define RT_SERIAL_RB_BUFSZ 64 +#define RT_USING_PIN /* Using USB */