mirror of
https://github.com/hathach/tinyusb.git
synced 2025-01-17 05:32:55 +08:00
move pio-usb init to family_configure_pio_usb_example() to stay compatible
This commit is contained in:
parent
993f7b6a2c
commit
717a474125
@ -27,3 +27,4 @@ target_include_directories(${PROJECT} PUBLIC
|
||||
# in hw/bsp/FAMILY/family.cmake for details.
|
||||
family_configure_device_example(${PROJECT})
|
||||
family_configure_host_example(${PROJECT})
|
||||
family_configure_pio_usb_example(${PROJECT})
|
||||
|
@ -24,4 +24,7 @@ target_include_directories(${PROJECT} PUBLIC
|
||||
|
||||
# Configure compilation flags and libraries for the example... see the corresponding function
|
||||
# in hw/bsp/FAMILY/family.cmake for details.
|
||||
family_configure_host_example(${PROJECT})
|
||||
family_configure_host_example(${PROJECT})
|
||||
|
||||
# For rp2040, un-comment to enable pico-pio-usb
|
||||
# family_configure_pio_usb_example(${PROJECT})
|
||||
|
@ -27,3 +27,6 @@ target_include_directories(${PROJECT} PUBLIC
|
||||
# Configure compilation flags and libraries for the example... see the corresponding function
|
||||
# in hw/bsp/FAMILY/family.cmake for details.
|
||||
family_configure_host_example(${PROJECT})
|
||||
|
||||
# For rp2040, un-comment to enable pico-pio-usb
|
||||
# family_configure_pio_usb_example(${PROJECT})
|
||||
|
@ -25,4 +25,7 @@ target_include_directories(${PROJECT} PUBLIC
|
||||
|
||||
# Configure compilation flags and libraries for the example... see the corresponding function
|
||||
# in hw/bsp/FAMILY/family.cmake for details.
|
||||
family_configure_host_example(${PROJECT})
|
||||
family_configure_host_example(${PROJECT})
|
||||
|
||||
# For rp2040, un-comment to enable pico-pio-usb
|
||||
# family_configure_pio_usb_example(${PROJECT})
|
||||
|
@ -177,12 +177,19 @@ if (NOT TARGET _rp2040_family_inclusion_marker)
|
||||
|
||||
function(family_configure_device_example TARGET)
|
||||
family_configure_target(${TARGET})
|
||||
target_link_libraries(${TARGET} PUBLIC pico_stdlib tinyusb_device tinyusb_pio_usb_base)
|
||||
target_link_libraries(${TARGET} PUBLIC pico_stdlib tinyusb_device)
|
||||
endfunction()
|
||||
|
||||
function(family_configure_host_example TARGET)
|
||||
family_configure_target(${TARGET})
|
||||
target_link_libraries(${TARGET} PUBLIC pico_stdlib tinyusb_host tinyusb_pio_usb_base)
|
||||
target_link_libraries(${TARGET} PUBLIC pico_stdlib tinyusb_host)
|
||||
endfunction()
|
||||
|
||||
function(family_configure_pio_usb_example TARGET)
|
||||
family_configure_target(${TARGET})
|
||||
target_link_libraries(${TARGET} PUBLIC pico_stdlib tinyusb_pio_usb_base)
|
||||
pico_generate_pio_header(tinyusb_common_base ${TOP}/lib/Pico-PIO-USB/src/usb_tx.pio)
|
||||
pico_generate_pio_header(tinyusb_common_base ${TOP}/lib/Pico-PIO-USB/src/usb_rx.pio)
|
||||
endfunction()
|
||||
|
||||
function(family_initialize_project PROJECT DIR)
|
||||
@ -190,8 +197,6 @@ if (NOT TARGET _rp2040_family_inclusion_marker)
|
||||
_family_initialize_project(${PROJECT} ${DIR})
|
||||
enable_language(C CXX ASM)
|
||||
pico_sdk_init()
|
||||
pico_generate_pio_header(tinyusb_common_base ${TOP}/lib/Pico-PIO-USB/src/usb_tx.pio)
|
||||
pico_generate_pio_header(tinyusb_common_base ${TOP}/lib/Pico-PIO-USB/src/usb_rx.pio)
|
||||
endfunction()
|
||||
|
||||
# This method must be called from the project scope to suppress known warnings in TinyUSB source files
|
||||
|
Loading…
x
Reference in New Issue
Block a user