SDK 2.3.0 - Missing or changed defines #3060
Labels
No labels
bazel
bluetooth
board settings
boot_stage2
bug
build
c++
can't reproduce
clang
clib-interface
cmsis
code cleanliness
code size
compiler version issues
cyw43_driver
debug
discussion
documentation
duplicate
dynamic_clock
elf2uf2
enhancement
errata
filesystem
flash layout
floating point
FreeRTOS
hardware_adc
hardware_claim
hardware_clocks
hardware_dma
hardware_exception
hardware_flash
hardware_gpio
hardware_i2c
hardware_irq
hardware_pio
hardware_pwm
hardware_rcp
hardware_rtc
hardware_spi
hardware_sync
hardware_uart
hardware_vreg
hardware_watchdog
hardware_xosc
help wanted
host
IAR
installation
invalid
linker scripts
lto
lwip
mbedtls
missing API
needs reporter detail
networking
newlib
newlib-multicore
non-c
non-cmake
non-gcc
openocd
orphan PR
OS integration
pico_async_context
pico_base
pico_binary_info
pico_flash
picolibc
pico_lwip
pico_malloc
pico_multicore
pico_printf
pico_runtime
pico_stdio
pico_stdio_usb
pico_sync
pico_time
pico_util
pioasm
port
question
review
review2
rtos interop
runtime init
static library
svd
test
tinyusb
vscode
wifi integration
wontfix
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-raspberrypi/pico-sdk#3060
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The above used to compile OK with v2.20 of the SDK. I cannot remember which version of the SDK I first introduced this code.
The 2.3.0 release documentation references
pico-usb-reset, but the link does not take me to any such documentation.It appears that at least some of the definitions have moved into "pico/pico-usb-reset.h".
The above sets
PICO_USB_RESET_MAGIC_BAUD_RATEto the value ofPICO_STDIO_USB_RESET_MAGIC_BAUD_RATE. However it does not initialise the old definitionPICO_STDIO_USB_RESET_MAGIC_BAUD_RATEto its previous value. For v2.2.0 this was initialised in "pico/stdio_usb.h".Yes, the documentation didn't quite make it out the door on Friday (hence the lack of announcement about SDK version)! Monday likely
This was changed in https://github.com/raspberrypi/pico-sdk/pull/2629 - the defines have been moved from
pico/stdio_usb.htopico/usb_reset_config.h(which is included bypico/usb_reset.h), and renamed to removeSTDIO.These defines weren't expected to be used outside of the SDK, hence only adding backwards compatibility in one direction. I think a fix (assuming you want to maintain backwards compatibility with older SDKs for your code) is to add this to that C file, after
#include "pico/stdio_usb.h"(or#include "pico/stdlib.h"):I can raise a PR to add backwards compatibility in this direction too
My solution was somewhat similar:
However, since this is now broken, I am not sure it is worth fixing since anybody using these defines will have to apply their own fix before the next release of the SDK.
I think I agree with you - I'll pop this in the
nonemilestone instead of closing it, in case anyone else runs into this issue