I tried setting up the toolchain on Ubuntu 22.04 host to run the examples from https://github.com/lancaster-university/microbit-samples/ but I’m just unable to setup Yotta, I keep getting different dependency issues. What are the exact steps needed?
I tried setting up the toolchain on Ubuntu 22.04 host to run the examples from https://github.com/lancaster-university/microbit-samples/ but I’m just unable to setup Yotta, I keep getting different dependency issues. What are the exact steps needed?
2
Answers
After trying to setup the toolchain for a while, I finally decided to Google for a Docker image with the toolchain, and found https://github.com/carlosperate/docker-microbit-toolchain at this commit from Carlos Atencio, a Micro:Bit foundation employee, and that just absolutely worked:
And you can then flash the example you want to run with:
The source code for the hello world from https://github.com/lancaster-university/microbit-samples/blob/285f9acfb54fce2381339164b6fe5c1a7ebd39d5/source/examples/hello-world/main.cpp is:
Atencios' Docker setup explains how get yotta working if you still want that: https://github.com/carlosperate/docker-microbit-toolchain/blob/master/Dockerfile , the key is likely using his magically crafted
requirements.txt
, likely kept back from the day when things really worked, to avoid the infinitely many dependency issues of yotta. He's on Ubuntu 20.04.It’s great that you’ve found a work around to compile C for the micro:bit. To answer your original question, here’s what worked for me to install yotta on Debian 11.5. I have Python v3.9.2 installed.