Closed colossalchicken closed 1 year ago
Yes, that should be possible. But you need to add and initialize a global allocator, otherwise you'll get the following error message:
error: no global memory allocator found but one is required; link to std or add `#[global_allocator]` to a static item that implements the GlobalAlloc trait
One global allocator you could use is embedded-alloc. The example given in https://github.com/rust-embedded/embedded-alloc/blob/master/examples/global_alloc.rs shows what you need to add to your main
function to make it work.
Thanks!
Is it possible to use the
alloc
crate on the RP2040?