1# cyw43 shared bus read and write
2pico_add_library(cybt_shared_bus NOFLAG)
3
4target_sources(cybt_shared_bus INTERFACE
5    ${CMAKE_CURRENT_LIST_DIR}/cybt_shared_bus.c
6    ${CMAKE_CURRENT_LIST_DIR}/cybt_shared_bus_driver.c
7)
8target_include_directories(cybt_shared_bus_headers SYSTEM INTERFACE
9    ${CMAKE_CURRENT_LIST_DIR}
10)
11
12# The BT firmware is supplied as a source file containing a static array with ascii hex data
13# Set this to true to use this for testing
14set(CYW43_USE_HEX_BTFW 0)
15if (CYW43_USE_HEX_BTFW)
16    message("Warning: CYW43_USE_HEX_BTFW is true")
17    target_sources(cybt_shared_bus INTERFACE
18        ${PICO_CYW43_DRIVER_PATH}/firmware/cybt_firmware_43439.c
19    )
20    target_compile_definitions(cybt_shared_bus INTERFACE
21        CYW43_USE_HEX_BTFW=1
22    )
23endif()