Closed shreeve closed 10 months ago
The listing shows that the program is compiled for the PicoPad device and not for the Pico (according to the lines .._devices/picopad..). The PicoPad device uses a checksum because of the program loader from the SD card, which verifies that the program is correctly loaded in memory. This checksum is not needed for the Pico device. If you want to compile a program for Pico, you must specify pico as a parameter of the c.sh startup script (see c.bat). Another option is to modify the _setup.sh configuration script for the default device - in "case" set the parameters for the default case *) according to the variant for "pico" - in this case the compilation always takes place for "pico" and there is no need to specify the parameter in c.sh.
I would like to point out that the USB library in PicoLibSDK is very different from the USB library in the original SDK. On the one hand it is faster, it works in a different way. But on the other hand, it doesn't include as many devices as the original SDK - for example, the USB Hub handling is missing for now.
@Panda381 - Excellent! I made a few updates, per your message and it works! Thank you!
This project looks really incredible! Great job!
I am on macOS and would like to compile and test this out.
I followed the readme for Linux and made the shell scripts executable and I was able to compile the example in
PicoLibSDK/Pico/USB/Hello
.The compilation died right at the end, because I don't have the
LoaderCrc
executable on macOS. Here's the message:However, in the generated files, I do see that there is
build/Hello.elf
file and also a./Hello.uf2
file. I assume that the.uf2
file is missing CRC information, which would normalled be added byLoaderCrc
. I tried the following:build/Hello.elf
file with this:sudo openocd -f interface/cmsis-dap.cfg -f target/rp2040.cfg -c "adapter speed 5000" -c "program build/Hello.elf verify reset exit"
. I assume that the*.elf
file does not need the CRC check on it, but I'm not certain.Hello.uf2
file as-is, usingpicotool load -f -x Hello.uf2
. I assume this will not work because it's missing the CRC information.bin2uf2
from @ataradov at his repo. This didn't work either.Do you have any suggestions on other ways I could get the compiled
Hello
example to my Pico?Thanks!