pxt-microbit 7.1.2 → 7.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -598,7 +598,7 @@ Many extensions are available to work with interface kits, add-on hardware, or o
598
598
  "cardType": "package"
599
599
  }, {
600
600
  "name": "MATRIX Micro",
601
- "url":"/pkg/pxt-MatrixMicro",
601
+ "url":"/pkg/matrix-robotics/pxt-MatrixMicro",
602
602
  "cardType": "package"
603
603
  }, {
604
604
  "name": "PTKidsBIT",
@@ -941,6 +941,10 @@ Many extensions are available to work with interface kits, add-on hardware, or o
941
941
 
942
942
  ```codecard
943
943
  [{
944
+ "name": "Sonification",
945
+ "url":"/pkg/davidnsousa/sonification",
946
+ "cardType": "package"
947
+ }, {
944
948
  "name": "Kitronik Klef Piano",
945
949
  "url":"/pkg/KitronikLtd/pxt-kitronik-klef-piano",
946
950
  "cardType": "package"
@@ -73,8 +73,8 @@ input.onButtonPressed(Button.A, function () {
73
73
 
74
74
  Let's now add an auditory indicator that your @boardname@ is logging data!
75
75
 
76
- ► From the ``||music:Music||`` category, grab a ``||music:play sound [giggle] [until done]||`` block and snap it into the **bottom** of the **top container** of your ``||logic:if then / else||`` statement.
77
- ► Click on the ``giggle`` dropdown and select ``hello``. Your block should now say ``||music:play sound [hello] [until done]||``.
76
+ ► From the ``||music:Music||`` category, grab a ``||music:play sound [dadadum] [in background]||`` block and snap it into the **bottom** of the **top container** of your ``||logic:if then / else||`` statement.
77
+ ► Click on the ``[dadadum]`` dropdown and select ``nyan``, then set the playback mode to ``||music:[until done]||``. Your block should now say ``||music:play melody [nyan] [until done]||``.
78
78
 
79
79
  ```blocks
80
80
  let logging = false
@@ -82,7 +82,7 @@ input.onButtonPressed(Button.A, function () {
82
82
  logging = !(logging)
83
83
  if (logging) {
84
84
  basic.showIcon(IconNames.Target)
85
- music.playSoundEffect(music.builtinSoundEffect(soundExpression.hello), SoundExpressionPlayMode.UntilDone)
85
+ music.play(music.builtInPlayableMelody(Melodies.Nyan), music.PlaybackMode.UntilDone)
86
86
  } else {
87
87
  }
88
88
  })
@@ -98,7 +98,7 @@ input.onButtonPressed(Button.A, function () {
98
98
  logging = !(logging)
99
99
  if (logging) {
100
100
  basic.showIcon(IconNames.Target)
101
- music.playSoundEffect(music.builtinSoundEffect(soundExpression.hello), SoundExpressionPlayMode.UntilDone)
101
+ music.play(music.builtInPlayableMelody(Melodies.Nyan), music.PlaybackMode.UntilDone)
102
102
  } else {
103
103
  basic.clearScreen()
104
104
  }
@@ -26,14 +26,14 @@ for (let index = 0; index <= 2; index++) {
26
26
 
27
27
  ## {Play music}
28
28
 
29
- ► From ``||music:Music||``, grab ``||music:play tone [Middle C] for [1 beat]||`` and snap it into your empty ``for`` loop.
29
+ ► From ``||music:Music||``, grab ``||music:play tone [Middle C] for [1 beat] [until done]||`` and snap it into your empty ``for`` loop.
30
30
  💡 Your simulator might start playing music. You can mute it if distracting.
31
31
  ► 1 beat is a little long. Use the **dropdown** to set the tone to play for ``||music:1/4 beat||``.
32
32
 
33
33
  ```blocks
34
34
  for (let index = 0; index <= 2; index++) {
35
35
  // @highlight
36
- music.playTone(262, music.beat(BeatFraction.Quarter))
36
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Quarter)), music.PlaybackMode.UntilDone)
37
37
  }
38
38
  ```
39
39
 
@@ -47,7 +47,7 @@ With every tone, we also want to **display** our countdown.
47
47
 
48
48
  ```blocks
49
49
  for (let index = 0; index <= 2; index++) {
50
- music.playTone(262, music.beat(BeatFraction.Quarter))
50
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Quarter)), music.PlaybackMode.UntilDone)
51
51
  // @highlight
52
52
  basic.showNumber(index)
53
53
  }
@@ -66,7 +66,7 @@ If you take a look at your simulator, you'll notice the @boardname@ flashing 0-1
66
66
 
67
67
  ```blocks
68
68
  for (let index = 0; index <= 2; index++) {
69
- music.playTone(262, music.beat(BeatFraction.Quarter))
69
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Quarter)), music.PlaybackMode.UntilDone)
70
70
  // @highlight
71
71
  basic.showNumber(3 - index)
72
72
  }
@@ -79,7 +79,7 @@ for (let index = 0; index <= 2; index++) {
79
79
 
80
80
  ```blocks
81
81
  for (let index = 0; index <= 2; index++) {
82
- music.playTone(262, music.beat(BeatFraction.Quarter))
82
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Quarter)), music.PlaybackMode.UntilDone)
83
83
  basic.showNumber(3 - index)
84
84
  }
85
85
  // @highlight
@@ -88,18 +88,18 @@ basic.showString("GO!")
88
88
 
89
89
  ## {Adding a "GO!" noise}
90
90
 
91
- ► From the ``||music:Music||`` category, grab ``||music:play tone [Middle C] for [1 beat]||`` and place it **above** your ``||basic:show string ["GO!"]||`` block and **below** your ``||loops:for||`` loop.
91
+ ► From the ``||music:Music||`` category, grab ``||music:play tone [Middle C] for [1 beat] [until done]||`` and place it **above** your ``||basic:show string ["GO!"]||`` block and **below** your ``||loops:for||`` loop.
92
92
  💡 This will let your @boardname@ play the sound and show ``GO!`` at the same time.
93
93
  ► Set the ``||music:tone||`` to be ``Middle G``.
94
94
  💡 ``Middle G`` is also tone ``392``.
95
95
 
96
96
  ```blocks
97
97
  for (let index = 0; index <= 2; index++) {
98
- music.playTone(262, music.beat(BeatFraction.Quarter))
98
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Quarter)), music.PlaybackMode.UntilDone)
99
99
  basic.showNumber(3 - index)
100
100
  }
101
101
  // @highlight
102
- music.playTone(392, music.beat(BeatFraction.Whole))
102
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Whole)), music.PlaybackMode.UntilDone)
103
103
  basic.showString("GO!")
104
104
  ```
105
105
 
@@ -111,10 +111,10 @@ If you have a @boardname@ with sound (the one with the **shiny gold** logo at th
111
111
 
112
112
  ```blocks
113
113
  for (let index = 0; index <= 2; index++) {
114
- music.playTone(262, music.beat(BeatFraction.Quarter))
114
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Quarter)), music.PlaybackMode.UntilDone)
115
115
  basic.showNumber(3 - index)
116
116
  }
117
- music.playTone(392, music.beat(BeatFraction.Whole))
117
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Whole)), music.PlaybackMode.UntilDone)
118
118
  basic.showString("GO!")
119
119
  ```
120
120
 
@@ -107,7 +107,7 @@ radio.onReceivedNumber(function (receivedNumber) {
107
107
 
108
108
  ## {Playing a sound pt. 1}
109
109
 
110
- ► From the ``||music:Music||`` category, grab a ``||music:play tone [Middle C] for [1 beat]||`` block and snap it at the **end** of the **bottom container** in your ``||logic:if then / else||`` statement.
110
+ ► From the ``||music:Music||`` category, grab a ``||music:play tone [Middle C] for [1 beat] [until done]||`` block and snap it at the **end** of the **bottom container** in your ``||logic:if then / else||`` statement.
111
111
 
112
112
  ```blocks
113
113
  radio.onReceivedNumber(function (receivedNumber) {
@@ -121,7 +121,7 @@ radio.onReceivedNumber(function (receivedNumber) {
121
121
  . . . . .
122
122
  `)
123
123
  // @highlight
124
- music.playTone(262, music.beat(BeatFraction.Whole))
124
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Whole)), music.PlaybackMode.UntilDone)
125
125
  }
126
126
  })
127
127
  ```
@@ -150,14 +150,14 @@ radio.onReceivedNumber(function (receivedNumber) {
150
150
  . . . . .
151
151
  . . . . .
152
152
  `)
153
- music.playTone(262, music.beat(BeatFraction.Whole))
153
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Whole)), music.PlaybackMode.UntilDone)
154
154
  }
155
155
  })
156
156
  ```
157
157
 
158
158
  ## {Playing a sound pt. 2}
159
159
 
160
- ► From the ``||music:Music||`` category, grab ``||music:play tone [Middle C] for [1 beat]||`` and snap it in at the **end** of the **top container** in your ``||logic:if then / else||`` statement.
160
+ ► From the ``||music:Music||`` category, grab ``||music:play tone [Middle C] for [1 beat] [until done]||`` and snap it in at the **end** of the **top container** in your ``||logic:if then / else||`` statement.
161
161
  ► Dots are shorter than dashes! Set the tone to play for ``1/4 beat``.
162
162
 
163
163
  ```blocks
@@ -171,7 +171,7 @@ radio.onReceivedNumber(function (receivedNumber) {
171
171
  . . . . .
172
172
  `)
173
173
  // @highlight
174
- music.playTone(262, music.beat(BeatFraction.Quarter))
174
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Quarter)), music.PlaybackMode.UntilDone)
175
175
  } else {
176
176
  basic.showLeds(`
177
177
  . . . . .
@@ -180,7 +180,7 @@ radio.onReceivedNumber(function (receivedNumber) {
180
180
  . . . . .
181
181
  . . . . .
182
182
  `)
183
- music.playTone(262, music.beat(BeatFraction.Whole))
183
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Whole)), music.PlaybackMode.UntilDone)
184
184
  }
185
185
  })
186
186
  ```
@@ -199,7 +199,8 @@ radio.onReceivedNumber(function (receivedNumber) {
199
199
  . . . . .
200
200
  . . . . .
201
201
  `)
202
- music.playTone(262, music.beat(BeatFraction.Quarter))
202
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Quarter)), music.PlaybackMode.UntilDone)
203
+
203
204
  } else {
204
205
  basic.showLeds(`
205
206
  . . . . .
@@ -208,7 +209,8 @@ radio.onReceivedNumber(function (receivedNumber) {
208
209
  . . . . .
209
210
  . . . . .
210
211
  `)
211
- music.playTone(262, music.beat(BeatFraction.Whole))
212
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Whole)), music.PlaybackMode.UntilDone)
213
+
212
214
  }
213
215
  // @highlight
214
216
  basic.clearScreen()
@@ -232,7 +234,8 @@ radio.onReceivedNumber(function (receivedNumber) {
232
234
  . . . . .
233
235
  . . . . .
234
236
  `)
235
- music.playTone(262, music.beat(BeatFraction.Quarter))
237
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Quarter)), music.PlaybackMode.UntilDone)
238
+
236
239
  } else {
237
240
  basic.showLeds(`
238
241
  . . . . .
@@ -241,7 +244,8 @@ radio.onReceivedNumber(function (receivedNumber) {
241
244
  . . . . .
242
245
  . . . . .
243
246
  `)
244
- music.playTone(262, music.beat(BeatFraction.Whole))
247
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Whole)), music.PlaybackMode.UntilDone)
248
+
245
249
  }
246
250
  basic.clearScreen()
247
251
  })
@@ -270,7 +274,8 @@ radio.onReceivedNumber(function (receivedNumber) {
270
274
  . . . . .
271
275
  . . . . .
272
276
  `)
273
- music.playTone(262, music.beat(BeatFraction.Quarter))
277
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Quarter)), music.PlaybackMode.UntilDone)
278
+
274
279
  } else {
275
280
  basic.showLeds(`
276
281
  . . . . .
@@ -279,7 +284,8 @@ radio.onReceivedNumber(function (receivedNumber) {
279
284
  . . . . .
280
285
  . . . . .
281
286
  `)
282
- music.playTone(262, music.beat(BeatFraction.Whole))
287
+ music.play(music.tonePlayable(262, music.beat(BeatFraction.Whole)), music.PlaybackMode.UntilDone)
288
+
283
289
  }
284
290
  basic.clearScreen()
285
291
  })
@@ -33,13 +33,13 @@ input.onLogoEvent(TouchButtonEvent.Pressed, function () {
33
33
 
34
34
  ## {Tickle sound}
35
35
 
36
- ► From the ``||music:Music||`` category, get a ``||music:play sound [giggle] until done||`` and add it to the **bottom** of your ``||input:on logo [pressed]||`` container.
36
+ ► From the ``||music:Music||`` category, get a ``||music:play melody [jump up] [in background]||`` and add it to the **bottom** of your ``||input:on logo [pressed]||`` container. Change the playback mode to ``||music:[until done]||``.
37
37
 
38
38
  ```blocks
39
39
  input.onLogoEvent(TouchButtonEvent.Pressed, function () {
40
40
  basic.showIcon(IconNames.Happy)
41
41
  //@highlight
42
- soundExpression.giggle.playUntilDone()
42
+ music.play(music.builtInPlayableMelody(Melodies.JumpUp), music.PlaybackMode.UntilDone)
43
43
  })
44
44
  ```
45
45
 
@@ -60,14 +60,14 @@ input.onGesture(Gesture.Shake, function () {
60
60
 
61
61
  ## {Dizzy sound}
62
62
 
63
- ► From the ``||music:Music||`` category, find the ``||music:play sound [giggle] until done||`` block and add it to the **bottom** of your ``||input:on [shake]||`` container.
64
- ► Click on the **dropdown** and set it so Cyrus plays a ``||music:sad||`` sound until done.
63
+ ► From the ``||music:Music||`` category, find the ``||music:play melody [dadadum] [in background]||`` block and add it to the **bottom** of your ``||input:on [shake]||`` container. Change the playback mode to ``||music:[until done]||``.
64
+ ► Click on the **dropdown** and set it so Cyrus plays a sad sound until done.
65
65
 
66
66
  ```blocks
67
67
  input.onGesture(Gesture.Shake, function () {
68
68
  basic.showIcon(IconNames.Sad)
69
69
  //@highlight
70
- soundExpression.sad.playUntilDone()
70
+ music.play(music.builtInPlayableMelody(Melodies.Wawawawaa), music.PlaybackMode.UntilDone)
71
71
  })
72
72
  ```
73
73
 
@@ -81,13 +81,13 @@ Let's ensure that Cyrus will always go back to sleep after being shaken or tickl
81
81
  ```blocks
82
82
  input.onGesture(Gesture.Shake, function () {
83
83
  basic.showIcon(IconNames.Sad)
84
- soundExpression.sad.playUntilDone()
84
+ music.play(music.builtInPlayableMelody(Melodies.Wawawawaa), music.PlaybackMode.UntilDone)
85
85
  //@highlight
86
86
  basic.showIcon(IconNames.Asleep)
87
87
  })
88
88
  input.onLogoEvent(TouchButtonEvent.Pressed, function () {
89
89
  basic.showIcon(IconNames.Happy)
90
- soundExpression.giggle.playUntilDone()
90
+ music.play(music.builtInPlayableMelody(Melodies.JumpUp), music.PlaybackMode.UntilDone)
91
91
  })
92
92
  basic.showIcon(IconNames.Asleep)
93
93
  ```
@@ -99,12 +99,12 @@ basic.showIcon(IconNames.Asleep)
99
99
  ```blocks
100
100
  input.onGesture(Gesture.Shake, function () {
101
101
  basic.showIcon(IconNames.Sad)
102
- soundExpression.sad.playUntilDone()
102
+ music.play(music.builtInPlayableMelody(Melodies.Wawawawaa), music.PlaybackMode.UntilDone)
103
103
  basic.showIcon(IconNames.Asleep)
104
104
  })
105
105
  input.onLogoEvent(TouchButtonEvent.Pressed, function () {
106
106
  basic.showIcon(IconNames.Happy)
107
- soundExpression.giggle.playUntilDone()
107
+ music.play(music.builtInPlayableMelody(Melodies.JumpUp), music.PlaybackMode.UntilDone)
108
108
  //@highlight
109
109
  basic.showIcon(IconNames.Asleep)
110
110
  })
@@ -124,12 +124,12 @@ If you have a new @boardname@ (the one with the **shiny gold** logo at the top),
124
124
  ```blocks
125
125
  input.onGesture(Gesture.Shake, function () {
126
126
  basic.showIcon(IconNames.Sad)
127
- soundExpression.sad.playUntilDone()
127
+ music.play(music.builtInPlayableMelody(Melodies.Wawawawaa), music.PlaybackMode.UntilDone)
128
128
  basic.showIcon(IconNames.Asleep)
129
129
  })
130
130
  input.onLogoEvent(TouchButtonEvent.Pressed, function () {
131
131
  basic.showIcon(IconNames.Happy)
132
- soundExpression.giggle.playUntilDone()
132
+ music.play(music.builtInPlayableMelody(Melodies.JumpUp), music.PlaybackMode.UntilDone)
133
133
  basic.showIcon(IconNames.Asleep)
134
134
  })
135
135
  basic.showIcon(IconNames.Asleep)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pxt-microbit",
3
- "version": "7.1.2",
3
+ "version": "7.1.3",
4
4
  "description": "micro:bit target for Microsoft MakeCode (PXT)",
5
5
  "keywords": [
6
6
  "JavaScript",
@@ -46,6 +46,6 @@
46
46
  },
47
47
  "dependencies": {
48
48
  "pxt-common-packages": "12.0.4",
49
- "pxt-core": "10.3.3"
49
+ "pxt-core": "10.3.6"
50
50
  }
51
51
  }
package/pxtarget.json CHANGED
@@ -200,7 +200,7 @@
200
200
  "codalTarget": {
201
201
  "name": "codal-microbit-v2",
202
202
  "url": "https://github.com/lancaster-university/codal-microbit-v2",
203
- "branch": "v0.2.67",
203
+ "branch": "v0.2.68",
204
204
  "type": "git"
205
205
  },
206
206
  "codalBinary": "MICROBIT",
@@ -590,6 +590,7 @@
590
590
 
591
591
  "dragFileImage": "/static/download/transfer.png",
592
592
  "connectDeviceImage": "/static/download/connect-microbit.gif",
593
+ "disconnectDeviceImage": "/static/download/full-reset.gif",
593
594
  "selectDeviceImage": "/static/download/selecting-microbit.gif",
594
595
  "connectionSuccessImage": "/static/download/successfully-paired.png",
595
596
  "incompatibleHardwareImage": "/static/download/incompatible.png",
package/targetconfig.json CHANGED
@@ -463,7 +463,8 @@
463
463
  "roborisen/gcube": { "tags": [ "Robotics" ] },
464
464
  "kittenbot/pxt-tabbyrobot": { "tags": [ "Robotics" ] },
465
465
  "pythom1234/pxt-oled": { "tags": [ "Lights and Display" ] },
466
- "softsmyth/lectrify-b4k": { "tags": [ "Robotics" ] }
466
+ "softsmyth/lectrify-b4k": { "tags": [ "Robotics" ] },
467
+ "davidnsousa/sonification": { "tags": [ "Software" ] }
467
468
  },
468
469
  "approvedEditorExtensionUrls": [
469
470
  "https://microsoft.github.io/ml4f/",
@@ -523,6 +524,10 @@
523
524
  {
524
525
  "title": "Checklists for Games",
525
526
  "cardsUrl": "teachertool/carousels/checklists-for-games/cards.json"
527
+ },
528
+ {
529
+ "title": "Checklists for Tools",
530
+ "cardsUrl": "teachertool/carousels/checklists-for-tools/cards.json"
526
531
  }
527
532
  ]
528
533
  },