Example Code for micro:bit-Auto Watering System
The article provides a step-by-step guide on building an auto watering system using micro:bit, with detailed hardware preparation, wiring diagrams, and sample code for both Mind+ and MakeCode platforms. It includes instructions for both programming and non-programming projects, making it accessible for learners of all levels.
Hardware Preparation
![]() |
![]() |
![]() |
|---|---|---|
| BOS0038 Soil Moisture Sensor | BOS0025 Servo Controller Module | SER0045 9g Metal Gear Micro Servo |
![]() |
![]() |
![]() |
| BOS0032 Threshold Module | MBT0039 micro:bit | BOS0035 Mainboard-3IO |
![]() |
||
| BOS0040 micro:bit BOSON Expansion Board |
Software Preparation
Wiring Diagram
Non-programming Project
Connection Diagram:

Programming Project
Connection Diagram:

Other Preparation Work
Tip: micro:bit and its expansion board will be used in programming projects.
Result
Program Flowchart:

Video Demo
| Non-programming | Programming |
|---|---|
![]() |
![]() |
Was this article helpful?









