Connection
- CLK – clock signal, connects to yellow bar on the extensions. It is necessary to set which pin we connected this signal to.
- GOD – data pin, connects to yellow bar on the extensions. It is necessary to set which pin we connected this signal to using the dupont cable.
- VCC – positive voltage (connects to the white bar).
- GND – earth (connects to the black bar).
Warning: When connecting, the expansion board must be turned off and the micro:bit disconnected from the power supply.
Programme
Basic program
First, we need to create a new variable, which we will name display.
Then we need to download the extension for our display. In the extensions section we find the library for the TM1637 display and add it to the makecode.
Now we have everything ready and we can start programming. The first thing we do when starting the program is to add a display to the program and turn it on. The display is set using the variable block “set display to 0”, which we place in the “at startup” window. Next, we select the initialization block from the TM1637 block to tell where the display is connected.
Once the display is set up, we turn it on using the “turn on” block and select the “display” variable.
Then we can test the correctness of the connection and programming using the “show number” block, which can be found in the TM1637 tab.



