From 0c973a5c7c9e7b7c11bc451fa1ddd8d21dc4cb70 Mon Sep 17 00:00:00 2001 From: Fortinbra Date: Tue, 1 Oct 2024 16:29:31 -0500 Subject: [PATCH 1/5] Updating pico build version --- .github/workflows/cmake.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index abbd1a63c..db5eb530f 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -34,7 +34,7 @@ jobs: fetch-tags: true - name: Setup SDK pipeline - uses: Fortinbra/RaspberryPiPicoBuild@v3 + uses: Fortinbra/RaspberryPiPicoBuild@v4 - name: Download a Build Artifact uses: actions/download-artifact@v4.1.2 From 4883070595fa8506f23a913e2c330730179cefc1 Mon Sep 17 00:00:00 2001 From: Fortinbra Date: Tue, 1 Oct 2024 16:36:39 -0500 Subject: [PATCH 2/5] Updating Pio_USB --- lib/pico_pio_usb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/pico_pio_usb b/lib/pico_pio_usb index 0f747aaa0..528616d80 160000 --- a/lib/pico_pio_usb +++ b/lib/pico_pio_usb @@ -1 +1 @@ -Subproject commit 0f747aaa0c16f750bdfa2ba37ec25d6c8e1bc117 +Subproject commit 528616d809ad3a400dc0cf4dab0f790e62944244 From 7fbbc33b92631db5dec1067c6304fe256060de5b Mon Sep 17 00:00:00 2001 From: Fortinbra Date: Fri, 4 Oct 2024 20:06:35 -0500 Subject: [PATCH 3/5] Enabling Pico VSCode Extension. --- CMakeLists.txt | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 3f77f7408..6eb6dea45 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,15 +1,27 @@ +# == DO NEVER EDIT THE NEXT LINES for Raspberry Pi Pico VS Code Extension to work == +if(WIN32) + set(USERHOME $ENV{USERPROFILE}) +else() + set(USERHOME $ENV{HOME}) +endif() +set(sdkVersion 2.0.0) +set(toolchainVersion 13_2_Rel1) +set(picotoolVersion 2.0.0) +set(picoVscode ${USERHOME}/.pico-sdk/cmake/pico-vscode.cmake) +if (EXISTS ${picoVscode}) + include(${picoVscode}) +endif() +# ==================================================================================== + cmake_minimum_required(VERSION 3.13) include(CMakePrintHelpers) - - - # initialize the SDK based on PICO_SDK_PATH # note: this must happen before project() include(pico_sdk_import.cmake) -if (PICO_SDK_VERSION_STRING VERSION_LESS "1.5.0") - message(FATAL_ERROR "Raspberry Pi Pico SDK version 1.5.0 (or later) required. Your version is ${PICO_SDK_VERSION_STRING}") +if (PICO_SDK_VERSION_STRING VERSION_LESS "2.0.0") + message(FATAL_ERROR "Raspberry Pi Pico SDK version 2.0.0 (or later) required. Your version is ${PICO_SDK_VERSION_STRING}") endif() # set the version for webconfig, etc. based on git From 1167bc2f023ce35d2bf258b70cf888e7b5d8cd43 Mon Sep 17 00:00:00 2001 From: Fortinbra Date: Fri, 4 Oct 2024 20:09:51 -0500 Subject: [PATCH 4/5] Updating Pio_USB --- lib/pico_pio_usb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/pico_pio_usb b/lib/pico_pio_usb index 528616d80..fe9133fc5 160000 --- a/lib/pico_pio_usb +++ b/lib/pico_pio_usb @@ -1 +1 @@ -Subproject commit 528616d809ad3a400dc0cf4dab0f790e62944244 +Subproject commit fe9133fc513b82cc3dc62c67cb51f2339cf29ef7 From 2d16215ac1ab7de2bda43514ae102227072b2308 Mon Sep 17 00:00:00 2001 From: Fortinbra Date: Fri, 4 Oct 2024 20:30:17 -0500 Subject: [PATCH 5/5] More updates --- .gitignore | 1 + lib/NeoPico/src/generated/ws2812.pio.h | 10 ++++++++++ pico_sdk_import.cmake | 15 +++++++++++++-- 3 files changed, 24 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index db45ca04d..0f485cc82 100644 --- a/.gitignore +++ b/.gitignore @@ -18,3 +18,4 @@ env.ini .devcontainer *Dockerfile *docker-compose.yml +lib/NeoPico/src/generated/ws2812.pio.h diff --git a/lib/NeoPico/src/generated/ws2812.pio.h b/lib/NeoPico/src/generated/ws2812.pio.h index 8cbeea6b7..4a564101f 100644 --- a/lib/NeoPico/src/generated/ws2812.pio.h +++ b/lib/NeoPico/src/generated/ws2812.pio.h @@ -14,6 +14,7 @@ #define ws2812_wrap_target 0 #define ws2812_wrap 3 +#define ws2812_pio_version 0 #define ws2812_T1 2 #define ws2812_T2 5 @@ -33,6 +34,10 @@ static const struct pio_program ws2812_program = { .instructions = ws2812_program_instructions, .length = 4, .origin = -1, + .pio_version = 0, +#if PICO_PIO_VERSION > 0 + .used_gpio_ranges = 0x0 +#endif }; static inline pio_sm_config ws2812_program_get_default_config(uint offset) { @@ -65,6 +70,7 @@ static inline void ws2812_program_init(PIO pio, uint sm, uint offset, uint pin, #define ws2812_parallel_wrap_target 0 #define ws2812_parallel_wrap 3 +#define ws2812_parallel_pio_version 0 #define ws2812_parallel_T1 2 #define ws2812_parallel_T2 5 @@ -84,6 +90,10 @@ static const struct pio_program ws2812_parallel_program = { .instructions = ws2812_parallel_program_instructions, .length = 4, .origin = -1, + .pio_version = 0, +#if PICO_PIO_VERSION > 0 + .used_gpio_ranges = 0x0 +#endif }; static inline pio_sm_config ws2812_parallel_program_get_default_config(uint offset) { diff --git a/pico_sdk_import.cmake b/pico_sdk_import.cmake index 65f8a6f7d..a0721d0d1 100644 --- a/pico_sdk_import.cmake +++ b/pico_sdk_import.cmake @@ -18,9 +18,20 @@ if (DEFINED ENV{PICO_SDK_FETCH_FROM_GIT_PATH} AND (NOT PICO_SDK_FETCH_FROM_GIT_P message("Using PICO_SDK_FETCH_FROM_GIT_PATH from environment ('${PICO_SDK_FETCH_FROM_GIT_PATH}')") endif () +if (DEFINED ENV{PICO_SDK_FETCH_FROM_GIT_TAG} AND (NOT PICO_SDK_FETCH_FROM_GIT_TAG)) + set(PICO_SDK_FETCH_FROM_GIT_TAG $ENV{PICO_SDK_FETCH_FROM_GIT_TAG}) + message("Using PICO_SDK_FETCH_FROM_GIT_TAG from environment ('${PICO_SDK_FETCH_FROM_GIT_TAG}')") +endif () + +if (PICO_SDK_FETCH_FROM_GIT AND NOT PICO_SDK_FETCH_FROM_GIT_TAG) + set(PICO_SDK_FETCH_FROM_GIT_TAG "master") + message("Using master as default value for PICO_SDK_FETCH_FROM_GIT_TAG") +endif() + set(PICO_SDK_PATH "${PICO_SDK_PATH}" CACHE PATH "Path to the Raspberry Pi Pico SDK") set(PICO_SDK_FETCH_FROM_GIT "${PICO_SDK_FETCH_FROM_GIT}" CACHE BOOL "Set to ON to fetch copy of SDK from git if not otherwise locatable") set(PICO_SDK_FETCH_FROM_GIT_PATH "${PICO_SDK_FETCH_FROM_GIT_PATH}" CACHE FILEPATH "location to download SDK") +set(PICO_SDK_FETCH_FROM_GIT_TAG "${PICO_SDK_FETCH_FROM_GIT_TAG}" CACHE FILEPATH "release tag for SDK") if (NOT PICO_SDK_PATH) if (PICO_SDK_FETCH_FROM_GIT) @@ -34,14 +45,14 @@ if (NOT PICO_SDK_PATH) FetchContent_Declare( pico_sdk GIT_REPOSITORY https://github.com/raspberrypi/pico-sdk - GIT_TAG master + GIT_TAG ${PICO_SDK_FETCH_FROM_GIT_TAG} GIT_SUBMODULES_RECURSE FALSE ) else () FetchContent_Declare( pico_sdk GIT_REPOSITORY https://github.com/raspberrypi/pico-sdk - GIT_TAG master + GIT_TAG ${PICO_SDK_FETCH_FROM_GIT_TAG} ) endif ()