#MonthOfMaking – Day 14

#MonthOfMaking – Day 14

March is all about MAKING!!

I have decided to take on the challenge of making a 5-minute micro:bit make every day throughout March.

Day13 – Touch a pin!

Today we are going to be learning about touch input on the micro:bit.

Python Code

from microbit import *
while True:
  if pin0.is_touched():
    display.scroll("You touched Pin 0!")
  elif pin1.is_touched():
    display.scroll("You touched Pin 1!")
  elif pin2.is_touched():
    display.scroll("You touched Pin 2!")

EduBlocks Code

MakeCode Code

MakeCode code

Demo

Final Words

Come back Tomorrow for another fun 5-minute micro:bit make