pxt-microbit 5.1.2 → 5.1.4
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.
- package/built/editor.js +11 -0
- package/built/sim-strings.json +1 -17
- package/built/sim.js +1 -1
- package/built/target-strings.json +1 -57
- package/built/target.js +1 -44155
- package/built/target.json +1 -44155
- package/built/targetlight.json +1 -408
- package/built/theme.json +1 -2311
- package/built/web/blockly.css +1 -1
- package/built/web/react-common-authcode.css +4 -6777
- package/built/web/react-common-multiplayer.css +13 -0
- package/built/web/react-common-skillmap.css +1 -1
- package/built/web/rtlblockly.css +1 -1
- package/built/web/rtlreact-common-authcode.css +13 -0
- package/built/web/rtlreact-common-multiplayer.css +13 -0
- package/built/web/rtlreact-common-skillmap.css +1 -1
- package/built/web/rtlsemantic.css +2 -2
- package/built/web/semantic.css +2 -2
- package/docs/device/v2.md +1 -1
- package/docs/extensions.md +40 -0
- package/docs/microcode.md +27 -0
- package/docs/projects/SUMMARY.md +6 -0
- package/docs/projects/electric-guitar/code.md +42 -0
- package/docs/projects/electric-guitar/make.md +40 -0
- package/docs/projects/electric-guitar.md +27 -0
- package/docs/projects/hot-potato.md +1 -1
- package/docs/projects/jonnys-bird.md +110 -0
- package/docs/projects/music.md +10 -0
- package/docs/projects/red-light-green-light.md +1 -1
- package/docs/projects/timing-gates.md +4 -4
- package/docs/projects/turtle-square.md +2 -2
- package/docs/projects/watch/timer.md +1 -1
- package/docs/projects.md +6 -0
- package/docs/reference/music/beat.md +1 -7
- package/docs/reference/music/change-tempo-by.md +5 -3
- package/docs/reference/music/play-tone.md +28 -15
- package/docs/reference/music/rest.md +28 -10
- package/docs/reference/music/ring-tone.md +7 -6
- package/docs/reference/music/set-tempo.md +7 -3
- package/docs/translate.md +53 -22
- package/docs/windows-app.md +3 -3
- package/package.json +2 -2
- package/pxtarget.json +34 -4
- package/targetconfig.json +16 -3
package/built/editor.js
CHANGED
|
@@ -3373,7 +3373,18 @@ class DAPWrapper {
|
|
|
3373
3373
|
isConnecting() {
|
|
3374
3374
|
return this.io.isConnecting() || (this.io.isConnected() && !this.initialized);
|
|
3375
3375
|
}
|
|
3376
|
+
async getBaudRate() {
|
|
3377
|
+
const readSerialSettings = new Uint8Array([0x81]); // get serial settings
|
|
3378
|
+
const serialSettings = await this.dapCmd(readSerialSettings);
|
|
3379
|
+
const baud = (serialSettings[4] << 24) + (serialSettings[3] << 16) + (serialSettings[2] << 8) + serialSettings[1];
|
|
3380
|
+
return baud;
|
|
3381
|
+
}
|
|
3376
3382
|
async setBaudRate() {
|
|
3383
|
+
const currentBaudRate = await this.getBaudRate();
|
|
3384
|
+
if (currentBaudRate === 115200) {
|
|
3385
|
+
log(`baud rate already set to 115200`);
|
|
3386
|
+
return;
|
|
3387
|
+
}
|
|
3377
3388
|
log(`set baud rate to 115200`);
|
|
3378
3389
|
const baud = new Uint8Array(5);
|
|
3379
3390
|
baud[0] = 0x82; // set baud
|
package/built/sim-strings.json
CHANGED
|
@@ -1,17 +1 @@
|
|
|
1
|
-
{
|
|
2
|
-
"Sound Level": "Sound Level",
|
|
3
|
-
"Thermometer": "Thermometer",
|
|
4
|
-
"acceleration.pitch": "acceleration.pitch",
|
|
5
|
-
"acceleration.roll": "acceleration.roll",
|
|
6
|
-
"acceleration.strength": "acceleration.strength",
|
|
7
|
-
"acceleration.x": "acceleration.x",
|
|
8
|
-
"acceleration.y": "acceleration.y",
|
|
9
|
-
"acceleration.z": "acceleration.z",
|
|
10
|
-
"heading": "heading",
|
|
11
|
-
"lightLevel": "lightLevel",
|
|
12
|
-
"logo touch (micro:bit v2 needed)": "logo touch (micro:bit v2 needed)",
|
|
13
|
-
"micro:bit v2 needed": "micro:bit v2 needed",
|
|
14
|
-
"microphone (micro:bit v2 needed)": "microphone (micro:bit v2 needed)",
|
|
15
|
-
"sound level": "sound level",
|
|
16
|
-
"temperature": "temperature"
|
|
17
|
-
}
|
|
1
|
+
{"Sound Level":"Sound Level","Thermometer":"Thermometer","acceleration.pitch":"acceleration.pitch","acceleration.roll":"acceleration.roll","acceleration.strength":"acceleration.strength","acceleration.x":"acceleration.x","acceleration.y":"acceleration.y","acceleration.z":"acceleration.z","heading":"heading","lightLevel":"lightLevel","logo touch (micro:bit v2 needed)":"logo touch (micro:bit v2 needed)","micro:bit v2 needed":"micro:bit v2 needed","microphone (micro:bit v2 needed)":"microphone (micro:bit v2 needed)","sound level":"sound level","temperature":"temperature"}
|
package/built/sim.js
CHANGED
|
@@ -1,57 +1 @@
|
|
|
1
|
-
{
|
|
2
|
-
"A Blocks / JavaScript code editor for the micro:bit powered by Microsoft MakeCode.": "A Blocks / JavaScript code editor for the micro:bit powered by Microsoft MakeCode.",
|
|
3
|
-
"A micro-servo library": "A micro-servo library",
|
|
4
|
-
"Adds new blocks for message communication in the radio category": "Adds new blocks for message communication in the radio category",
|
|
5
|
-
"BETA - Camera, remote control and other Bluetooth services. App required.": "BETA - Camera, remote control and other Bluetooth services. App required.",
|
|
6
|
-
"Behind the MakeCode Hardware": "Behind the MakeCode Hardware",
|
|
7
|
-
"Blocks to JavaScript": "Blocks to JavaScript",
|
|
8
|
-
"Bluetooth services": "Bluetooth services",
|
|
9
|
-
"Buy": "Buy",
|
|
10
|
-
"Can't import microbit.co.uk scripts...": "Can't import microbit.co.uk scripts...",
|
|
11
|
-
"Coding Cards": "Coding Cards",
|
|
12
|
-
"Coding for Teachers": "Coding for Teachers",
|
|
13
|
-
"Color manipulation": "Color manipulation",
|
|
14
|
-
"Courses": "Courses",
|
|
15
|
-
"Data logging to flash memory. micro:bit (V2) only.": "Data logging to flash memory. micro:bit (V2) only.",
|
|
16
|
-
"Data logging to flash.": "Data logging to flash.",
|
|
17
|
-
"Deep Dive": "Deep Dive",
|
|
18
|
-
"Disable Bluetooth Event Service": "Disable Bluetooth Event Service",
|
|
19
|
-
"Download cancelled": "Download cancelled",
|
|
20
|
-
"Download failed, please try again": "Download failed, please try again",
|
|
21
|
-
"Download for V2 only": "Download for V2 only",
|
|
22
|
-
"Fashion": "Fashion",
|
|
23
|
-
"Games": "Games",
|
|
24
|
-
"Go Back": "Go Back",
|
|
25
|
-
"Go to the old editor": "Go to the old editor",
|
|
26
|
-
"Great coding skills! Unfortunately, your program is too large to fit on a micro:bit V1😢. You can go back and try to make your program smaller, or you can download your program onto a micro:bit V2.": "Great coding skills! Unfortunately, your program is too large to fit on a micro:bit V1😢. You can go back and try to make your program smaller, or you can download your program onto a micro:bit V2.",
|
|
27
|
-
"Hardware": "Hardware",
|
|
28
|
-
"Importing microbit.co.uk programs is not supported in this editor anymore. Please open this script in the https://makecode.microbit.org/v0 editor.": "Importing microbit.co.uk programs is not supported in this editor anymore. Please open this script in the https://makecode.microbit.org/v0 editor.",
|
|
29
|
-
"Jacdac": "Jacdac",
|
|
30
|
-
"JustWorks pairing (default): Pairing is automatic once the pairing is initiated.": "JustWorks pairing (default): Pairing is automatic once the pairing is initiated.",
|
|
31
|
-
"Live Coding": "Live Coding",
|
|
32
|
-
"Microsoft MakeCode for micro:bit": "Microsoft MakeCode for micro:bit",
|
|
33
|
-
"Music": "Music",
|
|
34
|
-
"New? Start here!": "New? Start here!",
|
|
35
|
-
"No Pairing Required: Anyone can connect via Bluetooth.": "No Pairing Required: Anyone can connect via Bluetooth.",
|
|
36
|
-
"Oops, there was a problem downloading your code": "Oops, there was a problem downloading your code",
|
|
37
|
-
"Passkey pairing: Pairing requires 6 digit key to pair.": "Passkey pairing: Pairing requires 6 digit key to pair.",
|
|
38
|
-
"Radio Games": "Radio Games",
|
|
39
|
-
"Reference": "Reference",
|
|
40
|
-
"Science": "Science",
|
|
41
|
-
"Science Experiments": "Science Experiments",
|
|
42
|
-
"Settings storage in internal flash": "Settings storage in internal flash",
|
|
43
|
-
"Support": "Support",
|
|
44
|
-
"The microbit core library": "The microbit core library",
|
|
45
|
-
"The microphone library": "The microphone library",
|
|
46
|
-
"The radio services": "The radio services",
|
|
47
|
-
"Tools": "Tools",
|
|
48
|
-
"Toys": "Toys",
|
|
49
|
-
"Turtle": "Turtle",
|
|
50
|
-
"Tutorials": "Tutorials",
|
|
51
|
-
"Tutorials for the new micro:bit (V2)": "Tutorials for the new micro:bit (V2)",
|
|
52
|
-
"makecode.microbit.org": "makecode.microbit.org",
|
|
53
|
-
"{id:type}Image": "Image",
|
|
54
|
-
"{id:type}LedSprite": "LedSprite",
|
|
55
|
-
"{id:var}image": "image",
|
|
56
|
-
"{id:var}sprite": "sprite"
|
|
57
|
-
}
|
|
1
|
+
{"A Blocks / JavaScript code editor for the micro:bit powered by Microsoft MakeCode.":"A Blocks / JavaScript code editor for the micro:bit powered by Microsoft MakeCode.","A micro-servo library":"A micro-servo library","Adds new blocks for message communication in the radio category":"Adds new blocks for message communication in the radio category","BETA - Camera, remote control and other Bluetooth services. App required.":"BETA - Camera, remote control and other Bluetooth services. App required.","Behind the MakeCode Hardware":"Behind the MakeCode Hardware","Blocks to JavaScript":"Blocks to JavaScript","Bluetooth services":"Bluetooth services","Buy":"Buy","Can't import microbit.co.uk scripts...":"Can't import microbit.co.uk scripts...","Coding Cards":"Coding Cards","Coding for Teachers":"Coding for Teachers","Color manipulation":"Color manipulation","Courses":"Courses","Data logging to flash memory. micro:bit (V2) only.":"Data logging to flash memory. micro:bit (V2) only.","Data logging to flash.":"Data logging to flash.","Deep Dive":"Deep Dive","Disable Bluetooth Event Service":"Disable Bluetooth Event Service","Download cancelled":"Download cancelled","Download failed, please try again":"Download failed, please try again","Download for V2 only":"Download for V2 only","Fashion":"Fashion","Games":"Games","Go Back":"Go Back","Go to the old editor":"Go to the old editor","Great coding skills! Unfortunately, your program is too large to fit on a micro:bit V1😢. You can go back and try to make your program smaller, or you can download your program onto a micro:bit V2.":"Great coding skills! Unfortunately, your program is too large to fit on a micro:bit V1😢. You can go back and try to make your program smaller, or you can download your program onto a micro:bit V2.","Hardware":"Hardware","Importing microbit.co.uk programs is not supported in this editor anymore. Please open this script in the https://makecode.microbit.org/v0 editor.":"Importing microbit.co.uk programs is not supported in this editor anymore. Please open this script in the https://makecode.microbit.org/v0 editor.","Jacdac":"Jacdac","JustWorks pairing (default): Pairing is automatic once the pairing is initiated.":"JustWorks pairing (default): Pairing is automatic once the pairing is initiated.","Live Coding":"Live Coding","MicroCode for the new micro:bit (V2)":"MicroCode for the new micro:bit (V2)","Microsoft MakeCode for micro:bit":"Microsoft MakeCode for micro:bit","Music":"Music","New? Start here!":"New? Start here!","No Pairing Required: Anyone can connect via Bluetooth.":"No Pairing Required: Anyone can connect via Bluetooth.","Oops, there was a problem downloading your code":"Oops, there was a problem downloading your code","Passkey pairing: Pairing requires 6 digit key to pair.":"Passkey pairing: Pairing requires 6 digit key to pair.","Radio Games":"Radio Games","Reference":"Reference","Science":"Science","Science Experiments":"Science Experiments","Settings storage in internal flash":"Settings storage in internal flash","Support":"Support","The microbit core library":"The microbit core library","The microphone library":"The microphone library","The radio services":"The radio services","Tools":"Tools","Toys":"Toys","Turtle":"Turtle","Tutorials":"Tutorials","Tutorials for the new micro:bit (V2)":"Tutorials for the new micro:bit (V2)","makecode.microbit.org":"makecode.microbit.org","{id:type}Image":"Image","{id:type}LedSprite":"LedSprite","{id:var}image":"image","{id:var}sprite":"sprite"}
|