Skip to content

crwdns342183:0crwdne342183:0

crwdns342315:0crwdne342315:0

crwdns347529:0crwdne347529:0 | MakeCode, Python | crwdns255558:0crwdne255558:0, crwdns255562:0crwdne255562:0, crwdns255566:0crwdne255566:0 | crwdns258480:0crwdne258480:0, crwdns258498:0crwdne258498:0, crwdns258502:0crwdne258502:0, crwdns258536:0crwdne258536:0, crwdns258554:0crwdne258554:0, crwdns258616:0crwdne258616:0, crwdns258618:0crwdne258618:0

crwdns342257:0crwdne342257:0

crwdns342259:0crwdne342259:0

crwdns342261:0crwdne342261:0

crwdns347381:0crwdne347381:0

crwdns342265:0crwdne342265:0

  • crwdns342267:0crwdne342267:0 crwdns342269:0crwdne342269:0
  • crwdns342271:0crwdne342271:0 crwdns342273:0crwdne342273:0
  • crwdns342275:0crwdne342275:0 crwdns342277:0crwdne342277:0
  • crwdns342279:0crwdne342279:0
  • crwdns342281:0crwdne342281:0 crwdns342283:0crwdne342283:0

crwdns342285:0crwdne342285:0

  • crwdns342287:0crwdne342287:0
  • crwdns342289:0crwdne342289:0
  • crwdns342291:0crwdne342291:0
  • crwdns342293:0crwdne342293:0

crwdns342295:0crwdne342295:0

crwdns342297:0crwdne342297:0

1from microbit import *
2import radio
3radio.config(group=73)
4radio.on()
5
6while True:
7    if pin0.read_digital():
8        display.show(Image.DIAMOND_SMALL)
9        radio.send('moving')
10    else:
11        display.clear()
12        radio.send('still')
13    sleep(1000)
14

crwdns342299:0crwdne342299:0

1from microbit import *
2import music
3import radio
4radio.config(group=73)
5radio.on()
6
7while True:
8    message = radio.receive()
9    if message:
10        if message == 'moving':
11            display.show(Image.STICKFIGURE)
12            music.play(["C4:4"])
13        if message == 'still':
14            display.clear()
15

crwdns342301:0crwdne342301:0

  • crwdns342303:0crwdne342303:0 crwdns342305:0crwdne342305:0 crwdns342307:0crwdne342307:0
  • crwdns342309:0crwdne342309:0
  • crwdns342311:0crwdne342311:0