27. case 23 micro:bit Crawlers#

27.1. Introduction#

Let the children use the building blocks and micro:bit to make a crawling caterpillar. In this process, children could experience the fun of building blocks and get a preliminary understanding of the ratchet structure.

../../_images/case_23_01.png

27.2. Quick Start#

Materials Required#

Nezha expansion board × 1

micro:bit V2 × 1

360°servo × 1

Bricks × n

Tips: You may need to purchase Nezha Inventor’s Kit if you want all the above compoents.

Connection Diagram#

Connect the servo to S1 and the micro:bit to Nezha expansion board.

../../_images/case_23_03.png

Assembly Video#

Assembly Steps#

../../_images/case_step_23_01.png

../../_images/case_step_23_02.png

../../_images/case_step_23_03.png

../../_images/case_step_23_04.png

../../_images/case_step_23_05.png

../../_images/case_step_23_06.png

../../_images/case_step_23_07.png

../../_images/case_step_23_08.png

../../_images/case_step_23_09.png

../../_images/case_step_23_10.png

../../_images/case_step_23_11.png

../../_images/case_step_23_12.png

../../_images/case_step_23_13.png

../../_images/case_step_23_14.png

../../_images/case_step_23_15.png

27.3. MakeCode Programming#

Step 1#

Click “Advanced” in the MakeCode drawer to see more choices.

../../_images/case_01_10.png

We need to add a package for programming. Click “Extensions” in the bottom of the drawer and search with “nezha” in the dialogue box to download it.

../../_images/case_03_09.png

Note: If you met a tip indicating that the codebase will be deleted due to incompatibility, you may continue as the tips say or build a new project in the menu.

Programme as the picture shows:#

../../_images/case_23_10.png

Result#

The crawlers move forward after powering on.

../../_images/case-gif-23.gif