Introduction: Micro:Bit Compass DIY
How to code a Micro:Bit compass.
Click this LINK or go to https://makecode.microbit.org/
Step 2: Block Coding Part 1
Copy the block layout above.
Step 3: Block Coding Part 2
Add the code above to previous code in "forever" block. Use compass for reference (if unable to see compass headings).
Step 4: Finishing Block Coding
Once finish your code should look like this. Test your code using the simulator.
Step 5: Flashing Code to Micro:Bit
Next plug in your Micro:Bit (via the include micro usb cable). Then find the download button and click the three dots on the right side. Click pair device and follow the provided instructions.
Step 6: Have Fun!!!
Don't forget to calibrate your compass!
Participated in the
Block Code Contest
Be the First to Share
1 43 4.2K
2 years ago
Thanks for sharing :)