Skip to content

Commit 4586d8f

Browse files
committed
add upstream Pico-PIO-USB
1 parent be2a513 commit 4586d8f

File tree

4 files changed

+16
-8
lines changed

4 files changed

+16
-8
lines changed

.github/workflows/build_arm.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ jobs:
8282
run: |
8383
git clone --depth 1 -b develop https://github.com/raspberrypi/pico-sdk ~/pico-sdk
8484
echo >> $GITHUB_ENV PICO_SDK_PATH=~/pico-sdk
85-
git submodule update --init lib/Pico-PIO-USB
85+
git submodule update --init hw/mcu/raspberry_pi/Pico-PIO-USB
8686
8787
- name: Set Toolchain URL
8888
run: echo >> $GITHUB_ENV TOOLCHAIN_URL=https://github.com/xpack-dev-tools/arm-none-eabi-gcc-xpack/releases/download/v10.2.1-1.1/xpack-arm-none-eabi-gcc-10.2.1-1.1-linux-x64.tar.gz

.gitmodules

+3
Original file line numberDiff line numberDiff line change
@@ -146,3 +146,6 @@
146146
[submodule "hw/mcu/allwinner"]
147147
path = hw/mcu/allwinner
148148
url = https://github.com/hathach/allwinner_driver.git
149+
[submodule "hw/mcu/raspberry_pi/Pico-PIO-USB"]
150+
path = hw/mcu/raspberry_pi/Pico-PIO-USB
151+
url = https://github.com/sekigon-gonnoc/Pico-PIO-USB.git

hw/bsp/rp2040/family.cmake

+11-7
Original file line numberDiff line numberDiff line change
@@ -63,15 +63,19 @@ if (NOT TARGET _rp2040_family_inclusion_marker)
6363
#------------------------------------
6464
add_library(pico_pio_usb INTERFACE)
6565

66+
if (NOT DEFINED PICO_PIO_USB_PATH)
67+
set(PICO_PIO_USB_PATH "${TOP}/hw/mcu/raspberry_pi/Pico-PIO-USB")
68+
endif()
69+
6670
target_sources(pico_pio_usb INTERFACE
67-
${TOP}/lib/Pico-PIO-USB/src/pio_usb.c
68-
${TOP}/lib/Pico-PIO-USB/src/pio_usb_host.c
69-
${TOP}/lib/Pico-PIO-USB/src/pio_usb_device.c
70-
${TOP}/lib/Pico-PIO-USB/src/usb_crc.c
71+
${PICO_PIO_USB_PATH}/src/pio_usb.c
72+
${PICO_PIO_USB_PATH}/src/pio_usb_host.c
73+
${PICO_PIO_USB_PATH}/src/pio_usb_device.c
74+
${PICO_PIO_USB_PATH}/src/usb_crc.c
7175
)
7276

7377
target_include_directories(pico_pio_usb INTERFACE
74-
${TOP}/lib/Pico-PIO-USB/src
78+
${PICO_PIO_USB_PATH}/src
7579
)
7680

7781
target_link_libraries(pico_pio_usb INTERFACE
@@ -188,8 +192,8 @@ if (NOT TARGET _rp2040_family_inclusion_marker)
188192
function(family_configure_pico_pio_usb_example TARGET)
189193
family_configure_target(${TARGET})
190194
target_link_libraries(${TARGET} PUBLIC pico_stdlib pico_pio_usb)
191-
pico_generate_pio_header(tinyusb_common_base ${TOP}/lib/Pico-PIO-USB/src/usb_tx.pio)
192-
pico_generate_pio_header(tinyusb_common_base ${TOP}/lib/Pico-PIO-USB/src/usb_rx.pio)
195+
pico_generate_pio_header(tinyusb_common_base ${PICO_PIO_USB_PATH}/src/usb_tx.pio)
196+
pico_generate_pio_header(tinyusb_common_base ${PICO_PIO_USB_PATH}/src/usb_rx.pio)
193197
endfunction()
194198

195199
function(family_initialize_project PROJECT DIR)

hw/mcu/raspberry_pi/Pico-PIO-USB

Submodule Pico-PIO-USB added at 2a9fefd

0 commit comments

Comments
 (0)