crwdns361998:0crwdne361998:0
crwdns362000:0crwdne362000:0
crwdns362002:0crwdne362002:0
crwdns362008:0crwdne362008:0
crwdns362010:0crwdne362010:0 crwdns362012:0crwdne362012:0
crwdns362014:0crwdne362014:0
- crwdns362016:0crwdne362016:0
- crwdns362018:0crwdne362018:0
- crwdns362020:0crwdne362020:0
- crwdns362022:0crwdne362022:0 crwdns362024:0crwdne362024:0 crwdns362026:0crwdne362026:0
- crwdns362028:0crwdne362028:0 crwdns362030:0crwdne362030:0 crwdns362032:0crwdne362032:0
- crwdns362034:0crwdne362034:0
- crwdns362036:0crwdne362036:0 crwdns362038:0crwdne362038:0 crwdns362040:0crwdne362040:0 crwdns362042:0crwdne362042:0
crwdns362044:0crwdne362044:0
- crwdns362046:0crwdne362046:0
- crwdns362048:0crwdne362048:0
- crwdns362050:0crwdne362050:0
crwdns362052:0crwdne362052:0
1# Imports go at the top
2from microbit import *
3
4
5while True:
6 if button_a.was_pressed():
7 audio.play(Sound.TWINKLE)
8 if accelerometer.was_gesture('shake'):
9 for i in range(10):
10 display.show(Image('90909:'
11 '09090:'
12 '90909:'
13 '09090:'
14 '90909'))
15 sleep(500)
16 display.show(Image('09090:'
17 '90909:'
18 '09090:'
19 '90909:'
20 '09090'))
21 sleep(500)
22 display.clear()
23
crwdns362054:0crwdne362054:0
- crwdns362056:0crwdne362056:0 crwdns362058:0crwdne362058:0
- crwdns362060:0crwdne362060:0
- crwdns362062:0crwdne362062:0
This content is published under a Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) licence.