MicroBit Project #07 for INF 294

Project description:

Using code for MicroBit built in C/C++, make a timer that displays the numbers 0 to 9 then returns to 0. Uses timer and nested loops. I interpreted the instruction to "use timer" to mean that the interval between each number appearing on the display should be 1 second.

I used the MakeCode editor to test the algorithm in the MicroBit framework, then wrote the code in the mbed compiler to create the HEX file and test the program.

/https:/os.mbed.com/media/uploads/tsfarber/basic_logic_for_project_7.png

let seconds = 9
for (let index = 0; index <= seconds; index++) {
    basic.showNumber(index)
}
seconds = 0
basic.showNumber(seconds)

https://os.mbed.com/users/tsfarber/code/microbit-7-count_0-9-0_/


Please log in to post comments.