This is an automated email from the ASF dual-hosted git repository. jerpelea pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/nuttx.git
The following commit(s) were added to refs/heads/master by this push: new 01040400cb docs/rp2040: Remove documentation duplication of RP2040 boards. 01040400cb is described below commit 01040400cb12b600f5e1493a65bc948eb3cdeb60 Author: Matteo Golin <matteo.go...@gmail.com> AuthorDate: Sat May 10 10:02:33 2025 -0400 docs/rp2040: Remove documentation duplication of RP2040 boards. Installation instructions, license exceptions and supported features of the RP2040 common among all boards have been moved exclusively to the rp2040/index.rst file. Board documentation links back to the primary source for installation instructions. Signed-off-by: Matteo Golin <matteo.go...@gmail.com> --- .../boards/adafruit-feather-rp2040/index.rst | 140 ++-------------- .../arm/rp2040/boards/adafruit-kb2040/index.rst | 140 ++-------------- .../rp2040/boards/adafruit-qt-py-rp2040/index.rst | 127 ++------------- .../arm/rp2040/boards/pimoroni-tiny2040/index.rst | 128 ++------------- .../arm/rp2040/boards/raspberrypi-pico-w/index.rst | 140 ++-------------- .../arm/rp2040/boards/raspberrypi-pico/index.rst | 140 ++-------------- .../arm/rp2040/boards/seeed-xiao-rp2040/index.rst | 86 ++-------- .../arm/rp2040/boards/w5500-evb-pico/index.rst | 108 ++----------- .../boards/waveshare-rp2040-lcd-1.28/index.rst | 133 ++------------- .../rp2040/boards/waveshare-rp2040-zero/index.rst | 139 ++-------------- Documentation/platforms/arm/rp2040/index.rst | 178 +++++++++++++++++---- Documentation/platforms/arm/rp2040/rp2040.png | Bin 0 -> 387850 bytes 12 files changed, 269 insertions(+), 1190 deletions(-) diff --git a/Documentation/platforms/arm/rp2040/boards/adafruit-feather-rp2040/index.rst b/Documentation/platforms/arm/rp2040/boards/adafruit-feather-rp2040/index.rst index 6440502af8..e45965ef91 100644 --- a/Documentation/platforms/arm/rp2040/boards/adafruit-feather-rp2040/index.rst +++ b/Documentation/platforms/arm/rp2040/boards/adafruit-feather-rp2040/index.rst @@ -31,14 +31,6 @@ Features * 8 × Programmable IO (PIO) state machines for custom peripheral support * LiPoly Battery connector -Serial Console -============== - -By default a serial console appears on pins 14 (RX GPIO0) and pin 15 -(TX GPIO1). This console runs a 115200-8N1. - -The board can be configured to use the USB connection as the serial console. - Buttons and LEDs ================ @@ -60,6 +52,7 @@ the power. Pin Mapping =========== + Pads numbered anticlockwise from USB connector. ===== ========== ========== @@ -122,108 +115,23 @@ in PFM mode which provides the best efficiency, but may be switched to PWM mode for improved ripple by outputting a one on GPIO23. -Supported Capabilities -====================== - -NuttX supports the following RP2040 capabilities: - -* UART (console port) - - * GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are used for the console. - -* I2C -* SPI (master only) -* DMAC -* PWM -* ADC -* Watchdog -* USB device - - * MSC, CDC/ACM serial and these composite device are supported. - * CDC/ACM serial device can be used for the console. - -* PIO (RP2040 Programmable I/O) -* Flash ROM Boot -* SRAM Boot - - * If Pico SDK is available, nuttx.uf2 file which can be used in BOOTSEL mode will be created. - -* Persistent flash filesystem in unused flash ROM -* WiFi wireless communication - -There is currently no direct user mode access to these RP2040 hardware features: - -* SPI Slave Mode -* SSI -* RTC -* Timers - -NuttX also provide support for these external devices: - -* BMP180 sensor at I2C0 (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* INA219 sensor / module (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* SHT4X sensor at I2C0 -* Pico Display Pack (ST7789 LCD) - - * RGB leds and buttons are not supported yet. - -* Pico Audio Pack (PCM5100A I2S DAC) - - * I2S interface is realized by PIO. - -* WS2812 smart pixel support - -Installation -============ - -1. Download Raspberry Pi Pico SDK. +Installation & Build +==================== -.. code-block:: console +For instructions on how to to install the build dependencies and create a NuttX +image for this board, consult the main :doc:`RP2040 documentation +<../../index>`. - $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git - -2. Download and install picotool - - Instructions can be found here: https://github.com/raspberrypi/picotool - - If you are on Arch Linux, you can install the picotool through the AUR: - -.. code-block:: console - - $ yay -S picotool - -3. Set PICO_SDK_PATH environment variable - -.. code-block:: console - - $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> - -4. Configure and build NuttX - -.. code-block:: console - - $ git clone https://github.com/apache/nuttx.git nuttx - $ git clone https://github.com/apache/nuttx-apps.git apps - $ cd nuttx - $ make distclean - $ ./tools/configure.sh raspberrypi-pico-w:nsh - $ make V=1 - -5. Connect the Adafruit Feather RP2040 board to the USB port while pressing - BOOTSEL. - The board will be detected as USB Mass Storage Device. - Then copy "nuttx.uf2" into the device. - (Same manner as the standard Pico SDK applications installation.) +Configurations +============== -6. To access the console, GPIO 0 and 1 pins must be connected to the - device such as USB-serial converter. +All configurations listed below can be configured using the following command in +the ``nuttx`` directory (again, consult the main :doc:`RP2040 documentation +<../../index>`): - `usbnsh` configuration provides the console access by USB CDC/ACM serial - device. The console is available by using a terminal software on the USB - host. +.. code:: console -Configurations -============== + $ ./tools/configure.sh adafruit-feather-rp2040:<configname> audiopack --------- @@ -440,25 +348,3 @@ waveshare-lcd-1.3 NuttShell configuration (console enabled in UART0, at 115200 bps) with support for usbmsc. - -License exceptions -================== - -The following files are originated from the files in Pico SDK. -So, the files are licensed under 3-Clause BSD same as Pico SDK. - -* arch/arm/src/rp2040/rp2040_clock.c -* arch/arm/src/rp2040/rp2040_pll.c -* arch/arm/src/rp2040/rp2040_xosc.c - - * These are created by referring the Pico SDK clock initialization. - -* arch/arm/src/rp2040/rp2040_pio.c -* arch/arm/src/rp2040/rp2040_pio.h -* arch/arm/src/rp2040/rp2040_pio_instructions.h - - * These provide the similar APIs to Pico SDK's hardware_pio APIs. - -* arch/arm/src/rp2040/hardware/\*.h - - * These are generated from rp2040.svd originally provided in Pico SDK. diff --git a/Documentation/platforms/arm/rp2040/boards/adafruit-kb2040/index.rst b/Documentation/platforms/arm/rp2040/boards/adafruit-kb2040/index.rst index 13c3c411b8..df74c0509b 100644 --- a/Documentation/platforms/arm/rp2040/boards/adafruit-kb2040/index.rst +++ b/Documentation/platforms/arm/rp2040/boards/adafruit-kb2040/index.rst @@ -31,14 +31,6 @@ Features * 8 × Programmable IO (PIO) state machines for custom peripheral support * On-board STEMMA QT connector for quick I2C connection. -Serial Console -============== - -By default a serial console appears on pins 1 (TX GPIO0) and pin 2 -(RX GPIO1). This console runs a 115200-8N1. - -The board can be configured to use the USB connection as the serial console. - Buttons and LEDs ================ @@ -55,6 +47,7 @@ A ws2812 (NeoPixel) smart RGB LED controlled by GPIO17. Pin Mapping =========== + Pads numbered anticlockwise from USB connector. ===== ========== ========== @@ -89,7 +82,6 @@ Pad Signal Notes The board has a STEMMA QT connector that is also connected to pins GPI12 (I2C1 SDA) and GPI13 (I2C1 SDA). - Power Supply ============ @@ -99,107 +91,23 @@ or by supplying +5V to pin 23. The Raspberry Pi Pico chip run on 3.3 volts. This is supplied by an onboard voltage regulator. -Supported Capabilities -====================== - -NuttX supports the following RP2040 capabilities: - -* UART (console port) - - * GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are used for the console. - -* I2C -* SPI (master only) -* DMAC -* PWM -* ADC -* Watchdog -* USB device - - * MSC, CDC/ACM serial and these composite device are supported. - * CDC/ACM serial device can be used for the console. - -* PIO (RP2040 Programmable I/O) -* Flash ROM Boot -* SRAM Boot - - * If Pico SDK is available, nuttx.uf2 file which can be used in BOOTSEL mode will be created. - -* Persistent flash filesystem in unused flash ROM -* WiFi wireless communication - -There is currently no direct user mode access to these RP2040 hardware features: - -* SPI Slave Mode -* SSI -* RTC -* Timers - -NuttX also provide support for these external devices: - -* BMP180 sensor at I2C0 (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* INA219 sensor / module (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* SHT4X sensor at I2C0 -* Pico Display Pack (ST7789 LCD) - - * RGB leds and buttons are not supported yet. - -* Pico Audio Pack (PCM5100A I2S DAC) - - * I2S interface is realized by PIO. - -* WS2812 smart pixel support - -Installation -============ - -1. Download Raspberry Pi Pico SDK. +Installation & Build +==================== -.. code-block:: console +For instructions on how to to install the build dependencies and create a NuttX +image for this board, consult the main :doc:`RP2040 documentation +<../../index>`. - $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git - -2. Download and install picotool - - Instructions can be found here: https://github.com/raspberrypi/picotool - - If you are on Arch Linux, you can install the picotool through the AUR: - -.. code-block:: console - - $ yay -S picotool - -3. Set PICO_SDK_PATH environment variable - -.. code-block:: console - - $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> - -4. Configure and build NuttX - -.. code-block:: console - - $ git clone https://github.com/apache/nuttx.git nuttx - $ git clone https://github.com/apache/nuttx-apps.git apps - $ cd nuttx - $ make distclean - $ ./tools/configure.sh adafruit-kb2040:nsh - $ make V=1 - -5. Connect the Adafruit KB2040 board to USB port while pressing BOOT. - The board will be detected as USB Mass Storage Device. Then copy "nuttx.uf2" - into the device (Same manner as the standard Pico SDK applications - installation). +Configurations +============== -6. To access the console, GPIO 0 (TX) and GPIO 1 (RX) pins must be connected to - the device such as USB-serial converter. +All configurations listed below can be configured using the following command in +the ``nuttx`` directory (again, consult the main :doc:`RP2040 documentation +<../../index>`): - `usbnsh` configuration provides the console access by USB CDC/ACM serial - decive. The console is available by using a terminal software on the USB - host. +.. code:: console -Configurations -============== + $ ./tools/configure.sh adafruit-kb2040:<configname> audiopack --------- @@ -418,25 +326,3 @@ waveshare-lcd-1.3 NuttShell configuration (console enabled in UART0, at 115200 bps) with support for usbmsc. - -License exceptions -================== - -The following files are originated from the files in Pico SDK. -So, the files are licensed under 3-Clause BSD same as Pico SDK. - -* arch/arm/src/rp2040/rp2040_clock.c -* arch/arm/src/rp2040/rp2040_pll.c -* arch/arm/src/rp2040/rp2040_xosc.c - - * These are created by referring the Pico SDK clock initialization. - -* arch/arm/src/rp2040/rp2040_pio.c -* arch/arm/src/rp2040/rp2040_pio.h -* arch/arm/src/rp2040/rp2040_pio_instructions.h - - * These provide the similar APIs to Pico SDK's hardware_pio APIs. - -* arch/arm/src/rp2040/hardware/\*.h - - * These are generated from rp2040.svd originally provided in Pico SDK. diff --git a/Documentation/platforms/arm/rp2040/boards/adafruit-qt-py-rp2040/index.rst b/Documentation/platforms/arm/rp2040/boards/adafruit-qt-py-rp2040/index.rst index abed91b31a..5feb8f834f 100644 --- a/Documentation/platforms/arm/rp2040/boards/adafruit-qt-py-rp2040/index.rst +++ b/Documentation/platforms/arm/rp2040/boards/adafruit-qt-py-rp2040/index.rst @@ -30,14 +30,6 @@ Features * Accelerated floating point libraries on-chip * 8 × Programmable IO (PIO) state machines for custom peripheral support -Serial Console -============== - -By default a serial console appears on GPIO pins 20 (RX GPIO1) and pin 5 -(TX GPIO1). This console runs a 115200-8N1. - -The board can be configured to use the USB connection as the serial console. - Buttons and LEDs ================ @@ -91,96 +83,23 @@ is need to run as a usb host. The Raspberry Pi Pico chip run on 3.3 volts which is supplied by an on board regulator. -Supported Capabilities -====================== - -NuttX supports the following RP2040 capabilities: - -* UART (console port) - - * GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are used for the console. - -* I2C -* SPI (master only) -* DMAC -* PWM -* ADC -* Watchdog -* USB device - - * MSC, CDC/ACM serial and these composite device are supported. - * CDC/ACM serial device can be used for the console. - -* PIO (RP2040 Programmable I/O) -* Flash ROM Boot -* SRAM Boot - - * If Pico SDK is available, nuttx.uf2 file which can be used in BOOTSEL mode will be created. - -* Persistent flash filesystem in unused flash ROM -* WiFi wireless communication - -There is currently no direct user mode access to these RP2040 hardware features: - -* SPI Slave Mode -* SSI -* RTC -* Timers - -NuttX also provide support for these external devices: - -* WS2812 smart pixel support - -Installation -============ - -1. Download Raspberry Pi Pico SDK. - -.. code-block:: console - - $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git - -2. Download and install picotool +Installation & Build +==================== - Instructions can be found here: https://github.com/raspberrypi/picotool +For instructions on how to to install the build dependencies and create a NuttX +image for this board, consult the main :doc:`RP2040 documentation +<../../index>`. - If you are on Arch Linux, you can install the picotool through the AUR: - -.. code-block:: console - - $ yay -S picotool - -3. Set PICO_SDK_PATH environment variable - -.. code-block:: console - - $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> - -4. Configure and build NuttX - -.. code-block:: console - - $ git clone https://github.com/apache/nuttx.git nuttx - $ git clone https://github.com/apache/nuttx-apps.git apps - $ cd nuttx - $ make distclean - $ ./tools/configure.sh adafruit-qt-py-rp2040:nsh - $ make V=1 +Configurations +============== -5. Connect the Adafruit QT Py RP2040 board to USB port while pressing BOOT. - The board will be detected as USB Mass Storage Device. Then copy "nuttx.uf2" - into the device (Same manner as the standard Pico SDK applications - installation). +All configurations listed below can be configured using the following command in +the ``nuttx`` directory (again, consult the main :doc:`RP2040 documentation +<../../index>`): -6. To access the console, GPIO 20 (TX) and GPIO 5 (RX) pins must be connected to - the device such as USB-serial converter. +.. code:: console - `usbnsh` configuration provides the console access by USB CDC/ACM serial - decive. The console is available by using a terminal software on the USB - host. - -Configurations -============== + $ ./tools/configure.sh adafruit-qt-py-rp2040:<configname> gpio -------- @@ -215,25 +134,3 @@ usbnsh Basic NuttShell configuration using CDC/ACM serial (console enabled in USB Port, at 115200 bps). - -License exceptions -================== - -The following files are originated from the files in Pico SDK. -So, the files are licensed under 3-Clause BSD same as Pico SDK. - -* arch/arm/src/rp2040/rp2040_clock.c -* arch/arm/src/rp2040/rp2040_pll.c -* arch/arm/src/rp2040/rp2040_xosc.c - - * These are created by referring the Pico SDK clock initialization. - -* arch/arm/src/rp2040/rp2040_pio.c -* arch/arm/src/rp2040/rp2040_pio.h -* arch/arm/src/rp2040/rp2040_pio_instructions.h - - * These provide the similar APIs to Pico SDK's hardware_pio APIs. - -* arch/arm/src/rp2040/hardware/\*.h - - * These are generated from rp2040.svd originally provided in Pico SDK. diff --git a/Documentation/platforms/arm/rp2040/boards/pimoroni-tiny2040/index.rst b/Documentation/platforms/arm/rp2040/boards/pimoroni-tiny2040/index.rst index 997de387ea..e74233763e 100644 --- a/Documentation/platforms/arm/rp2040/boards/pimoroni-tiny2040/index.rst +++ b/Documentation/platforms/arm/rp2040/boards/pimoroni-tiny2040/index.rst @@ -33,14 +33,6 @@ Features * Accelerated floating point libraries on-chip * 8 × Programmable IO (PIO) state machines for custom peripheral support -Serial Console -============== - -By default a serial console appears on pins 15 (RX GPIO0) and -pin 16 (TX GPIO1). This console runs a 115200-8N1. - -The board can be configured to use the USB connection as the serial console. - Buttons and LEDs ================ @@ -87,97 +79,23 @@ or by supplying +5V to pin 1. The Raspberry Pi Pico chip run on 3.3 volts. This is supplied by an onboard voltage regulator. -Supported Capabilities -====================== - -NuttX supports the following RP2040 capabilities: - -* UART (console port) - - * GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are used for the console. - -* I2C -* SPI (master only) -* DMAC -* PWM -* ADC -* Watchdog -* USB device - - * MSC, CDC/ACM serial and these composite device are supported. - * CDC/ACM serial device can be used for the console. - -* PIO (RP2040 Programmable I/O) -* Flash ROM Boot -* SRAM Boot - - * If Pico SDK is available, nuttx.uf2 file which can be used in BOOTSEL mode will be created. - -* Persistent flash filesystem in unused flash ROM -* WiFi wireless communication - -There is currently no direct user mode access to these RP2040 hardware features: - -* SPI Slave Mode -* SSI -* RTC -* Timers - -NuttX also provide support for these external devices: - -* WS2812 smart pixel support - -Installation -============ - -1. Download Raspberry Pi Pico SDK - -.. code-block:: console - - $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git - -2. Download and install picotool +Installation & Build +==================== - Instructions can be found here: https://github.com/raspberrypi/picotool +For instructions on how to to install the build dependencies and create a NuttX +image for this board, consult the main :doc:`RP2040 documentation +<../../index>`. - If you are on Arch Linux, you can install the picotool through the AUR: - -.. code-block:: console - - $ yay -S picotool - -3. Set PICO_SDK_PATH environment variable - -.. code-block:: console - - $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> - -4. Configure and build NuttX - -.. code-block:: console - - $ git clone https://github.com/apache/nuttx.git nuttx - $ git clone https://github.com/apache/nuttx-apps.git apps - $ cd nuttx - $ make distclean - $ ./tools/configure.sh pimoroni-tiny2040:nsh - $ make V=1 +Configurations +============== -5. Connect Pimoroni Tiny 2040 board to USB port. While pressing the - BOOT button, shortly press the RESET button. On releasing the BOOT - button the board boots from internal ROM and will be detected as - USB Mass Storage Device. Then copy "nuttx.uf2" into the device. - (Same manner as the standard Pico SDK applications installation.) +All configurations listed below can be configured using the following command in +the ``nuttx`` directory (again, consult the main :doc:`RP2040 documentation +<../../index>`): -6. To access the console, GPIO 0 and 1 pins must be connected to the - device such as USB-serial converter. +.. code:: console - `usbnsh` configuration provides the console access by USB CDC/ACM serial - decive. The console is available by using a terminal software on the USB - host. - -Configurations -============== + $ ./tools/configure.sh pimoroni-tiny2040:<configname> composite --------- @@ -277,25 +195,3 @@ usbnsh Basic NuttShell configuration using CDC/ACM serial (console enabled in USB Port, at 115200 bps). - -License exceptions -================== - -The following files are originated from the files in Pico SDK. -So, the files are licensed under 3-Clause BSD same as Pico SDK. - -* arch/arm/src/rp2040/rp2040_clock.c -* arch/arm/src/rp2040/rp2040_pll.c -* arch/arm/src/rp2040/rp2040_xosc.c - - * These are created by referring the Pico SDK clock initialization. - -* arch/arm/src/rp2040/rp2040_pio.c -* arch/arm/src/rp2040/rp2040_pio.h -* arch/arm/src/rp2040/rp2040_pio_instructions.h - - * These provide the similar APIs to Pico SDK's hardware_pio APIs. - -* arch/arm/src/rp2040/hardware/\*.h - - * These are generated from rp2040.svd originally provided in Pico SDK. diff --git a/Documentation/platforms/arm/rp2040/boards/raspberrypi-pico-w/index.rst b/Documentation/platforms/arm/rp2040/boards/raspberrypi-pico-w/index.rst index 34feb6e8d8..9bf308d152 100644 --- a/Documentation/platforms/arm/rp2040/boards/raspberrypi-pico-w/index.rst +++ b/Documentation/platforms/arm/rp2040/boards/raspberrypi-pico-w/index.rst @@ -28,14 +28,6 @@ Features * 8 × Programmable IO (PIO) state machines for custom peripheral support * Built in WiFi radio (Infineon CYW43439) -Serial Console -============== - -By default a serial console appears on pins 1 (TX GPIO0) and pin 2 -(RX GPIO1). This console runs a 115200-8N1. - -The board can be configured to use the USB connection as the serial console. - Buttons and LEDs ================ @@ -144,109 +136,23 @@ in PFM mode which provides the best efficiency, but may be switched to PWM mode for improved ripple by outputting a one on the wireless chip's GPIO1 (not the RP2040's GPIO1). -Supported Capabilities -====================== - -NuttX supports the following RP2040 capabilities: - -* UART (console port) - - * GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are used for the console. - -* I2C -* SPI (master only) -* DMAC -* PWM -* ADC -* Watchdog -* USB device - - * MSC, CDC/ACM serial and these composite device are supported. - * CDC/ACM serial device can be used for the console. - -* PIO (RP2040 Programmable I/O) -* Flash ROM Boot -* SRAM Boot - - * If Pico SDK is available, nuttx.uf2 file which can be used in BOOTSEL mode will be created. - -* Persistent flash filesystem in unused flash ROM -* WiFi wireless communication - -There is currently no direct user mode access to these RP2040 hardware features: - -* SPI Slave Mode -* SSI -* RTC -* Timers - -NuttX also provide support for these external devices: - -* BMP180 sensor at I2C0 (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* INA219 sensor / module (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* SHT4X sensor at I2C0 -* Pico Display Pack (ST7789 LCD) - - * RGB leds and buttons are not supported yet. - -* Pico Audio Pack (PCM5100A I2S DAC) - - * I2S interface is realized by PIO. - -* WS2812 smart pixel support - -Installation -============ - -1. Download Raspberry Pi Pico SDK and update submodule (cyw43-driver) - -.. code-block:: console - - $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git - $ cd pico-sdk - $ git submodule update --init --recursive lib/cyw43-driver - -2. Download and install picotool - - Instructions can be found here: https://github.com/raspberrypi/picotool - - If you are on Arch Linux, you can install the picotool through the AUR: - -.. code-block:: console - - $ yay -S picotool - -3. Set PICO_SDK_PATH environment variable - -.. code-block:: console - - $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> - -4. Configure and build NuttX - -.. code-block:: console +Installation & Build +==================== - $ git clone https://github.com/apache/nuttx.git nuttx - $ git clone https://github.com/apache/nuttx-apps.git apps - $ cd nuttx - $ make distclean - $ ./tools/configure.sh raspberrypi-pico-w:nsh - $ make V=1 +For instructions on how to to install the build dependencies and create a NuttX +image for this board, consult the main :doc:`RP2040 documentation +<../../index>`. -5. Connect Raspberry Pi Pico board to USB port while pressing BOOTSEL. - The board will be detected as USB Mass Storage Device. - Then copy "nuttx.uf2" into the device. - (Same manner as the standard Pico SDK applications installation.) +Configurations +============== -6. To access the console, GPIO 0 and 1 pins must be connected to the - device such as USB-serial converter. +All configurations listed below can be configured using the following command in +the ``nuttx`` directory (again, consult the main :doc:`RP2040 documentation +<../../index>`): - `usbnsh` configuration provides the console access by USB CDC/ACM serial - device. The console is available by using a terminal software on the USB - host. +.. code:: console -Configurations -============== + $ ./tools/configure.sh raspberrypi-pico-w:<configname> audiopack --------- @@ -473,25 +379,3 @@ waveshare-lcd-1.3 NuttShell configuration (console enabled in UART0, at 115200 bps) with support for usbmsc. - -License exceptions -================== - -The following files are originated from the files in Pico SDK. -So, the files are licensed under 3-Clause BSD same as Pico SDK. - -* arch/arm/src/rp2040/rp2040_clock.c -* arch/arm/src/rp2040/rp2040_pll.c -* arch/arm/src/rp2040/rp2040_xosc.c - - * These are created by referring the Pico SDK clock initialization. - -* arch/arm/src/rp2040/rp2040_pio.c -* arch/arm/src/rp2040/rp2040_pio.h -* arch/arm/src/rp2040/rp2040_pio_instructions.h - - * These provide the similar APIs to Pico SDK's hardware_pio APIs. - -* arch/arm/src/rp2040/hardware/\*.h - - * These are generated from rp2040.svd originally provided in Pico SDK. diff --git a/Documentation/platforms/arm/rp2040/boards/raspberrypi-pico/index.rst b/Documentation/platforms/arm/rp2040/boards/raspberrypi-pico/index.rst index bb7d36b627..694696a5e7 100644 --- a/Documentation/platforms/arm/rp2040/boards/raspberrypi-pico/index.rst +++ b/Documentation/platforms/arm/rp2040/boards/raspberrypi-pico/index.rst @@ -27,14 +27,6 @@ Features * Accelerated floating point libraries on-chip * 8 × Programmable IO (PIO) state machines for custom peripheral support -Serial Console -============== - -By default a serial console appears on pins 1 (TX GPIO0) and pin 2 -(RX GPIO1). This console runs a 115200-8N1. - -The board can be configured to use the USB connection as the serial console. - Buttons and LEDs ================ @@ -48,6 +40,7 @@ on the RP2040. Pin Mapping =========== + Pads numbered anticlockwise from USB connector. ===== ========== ========== @@ -122,108 +115,23 @@ in PFM mode which provides the best efficiency, but may be switched to PWM mode for improved ripple by outputting a one on GPIO23. -Supported Capabilities -====================== - -NuttX supports the following RP2040 capabilities: - -* UART (console port) - - * GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are used for the console. - -* I2C -* SPI (master only) -* DMAC -* PWM -* ADC -* Watchdog -* USB device - - * MSC, CDC/ACM serial and these composite device are supported. - * CDC/ACM serial device can be used for the console. - -* PIO (RP2040 Programmable I/O) -* Flash ROM Boot -* SRAM Boot - - * If Pico SDK is available, nuttx.uf2 file which can be used in BOOTSEL mode will be created. - -* Persistent flash filesystem in unused flash ROM -* WiFi wireless communication - -There is currently no direct user mode access to these RP2040 hardware features: - -* SPI Slave Mode -* SSI -* RTC -* Timers - -NuttX also provide support for these external devices: - -* BMP180 sensor at I2C0 (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* INA219 sensor / module (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* SHT4X sensor at I2C0 -* Pico Display Pack (ST7789 LCD) - - * RGB leds and buttons are not supported yet. - -* Pico Audio Pack (PCM5100A I2S DAC) - - * I2S interface is realized by PIO. - -* WS2812 smart pixel support - -Installation -============ - -1. Download Raspberry Pi Pico SDK - -.. code-block:: console - - $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git +Installation & Build +==================== -2. Download and install picotool +For instructions on how to to install the build dependencies and create a NuttX +image for this board, consult the main :doc:`RP2040 documentation +<../../index>`. - Instructions can be found here: https://github.com/raspberrypi/picotool - - If you are on Arch Linux, you can install the picotool through the AUR: - -.. code-block:: console - - $ yay -S picotool - -3. Set PICO_SDK_PATH environment variable - -.. code-block:: console - - $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> - -4. Configure and build NuttX - -.. code-block:: console - - $ git clone https://github.com/apache/nuttx.git nuttx - $ git clone https://github.com/apache/nuttx-apps.git apps - $ cd nuttx - $ make distclean - $ ./tools/configure.sh raspberrypi-pico:nsh - $ make V=1 - -5. Connect Raspberry Pi Pico board to USB port while pressing BOOTSEL. - The board will be detected as USB Mass Storage Device. - Then copy "nuttx.uf2" into the device. - (Same manner as the standard Pico SDK applications installation.) +Configurations +============== -6. To access the console, GPIO 0 and 1 pins must be connected to the - device such as USB-serial converter. +All configurations listed below can be configured using the following command in +the ``nuttx`` directory (again, consult the main :doc:`RP2040 documentation +<../../index>`): - `usbnsh` configuration provides the console access by USB CDC/ACM serial - device. The console is available by using a terminal software on the USB - host. +.. code:: console - -Configurations -============== + $ ./tools/configure.sh raspberrypi-pico:<configname> audiopack --------- @@ -451,25 +359,3 @@ waveshare-lcd-1.3 NuttShell configuration (console enabled in UART0, at 115200 bps) with support for usbmsc. - -License exceptions -================== - -The following files are originated from the files in Pico SDK. -So, the files are licensed under 3-Clause BSD same as Pico SDK. - -* arch/arm/src/rp2040/rp2040_clock.c -* arch/arm/src/rp2040/rp2040_pll.c -* arch/arm/src/rp2040/rp2040_xosc.c - - * These are created by referring the Pico SDK clock initialization. - -* arch/arm/src/rp2040/rp2040_pio.c -* arch/arm/src/rp2040/rp2040_pio.h -* arch/arm/src/rp2040/rp2040_pio_instructions.h - - * These provide the similar APIs to Pico SDK's hardware_pio APIs. - -* arch/arm/src/rp2040/hardware/\*.h - - * These are generated from rp2040.svd originally provided in Pico SDK. diff --git a/Documentation/platforms/arm/rp2040/boards/seeed-xiao-rp2040/index.rst b/Documentation/platforms/arm/rp2040/boards/seeed-xiao-rp2040/index.rst index 51f4e8b3a1..ea81c7046d 100644 --- a/Documentation/platforms/arm/rp2040/boards/seeed-xiao-rp2040/index.rst +++ b/Documentation/platforms/arm/rp2040/boards/seeed-xiao-rp2040/index.rst @@ -22,13 +22,6 @@ Features * 1 user LED, 1 power LED, two LEDs for serial port downloading, 1 RGB LED * 1 RESET button, 1 BOOT button -Serial Console -============== - -By default a serial console appears on pins 6 (TX GPIO0) and pin 7 -(RX GPIO1). This console runs a 115200-8N1. -The board can be configured to use the USB connection as the serial console. - LEDs ==== @@ -84,56 +77,23 @@ For power supply pins: The built-in DC-DC converter circuit able to change 5V voltage into 3.3V allows to power the device with a 5V supply via VIN-PIN and via the USB connector. -Installation -============ - -1. Download Raspberry Pi Pico SDK. - -.. code-block:: console - - $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git - -2. Download and install picotool - - Instructions can be found here: https://github.com/raspberrypi/picotool - - If you are on Arch Linux, you can install the picotool through the AUR: - -.. code-block:: console - - $ yay -S picotool - -3. Set PICO_SDK_PATH environment variable - -.. code-block:: console - - $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> +Installation & Build +==================== -4. Configure and build NuttX +For instructions on how to to install the build dependencies and create a NuttX +image for this board, consult the main :doc:`RP2040 documentation +<../../index>`. -.. code-block:: console - - $ git clone https://github.com/apache/nuttx.git nuttx - $ git clone https://github.com/apache/nuttx-apps.git apps - $ cd nuttx - $ make distclean - $ ./tools/configure.sh seeed-xiao-rp2040:nsh - $ make V=1 +Configurations +============== -5. Connect the Seeed Studio Xiao RP2040 board to USB port while pressing BOOTSEL - (small button marked "B"). The board will be detected as USB Mass Storage - Device. Then copy "nuttx.uf2" into the device. (Same manner as the standard - Pico SDK applications installation) +All configurations listed below can be configured using the following command in +the ``nuttx`` directory (again, consult the main :doc:`RP2040 documentation +<../../index>`): -6. To access the console, GPIO 0 and 1 pins must be connected to the - device such as USB-serial converter. +.. code:: console - `usbnsh` configuration provides the console access by USB CDC/ACM serial - device. The console is available by using a terminal software on the USB - host. - -Configurations -============== + $ ./tools/configure.sh seeed-xiao-rp2040:<configname> nsh --- @@ -150,25 +110,3 @@ usbnsh Basic NuttShell configuration using CDC/ACM serial (console enabled in USB Port, at 115200 bps). - -License exceptions -================== - -The following files are originated from the files in Pico SDK. -So, the files are licensed under 3-Clause BSD same as Pico SDK. - -* arch/arm/src/rp2040/rp2040_clock.c -* arch/arm/src/rp2040/rp2040_pll.c -* arch/arm/src/rp2040/rp2040_xosc.c - - * These are created by referring the Pico SDK clock initialization. - -* arch/arm/src/rp2040/rp2040_pio.c -* arch/arm/src/rp2040/rp2040_pio.h -* arch/arm/src/rp2040/rp2040_pio_instructions.h - - * These provide the similar APIs to Pico SDK's hardware_pio APIs. - -* arch/arm/src/rp2040/hardware/\*.h - - * These are generated from rp2040.svd originally provided in Pico SDK. diff --git a/Documentation/platforms/arm/rp2040/boards/w5500-evb-pico/index.rst b/Documentation/platforms/arm/rp2040/boards/w5500-evb-pico/index.rst index 3c251e8205..bd67d7c712 100644 --- a/Documentation/platforms/arm/rp2040/boards/w5500-evb-pico/index.rst +++ b/Documentation/platforms/arm/rp2040/boards/w5500-evb-pico/index.rst @@ -30,45 +30,6 @@ Features * 8 × Programmable IO (PIO) state machines for custom peripheral support * Ethernet port via WIZnet W5500, hardwired to SPI0 and two GPIO pins. -Supported RP2040 capabilities -============================= - -* UART (console port) - - * GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are used for the console. - -* I2C -* SPI (master only) -* DMAC -* PWM -* ADC -* Watchdog -* USB device - - * MSC, CDC/ACM serial and these composite device are supported. - * CDC/ACM serial device can be used for the console. - -* PIO (RP2040 Programmable I/O) -* Flash ROM Boot -* SRAM Boot - - * If Pico SDK is available, nuttx.uf2 file which can be used in - BOOTSEL mode will be created. - * Persistent flash filesystem in unused flash ROM - -Currently unsupported RP2040 capabilities -========================================= - -* SPI Slave Mode -* SSI -* RTC -* Timers - -Serial Console -============== - -The board is configured to use the USB connection as the serial console. - Buttons and LEDs ================ @@ -160,71 +121,26 @@ in PFM mode which provides the best efficiency, but may be switched to PWM mode for improved ripple by outputting a one on GPIO23. -Installation -============ - -1. Download Raspberry Pi Pico SDK - -:: - - $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git +Installation & Build +==================== -2. Set PICO_SDK_PATH environment variable +For instructions on how to to install the build dependencies and create a NuttX +image for this board, consult the main :doc:`RP2040 documentation +<../../index>`. -:: - - $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> - -3. Configure and build NuttX - -:: - - $ git clone https://github.com/apache/nuttx.git nuttx - $ git clone https://github.com/apache/nuttx-apps.git apps - $ cd nuttx - $ make distclean - $ ./tools/configure.sh w5500-evb-pico:usbnsh - $ make V=1 +Configurations +============== -4. Connect W5500-EVB-Pico board to USB port while pressing BOOTSEL. - The board will be detected as USB Mass Storage Device. - Then copy "nuttx.uf2" into the device. - (Same manner as the standard Pico SDK applications installation.) +All configurations listed below can be configured using the following command in +the ``nuttx`` directory (again, consult the main :doc:`RP2040 documentation +<../../index>`): -5. `usbnsh` configuration provides the console access by USB CDC/ACM serial - devcice. The console is available by using a terminal software on the USB - host. +.. code:: console -Configurations -============== + $ ./tools/configure.sh w5500-evb-pico:<configname> usbnsh ------ USB CDC/ACM serial console with NuttShell. TCP/IPv4 & IPv6 networking is supported via the Ethernet port. - -License exceptions -================== - -The following files are originated from the files in Pico SDK. -So, the files are licensed under 3-Clause BSD same as Pico SDK. - -Created by referring to the Pico SDK clock initialization ---------------------------------------------------------- - -* arch/arm/src/rp2040/rp2040_clock.c -* arch/arm/src/rp2040/rp2040_pll.c -* arch/arm/src/rp2040/rp2040_xosc.c - -Providing an API similar to the Pico SDK's hardware_pio API ------------------------------------------------------------ - -* arch/arm/src/rp2040/rp2040_pio.c -* arch/arm/src/rp2040/rp2040_pio.h -* arch/arm/src/rp2040/rp2040_pio_instructions.h - -Generated from rp2040.svd originally provided in Pico SDK ---------------------------------------------------------- - -* arch/arm/src/rp2040/hardware/\*.h diff --git a/Documentation/platforms/arm/rp2040/boards/waveshare-rp2040-lcd-1.28/index.rst b/Documentation/platforms/arm/rp2040/boards/waveshare-rp2040-lcd-1.28/index.rst index 0b0c29b632..0aa5c7ce57 100644 --- a/Documentation/platforms/arm/rp2040/boards/waveshare-rp2040-lcd-1.28/index.rst +++ b/Documentation/platforms/arm/rp2040/boards/waveshare-rp2040-lcd-1.28/index.rst @@ -32,14 +32,6 @@ Features * Accelerated floating-point libraries on-chip * 8 x Programmable I/O (PIO) state machines for custom peripheral support -Serial Console -============== - -By default a serial console appears on pins 1 (TX GPIO0) and pin 2 -(RX GPIO1). This console runs a 115200-8N1. - -The board can be configured to use the USB connection as the serial console. - Buttons and LEDs ================ @@ -68,101 +60,26 @@ The Raspberry Pi Pico can be powered via the USB connector, connecting a lithium battery through connector, or by supplying +5V to pin 18(VSYS). The board had a diode that prevents power from pin 18 from flowing back to the USB socket. Power through USB or VSYS will be charging the battery -if connected. The schematic is available at `RP2040-LCD-1.28-sch.pdf <https://www.waveshare.net/w/upload/6/60/RP2040-LCD-1.28-sch.pdf>`_ - -Supported Capabilities -====================== - -NuttX supports the following RP2040 capabilities: - -* UART (console port) - - * GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are used for the console. - -* I2C -* SPI (master only) -* DMAC -* PWM -* ADC -* Watchdog -* USB device - - * MSC, CDC/ACM serial and these composite device are supported. - * CDC/ACM serial device can be used for the console. - -* PIO (RP2040 Programmable I/O) -* Flash ROM Boot -* SRAM Boot - - * If Pico SDK is available, nuttx.uf2 file which can be used in BOOTSEL mode will be created. - -* Persistent flash filesystem in unused flash ROM -* WiFi wireless communication - -There is currently no direct user mode access to these RP2040 hardware features: - -* SPI Slave Mode -* SSI -* RTC -* Timers - -NuttX also provide support for these external devices: - -* BMP180 sensor at I2C0 (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* INA219 sensor / module (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* SHT4X sensor at I2C0 -* WS2812 smart pixel support - -Installation -============ - -1. Download Raspberry Pi Pico SDK - -.. code-block:: console - - $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git +if connected. The schematic is available at `RP2040-LCD-1.28-sch.pdf +<https://www.waveshare.net/w/upload/6/60/RP2040-LCD-1.28-sch.pdf>`_ -2. Download and install picotool +Installation & Build +==================== - Instructions can be found here: https://github.com/raspberrypi/picotool +For instructions on how to to install the build dependencies and create a NuttX +image for this board, consult the main :doc:`RP2040 documentation +<../../index>`. - If you are on Arch Linux, you can install the picotool through the AUR: - -.. code-block:: console - - $ yay -S picotool - -3. Set PICO_SDK_PATH environment variable - -.. code-block:: console - - $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> - -4. Configure and build NuttX - -.. code-block:: console - - $ git clone https://github.com/apache/nuttx.git nuttx - $ git clone https://github.com/apache/nuttx-apps.git apps - $ cd nuttx - $ make distclean - $ ./tools/configure.sh waveshare-rp2040-lcd-1.28:nsh - $ make V=1 +Configurations +============== -5. Connect the Waveshare RP2040 board to USB port while pressing BOOT. - The board will be detected as USB Mass Storage Device. - Then copy "nuttx.uf2" into the device. - (Same manner as the standard Pico SDK applications installation.) +All configurations listed below can be configured using the following command in +the ``nuttx`` directory (again, consult the main :doc:`RP2040 documentation +<../../index>`): -6. To access the console, GPIO 0 and 1 pins must be connected to the - device such as USB-serial converter. +.. code:: console - `usbnsh` configuration provides the console access by USB CDC/ACM serial - decive. The console is available by using a terminal software on the USB - host. - -Configurations -============== + $ ./tools/configure.sh waveshare-rp2040-lcd-1.28:<configname> composite --------- @@ -252,25 +169,3 @@ lvgl NuttShell configuration (console enabled in USB Port, at 115200 bps) with support for gc9a01 and LVGL demo (using lcd_dev). - -License exceptions -================== - -The following files are originated from the files in Pico SDK. -So, the files are licensed under 3-Clause BSD same as Pico SDK. - -* arch/arm/src/rp2040/rp2040_clock.c -* arch/arm/src/rp2040/rp2040_pll.c -* arch/arm/src/rp2040/rp2040_xosc.c - - * These are created by referring the Pico SDK clock initialization. - -* arch/arm/src/rp2040/rp2040_pio.c -* arch/arm/src/rp2040/rp2040_pio.h -* arch/arm/src/rp2040/rp2040_pio_instructions.h - - * These provide the similar APIs to Pico SDK's hardware_pio APIs. - -* arch/arm/src/rp2040/hardware/\*.h - - * These are generated from rp2040.svd originally provided in Pico SDK. diff --git a/Documentation/platforms/arm/rp2040/boards/waveshare-rp2040-zero/index.rst b/Documentation/platforms/arm/rp2040/boards/waveshare-rp2040-zero/index.rst index a7c924cae6..e2d3ae60d2 100644 --- a/Documentation/platforms/arm/rp2040/boards/waveshare-rp2040-zero/index.rst +++ b/Documentation/platforms/arm/rp2040/boards/waveshare-rp2040-zero/index.rst @@ -27,14 +27,6 @@ Features * Accelerated floating point libraries on-chip * 8 × Programmable IO (PIO) state machines for custom peripheral support -Serial Console -============== - -By default a serial console appears on pins 23 (TX GPIO0) and pin 22 -(RX GPIO1). This console runs a 115200-8N1. - -The board can be configured to use the USB connection as the serial console. - Buttons and LEDs ================ @@ -88,108 +80,23 @@ or by supplying +5V to pin 1. The RP2040 runs on 3.3 volts. This is supplied by an onboard voltage regulator. -Supported Capabilities -====================== - -NuttX supports the following RP2040 capabilities: - -* UART (console port) - - * GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are used for the console. - -* I2C -* SPI (master only) -* DMAC -* PWM -* ADC -* Watchdog -* USB device - - * MSC, CDC/ACM serial and these composite device are supported. - * CDC/ACM serial device can be used for the console. - -* PIO (RP2040 Programmable I/O) -* Flash ROM Boot -* SRAM Boot - - * If Pico SDK is available, nuttx.uf2 file which can be used in BOOTSEL mode will be created. - -* Persistent flash filesystem in unused flash ROM -* WiFi wireless communication - -There is currently no direct user mode access to these RP2040 hardware features: - -* SPI Slave Mode -* SSI -* RTC -* Timers - -NuttX also provide support for these external devices: - -* BMP180 sensor at I2C0 (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* INA219 sensor / module (don't forget to define I2C0 GPIOs at "I2C0 GPIO pin assign" in Board Selection menu) -* SHT4X sensor at I2C0 -* Pico Display Pack (ST7789 LCD) - - * RGB leds and buttons are not supported yet. - -* Pico Audio Pack (PCM5100A I2S DAC) - - * I2S interface is realized by PIO. - -* WS2812 smart pixel support - -Installation -============ - -1. Download Raspberry Pi Pico SDK - -.. code-block:: console +Installation & Build +==================== - $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git +For instructions on how to to install the build dependencies and create a NuttX +image for this board, consult the main :doc:`RP2040 documentation +<../../index>`. -2. Download and install picotool - - Instructions can be found here: https://github.com/raspberrypi/picotool - - If you are on Arch Linux, you can install the picotool through the AUR: - -.. code-block:: console - - $ yay -S picotool - -3. Set PICO_SDK_PATH environment variable - -.. code-block:: console - - $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> - -4. Configure and build NuttX - -.. code-block:: console - - $ git clone https://github.com/apache/nuttx.git nuttx - $ git clone https://github.com/apache/nuttx-apps.git apps - $ cd nuttx - $ make distclean - $ ./tools/configure.sh waveshare-rp2040-zero:nsh - $ make V=1 - -5. Connect Raspberry Pi Pico board to USB port while pressing BOOTSEL. - The board will be detected as USB Mass Storage Device. - Then copy "nuttx.uf2" into the device. - (Same manner as the standard Pico SDK applications installation.) - -6. To access the console, GPIO 0 and 1 pins must be connected to the - device such as USB-serial converter. +Configurations +============== - `usbnsh` configuration provides the console access by USB CDC/ACM serial - device. The console is available by using a terminal software on the USB - host. +All configurations listed below can be configured using the following command in +the ``nuttx`` directory (again, consult the main :doc:`RP2040 documentation +<../../index>`): +.. code:: console -Configurations -============== + $ ./tools/configure.sh waveshare-rp2040-zero:<configname> gpio -------- @@ -212,25 +119,3 @@ ws2812 ------ Basic NuttShell configuration with WS2812 driver and example enabled. Console is enabled over USB at 115200 bps. - -License exceptions -================== - -The following files are originated from the files in Pico SDK. -So, the files are licensed under 3-Clause BSD same as Pico SDK. - -* arch/arm/src/rp2040/rp2040_clock.c -* arch/arm/src/rp2040/rp2040_pll.c -* arch/arm/src/rp2040/rp2040_xosc.c - - * These are created by referring the Pico SDK clock initialization. - -* arch/arm/src/rp2040/rp2040_pio.c -* arch/arm/src/rp2040/rp2040_pio.h -* arch/arm/src/rp2040/rp2040_pio_instructions.h - - * These provide the similar APIs to Pico SDK's hardware_pio APIs. - -* arch/arm/src/rp2040/hardware/\*.h - - * These are generated from rp2040.svd originally provided in Pico SDK. diff --git a/Documentation/platforms/arm/rp2040/index.rst b/Documentation/platforms/arm/rp2040/index.rst index ef86cfd106..efd0b97738 100644 --- a/Documentation/platforms/arm/rp2040/index.rst +++ b/Documentation/platforms/arm/rp2040/index.rst @@ -4,19 +4,23 @@ RaspberryPi rp2040 .. tags:: chip:rp2040 -The rp2040 is a dual core chip produced by the RaspberryPi Foundation that +.. figure:: rp2040.png + :align: center + :scale: 50 % + +The RP2040 is a dual core chip produced by the RaspberryPi Foundation that is based on ARM Cortex-M0+. Peripheral Support ================== -The following list indicates peripherals currently supported in NuttX: +The following list indicates RP2040 peripherals currently supported in NuttX: ============== ===== Peripheral Notes ============== ===== GPIO See Supported Boards documentation for available pins. -UART GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are used for the console. +UART GPIO 0 (UART0 TX) and GPIO 1 (UART0 RX) are often used for the console. I2C SPI DMAC @@ -36,47 +40,101 @@ INA219 Requires I2C0 The Pico Display Pack (ST7789 LCD) and Pico Audio Pack (PCM5100A I2S DAC) are also available. +There is currently no direct user mode access to these RP2040 hardware features: + +* SPI Slave Mode +* SSI +* RTC +* Timers + +Additionally, some supported features are: + +* Persistent flash filesystem in unused flash ROM +* WiFi wireless communication (for capable boards such as :doc:`the Pico W + <boards/raspberrypi-pico-w/index>`) + Installation ============ -1. Download Raspberry Pi Pico SDK: +1. Download the Raspberry Pi Pico SDK: + + .. code:: console + + $ git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git + +2. Download and install the ``picotool`` + + Instructions for installing/building it can be found here: + https://github.com/raspberrypi/picotool + + If you are on Arch Linux, you can also install the ``picotool`` through the + AUR: + + .. code-block:: console - git clone -b 2.0.0 https://github.com/raspberrypi/pico-sdk.git + $ yay -S picotool -2. Set PICO_SDK_PATH environment variable:: +3. Set ``PICO_SDK_PATH`` environment variable to point to the cloned SDK: - export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> + .. code:: console -3. Download NuttX and the companion applications. These must both be - contained in the same directory:: + $ export PICO_SDK_PATH=<absolute_path_to_pico-sdk_directory> + + You will have to do this every time you restart the terminal where you are + building NuttX, so it might be best to include this command in your + ``bashrc`` so NuttX's build system always knows where to find the SDK. + +4. Download NuttX and NuttX applications. These must both be contained in the + same directory: + + .. code:: console - git clone https://github.com/apache/nuttx.git nuttx - git clone https://github.com/apache/nuttx-apps.git apps + $ git clone https://github.com/apache/nuttx.git nuttx + $ git clone https://github.com/apache/nuttx-apps.git apps + +Now you have all of the required dependencies for building NuttX for the RP2040. Building NuttX ============== -1. Change to NuttX directory:: +1. Change to the NuttX directory: + + .. code:: console + + $ cd nuttx + +2. Select a configuration. The available configurations can be listed with the + command: + + .. code:: console + + $ ./tools/configure.sh -L + + The one you choose will be dependent on the board you want to build for, like + ``raspberrypi-pico:usbnsh`` to use the ``usbnsh`` configuration for the + :doc:`Raspberry Pi Pico <boards/raspberrypi-pico/index>`. - cd nuttx +3. Load the selected configuration: -2. Select a configuration. The available configurations - can be listed with the command:: + .. code:: console - ./tools/configure.sh -L + $ make distclean + $ ./tools/configure.sh <selected_configuration> -3. Load the selected configuration.:: +4. Modify the configuration as needed (optional): - make distclean - ./tools/configure.sh <selected_configuration> + .. code:: console -4. Modify the configuration as needed (optional):: + $ make menuconfig - make menuconfig +5. Build NuttX: -5. Build NuttX:: + .. code:: console - make + $ make + +The output of the build process will be a file called ``nuttx.uf2``, which you +are able to flash to the RP2040. Programming ============ @@ -84,26 +142,56 @@ Programming Programming using BOOTSEL ------------------------- -Connect board to USB port while pressing BOOTSEL. -The board will be detected as USB Mass Storage Device. -Then copy "nuttx.uf2" into the device. -(Same manner as the standard Pico SDK applications installation.) +Connect the board to the USB port of your host computer while pressing down the +BOOTSEL button. + +.. note:: + + Some boards call it a different name, and some boards use pins that need to + be jumpered instead of buttons. Consult the documentation for your particular + board. + +.. note:: + + If your board comes with a BOOTSEL and a RESET button, you might find it + easier to hold down the BOOTSEL button and then press RESET, all while the + board is still plugged in via USB. This will trigger the boot mode without + having to constantly unplug and plug in the USB cable. + +The board should be detected as USB Mass Storage Device, which you can mount in +your file explorer just like a USB drive. + +Then copy ``nuttx.uf2`` onto the device. It should reboot itself into NuttX once +the UF2 file is done copying over! Programming using SDB --------------------- -Most (but no all) RP2040 boards provide a serial (SDB) debug port. -The "nuttx" ELF file can be uploaded with an appropriate SDB programmer -module and companion software. +Most (but not all) RP2040 boards provide a serial (SDB) debug port. The "nuttx" +ELF file can be uploaded with an appropriate SDB programmer module and companion +software. Running NuttX ============= -Most builds provide access to the console via UART0. To access this -GPIO 0 and 1 pins must be connected to the device such as USB-serial converter. +The ``usbnsh`` configuration that most supported boards provide allows console +access by USB CDC/ACM serial device. The console is available by using a +terminal software on your host computer with the device plugged in. Some +options are: + +* PuTTY +* Minicom +* Picocom + +Many configurations may also provide access to the console via UART0. To access +this console from your host computer, GPIO 0 and 1 pins on your board must be +connected to a `USB-serial converter <https://www.adafruit.com/product/954>`_ +(and typically the GND pin as well), which is plugged into your computer. You +can then use your terminal software just like with ``usbnsh``. + +.. note:: -The `usbnsh` configuration provides the console access by USB CDC/ACM serial -devcice. The console is available by using a terminal software on the USB host. + Most configurations will run the console at 115200 baud. Supported Boards ================ @@ -114,3 +202,25 @@ Supported Boards boards/*/* + +License exceptions +================== + +The following files are originated from the files in Pico SDK. +So, the files are licensed under 3-Clause BSD same as Pico SDK. + +* ``arch/arm/src/rp2040/rp2040_clock.c`` +* ``arch/arm/src/rp2040/rp2040_pll.c`` +* ``arch/arm/src/rp2040/rp2040_xosc.c`` + + * These are created by referring the Pico SDK clock initialization. + +* ``arch/arm/src/rp2040/rp2040_pio.c`` +* ``arch/arm/src/rp2040/rp2040_pio.h`` +* ``arch/arm/src/rp2040/rp2040_pio_instructions.h`` + + * These provide the similar APIs to Pico SDK's hardware_pio APIs. + +* ``arch/arm/src/rp2040/hardware/\*.h`` + + * These are generated from rp2040.svd originally provided in Pico SDK. diff --git a/Documentation/platforms/arm/rp2040/rp2040.png b/Documentation/platforms/arm/rp2040/rp2040.png new file mode 100644 index 0000000000..5ea3fa4267 Binary files /dev/null and b/Documentation/platforms/arm/rp2040/rp2040.png differ