Using the C/C++ Pico SDK, how can I find out which core my code is running on?
(Specifically, I'd like to use lwIP's LWIP_ASSERT_CORE_LOCKED
, which requires a thread or core identifier to determine whether it holds the right locks.)
Raspberry Pi Stack Exchange is a question and answer site for users and developers of hardware and software for Raspberry Pi. It only takes a minute to sign up.
Sign up to join this communityNot sure why I didn't find it the last time around, but there's get_core_num()
in pico_platform
.