Skip to content

Update to Pico SDK 2.2.0 #14

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 227 commits into
base: zephyr
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
227 commits
Select commit Hold shift + click to select a range
bb916f4
start 2.1.1-develop
kilograham Nov 25, 2024
f0a1ff3
Fixes for/found by documentation generation (#2099)
kilograham Nov 25, 2024
fe81780
Update btstack license. (#2115)
peterharperuk Dec 1, 2024
54784f8
Add rom_data_lookup_inline function (#2116)
will-v-pi Dec 2, 2024
ba7aa3f
Fix mis-matched backticks in doxygen (#2104)
lurch Dec 4, 2024
969f589
ta_set_timeout can fail to set an alarm (#2127)
peterharperuk Dec 6, 2024
e7a0e61
convert windows path delimiter to posix (#2149) (#2150)
jjonethal Jan 7, 2025
7bd430d
Fix RP02040 typos (#2168)
lurch Jan 11, 2025
1b80db2
Restore the "API Documentation" link in sidebar when building with Do…
lurch Jan 11, 2025
fc37bed
Fix Doxygen comment (#2175)
karaketir16 Jan 11, 2025
5202c27
Initialise stack in async_context_execute_sync call (#2106)
peterharperuk Jan 11, 2025
306c461
Fix: solve the problem that micropython could not be used (#2098)
Lesords Jan 11, 2025
4b6e647
Update Clang toolchain used by Bazel (#2151)
petrhosek Jan 13, 2025
61e2712
Added some weveshare board support (#2145)
waveshare Jan 18, 2025
b8dc8c4
Fix ta_wakes_up_on_or_before (#2190)
peterharperuk Jan 20, 2025
5022582
Fix brief #2196 (#2197)
ArkinSolomon Jan 20, 2025
863f544
Follow-up to #1795 (#2177)
gneverov Jan 20, 2025
09482ed
Disable irq before removing handler in cyw43_irq_deinit (#2185)
gazzyt Jan 20, 2025
73d007f
Update cyw43 driver. (#2199)
peterharperuk Jan 20, 2025
c54475d
Remove deprecated uses of FetchContent_Populate (#2169)
will-v-pi Jan 20, 2025
a62d17c
Add PASSED/FAILED output to cmsis_test.c
kilograham Jan 26, 2025
f20663c
Fix pico_divider_nesting_test.c on RP2350 - was broken due to running…
kilograham Jan 26, 2025
9f95a46
fix pico_time_test.c compile on native (#2207)
kilograham Jan 29, 2025
3ba9534
update tinyusb to 0.18 (#2215)
rgrr Jan 29, 2025
524716f
Fix unreliable writes to cyw43. (#2209)
peterharperuk Jan 29, 2025
700f861
Update btstack 1.6.2 (#2202)
peterharperuk Jan 29, 2025
d1a1c9f
Support multiple .pio file in pico_generate_pio_header (#2188)
RigoLigoRLC Jan 29, 2025
25069f5
btstack: configure incoming pre-buffer for cyw43 driver (#2165)
mringwal Jan 29, 2025
3d746b3
Add SparkFun IoT Node LoRaWAN board (#2143)
sfe-SparkFro Jan 29, 2025
6c06f90
Release the lock in mbedtls_sha256_free if it was not released alread…
nilswiersma Jan 31, 2025
d7f6582
Declare platform.h functions with C linkage (#2218)
rhulme Feb 2, 2025
0c2de5d
Eat PATH argument to pico_generate_pio_header which was ignored befor…
kilograham Feb 3, 2025
ccbd07c
add extra assertions to pio.h (#2211)
kilograham Feb 3, 2025
5288585
add multicore_lockout_victim_deinit. clear lockedout_flag for core1 d…
kilograham Feb 3, 2025
0d90992
clarify clock_configure and make it return the correct value achieved…
kilograham Feb 4, 2025
b51fa1b
Mark flash_devinfo_ptr() as RAM code to avoid flash call during flash…
Wren6991 Feb 4, 2025
7d450bf
add a bunch of verbosity around shared vtables (#2230)
kilograham Feb 4, 2025
e85c3e5
rationalize pico_float/pico_double libraries (#2208)
kilograham Feb 4, 2025
eb5c2c3
Clang related fixes (#2231)
kilograham Feb 5, 2025
111fa7d
small pioasm improvements (#2224)
kilograham Feb 5, 2025
7dfbb3c
Add a delay after rtc_set_datetime (#2156)
peterharperuk Feb 6, 2025
1ee91e1
Add license to pico_sdk_import.cmake (#2239)
kilograham Feb 7, 2025
876c09c
pico_flash: Support FreeRTOS Static Allocation (#2229)
SConaway Feb 7, 2025
396aa06
Fix Windows CI (#2241)
will-v-pi Feb 7, 2025
05dbc11
update stdio_usb CDC constants to the defaults used by TinyUSB, and a…
kilograham Feb 7, 2025
f407f5b
boards/adafruit_feather_rp2350.h: add PICO_XOSC_STARTUP_DELAY_MULTIPL…
dhalbert Feb 10, 2025
24c4480
Fix semicolon in makefsdata.py (#2238)
HugoTro Feb 11, 2025
564aa64
minor irq.h comment tweaks
kilograham Feb 12, 2025
de0416a
Minor irq.h comment typos (#2257)
lurch Feb 12, 2025
7c023fa
Increase default PICO_XOSC_STARTUP_DELAY_MULTIPLIER to 6 (ms) (#2245)
kilograham Feb 12, 2025
0ca463a
Fix compilation of pico_double_test on llvm 15 - workaround compiler …
kilograham Feb 12, 2025
e7f8e48
Add clang and host CI builds (#2259)
kilograham Feb 13, 2025
302fd9a
Fix `WAIT GPIO n` for n > 32 and when using gpio_base = 16 (#2265)
kilograham Feb 14, 2025
6989c89
Update Clang toolchain used by Bazel (#2269)
petrhosek Feb 15, 2025
1ca3868
Correct type in comment in CMakeLists.txt (#2274)
d-c-d Feb 16, 2025
f9d65a0
remove reference to hardware_busctrl doxygen group that doesn't exit …
kilograham Feb 16, 2025
04525b8
Fixed linker error for lwIP PPP support (#2272) (#2278)
TheRealZago Feb 16, 2025
c691da8
update previous fix as 1.0 < clkdiv < 2.0 IS supported on RP2350 (#2255)
kilograham Feb 17, 2025
7b96a34
add missing extern C (#2284)
kilograham Feb 17, 2025
59c9211
Add enable_interrupts() and disable_interrupts() (#2276)
kilograham Feb 17, 2025
0ed224c
Add irq_has_handler() and use it to fix GPIO IRQ assert (#2277)
kilograham Feb 17, 2025
6685531
Update README.md (#2289)
d-c-d Feb 17, 2025
38776d8
add missing define
kilograham Feb 18, 2025
7ce1ae8
Comment typo (#2293)
lurch Feb 18, 2025
c757f36
add PICO_USE_FASTEST_SUPPORTED_CLOCK, and support vreg setting and SY…
kilograham Feb 18, 2025
a38da92
add cast (#2298)
kilograham Feb 18, 2025
186e715
fix up access type of CHAN_ABORT register in RP2040.svd and RP2350.sv…
kilograham Feb 18, 2025
2dd58bf
fix emulated asynchronous divisions started via hw_divider_divmod_s32…
kilograham Feb 18, 2025
6a7b4c7
fix warning
kilograham Feb 18, 2025
b5af607
bump SDK version to 2.1.1 and update picotool dependency since 2.1.1 …
kilograham Feb 18, 2025
a994a8a
temporary disable bazel CI check against referened picotool
kilograham Feb 18, 2025
bddd20f
SDK 2.1.1 Release
kilograham Feb 18, 2025
c871e75
start 2.1.2-develop
kilograham Feb 19, 2025
ee68c78
fix doc for SYS_CLK_VREG_VOLTAGE_AUTO_ADJUST_DELAY_US
kilograham Feb 19, 2025
c7ff325
Merge branch 'master' into develop to pick up doc fix
kilograham Feb 19, 2025
26ab4be
Fix misleading error messages in spin_lock.h (#2326)
lurch Mar 3, 2025
dd1f483
Add upcoming sparkfun board (#2329)
SFE-Brudnerd Mar 5, 2025
b1676c1
fix return type of enable/disable interrupt methods... add host versi…
kilograham Mar 9, 2025
ab12d55
Fix use of PICO_RP2040 macro. (#2356)
eightycc Mar 18, 2025
4f31ef1
Add SparkFun XRP Controller header (#2347)
sfe-SparkFro Mar 18, 2025
a45e1e4
Add board file for Eelectronicparts Pico Mini in 2,4,8,16MB variants …
gsboylan Mar 18, 2025
cc1ac39
Remove assignment of cyw43 last_size/header/backplane_window variable…
dpgeorge Mar 18, 2025
3751bc5
Check for the misuse of '#define PICO_RP2350B' in board headers (#2290)
lurch Mar 18, 2025
6a56480
Remove FIXME delete comment (#2341)
d-c-d Mar 18, 2025
6d8588d
Adjust generated name to match pio_mov_status_type (#2324)
KewlKris Mar 18, 2025
26e7dc5
Add Bazel label flag for overriding tusb_config.h (#2264)
mbrase Mar 18, 2025
a995b97
Missed doc change in #850 (#2302)
kilograham Mar 18, 2025
7d0f44b
Fix tools/build_all_headers.py to cope with chip-specific headers (#2…
lurch Mar 18, 2025
ba936d3
pico_lwip_arch is actually what depends on pico_rand (#2303)
kilograham Mar 18, 2025
3241bdc
Fix PICO_PREVIOUS_PLATFORM error (#2357)
will-v-pi Mar 18, 2025
645b33c
Update hellbender_0001.h (#2359)
lurch Mar 19, 2025
005759d
Fix #2253 cybt_printf by wrapping with NDEBUG (#2323)
d-c-d Mar 19, 2025
332eb53
Add new feature defines to pico_stdio_usb (#2296)
mbrase Mar 22, 2025
bbb94e5
Add rom_pick_ab_update_partition function (#2182)
will-v-pi Mar 22, 2025
f81851a
Throw a warning when using the example signing/encryption keys (#2352)
will-v-pi Mar 22, 2025
e43b753
Add new stdio_usb_call_chars_available_callback() function (#2300)
mbrase Mar 22, 2025
fa94f64
Look for PICO_CONFIG: entries in .S files too (#2368)
lurch Mar 24, 2025
39fafaa
Add SPARE_IRQs to the SVD (#2271)
kilograham Mar 25, 2025
a5ba689
Initial commit pulled in a bunch of stuff - see description
will-v-pi Mar 26, 2025
bb5b5f9
Move unique_id (configurably) earlier in the static init process (#2379)
byteit101 Mar 29, 2025
472c781
Fix sign conversion error introduced by #2233 (#2392)
will-v-pi Apr 2, 2025
ac3c458
move irq_has_handler() so it can be used without shared handlers (#2383)
kilograham Apr 3, 2025
f154f58
unclaim alarm on correct timer in ta_disable_irq_handler (#2382)
kilograham Apr 3, 2025
f62bc4f
Properly respect setting PICO_DEFAULT_BINARY_TYPE (#2381)
kilograham Apr 3, 2025
ad0bca9
Fix bug in extract_configs.py (#2389)
lurch Apr 4, 2025
5edf1a0
Fix WindowsCI (again) (#2388)
lurch Apr 4, 2025
c88bd53
Ensure that all RP2350 board-headers explicitly define PICO_RP2350A (…
lurch Apr 4, 2025
701c193
Set default GATT path to CMAKE_CURRENT_LIST_DIR if not specified (#2385)
will-v-pi Apr 4, 2025
5912699
Lots of small doxygen fixes (#2390)
lurch Apr 4, 2025
950a68f
define __force_inline in host compiles (#2396)
kilograham Apr 4, 2025
93ea261
Force inline critical_section_{enter,exit} (#2393)
tannewt Apr 6, 2025
d47c0c8
Update mbedtls, lwip and cyw43-driver (#2405)
peterharperuk Apr 11, 2025
f674850
Fix DST bug in aon_timer_get_time for rp2040 (#2409)
peterharperuk Apr 11, 2025
1721f9d
Add some docs for pico_set_lwip_httpd_content (#2411)
peterharperuk Apr 11, 2025
6fea77f
Change BT flash storage default for rp2350 A2 (#2412)
peterharperuk Apr 11, 2025
1ff6321
Fix #2413 - Misleading comment about bootloader in rp2350/memmap_copy…
d-c-d Apr 11, 2025
5592322
Add --recursive flag to git submodule cmd (#2416)
peterharperuk Apr 12, 2025
fed7188
Rework use of pico_cmake_set in board headers to make it slightly les…
kilograham Apr 14, 2025
65a8907
Make doxygen buildable again (#2423)
lurch Apr 15, 2025
829c067
add word alignment for rtwopi (#2429)
kilograham Apr 21, 2025
8421b45
Revert "Make doxygen buildable again (#2423)" (#2437)
lurch Apr 23, 2025
eee72cd
Fix submodule path typos (#2424)
lurch Apr 23, 2025
174cafc
Add CYW43_WL_GPIO_SMPS_PIN for pico_w and pico2_w (#2410)
peterharperuk Apr 23, 2025
ae332b3
Ensure each test has a unique name (followup to #2208) (#2443)
lurch Apr 26, 2025
082d9f7
More board-header checks (followup to #2397) (#2442)
lurch Apr 26, 2025
333944a
Update hellbender_2350A_devboard.h for release version of the board. …
CBJamo Apr 29, 2025
6e31579
Add script to extract CMake function descriptions (#2422)
will-v-pi Apr 29, 2025
31fadf4
Revert "Add --recursive flag to git submodule cmd (#2416)" (#2445)
peterharperuk May 1, 2025
0de8847
Crashes after calling btstack_cyw43_deinit (#2446)
peterharperuk May 1, 2025
4bbd533
Fix sha build issues with mbedtls 3.x (#2447)
peterharperuk May 2, 2025
ec25563
Fix binary_info compilation in C++ due to out-of-order designated ini…
brokeh May 4, 2025
25789c4
Fix wrong value used for lposc_freq_khz_frac and xosc_freq_khz_frac
tommy-gilligan May 4, 2025
0779dfe
Small PICO_CONFIG tweak (#2456)
lurch May 6, 2025
7cdb8ec
Add PICO_CRT0_NO_RESET_SECTION (#2453)
kilograham May 7, 2025
799225d
Add PICO_CRT0_NEAR_CALLS to indicate that crt0 can call runtimine_ini…
kilograham May 7, 2025
792f556
Use cyw43_delay_ms() in cyw43_spi_reset() instead of sleep_ms() (#2431)
mbrase May 8, 2025
550aa09
fix typo in PICO_RUNTIME_SKIP_INIT_POST_CLOCK_RESETS (was missing INI…
kilograham May 12, 2025
14d75c0
Add printout of picotool location (#2475)
will-v-pi May 20, 2025
66540fe
Fix pioasm build failure caused by GCC 15 changes (#2448) (#2468)
onion108 May 20, 2025
8066bee
give user more control over embedded_start_block.S contents (#2470)
kilograham May 20, 2025
cbd7656
Minor fixups to compile with TF-M (#2403)
will-v-pi May 20, 2025
47f288b
Add support for wiznet_w5100s_evb_pico2 (#2458)
scaprile May 20, 2025
3515dad
Fix multicore_lockout features so that the victim core cannot become …
jwhitham May 20, 2025
c9c3825
remove assembler warning if StackSize or HeapSize are explicitly set …
kilograham May 21, 2025
9fdfe11
Remove accidental comment words in stdio.h (#2480)
lurch May 23, 2025
6613aa4
Add support for creating self-decrypting binaries (#2315)
will-v-pi May 29, 2025
0722de3
add new M33 processor exception handlers (#2482)
kilograham May 29, 2025
67f89e4
Update Bazel pin, ignore build-* directories (#2461)
armandomontanez May 29, 2025
6860f0d
Call enable_interrupts when initialising IRQs (#2491)
will-v-pi May 30, 2025
6841d4d
Remove DEPENDS argument from add_custom_command(TARGET functions (#2489)
will-v-pi May 30, 2025
1ae2f0e
Don't include the picobin end block when sealing (#2492)
will-v-pi May 30, 2025
a9146b6
fix(async_context_threadsafe_background_execute_sync): prevent use-af…
schkovich Jun 3, 2025
d7abd66
Fix typo (#2508)
marek22k Jun 9, 2025
a1faacf
Remove reference to wafer_id (#2512)
will-v-pi Jun 10, 2025
e6d1892
RP2040 and RP2350 have different maximum watchdog delays (#2500)
lurch Jun 12, 2025
be54918
Bazel build implementation, doesn't provide options for the compilati…
NolanBrad Jun 12, 2025
a9851a1
remove unnecessary escaping (#2526)
markhermeling Jun 16, 2025
a7ec8c3
Fix the "type" of SYS_CLK_VREG_VOLTAGE_AUTO_ADJUST_DELAY_US (#2531)
lurch Jun 18, 2025
2871965
Add config check action (#2525)
will-v-pi Jun 18, 2025
7d58f95
Add board definition for Adafruit Feather RP2040 Adalogger (#2524)
b4shful Jun 18, 2025
dddb514
Adafruit Fruit Jam board (#2363)
dhalbert Jun 18, 2025
893a06b
Add UUGear Witty Pi 5 HAT+ board header file (#2518)
uugear Jun 18, 2025
5ddb441
async_context_freertos: Add support for configSUPPORT_STATIC_ALLOCATI…
mbrase Jun 18, 2025
c3c6267
Clean extra output files (#2504)
will-v-pi Jun 18, 2025
24af10a
Use cyw43 macros for bluetooth logging (#2490)
peterharperuk Jun 18, 2025
d45a090
Fix ms/us confusion around watchdog time_remaining functions (#2533)
lurch Jun 19, 2025
a24bc13
Add board header for Waveshare RP2350-USB-A (#2435)
sonodima Jun 19, 2025
b1ca434
async_context_threadsafe_background: fix incorrect mutex assertion in…
schkovich Jun 19, 2025
44527b4
fix compiler warning
kilograham Jun 19, 2025
52ec9ec
downgrade hard_assert to assert
kilograham Jun 19, 2025
7b4b2b7
Add POWMAN_PASSWORD_BITS to pico_bootsel_via_double_reset. (#2532)
Gadgetoid Jun 19, 2025
8fb131a
Fix powman powman_configure_wakeup_state and powman_get_power_state (…
eightycc Jun 20, 2025
6f856ee
Add Board Header Check Action (#2519)
will-v-pi Jun 26, 2025
d7c26e6
add armv8m.main_soft_nofp_unaligned as a supporter clang runtime (for…
kilograham Jun 30, 2025
e5acd29
Added Olimex RP2350-PICO2-XL&XXL boards (#2541)
bog-dan-ro Jul 2, 2025
214c243
Add a "quick start" section for RISC-V to the readme (#2537)
peterharperuk Jul 2, 2025
9a4113f
Lock picotool version on master to 2.1.1 (#2401)
will-v-pi Jul 7, 2025
4ee0972
Use platform/generator agnostic CMake commands (#2539)
will-v-pi Jul 14, 2025
69e0185
Add PR branch check action (#2536)
will-v-pi Jul 14, 2025
b3aed37
Provide an easy way to disable cyw43 logging (#2535)
peterharperuk Jul 14, 2025
a72865b
Allow pio_encode_sideset_opt(0, value) (#2485)
magy00 Jul 14, 2025
19904be
Update makefsdata.py to support content encoding Fixes #2548 (#2549)
rbryson74 Jul 14, 2025
d2cdf6c
add pioasm --version, and print version number in generated files (#2…
kilograham Jul 15, 2025
d70cccd
Add FLASH option to pico_package_uf2_output (#2545)
will-v-pi Jul 15, 2025
c1981f5
Fix Windows CI (#2563)
will-v-pi Jul 16, 2025
e62cd02
Powman fix (#2499)
peterharperuk Jul 16, 2025
c7f37fc
make gpio_acknowledge_irq inline (#2562)
kilograham Jul 16, 2025
8fd7c60
Add WeAct RP2350B Core board support. (#2570)
tjko Jul 17, 2025
820a33a
Add Wi-Fi firmware partition support for Pico 2 W (#1969)
will-v-pi Jul 17, 2025
d32d315
minor tidying of hardware_rcp header; add an `rcp_is_true()` that is …
kilograham Jul 17, 2025
af518de
add missing libraries to test/kitchen_sink and auto-gen includes (#2567)
kilograham Jul 17, 2025
9682896
Gpio to gpout clock handle (#2561)
kilograham Jul 17, 2025
f5e0371
Make spacer sections allocatable (#2515)
will-v-pi Jul 17, 2025
4003a64
Merge style and grammar updates
JeuneseRPi Jul 18, 2025
4242010
Misc cleanup (#2569)
kilograham Jul 18, 2025
175abe7
Clarify pio_gpio_init doxygen (fixes #2387) (#2574)
Wren6991 Jul 18, 2025
dfc26a0
hardware_flash: preserve QSPI pad state over flash access calls. (#2565)
Wren6991 Jul 20, 2025
2e2651f
add default implementation of `_get_entropy()` that returns -1 to avo…
kilograham Jul 22, 2025
2afa251
fix typo "serialzed" -> "serialized" (#2583)
fadhil-riyanto Jul 23, 2025
9b876bb
Fix location of map file on Ninja (#2584)
will-v-pi Jul 23, 2025
f194749
Update and expand docs/weblinks_page.md (#2575)
lurch Jul 23, 2025
bf4906b
Improve error code description for some cyw43 connection methods (#2586)
peterharperuk Jul 23, 2025
58d000f
Improve rom_pick_ab_update_partition docs (#2577)
will-v-pi Jul 23, 2025
c650739
Look for other possible "missing PICO_CONFIG" lines, and make message…
lurch Jul 23, 2025
d011e8a
add a task completion semaphore to guarantee async_context task is fi…
kilograham Jul 23, 2025
b51a993
Improve pico_use_wifi_firmware_partition docs (#2580)
will-v-pi Jul 24, 2025
dad0112
Fix typo: IMAGEDEF → IMAGE_DEF, as it is defined in the datasheet (#2…
vazhnov Jul 24, 2025
59d2b02
add some doxygen to hard_assert (#2582)
kilograham Jul 24, 2025
50b4a22
Fix minor typos in error header (#2594) (#2594)
andygpz11 Jul 25, 2025
de5fb4f
Doxygen "group" fixes (#2591)
lurch Jul 25, 2025
4f5ebb8
Refactor extraction-scripts to reduce code-duplication (#2592)
lurch Jul 25, 2025
c4e30ce
Update docs, and add methods for new RP2350 DMA features (#2588)
kilograham Jul 25, 2025
e298fe6
merge (discarding changes) one off master fix back into develop
kilograham Jul 25, 2025
3461d65
add some missing pico_config and pico_cmake_config entries (#2559)
kilograham Jul 25, 2025
bb66fdf
pico_encode_gpio_wait doc improvement (#2579)
kilograham Jul 25, 2025
9227cad
add pico_status_led (#2501)
peterharperuk Jul 28, 2025
4635b37
Enable hardware_irq library also in host and not only in rp2_common (…
el-bert0 Jul 28, 2025
3f6f0fc
pico_rand (#2598)
el-bert0 Jul 28, 2025
c493a3a
fix errors in generated headers/SVD (#2599)
kilograham Jul 28, 2025
9b1e125
pico_status_led doxygen improvements (#2601)
lurch Jul 28, 2025
ef5bc2c
Fix build issue with status led (#2600)
peterharperuk Jul 28, 2025
681574b
add pico_status_led to host (#2605)
kilograham Jul 29, 2025
b375d7f
wow; runtime.c has been missing from host/pico_runtime for a while
kilograham Jul 29, 2025
a1438df
SDK 2.2.0 Release
kilograham Jul 29, 2025
547c083
Merge tag '2.2.0' into merge-2.2.0
ajf58 Jul 29, 2025
c3c2b7f
picod-sdk: Use PICO_MHZ for FPGA_CLK_SYS_HZ and FPGA_CLK_REF_HZ
ajf58 Jul 30, 2025
a43ee13
pico-sdk: Replace more use of MHZ with PICO_MHZ
ajf58 Aug 1, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 0 additions & 4 deletions .bazelignore

This file was deleted.

4 changes: 4 additions & 0 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,7 @@ common --host_per_file_copt=external/.*@-w

# Produce useful output when the build fails.
common --verbose_failures

# Silence warnings about old bazel_dep pins. Bazel 8 brings along newer ones,
# but we can support Bazel 7 (for now).
common --check_direct_dependencies=off
2 changes: 1 addition & 1 deletion .bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.2.1
8.1.0
27 changes: 27 additions & 0 deletions .github/workflows/check_board.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Check Board Headers

on:
push:
paths:
- 'src/boards/include/boards/**'
- 'tools/check_board_header.py'
- 'tools/check_all_board_headers.sh'
- '.github/workflows/check_board.yml'
pull_request:
paths:
- 'src/boards/include/boards/**'
- 'tools/check_board_header.py'
- 'tools/check_all_board_headers.sh'
- '.github/workflows/check_board.yml'

jobs:
check-board-headers:
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Check Board Headers
run: |
tools/check_all_board_headers.sh
33 changes: 33 additions & 0 deletions .github/workflows/check_configs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Check Configs

on:
push:
pull_request:

jobs:
check-configs:
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Check Build Defines
if: always()
run: |
tools/extract_build_defines.py .

- name: Check CMake Configs
if: always()
run: |
tools/extract_cmake_configs.py .

- name: Check CMake Functions
if: always()
run: |
tools/extract_cmake_functions.py .

- name: Check Configs
if: always()
run: |
tools/extract_configs.py .
2 changes: 0 additions & 2 deletions .github/workflows/choco_packages.config
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="gcc-arm-embedded" version="10.2.1" />
<package id="cmake" version="3.31.0" installArguments="ADD_CMAKE_TO_PATH=System" />
<package id="mingw" version="12.2.0" />
<package id="ninja" version="1.11.1" />
</packages>
2 changes: 1 addition & 1 deletion .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
uses: actions/checkout@v4

- name: Checkout submodules
run: git submodule update --init
run: git submodule update --init --recursive

- name: Create Build Environment
# Some projects don't allow in-source building, so create a separate build directory
Expand Down
422 changes: 344 additions & 78 deletions .github/workflows/multi-gcc.yml

Large diffs are not rendered by default.

28 changes: 28 additions & 0 deletions .github/workflows/pr-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Make sure PRs target the develop branch

on:
pull_request_target:

# By default, pull_request_target gets write permissions to the repo - this prevents that
permissions:
pull-requests: write

jobs:
check-branch:
if: github.event.pull_request.base.ref == 'master'
runs-on: ubuntu-latest
steps:
- name: Add comment
uses: actions/github-script@v7
with:
script: |
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: 'Please do not submit against `master`, use `develop` instead'
})
- name: Throw error
run: |
echo "::error title=wrong-branch::Please do not submit against 'master', use 'develop' instead"
exit 1
115 changes: 96 additions & 19 deletions .github/workflows/scripts/generate_multi_gcc_workflow.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,52 @@
import subprocess
import re

toolchain_dir = "/opt/arm"
toolchains = os.listdir(toolchain_dir)
toolchains = [os.path.join("/opt/arm", x) for x in os.listdir("/opt/arm")]
toolchains += [os.path.join("/opt/riscv", x) for x in os.listdir("/opt/riscv")]

gcc_versions = OrderedDict()
compilers = []
class Compiler:
def __init__(self, version, path, type):
self.version = version
self.path = path
self.type = type

@property
def gcc(self):
return self.type == "GCC"

@property
def llvm(self):
return self.type == "LLVM"

@property
def riscv(self):
return "RISCV" in self.type

def __repr__(self):
return self.version

seen_versions = []
for toolchain in toolchains:
fullpath = os.path.join(toolchain_dir, toolchain)
gcc_path = os.path.join(fullpath, "bin/arm-none-eabi-gcc")
version = subprocess.run([gcc_path, "--version"], capture_output=True)
gcc_path = os.path.join(toolchain, "bin/arm-none-eabi-gcc")
llvm_path = os.path.join(toolchain, "bin/clang")
riscv_gcc_path = os.path.join(toolchain, "bin/riscv32-unknown-elf-gcc")

type = None
path = None
if os.path.exists(gcc_path):
path = gcc_path
type = "GCC"
elif os.path.exists(llvm_path):
path = llvm_path
type = "LLVM"
elif os.path.exists(riscv_gcc_path):
path = riscv_gcc_path
type = "RISCV GCC"
else:
raise Exception("Unknown compiler type")

version = subprocess.run([path, "--version"], capture_output=True)
stdout = version.stdout.decode('utf-8')
stderr = version.stderr.decode('utf-8')
assert(len(stderr) == 0)
Expand All @@ -23,14 +60,13 @@
assert(m is not None)
version = m.group(1)

if version in gcc_versions:
raise Exception("Already have version {} in versions current path {}, this path {}".format(version, gcc_versions[version], fullpath))

gcc_versions[version] = fullpath
if version in seen_versions:
raise Exception("Already have version {} in versions current path {}, this path {}".format(version, gcc_versions[version], path))

# Sort by major version
gcc_versions_sorted = OrderedDict(sorted(gcc_versions.items(), key=lambda item: int(item[0].replace(".", ""))))
compilers.append(Compiler(version, toolchain, type))
seen_versions.append(version)

compilers_sorted = sorted(compilers, key=lambda x: int(x.version.replace(".", "")))

# Create output
output = '''
Expand Down Expand Up @@ -59,14 +95,55 @@

- name: Checkout submodules
run: git submodule update --init

- name: Host Release
run: cd ${{github.workspace}}; mkdir -p build; rm -rf build/*; cd build; cmake ../ -DPICO_SDK_TESTS_ENABLED=1 -DCMAKE_BUILD_TYPE=Release -DPICO_NO_PICOTOOL=1 -DPICO_PLATFORM=host; make --output-sync=target --no-builtin-rules --no-builtin-variables -j$(nproc)

- name: Host Debug
run: cd ${{github.workspace}}; mkdir -p build; rm -rf build/*; cd build; cmake ../ -DPICO_SDK_TESTS_ENABLED=1 -DCMAKE_BUILD_TYPE=Debug -DPICO_NO_PICOTOOL=1 -DPICO_PLATFORM=host; make --output-sync=target --no-builtin-rules --no-builtin-variables -j$(nproc)
'''

for gcc_version, toolchain_path in gcc_versions_sorted.items():
for build_type in ["Debug", "Release"]:
output += "\n"
output += " - name: GCC {} {}\n".format(gcc_version, build_type)
output += " if: always()\n"
output += " shell: bash\n"
output += " run: cd ${{{{github.workspace}}}}; mkdir -p build; rm -rf build/*; cd build; cmake ../ -DPICO_SDK_TESTS_ENABLED=1 -DCMAKE_BUILD_TYPE={} -DPICO_TOOLCHAIN_PATH={} -DPICO_BOARD=pico_w; make --output-sync=target --no-builtin-rules --no-builtin-variables -j$(nproc)\n".format(build_type, toolchain_path)
platforms = []
class Platform:
def __init__(self, name, platform, board, minimum_gcc_version=None):
self.name = name
self.board = board
self.platform = platform
self.riscv = "riscv" in platform
self.minimum_gcc_version = minimum_gcc_version

def cmake_string(self, compiler):
opts = []
# Temporary while private repo
opts.append("-DPICO_NO_PICOTOOL=1")
if self.board: opts.append(f"-DPICO_BOARD={self.board}")
opts.append(f"-DPICO_PLATFORM={self.platform}")
if compiler.llvm: opts.append("-DPICO_COMPILER=pico_arm_clang")
opts.append(f"-DPICO_TOOLCHAIN_PATH={compiler.path}")
return " ".join(opts)

def compiler_valid(self, compiler):
if compiler.riscv != self.riscv:
return False

if self.minimum_gcc_version and compiler.gcc:
if int(compiler.version.split(".")[0]) < self.minimum_gcc_version:
return False

return True


platforms.append(Platform("Pico W", "rp2040", "pico_w"))
platforms.append(Platform("RP2350", "rp2350", None, 9))
platforms.append(Platform("RP2350 RISCV", "rp2350-riscv", None))

for compiler in compilers_sorted:
for build_type in ["Debug", "Release"]:
for p in platforms:
if not p.compiler_valid(compiler): continue
output += "\n"
output += " - name: {} {} {} {}\n".format(compiler.type, compiler.version, build_type, p.name)
output += " if: always()\n"
output += " shell: bash\n"
output += " run: cd ${{{{github.workspace}}}}; mkdir -p build; rm -rf build/*; cd build; cmake ../ -DPICO_SDK_TESTS_ENABLED=1 -DCMAKE_BUILD_TYPE={} {}; make --output-sync=target --no-builtin-rules --no-builtin-variables -j$(nproc)\n".format(build_type, p.cmake_string(compiler))
print(output)
35 changes: 21 additions & 14 deletions MODULE.bazel
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
module(
name = "pico-sdk",
version = "2.1.0",
version = "2.2.0",
)

bazel_dep(name = "platforms", version = "0.0.9")
bazel_dep(name = "bazel_skylib", version = "1.6.1")
bazel_dep(name = "rules_python", version = "0.36.0")
bazel_dep(name = "picotool", version = "2.1.0")
bazel_dep(name = "picotool", version = "2.2.0")
bazel_dep(name = "rules_cc", version = "0.0.10")

http_archive = use_repo_rule("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
Expand Down Expand Up @@ -54,34 +54,34 @@ http_archive(
http_archive(
name = "clang_linux-x86_64",
build_file = "//bazel/toolchain:clang.BUILD",
sha256 = "6c599d1aba568236064c340d7813324849896d5a4e2f3fd8225a8c31bfcbf884",
sha256 = "82302f8f0d9cb1062e60756147403c1525e965e1d7b777fab8076c74c7a5a19b",
type = "zip",
url = "https://chrome-infra-packages.appspot.com/dl/fuchsia/third_party/clang/linux-amd64/+/git_revision:2b0a708f41dd6291ee744704d43febc975e3d026",
url = "https://chrome-infra-packages.appspot.com/dl/fuchsia/third_party/clang/linux-amd64/+/git_revision:910be4ff90d7d07bd4518ea03b85c0974672bf9c",
)

http_archive(
name = "clang_win-x86_64",
build_file = "//bazel/toolchain:clang.BUILD",
sha256 = "f49ba4123ee3958f2b47289d017a5b3f1ca01f82dd7a2168c45412c18101fd13",
sha256 = "2e9b8ac889838754e5305b6fd73c7bba7a6ec7364f1ce8ac60268b6d3bc61e6c",
type = "zip",
# Windows doesn't like `:` in the produced filename, so replace it with `%3A`.
url = "https://chrome-infra-packages.appspot.com/dl/fuchsia/third_party/clang/windows-amd64/+/git_revision:2b0a708f41dd6291ee744704d43febc975e3d026".replace("git_revision:", "git_revision%3A"),
url = "https://chrome-infra-packages.appspot.com/dl/fuchsia/third_party/clang/windows-amd64/+/git_revision:910be4ff90d7d07bd4518ea03b85c0974672bf9c".replace("git_revision:", "git_revision%3A"),
)

http_archive(
name = "clang_mac-x86_64",
build_file = "//bazel/toolchain:clang.BUILD",
sha256 = "d3516f2eb4c12d17ae77ee84c9226fbea581d4fb806910ceac4717d5adfcf748",
sha256 = "d3f2ef6f391ef66141092cfdf07facd18d2587a25616e1251e6e6b13b05ab3df",
type = "zip",
url = "https://chrome-infra-packages.appspot.com/dl/fuchsia/third_party/clang/mac-amd64/+/git_revision:2b0a708f41dd6291ee744704d43febc975e3d026",
url = "https://chrome-infra-packages.appspot.com/dl/fuchsia/third_party/clang/mac-amd64/+/git_revision:910be4ff90d7d07bd4518ea03b85c0974672bf9c",
)

http_archive(
name = "clang_mac-aarch64",
build_file = "//bazel/toolchain:clang.BUILD",
sha256 = "68e551f41c7e9473063b09819f6ab8ec6e7e53677f4078189656cb14dc52984b",
sha256 = "61109b8464e9213ef8b9bfe55ce56298b94d4c66eaea308cf2b6556b0b85429e",
type = "zip",
url = "https://chrome-infra-packages.appspot.com/dl/fuchsia/third_party/clang/mac-arm64/+/git_revision:2b0a708f41dd6291ee744704d43febc975e3d026",
url = "https://chrome-infra-packages.appspot.com/dl/fuchsia/third_party/clang/mac-arm64/+/git_revision:910be4ff90d7d07bd4518ea03b85c0974672bf9c",
)

new_git_repository = use_repo_rule("@bazel_tools//tools/build_defs/repo:git.bzl", "new_git_repository")
Expand All @@ -90,34 +90,41 @@ new_git_repository = use_repo_rule("@bazel_tools//tools/build_defs/repo:git.bzl"
new_git_repository(
name = "tinyusb",
build_file = "//src/rp2_common/tinyusb:tinyusb.BUILD",
commit = "5217cee5de4cd555018da90f9f1bcc87fb1c1d3a", # keep-in-sync-with-submodule: lib/tinyusb
commit = "86ad6e56c1700e85f1c5678607a762cfe3aa2f47", # keep-in-sync-with-submodule: lib/tinyusb
remote = "https://github.com/hathach/tinyusb.git",
)

# TODO: Provide btstack as a proper Bazel module.
new_git_repository(
name = "btstack",
build_file = "//src/rp2_common/pico_btstack:btstack.BUILD",
commit = "2b49e57bd1fae85ac32ac1f41cdb7c794de335f6", # keep-in-sync-with-submodule: lib/btstack
commit = "501e6d2b86e6c92bfb9c390bcf55709938e25ac1", # keep-in-sync-with-submodule: lib/btstack
remote = "https://github.com/bluekitchen/btstack.git",
)

# TODO: Provide cyw43-driver as a proper Bazel module.
new_git_repository(
name = "cyw43-driver",
build_file = "//src/rp2_common/pico_cyw43_driver:cyw43-driver.BUILD",
commit = "cf924bb04c8984675ca0fc2178f082e404e048c3", # keep-in-sync-with-submodule: lib/cyw43-driver
commit = "dd7568229f3bf7a37737b9e1ef250c26efe75b23", # keep-in-sync-with-submodule: lib/cyw43-driver
remote = "https://github.com/georgerobotics/cyw43-driver.git",
)

# TODO: Provide lwip as a proper Bazel module.
new_git_repository(
name = "lwip",
build_file = "//src/rp2_common/pico_lwip:lwip.BUILD",
commit = "0a0452b2c39bdd91e252aef045c115f88f6ca773", # keep-in-sync-with-submodule: lib/lwip
commit = "77dcd25a72509eb83f72b033d219b1d40cd8eb95", # keep-in-sync-with-submodule: lib/lwip
remote = "https://github.com/lwip-tcpip/lwip.git",
)

new_git_repository(
name = "mbedtls",
build_file = "//src/rp2_common/pico_mbedtls:mbedtls.BUILD",
commit = "107ea89daaefb9867ea9121002fbbdf926780e98", # keep-in-sync-with-submodule: lib/mbedtls
remote = "https://github.com/Mbed-TLS/mbedtls.git",
)

register_toolchains(
"//bazel/toolchain:linux-aarch64-rp2040",
"//bazel/toolchain:linux-aarch64-rp2350",
Expand Down
Loading
Loading