Science Oxford Logo

Adding a connection sensor

Pins 0, 1 and 2 on the micro:bit can be used to sense when a connection has been made.

You will need two crocodile clips.

Design some code to make something happen when the two wires touch, then think about what problems you could solve by monitoring when a connection is made.


Example Code



What can you use this for?

As well as your Inputs, the blocks you need for this are in the Logic menu.

As well as the Conditionals, you can combine Comparison and Boolean blocks to make a really interesting program!


What materials could you use to make a more useable connection sensor?

What problems could you solve using a connection sensor?