pxt-microbit 4.1.5 → 4.1.9

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.
Files changed (59) hide show
  1. package/built/common-sim.d.ts +55 -2
  2. package/built/common-sim.js +338 -6
  3. package/built/hexcache/167b21509d45dcf8aa9ac0e8dee0ad14c23cfa41fd75bbf9d0bb839519ac56b1.hex +14849 -0
  4. package/built/hexcache/{6526a3337377701ca7bf1d9940f76fdccac145405380ee3ecc2c96f6049e34ce.hex → 5f77c6b19fd0775b3c9f06534d4d55b43bba44d755df21a7ea304a6b4bc8c33d.hex} +10762 -10738
  5. package/built/hexcache/77bf628097cfa081fbde884794a216b621827ef66ce3beeee76691a64a8f2f84.hex +14318 -0
  6. package/built/hexcache/f091c776e3c7f7fdaae7df4b89e0390e843a916f5a561903fa6188993a5bffe1.hex +20247 -0
  7. package/built/sim-strings.json +3 -3
  8. package/built/sim.js +10 -12
  9. package/built/target-strings.json +1 -1
  10. package/built/target.js +129 -49
  11. package/built/target.json +129 -49
  12. package/built/targetlight.json +6 -6
  13. package/built/web/blockly.css +1 -1
  14. package/built/web/react-common-skillmap.css +1 -0
  15. package/built/web/rtlblockly.css +1 -1
  16. package/built/web/rtlreact-common-skillmap.css +1 -0
  17. package/built/web/rtlsemantic.css +16 -16
  18. package/built/web/semantic.css +16 -16
  19. package/docs/blocks/comments.md +131 -0
  20. package/docs/blocks/loops.md +12 -0
  21. package/docs/device/usb/webusb.md +31 -9
  22. package/docs/device/usb/windows-chrome.md +14 -24
  23. package/docs/device/usb/windows-edge.md +11 -13
  24. package/docs/device/usb.md +10 -4
  25. package/docs/device.md +28 -12
  26. package/docs/docs.md +1 -1
  27. package/docs/extensions.md +126 -2
  28. package/docs/projects/SUMMARY.md +1 -1
  29. package/docs/projects/micro-chat.md +8 -8
  30. package/docs/projects/mood-radio.md +3 -1
  31. package/docs/projects/multi-dice.md +8 -6
  32. package/docs/projects/plot-acceleration.md +2 -2
  33. package/docs/projects/v2-morse-chat.md +2 -2
  34. package/docs/projects/v2-pet-hamster.md +1 -1
  35. package/docs/projects.md +3 -3
  36. package/docs/reference/basic/forever.md +17 -4
  37. package/docs/reference/basic/show-number.md +1 -1
  38. package/docs/reference/game/change.md +10 -6
  39. package/docs/reference/game/get.md +6 -6
  40. package/docs/reference/game/set.md +29 -12
  41. package/docs/reference/loops/every-interval.md +42 -0
  42. package/docs/reference/radio/on-received-buffer.md +1 -0
  43. package/docs/reference/radio/on-received-number.md +2 -0
  44. package/docs/reference/radio/on-received-string.md +1 -0
  45. package/docs/reference/radio/on-received-value.md +1 -0
  46. package/docs/reference/radio/received-packet.md +1 -0
  47. package/docs/reference/radio/send-buffer.md +1 -0
  48. package/docs/reference/radio/send-string.md +1 -0
  49. package/docs/reference/radio/set-group.md +8 -0
  50. package/docs/reference/radio/write-received-packet-to-serial.md +1 -0
  51. package/docs/reference/radio/write-value-to-serial.md +1 -0
  52. package/docs/{v2tutorials.md → tutorials-v2.md} +1 -1
  53. package/package.json +5 -5
  54. package/pxtarget.json +1 -1
  55. package/sim/public/icons/jacdac.svg +1 -1
  56. package/targetconfig.json +48 -9
  57. package/built/hexcache/02e34856c566087a1e5f0212e31686199c414ee7c8a2b9c36be7167d71548860.hex +0 -13960
  58. package/built/hexcache/447fa4d5b24ea1ca19eab3745af559cd49d5831ea3e3d6750812b3af3de0f2c4.hex +0 -14499
  59. package/built/hexcache/8fc8a1499d69a5d8cc851cf49d16112b3021ab801238204dacf84073acf90e7c.hex +0 -20222
@@ -0,0 +1,131 @@
1
+ # Comments
2
+
3
+ For simple programs, is easy to understand the steps and the flow the program might take when it runs. If you have just a few steps in your program that run one after the other in a sequence, it's fairly easy to understand what's happening at each place in your program.
4
+
5
+ The following program does 4 simple things:
6
+
7
+ 1. Show a "Hello" message
8
+ 2. Display a smiley face as part of a greeting
9
+ 2. Pause for a second so you can see the smiley
10
+ 3. Clear the screen
11
+
12
+ ```blocks
13
+ basic.showString("Hello!")
14
+ basic.showIcon(IconNames.Happy)
15
+ basic.pause(1000)
16
+ basic.clearScreen()
17
+ ```
18
+
19
+ It's quite obvious what this program is doing. Each block does one thing, the next block runs after the previous one in a sequence, then the program ends. Let's say you want the user to show that they saw the greeting. You could add button press event that shows a check mark icon.
20
+
21
+ ```blocks
22
+ basic.showString("Hello!")
23
+ basic.showIcon(IconNames.Happy)
24
+ basic.pause(1000)
25
+ basic.clearScreen()
26
+ input.onButtonPressed(Button.A, function () {
27
+ basic.showIcon(IconNames.Yes)
28
+ })
29
+ ```
30
+
31
+ You know, of course, that the button press event means that the user has acknowleged your greeting. If you shared your program with someone else though, they might not understand why you wanted to add the button press to the program.
32
+
33
+ ## Block comments
34
+
35
+ To let others know what certain parts of your program are supposed to do, you can add **comments**. Comments are a text description that says what that part of your program is doing. To put a comment on a block, open the block menu and select **Add comment**.
36
+
37
+ ![Block menu](/static/blocks/block-menu.jpg)
38
+
39
+ A place for your comment will appear and you can type in your description of what that block is for and what it's supposed to do.
40
+
41
+ ![Insert the comment](/static/blocks/insert-comment.jpg)
42
+
43
+ Once a comment is added to a block, a comment icon will show in the upper-left corner of the block. Here's our program with the comment on the ``||input:on button A press||``.
44
+
45
+ ```blocks
46
+ // Signal that the greeting was seen
47
+ input.onButtonPressed(Button.A, function () {
48
+ basic.showIcon(IconNames.Yes)
49
+ })
50
+ basic.showString("Hello!")
51
+ basic.showIcon(IconNames.Happy)
52
+ basic.pause(1000)
53
+ basic.clearScreen()
54
+ ```
55
+
56
+ In the Blocks editor, the comment is displayed when you click on the comment icon. If you view the JavaScript or Python code, you'll see a comment line directly above the button press code.
57
+
58
+ ```typescript
59
+ // Signal that the greeting was seen
60
+ input.onButtonPressed(Button.A, function () {
61
+ basic.showIcon(IconNames.Yes)
62
+ })
63
+ basic.showString("Hello!")
64
+ basic.showIcon(IconNames.Happy)
65
+ basic.pause(1000)
66
+ basic.clearScreen()
67
+ ```
68
+
69
+ When a program contains conditionals, loops, or functions, adding comments becomes important to help understand what's happening at those places in your program. The program can take a different path based on a condition, result from a function, or some other action.
70
+
71
+ ### ~ hint
72
+
73
+ #### Workspace comments
74
+
75
+ You can add comments an notes about your project with **Workspace Comments**. Just right-click on the Workspace background and choose **Add Comment** to insert your comments for the project.
76
+
77
+ ```block
78
+ /**
79
+ * This is a workspace comment.
80
+ *
81
+ * Use this space to make comments
82
+ *
83
+ * and notes about your project.
84
+ */
85
+ // Display a message
86
+ function showMessage () {
87
+ basic.showString("Workspaces have comments!")
88
+ }
89
+ ```
90
+
91
+ ### ~
92
+
93
+ The following example has a conditional inside a loop to choose one of three different mood values. For each mood, a function will display an icon for it. Each block has a comment that describes what it will do. Take a look at the JavaScript or Python code to see the comments on the code text also.
94
+
95
+ ```blocks
96
+ /**
97
+ * The mood icon project.
98
+ *
99
+ * TODO: add more moods
100
+ *
101
+ * 1. Sad
102
+ *
103
+ * 2. Confused
104
+ */
105
+ // Display an emotion of love
106
+ function heart () {
107
+ basic.showIcon(IconNames.Heart)
108
+ }
109
+ // Show a surprised expression
110
+ function surprised () {
111
+ basic.showIcon(IconNames.Surprised)
112
+ }
113
+ // Display a smiley mood
114
+ function smiley () {
115
+ basic.showIcon(IconNames.Happy)
116
+ }
117
+ // My program that shows three mood icons
118
+ // Run the loop to show 3 icons
119
+ for (let index = 0; index <= 2; index++) {
120
+ // Select an icon based on the index
121
+ if (index == 0) {
122
+ smiley()
123
+ } else if (index == 1) {
124
+ heart()
125
+ } else {
126
+ surprised()
127
+ }
128
+ // Pause for a second between moods
129
+ basic.pause(1000)
130
+ }
131
+ ```
@@ -1,3 +1,15 @@
1
1
  # @extends
2
2
 
3
3
  ## #specific
4
+
5
+ ```cards
6
+ loops.everyInterval(500, function () {})
7
+ ```
8
+
9
+ ## #seealso
10
+
11
+ [for](/blocks/loops/for),
12
+ [while](/blocks/loops/while),
13
+ [repeat](/blocks/loops/repeat),
14
+ [for of](/blocks/loops/for-of),
15
+ [every](/reference/loops/every)
@@ -1,12 +1,11 @@
1
1
  # WebUSB
2
2
 
3
- [WebUSB](https://wicg.github.io/webusb/) is an emerging web standard that allows to access @boardname@ from web pages.
4
- It allows for a **one-click download** without installing any additional app or software! It also allows to receive data from the @boardname@.
3
+ [WebUSB](https://wicg.github.io/webusb/) is a recent and developing web standard that allows you to access @boardname@ directly from a web page. It allows for a **one-click download** without installing any additional app or software! It also lets you receive data into the web page from the @boardname@.
5
4
 
6
5
  ## Support
7
6
 
8
- * Chrome 79+ browser for Android, Chrome OS, Linux, macOS and Windows 10.
9
- * Microsoft Edge 79+ browser for Android, Chrome OS, Linux, macOS and Windows 10.
7
+ * Chrome (version 79 and newer) browser for Android, Chrome OS, Linux, macOS and Windows 10.
8
+ * Microsoft Edge (version 79 and newer) browser for Android, Chrome OS, Linux, macOS and Windows 10.
10
9
 
11
10
  ## Prepare your @boardname@
12
11
 
@@ -18,13 +17,36 @@ Make sure that your @boardname@ is running version **0249** or above of the firm
18
17
 
19
18
  Here are the steps on the supported browsers:
20
19
 
21
- * connect your @boardname@ to your computer with the microUSB cable
22
- * open a project
23
- * click the triple dot icon on the **Download** button and click **Pair device**
24
- * click on the **Pair device** button and select **BBC micro:bit CMSIS-DAP** or **DAPLink CMSIS-DAP** from the list.
20
+ * Connect your @boardname@ to your computer with the Micro USB cable
21
+ * Open a project
22
+ * Click the triple dot icon on the **Download** button and then click **Connect device**.
23
+
24
+ ![Download button and menu](/static/mb/device/usb/download-button-menu.jpg)
25
+
26
+ * In the connection message window, click **Next**.
27
+
28
+ ![Connect device dialog](/static/mb/device/usb/connect-usb.jpg)
29
+
30
+ * Another message window will display telling you which device you should pair with. Click **Next** to go to the device list.
31
+
32
+ ![Device name dialog](/static/mb/device/usb/pair-dap.jpg)
33
+
34
+ * Select **BBC micro:bit CMSIS-DAP** or **DAPLink CMSIS-DAP** from the list and click **Connect**.
35
+
36
+ ![Device list for WebUSB pairing](/static/mb/device/usb/pair-device.jpg)
25
37
 
26
38
  If you don't see any devices in the list and @boardname@ has the right firmware (**0249** or above), you can create a [support ticket](https://support.microbit.org/support/tickets/new) to notify the Micro:bit Foundation of the problem. Skip the rest of these steps.
27
39
 
40
+ ![Device list for WebUSB pairing](/static/mb/device/usb/no-pair.jpg)
41
+
42
+ * When your @boardname@ is connected, you'll see the **Connected to micro:bit** message window. Click on **Done** and you're ready to go!
43
+
44
+ ![Connected message window](/static/mb/device/usb/connected.jpg)
45
+
46
+ * If the connection to your @boardname@ was unsuccessful, you'll see the **Connect failed** message. You can press **Try Again** to attempt the connection again or cancel the window and [troubleshoot](/device/usb/webusb/troubleshoot) your connection.
47
+
48
+ ![Connect failed message window](/static/mb/device/usb/connect-fail.jpg)
49
+
28
50
  ## Unpair your @boardname@ #unpair
29
51
 
30
52
  You will need to unpair your device from the editor to disable WebUSB.
@@ -33,7 +55,7 @@ You will need to unpair your device from the editor to disable WebUSB.
33
55
  * Uncheck each **BBC micro:bit CMSIS-DAP** or **DAPLink CMSIS-DAP** device
34
56
  * Reload the page
35
57
 
36
- ![](/static/webusb/unpair.gif)
58
+ ![Unpairing from the browser](/static/webusb/unpair.gif)
37
59
 
38
60
  ## One-click Download
39
61
 
@@ -1,32 +1,22 @@
1
- # Uploading from Chrome for Windows
2
-
3
- ## ~ hint
4
-
5
- Starting with Chrome 65 on Windows 10,
6
- you can use **WebUSB** to download with one-click.
7
- [Learn more about WebUSB...](/device/usb/webusb).
8
-
9
- ## ~
1
+ # Transferring from Chrome for Windows
10
2
 
11
3
  While you're writing and testing your programs, you'll mostly be [running them
12
4
  in the simulator](/device/simulator), but once you've finished your program you
13
5
  can **compile** it and run it on your micro:bit.
14
6
 
15
- The basic steps are:
7
+ ## Transfer using a WebUSB connection
16
8
 
17
- 1. Connect your micro:bit to your computer via USB
18
- 2. Click **Download** and download the `.hex` file
19
- 3. Copy the `.hex` file from your computer onto the micro:bit drive
9
+ With Chrome (version 79 and newer), you can transfer your program to the @boardname@ with a single click. If your browser supports WebUSB, you can use the **one-click download** feature to send your programs to the @boardname@. See the [WebUSB](/device/usb/webusb) page to learn how to pair your @boardname@ with a computer and transfer your programs with a single click.
20
10
 
21
- ## Requirements
11
+ ## Downloading your program as file
22
12
 
23
- You need the following things to transfer and run a script on your micro:bit:
13
+ The basic steps are:
24
14
 
25
- * A-Male to Micro USB cable to connect your computer to your micro:bit. This is
26
- the same cable that is commonly used to connect a smart phone to a computer.
27
- * A PC running Windows 7 or later.
15
+ 1. Connect your @boardname@ to your computer with a USB cable (use an A-Male to Micro USB cable)
16
+ 2. Click **Download** and download the `.hex` file
17
+ 3. Copy the `.hex` file from your computer onto the micro:bit drive
28
18
 
29
- ## Step 1: Connect your micro:bit to your computer
19
+ ### Step 1: Connect your micro:bit to your computer
30
20
 
31
21
  First, connect the micro:bit:
32
22
 
@@ -40,7 +30,7 @@ it appears as a new drive under Devices.
40
30
 
41
31
  ![](/static/mb/device/usb-windows-device.jpg)
42
32
 
43
- ## Step 2 (optional): Configure Chrome to ask where to save the file
33
+ ### Step 2 (optional): Configure Chrome to ask where to save the file
44
34
 
45
35
  You only need to do this once.
46
36
 
@@ -49,7 +39,7 @@ You only need to do this once.
49
39
  3. Find the **Downloads** settings.
50
40
  4. Enable the setting **Ask where to save each file before downloading**.
51
41
 
52
- ## Step 3: Download your program
42
+ ### Step 3: Download your program
53
43
 
54
44
  1. Open your project on @homeurl@
55
45
  2. Click **Download**
@@ -57,11 +47,11 @@ You only need to do this once.
57
47
  so save it into the `MICROBIT` drive.
58
48
  Otherwise, continue with one of the options in Step 4 below.
59
49
 
60
- ## Step 4: Transfer the file to your micro:bit
50
+ ### Step 4: Transfer the file to your micro:bit
61
51
 
62
52
  If the file was saved onto your computer, you will need to transfer it to the micro:bit.
63
53
 
64
- ## Manual transfer
54
+ #### Manual transfer
65
55
 
66
56
  Your `.hex` file (created in Step 3 above) appears as a download at the bottom of the browser.
67
57
  Click on the arrow next to the name of the file and then click **Show in folder**.
@@ -74,7 +64,7 @@ Alternatively, right-click on the hex file, choose **Send to**, and then **MICRO
74
64
 
75
65
  ![](/static/mb/device/usb-windows-sendto.jpg)
76
66
 
77
- ## Step 5: After transferring the file
67
+ ### Step 5: After transferring the file
78
68
 
79
69
  * The LED on the back of your micro:bit flashes during the transfer (which
80
70
  should only take a few seconds).
@@ -1,26 +1,24 @@
1
- # Uploading from Microsoft Edge on Windows
1
+ # Transferring from Microsoft Edge on Windows
2
2
 
3
- How to compile, transfer, and run a program on your micro:bit on **Microsoft Edge**.
3
+ How to compile, transfer, and run a program on your micro:bit with **Microsoft Edge**.
4
4
 
5
5
  While you're writing and testing your programs, you'll mostly be [running them
6
6
  in the simulator](/device/simulator), but once you've finished your program you
7
7
  can **compile** it and run it on your micro:bit.
8
8
 
9
- The basic steps are:
9
+ ## Transfer using a WebUSB connection
10
10
 
11
- 1. Connect your @boardname@ to your computer via USB
12
- 2. Click **Download** to download the `.hex` file
13
- 3. Click the **Save As** button in the bottom bar and save the `.hex` file into the MICROBIT drive
11
+ With Microsoft Edge (version 79 and newer), you can transfer your program to the @boardname@ with a single click. If your browser supports WebUSB, you can use the **one-click download** feature to send your programs to the @boardname@. See the [WebUSB](/device/usb/webusb) page to learn how to pair your @boardname@ with a computer and transfer your programs with a single click.
14
12
 
15
- ## Requirements
13
+ ## Downloading your program as file
16
14
 
17
- You need the following things to transfer and run a script on your micro:bit:
15
+ The basic steps are:
18
16
 
19
- * A-Male to Micro USB cable to connect your computer to your micro:bit. This is
20
- the same cable that is commonly used to connect a smart phone to a computer.
21
- * A PC running Windows 7 or later.
17
+ 1. Connect your @boardname@ to your computer with a USB cable (use an A-Male to Micro USB cable)
18
+ 2. Click **Download** to download the `.hex` file
19
+ 3. Click the **Save As** button in the bottom bar and save the `.hex` file into the MICROBIT drive
22
20
 
23
- ## Step 1: Connect your micro:bit to your computer
21
+ ### Step 1: Connect your micro:bit to your computer
24
22
 
25
23
  First, connect the micro:bit:
26
24
 
@@ -34,7 +32,7 @@ it appears as a new drive under Devices.
34
32
 
35
33
  ![](/static/mb/device/usb-windows-device.jpg)
36
34
 
37
- ## Step 2: Download your program
35
+ ### Step 2: Download your program
38
36
 
39
37
  1. Open your project on @homeurl@
40
38
  2. Click **Download**
@@ -1,10 +1,16 @@
1
- # Uploading programs to your @boardname@
1
+ # Transferring programs to your @boardname@
2
2
 
3
- Most of the time you'll be writing and testing your programs in the [simulator](/device/simulator). Once you've finished your program though, you can **compile** it and run it on your @boardname@. Transferring your program to the @boardname@ is as simple as saving a file to a drive on your computer.
3
+ Most of the time you'll be writing and testing your programs in the [simulator](/device/simulator). Once you've finished your program though, you can **compile** it and run it on your @boardname@. Transferring your program to the @boardname@ is as simple as clicking the **Download** button, or by saving a file to a drive on your computer.
4
4
 
5
- When you plug your @boardname@ into USB, a new drive is created with the **@drivename@** label. This is where you'll save your program.
5
+ ![micro:bit connected using USB](/static/mb/device/usb-thin.jpg)
6
6
 
7
- ![](/static/mb/device/usb-thin.jpg)
7
+ ## Transfer using a WebUSB connection
8
+
9
+ With some newer browsers, you can transfer your program to the @boardname@ with a single click. If your browser supports WebUSB, you can use the **one-click download** feature to send your programs to the @boardname@. See the [WebUSB](/device/usb/webusb) page to learn how to pair your @boardname@ with a computer and transfer your programs with a single click.
10
+
11
+ ## Downloading your program as file
12
+
13
+ If your browser doesn't support WebUSB or you want to use your computer's file system to transfer your program instead, you can download it to the @boardname@ as a file. When you plug your @boardname@ into USB, a new drive is created with the **@drivename@** label. This is where you'll save your program.
8
14
 
9
15
  The basic steps are:
10
16
 
package/docs/device.md CHANGED
@@ -1,16 +1,24 @@
1
1
  # Device
2
2
 
3
+ ### ~ hint
3
4
 
4
- ## ~ hint
5
+ #### Looking to buy a micro:bit?
5
6
 
6
- **Looking to buy a micro:bit?** See the [list of resellers](https://microbit.org/resellers).
7
+ See the [list of resellers](https://microbit.org/resellers).
7
8
 
8
- ## ~
9
+ ### ~
9
10
 
10
11
  All the bits and pieces that make up the BBC micro:bit
11
12
 
12
- ![micro:bit board layout](/static/mb/device-0.png)
13
+ ![micro:bit board layout](/static/mb/device-v2.jpg)
13
14
 
15
+ ### ~ hint
16
+
17
+ #### The current version of micro:bit is v2
18
+
19
+ The version of @boardname@ is now currently at **v2**. See the what's new in MakeCode for programming the [@boardname@ v2](/device/v2).
20
+
21
+ ### ~
14
22
 
15
23
  ## LED Screen and Status LED
16
24
 
@@ -27,17 +35,21 @@ https://www.youtube.com/watch?v=qqBmvHD5bCw
27
35
 
28
36
  ## Buttons
29
37
 
30
- Buttons A and B are a form of input. When you press a button, it completes an electrical circuit.
38
+ Buttons **A** and **B** are a form of input. When you press a button, it completes an electrical circuit.
31
39
  The micro:bit can detect either of its two buttons being pressed/released and be programmed
32
40
  to act on these events.
33
41
 
34
- Button R on the back of the micro:bit is a system button. It has different uses.
35
- When you have downloaded and run your code onto your micro:bit, press Button R to restart and run your program from the beginning.
42
+ Button **R** on the back of the micro:bit is a system button. It has different uses.
43
+ When you have downloaded and run your code onto your micro:bit, press Button **R** to restart and run your program from the beginning.
36
44
 
37
45
  Find out how buttons provide input to the @boardname@ in this video:
38
46
 
39
47
  https://www.youtube.com/watch?v=t_Qujjd_38o
40
48
 
49
+ ## Touch
50
+
51
+ Pins **0**, **1**, **2**, and the board **logo** can work as touch buttons when they are programmed for input.
52
+
41
53
  ## USB connection
42
54
 
43
55
  When you plug in your micro:bit via [USB](/device/usb), it should appear as a ``MICROBIT`` drive.
@@ -47,9 +59,9 @@ the micro:bit will appear as a ``MAINTENANCE`` drive instead of ``MICROBIT``. Th
47
59
 
48
60
  To continue programming your micro:bit YOU MUST unplug your USB and reconnect it. Check that the drive now shows as ``MICROBIT``.
49
61
 
50
- ## ~ hint
62
+ ### ~ hint
51
63
 
52
- ### Open the version file
64
+ #### Open the version file
53
65
 
54
66
  Use with caution!
55
67
  If you click on the drive while it shows the ``MAINTENANCE`` label,
@@ -57,7 +69,7 @@ you can see which version of firmware you have running on your micro:bit.
57
69
  Firmware on your micro:bit should be up-to-date already.
58
70
  You can find the version of firmware in the 'version.txt' file on the micro:bit. See the @boardname@ **[firmware](https://microbit.org/guide/firmware/)** page for more about checking your board's firmware version.
59
71
 
60
- ## ~
72
+ ### ~
61
73
 
62
74
  ## Compass
63
75
 
@@ -79,7 +91,11 @@ https://www.youtube.com/watch?v=byngcwjO51U
79
91
  ## Pins
80
92
 
81
93
  The [pins](/device/pins) can be a form of electrical input or output.
82
- There are labels for the input/output pins ``P0``, ``P1``, ``P2``, which you can attach external sensors to such as thermometers or moisture detectors.
94
+ There are labels for the input/output pins **0**, **1**, **2**, which you can attach external sensors to such as thermometers or moisture detectors.
95
+
96
+ ## Microphone
97
+
98
+ Using the microphone, your programs can detect sounds that are present. You can check for loud or quiet sounds and find out what their sound level is.
83
99
 
84
100
  ## Light level
85
101
 
@@ -119,7 +135,7 @@ and [click here to read more about the error messages you might get](/device/err
119
135
  When your micro:bit is connected to your computer with the micro USB, it doesn’t need another power source.
120
136
  When your micro:bit isn’t connected to your computer, tablet or mobile, you will need 2 x AAA 1.5 V batteries to power it.
121
137
 
122
- The pins labelled 3V and GND are the power supply pins.
138
+ The pins labelled **3V** and **GND** are the power supply pins.
123
139
  You can attach an external device such as a motor to these and power it using the battery or USB.
124
140
 
125
141
  ## Serial Communication
package/docs/docs.md CHANGED
@@ -21,7 +21,7 @@
21
21
 
22
22
  ## More questions?
23
23
 
24
- * [Frequently Asked Question](/faq)
24
+ * [Frequently Asked Questions](/faq)
25
25
  * [Help Translate](/translate)
26
26
  * [Embedding project](/share)
27
27