Skip to content

Aktivnost

Touch emotion badge

Početni | MakeCode, Python | LED zaslon, Logo osjetljiv na dodir, Tipke | Ulaz (Input)/izlaz (Output)

1. korak: Napravi

Što je to?

Add another expression to an emotion badge project using the new micro:bit's touch logo sensor as an extra button

Uvod

Vodič za kodiranje

Što ćeš naučiti

  • How computers take inputs, process them using code and create different outputs
  • How to use the new micro:bit's touch logo like a button input to trigger outputs

Kako to radi

  • This program senses if you press button A and shows a happy face icon on the LED display output.
  • It senses if you press button B and shows a sad face on the LED display.
  • If you touch the gold logo on the front of the new micro:bit, the program detects your finger and shows a surprised face on the LEDs.

Što ti treba

  • novi micro:bit sa zvukom (ili simulator u MakeCodeu)
  • Uređivač MakeCode ili Python
  • baterije (prema potrebi)

2. korak: Kodiraj

3. korak: Unaprijedi

  • Change the icons that appear, or draw your own to show different emotions.
  • Create an animated sequence of faces when you press each button.
  • Add different sounds that match each emotion.