Compare commits
556 Commits
Author | SHA1 | Date | |
---|---|---|---|
5344717749 | |||
1bbf8a4473 | |||
f1d9075c9d | |||
cffbdb9eae | |||
cc75ae57da | |||
068300c5f5 | |||
251f198441 | |||
fe39902d10 | |||
030cd46c5f | |||
8cc2f1219f | |||
39a629cc58 | |||
df65c34f15 | |||
00fefe10d6 | |||
d442f5aa41 | |||
3311865817 | |||
2cd2950496 | |||
b0de3d8c1b | |||
acefe3ae11 | |||
cb6c83eec7 | |||
e0c8f65a65 | |||
a4e02dcd03 | |||
fb5776ec41 | |||
d852fd961b | |||
1ed8122804 | |||
c5cec3a6ba | |||
ba94322d4c | |||
225f1da6d5 | |||
a06331eef1 | |||
aa741ce8de | |||
61fe5091fe | |||
3d90e13797 | |||
469767a40a | |||
604fa764e6 | |||
25cf2a9cdb | |||
7549f865d6 | |||
a5de9d88bb | |||
0437df10de | |||
2079173dfa | |||
018a1e7528 | |||
757f95d984 | |||
8bc3fdc8ba | |||
e8a1e73cf5 | |||
e9b2b239ad | |||
5ad2288a9f | |||
92d13ef343 | |||
471ca5d915 | |||
f745079728 | |||
d179f18ef3 | |||
805fc6c787 | |||
374bbb8304 | |||
25452efc92 | |||
80b9c715b2 | |||
cb816c91ad | |||
3012068986 | |||
4c9c7d6a69 | |||
ad3652c290 | |||
d8971829e3 | |||
8ca4558fc2 | |||
d85b5c5129 | |||
95b1c6a50f | |||
4dc2872286 | |||
6c9ff804c8 | |||
7581b5af9e | |||
07504027f9 | |||
a0e133864a | |||
0285711954 | |||
91be998d7e | |||
e862869327 | |||
8047cb2612 | |||
8e2ffefd2c | |||
092e7b0522 | |||
42454ecd57 | |||
2563fd6031 | |||
e0c1f2dca0 | |||
c80574ed3f | |||
b28b5cb6b7 | |||
d1f11059db | |||
6de5c6afdf | |||
b72c7c0c4f | |||
352c1ca5ec | |||
6d940a9ec7 | |||
c070173346 | |||
6fcf68f174 | |||
02f2a85d28 | |||
f63196908e | |||
ad48ee12ca | |||
83aeb24a98 | |||
fc5ecd9f10 | |||
0b3b840ac1 | |||
60c09809e7 | |||
148067a143 | |||
6f34887c94 | |||
64a9930c2e | |||
5815e16647 | |||
c4f5e425c2 | |||
361ae7a2d2 | |||
3769402ade | |||
5c3c83eb52 | |||
0f07a89981 | |||
11d887a213 | |||
8150b2dbb0 | |||
89f41f23da | |||
6b78e08053 | |||
186c86d2b1 | |||
181c71d2dd | |||
be05da3232 | |||
5958157a76 | |||
f72b825377 | |||
d76af5e5af | |||
23f48db20b | |||
2975bf2b55 | |||
5314515619 | |||
75b2db9f67 | |||
cf2e39f1b2 | |||
6d15d69aa1 | |||
72a0940235 | |||
b08dd8a7d2 | |||
def648a98b | |||
32a92789b3 | |||
9956bb06fb | |||
83b9aecd7a | |||
17ab24eaa9 | |||
9c5d5f9a86 | |||
43a13e0877 | |||
fe0915484d | |||
87a65aa38f | |||
1317da8904 | |||
62b2881e2a | |||
bf482a2ac9 | |||
243600ad8f | |||
349caa4aed | |||
56bbcde299 | |||
7e9cc791ec | |||
d5194b8d28 | |||
12b1eb349b | |||
68dc195ea4 | |||
0251b914f2 | |||
1fc818767c | |||
9aeaec477f | |||
7fc796d2cb | |||
cb1cd2a4b4 | |||
39bd7aa0eb | |||
140ba64462 | |||
42fe96aa5a | |||
1a5b42026d | |||
9fe649aa3c | |||
a97dfb17b2 | |||
277c9903bb | |||
0de8a84de2 | |||
a302bbfc2b | |||
bcb682b602 | |||
e4a7531541 | |||
348964c888 | |||
8b3461bebd | |||
e511630c2e | |||
db156d5df0 | |||
93c6975400 | |||
abc93dd7da | |||
85cfc86bf8 | |||
b66d4f2d64 | |||
5843deab11 | |||
8d5edc38bb | |||
0309e50058 | |||
aa40e7b169 | |||
75cf8da396 | |||
db9b6a995b | |||
fb255edafe | |||
f4c39f74e8 | |||
3e56e2c3e2 | |||
79b5f8cc88 | |||
312729142f | |||
5bd4aed0e1 | |||
cfaa4ae3ef | |||
faa839d59f | |||
630687bfce | |||
2b300a4094 | |||
5fb8c0de6e | |||
1f65cd59a8 | |||
fd75bb61d6 | |||
4d2f72575b | |||
1fe3d3e01a | |||
0c6e65d828 | |||
ae9c0603f2 | |||
06aeca228a | |||
31fd4799a5 | |||
7d8e6891ee | |||
462234b1c0 | |||
dad1bd0cd4 | |||
b71bfef418 | |||
2e0a34c99b | |||
4133828a10 | |||
f0c19bc976 | |||
a09b4a083f | |||
15dff9af08 | |||
6fa5c1b688 | |||
d76cea1477 | |||
ca09a0a833 | |||
fcc864823e | |||
166dc27b93 | |||
66e50473c4 | |||
58452e1ca3 | |||
2b7498ea2d | |||
5ab2b97663 | |||
ffe0f0fb32 | |||
f27d13f88e | |||
31067dcef8 | |||
123f6c84b2 | |||
c5f07ca67c | |||
22fc7dee18 | |||
1f58b649c5 | |||
fc75fe8e16 | |||
b399c37527 | |||
a054fdd3d3 | |||
a239589913 | |||
98a046237c | |||
eb385ec532 | |||
2fdce16685 | |||
74eb77a9ae | |||
4fba96588f | |||
03c07bdcf5 | |||
6da1bc3cb1 | |||
dfc9ca1db4 | |||
83b64c1e54 | |||
a0cf8655f2 | |||
e4cf2c99c0 | |||
076fb8487e | |||
c725561389 | |||
3dc781f4fd | |||
4456767f2d | |||
6dba240899 | |||
d7172a1f3a | |||
245ff9d5b2 | |||
bfb258ce61 | |||
63beb2cac7 | |||
73d3dce139 | |||
21be8a5021 | |||
03a82d6bcd | |||
60ea0f0cd5 | |||
f69a0d5289 | |||
e2e8536b37 | |||
4096875a88 | |||
9825a90df2 | |||
7ad5d123a3 | |||
3599483ed2 | |||
7a6818931f | |||
eda38ebbc4 | |||
026f7a3180 | |||
f58fcb60e2 | |||
dbda86abb5 | |||
3c13565e7c | |||
f8524cf1a7 | |||
bf4b1090fc | |||
ea4d8cf66a | |||
b32ae4e61a | |||
1df90a6ea3 | |||
09ac2a7a47 | |||
06565995d3 | |||
1a73aec74d | |||
5516d041d6 | |||
7aac8ab5f3 | |||
73da17a395 | |||
16197f2987 | |||
5ec7eb6f04 | |||
f05ad887b8 | |||
c8a7b73101 | |||
0b9d029ecc | |||
d6f0fee300 | |||
d78b4c5ee3 | |||
13f5ebd6a7 | |||
ccbebabc55 | |||
5c61677ab9 | |||
21025b5f83 | |||
f9a0729b63 | |||
8e456f5c3c | |||
e05e147d6a | |||
fc83cc5d5b | |||
7974f36c31 | |||
6513dbc901 | |||
97215e894a | |||
1368ee824b | |||
f2344ac52e | |||
299acea61f | |||
a99f0212ac | |||
d128dad3dc | |||
3d7ebeb7b7 | |||
304cbb5ee3 | |||
0f7ec45db4 | |||
2bc2bda502 | |||
51cb7a5299 | |||
068eb7017f | |||
bb4966dca7 | |||
e981d1b95d | |||
4f91d992a5 | |||
c91bf3ea7c | |||
c6f92aa1cb | |||
5de5b64e61 | |||
1d442b7de9 | |||
8508d5e8ba | |||
f04a76a95f | |||
88969da972 | |||
b19e5c4e4b | |||
15caad8b02 | |||
22ce6a8716 | |||
c288242b9c | |||
a8249e94c5 | |||
92fbc1552b | |||
92f29ef5d6 | |||
c7fabfd994 | |||
df49475a26 | |||
17d8e61ebc | |||
dbdc1810cd | |||
d3b7530b17 | |||
e31f4c934f | |||
b22ec74f7e | |||
cd38f670d2 | |||
8fca537251 | |||
cf39956e2d | |||
9e3a8ab4ed | |||
022a6765bf | |||
1e4edc5109 | |||
caf273be84 | |||
ccba83cfab | |||
8417c6ce57 | |||
39236fe8b2 | |||
f50aabeec5 | |||
c2167b6405 | |||
59dcd1ee72 | |||
bf8f73f885 | |||
a81e3b9f11 | |||
e90b6a7946 | |||
7ce6c8b773 | |||
022651b338 | |||
8d0bc280a0 | |||
7b61a8fbc3 | |||
1d45652ab2 | |||
4db9c8bc0a | |||
df99fa1699 | |||
ef218bcc24 | |||
99ccbfc348 | |||
101306b8f8 | |||
e167f109b0 | |||
e5d78d65cb | |||
b79881ade0 | |||
a05d12abdf | |||
6c2cd1a658 | |||
90204ce58f | |||
d8c4eeeb13 | |||
df6249931d | |||
de61919fc1 | |||
105da90f3f | |||
023fc8fe96 | |||
442b014233 | |||
54681668ad | |||
db1724b9fa | |||
7ed5a9bca6 | |||
7de61c7254 | |||
df99f18c8d | |||
6d7bd63c3a | |||
9d1f39981d | |||
e4e87c427d | |||
1fece05e5e | |||
186c7e2e3f | |||
3322119f35 | |||
515be621a0 | |||
b337f4cf1c | |||
e6e6016bc0 | |||
3f23f5afa8 | |||
f0df0222c0 | |||
2a371b9cc6 | |||
3211999583 | |||
b29862d566 | |||
b262d944b7 | |||
1b89d08337 | |||
6bdae6547a | |||
30a67b729d | |||
3e2c61e212 | |||
7a37dec196 | |||
bac792f188 | |||
e4c3fa0e57 | |||
76f7df7579 | |||
d7e671175c | |||
f4b7230a67 | |||
afe0f9b0f7 | |||
23b6edc4bf | |||
13b3c1a194 | |||
7e58b9b699 | |||
08a860bd80 | |||
4a966a73f1 | |||
542216000c | |||
b323929f03 | |||
1e3647738d | |||
838b3f7f9a | |||
0ff2d7866d | |||
4c978d793a | |||
06ca53ae89 | |||
84990d66a9 | |||
4825172423 | |||
b69af383a6 | |||
6e1a613798 | |||
b5005f3b10 | |||
044b585f24 | |||
94fe26e390 | |||
ca832f52db | |||
6f2fe212df | |||
96be357af1 | |||
36df6cfb03 | |||
e1095b3d4a | |||
9257e08f0d | |||
149f256454 | |||
ba00d91bf2 | |||
764994a633 | |||
ab85cf2d0a | |||
ce7ecd5121 | |||
40fb4107cf | |||
9b8816f781 | |||
27756d922e | |||
0b1d7068e9 | |||
0a5b4b9329 | |||
2da1b3111f | |||
f600ee270e | |||
7c3d499109 | |||
8ed79e7133 | |||
95ab3be26e | |||
83700b4e14 | |||
989699c620 | |||
e0c80361db | |||
67153fccc5 | |||
3c96cfcc0a | |||
03add213d9 | |||
e43837d358 | |||
be207282e3 | |||
d6e4c5a717 | |||
5384ec567d | |||
6ea8a59f58 | |||
03c6100635 | |||
173b5dfd18 | |||
c86331b857 | |||
43a3942147 | |||
10cc883ef7 | |||
2cbb3e05b0 | |||
eac73932be | |||
62e8f698a5 | |||
d0331720b4 | |||
724ac19281 | |||
3e193e97bf | |||
23c1789976 | |||
87b08bf6f3 | |||
3e534f7329 | |||
7f8499bb5f | |||
4bcde58c0c | |||
dd5df88dea | |||
f35ed0205b | |||
7379c8dfe7 | |||
574de3a15e | |||
a3c08ddb01 | |||
070cc42d36 | |||
77aa7b86d8 | |||
f912ea6104 | |||
b06bc6bc6c | |||
af3189d8b5 | |||
661157f112 | |||
141bc6bddb | |||
bd06fb80f3 | |||
2c874570ce | |||
08ee2b2017 | |||
499d97b07c | |||
32b7400e9e | |||
90717cfc33 | |||
bd3b149dcc | |||
fafd3d37da | |||
138425c0fb | |||
231cd41f7a | |||
eb7cd5d97c | |||
a4a9af28a4 | |||
6c253182e4 | |||
0198be6dda | |||
57ab6d153d | |||
fd0bd4ef39 | |||
8b2ae10980 | |||
4627328bcd | |||
80989cf4c9 | |||
00b193b126 | |||
e65db0b756 | |||
8f211a5c19 | |||
379a6a26be | |||
8398c8efdb | |||
f41310e879 | |||
82198020de | |||
09d6b728b0 | |||
9147cb98c2 | |||
6d29cd40cb | |||
d5b4ec5255 | |||
b8286ab0b9 | |||
ac1380ec92 | |||
a433988929 | |||
d837a515dc | |||
4be657e84d | |||
c90f00f6d0 | |||
ecc880cf8d | |||
fbb3280bc8 | |||
29f081eb03 | |||
49ab5ec099 | |||
5277cc847c | |||
e11b11d19c | |||
57c1ae0f99 | |||
2129601e6a | |||
e1727dc917 | |||
ecc9319334 | |||
81758f2555 | |||
7825bd1579 | |||
ac81067f82 | |||
b1958d77e7 | |||
232744520b | |||
ac9ebf6776 | |||
c97098b99e | |||
b39a7f3484 | |||
806f60a419 | |||
0bb7295d86 | |||
60bf3df1d8 | |||
b8a3fa345f | |||
ec1ceea138 | |||
b618bfec59 | |||
2467b3c4c9 | |||
69194b0b76 | |||
3339a7660a | |||
9c3be9fe37 | |||
c0413aa192 | |||
6c626f9c98 | |||
f95b39cd62 | |||
bba0af6193 | |||
a8a92ca806 | |||
6f066e4397 | |||
7dd27b3da1 | |||
41514cfa64 | |||
53ad94d0ad | |||
220a774238 | |||
7444b28ebb | |||
8abc137d60 | |||
3cad464ea5 | |||
b6b23314cb | |||
34381ed171 | |||
a627d19ebf | |||
4cbdd72770 | |||
6412d52f99 | |||
c75bd0b06d | |||
79afed3667 | |||
e040407070 | |||
123d41cb64 | |||
0dc2548d0b | |||
b4b3a24ed2 | |||
ed653e8a37 | |||
31f91d4e24 | |||
8536126e23 | |||
f1ea113fc0 | |||
550528c695 | |||
89e1819399 |
35
.github/ISSUE_TEMPLATE/bug_report.md
vendored
Normal file
@ -0,0 +1,35 @@
|
||||
---
|
||||
name: Bug report
|
||||
about: Create a report to help us improve
|
||||
|
||||
---
|
||||
|
||||
**Describe the bug**
|
||||
A clear and concise description of what the bug is.
|
||||
|
||||
**To Reproduce**
|
||||
Steps to reproduce the behavior:
|
||||
1. Go to '...'
|
||||
2. Click on '....'
|
||||
3. Scroll down to '....'
|
||||
4. See error
|
||||
|
||||
**Expected behavior**
|
||||
A clear and concise description of what you expected to happen.
|
||||
|
||||
**Screenshots**
|
||||
Add screenshots to help explain your problem. You can copy paste the screenshot in the github report. The .gif screen recording is very useful as well.
|
||||
|
||||
**Desktop (please complete the following information):**
|
||||
- OS: [e.g. iOS]
|
||||
- Browser [e.g. chrome, safari]
|
||||
- Version [e.g. 22]
|
||||
|
||||
**Smartphone (please complete the following information):**
|
||||
- Device: [e.g. iPhone6]
|
||||
- OS: [e.g. iOS8.1]
|
||||
- Browser [e.g. stock browser, safari]
|
||||
- Version [e.g. 22]
|
||||
|
||||
**Additional context**
|
||||
Add any other context about the problem here.
|
17
.github/ISSUE_TEMPLATE/feature_request.md
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
---
|
||||
name: Feature request
|
||||
about: Suggest an idea for this project
|
||||
|
||||
---
|
||||
|
||||
**Is your feature request related to a problem? Please describe.**
|
||||
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||
|
||||
**Describe the solution you'd like**
|
||||
A clear and concise description of what you want to happen.
|
||||
|
||||
**Describe alternatives you've considered**
|
||||
A clear and concise description of any alternative solutions or features you've considered.
|
||||
|
||||
**Additional context**
|
||||
Add any other context or screenshots about the feature request here.
|
1
.gitignore
vendored
@ -17,6 +17,7 @@ clients/**/bin/**
|
||||
clients/**/obj/**
|
||||
clients/electron/projects
|
||||
libs/**/_locales/**
|
||||
package-lock.json
|
||||
|
||||
videos/**
|
||||
|
||||
|
9
.travis.yml
Normal file
@ -0,0 +1,9 @@
|
||||
language: node_js
|
||||
node_js:
|
||||
- "8.9.0"
|
||||
script:
|
||||
- "node node_modules/pxt-core/built/pxt.js travis"
|
||||
sudo: false
|
||||
cache:
|
||||
directories:
|
||||
- node_modules
|
34
README.md
@ -1,13 +1,8 @@
|
||||
# LEGO Mindstorms EV3 target for PXT
|
||||
# LEGO® MINDSTORMS® Education EV3 for Microsoft MakeCode [](https://travis-ci.org/microsoft/pxt-ev3)
|
||||
|
||||
[](https://ci2.dot.net/job/Private/job/pxt_project_rainbow/job/master/job/pxt-ev3_Push/)
|
||||
This repo contains the editor target hosted at https://makecode.mindstorms.com
|
||||
|
||||
This repo contains the editor target hosted at https://makecode.legoeducation.com
|
||||
|
||||
LEGO Auth: https://src.education.lego.com/groups/ev3-makecode (use Google Authenticator)
|
||||
LEGO Chat: https://chat.internal.education.lego.com/make-code/channels/town-square
|
||||
|
||||
## Local Dev setup
|
||||
## Local setup
|
||||
|
||||
These instructions assume familiarity with dev tools and languages.
|
||||
|
||||
@ -15,18 +10,25 @@ These instructions assume familiarity with dev tools and languages.
|
||||
* install Docker; make sure `docker` command is in your `PATH`
|
||||
* (optional) install [Visual Studio Code](https://code.visualstudio.com/)
|
||||
|
||||
In a common folder,
|
||||
|
||||
* clone https://github.com/Microsoft/pxt to ``pxt`` folder
|
||||
* clone https://github.com/Microsoft/pxt-common-packages to ``pxt-common-packages`` folder
|
||||
* clone https://github.com/Microsoft/pxt-ev3 to ``pxt-ev3`` folder
|
||||
* go to ``pxt`` and run
|
||||
|
||||
```
|
||||
npm install
|
||||
typings install
|
||||
```
|
||||
|
||||
* to run the local server,
|
||||
```
|
||||
pxt serve --cloud
|
||||
```
|
||||
|
||||
## Local Dev setup
|
||||
|
||||
In the common folder,
|
||||
|
||||
* clone https://github.com/Microsoft/pxt to ``pxt`` folder
|
||||
* clone https://github.com/Microsoft/pxt-common-packages to ``pxt-common-packages`` folder
|
||||
|
||||
* go to ``pxt-common-packages`` and run
|
||||
|
||||
```
|
||||
@ -58,12 +60,12 @@ cd libs/core
|
||||
pxt deploy
|
||||
```
|
||||
|
||||
### Jenkins build
|
||||
https://ci2.dot.net/job/Private/job/pxt_project_rainbow/job/master/
|
||||
|
||||
## License
|
||||
MIT
|
||||
|
||||
## Trademarks
|
||||
MICROSOFT, the Microsoft Logo, and MAKECODE are registered trademarks of Microsoft Corporation. They can only be used for the purposes described in and in accordance with Microsoft’s Trademark and Brand guidelines published at https://www.microsoft.com/en-us/legal/intellectualproperty/trademarks/usage/general.aspx. If the use is not covered in Microsoft’s published guidelines or you are not sure, please consult your legal counsel or the MakeCode team (makecode@microsoft.com).
|
||||
|
||||
## Code of Conduct
|
||||
|
||||
This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.
|
||||
|
14
cmds/cmds.ts
@ -1,14 +0,0 @@
|
||||
/// <reference path="../node_modules/pxt-core/built/pxtlib.d.ts" />
|
||||
|
||||
import * as fs from 'fs';
|
||||
|
||||
const deploy = require("./editor/deploy")
|
||||
|
||||
export function deployCoreAsync(resp: pxtc.CompileResult) {
|
||||
return deploy.deployCoreAsync(resp, process.env["PXT_SERIAL"] ? false : true)
|
||||
.then(() => {
|
||||
fs.writeFileSync("built/full-" + pxtc.BINARY_UF2, resp.outfiles[pxtc.BINARY_UF2], {
|
||||
encoding: "base64"
|
||||
})
|
||||
})
|
||||
}
|
@ -1,6 +0,0 @@
|
||||
/// <reference path="../node_modules/pxt-core/built/pxtlib.d.ts" />
|
||||
|
||||
import * as path from "path";
|
||||
export let pxtCore = require("pxt-core");
|
||||
// require.resolve() gives path to [pxt dir]/built/pxt.js, so move up twice to get pxt root dir
|
||||
export let pxtCoreDir = path.resolve(require.resolve("pxt-core"), "..", "..");
|
18
docfiles/footer.html
Normal file
@ -0,0 +1,18 @@
|
||||
<footer class="ui vertical footer segment hideprint" aria-hidden="false">
|
||||
<div class="ui center aligned container">
|
||||
<div class="ui section divider"></div>
|
||||
<div class="ui container horizontal small divided link list">
|
||||
<!-- <a class="item" href="https://makecode.com/contact" target="_blank" rel="noopener">Contact Us</a> -->
|
||||
<a class="item" href="https://makecode.com/privacy" target="_blank" rel="noopener">Privacy & Cookies</a>
|
||||
<a class="item" href="https://makecode.com/termsofuse" target="_blank" rel="noopener"> Terms Of Use</a>
|
||||
<a class="item" href="https://makecode.com/trademarks" target="_blank" rel="noopener">Trademarks</a>
|
||||
<div class="item">© 2018 Microsoft</div>
|
||||
</div>
|
||||
<div class="ui container horizontal small divided link list">
|
||||
<a class="ui centered item" href="https://makecode.com/" title="Microsoft MakeCode" target="_blank" rel="noopener">Powered by Microsoft MakeCode</a>
|
||||
</div>
|
||||
<div class="ui centered container small list">
|
||||
<p class="item">LEGO, the LEGO logo, MINDSTORMS and the MINDSTORMS EV3 logo are trademarks and/ or copyrights of the LEGO Group. ©2018 The LEGO Group. All rights reserved.</p>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
@ -1,11 +1,37 @@
|
||||
# @extends
|
||||
|
||||
## Support #support
|
||||
|
||||
* [Troubleshoot](/troubleshoot)
|
||||
* [EV3 Manager](https://ev3manager.education.lego.com/)
|
||||
* [Bluetooth](/bluetooth)
|
||||
* [Forum](https://forum.makecode.com)
|
||||
* [LEGO Support](https://www.lego.com/service/)
|
||||
* [FIRST LEGO League](/fll)
|
||||
|
||||
## Projects #projects
|
||||
|
||||
* [Getting Started](/getting-started)
|
||||
* [Try](/getting-started/try)
|
||||
* [Use](/getting-started/use)
|
||||
|
||||
* [Tutorials](/tutorials)
|
||||
* [Wake Up!](/tutorials/wake-up)
|
||||
* [Make An Animation](/tutorials/make-an-animation)
|
||||
* [What Animal Am I?](/tutorials/what-animal-am-i)
|
||||
* [Music Brick](/tutorials/music-brick)
|
||||
* [Run Motors](/tutorials/run-motors)
|
||||
* [Tank ZigZag](/tutorials/tank-zigzag)
|
||||
* [Touch to Run](/tutorials/touch-to-run)
|
||||
* [Touch Sensor Values](/tutorials/touch-sensor-values)
|
||||
* [What Color?](/tutorials/what-color)
|
||||
* [Line Following](/tutorials/line-following)
|
||||
* [Red Light, Green Light](/tutorials/redlight-greenlight)
|
||||
* [Reflected Light Measure](/tutorials/reflected-light-measure)
|
||||
* [Reflected Light Calibration](/tutorials/reflected-light-calibration)
|
||||
* [Object Near?](/tutorials/object-near)
|
||||
* [Security Alert](/tutorials/security-alert)
|
||||
|
||||
* [Coding](/coding)
|
||||
* [Autonomous Parking](/coding/autonomous-parking)
|
||||
* [Object Detection](/coding/object-detection)
|
||||
@ -18,33 +44,7 @@
|
||||
|
||||
* [Maker](/maker)
|
||||
* [Make a Sound Machine](/maker/sound-machine)
|
||||
|
||||
* [Examples](/examples)
|
||||
* [Make it move](/lessons/make-it-move)
|
||||
* [Line detection](/lessons/line-detection)
|
||||
* [Sound of Color](/maker/sound-of-color)
|
||||
* [Security Gadget](/maker/security-gadget)
|
||||
* [Intruder detector](/maker/intruder-detector)
|
||||
* [Puppet](/maker/puppet)
|
||||
* [Three Point Turn 1](/coding/three-point-turn-1)
|
||||
* [Three Point Turn 2](/coding/three-point-turn-2)
|
||||
* [Three Point Turn 3](/coding/three-point-turn-3)
|
||||
* [Reversing the robot 1](/coding/reversing-the-robot-1)
|
||||
* [Reversing the robot 2](/coding/reversing-the-robot-2)
|
||||
* [Reversing the robot 3](/coding/reversing-the-robot-3)
|
||||
* [Light the way 1](/coding/light-the-way-1)
|
||||
* [Light the way 2](/coding/light-the-way-2)
|
||||
* [Light the way 3](/coding/light-the-way-3)
|
||||
* [Traffic Lights 1](/coding/traffic-lights-1)
|
||||
* [Traffic Lights 2](/coding/traffic-lights-2)
|
||||
* [Traffic Lights 3](/coding/traffic-lights-3)
|
||||
* [Reverse Beeper 1](/coding/reverse-beeper-1)
|
||||
* [Reverse Beeper 2](/coding/reverse-beeper-2)
|
||||
* [Reverse Beeper 3](/coding/reverse-beeper-3)
|
||||
* [Ignition](/coding/ignition)
|
||||
* [Cruise Control](/coding/cruise-control)
|
||||
* [Roaming 1](/coding/roaming-1)
|
||||
* [Roaming 2](/coding/roaming-2)
|
||||
* [Make a Security Gadget](/maker/security-gadget)
|
||||
|
||||
## Reference #reference
|
||||
|
||||
@ -56,6 +56,7 @@
|
||||
* [show mood](/reference/brick/show-mood)
|
||||
* [show image](/reference/brick/show-image)
|
||||
* [clear screen](/reference/brick/clear-screen)
|
||||
* [show ports](/reference/brick/show-ports)
|
||||
* [on event](/reference/brick/button/on-event)
|
||||
* [is pressed](/reference/brick/button/is-pressed)
|
||||
* [was pressed](/reference/brick/button/was-pressed)
|
||||
@ -71,7 +72,6 @@
|
||||
* [set regulated](/reference/motors/motor/set-regulated)
|
||||
* [tank](/reference/motors/synced/tank)
|
||||
* [steer](/reference/motors/synced/steer)
|
||||
* [tacho](/reference/motors/motor/tacho)
|
||||
* [angle](/reference/motors/motor/angle)
|
||||
* [speed](/reference/motors/motor/speed)
|
||||
* [clear counts](/reference/motors/motor/clear-counts)
|
||||
@ -88,12 +88,12 @@
|
||||
* [reset](/reference/sensors/gyro/reset)
|
||||
* [Ultrasonic](/reference/sensors/ultrasonic)
|
||||
* [on event](/reference/sensors/ultrasonic/on-event)
|
||||
* [distance](reference/sensors/ultrasonic/distance)
|
||||
* [pause until](reference/sensors/ultrasonic/pause-until)
|
||||
* [distance](/reference/sensors/ultrasonic/distance)
|
||||
* [pause until](/reference/sensors/ultrasonic/pause-until)
|
||||
* [Infrared](/reference/sensors/infrared)
|
||||
* [on event](/reference/sensors/infrared/on-event)
|
||||
* [distance](reference/sensors/infrared/proximity)
|
||||
* [pause until](reference/sensors/infrared/pause-until)
|
||||
* [distance](/reference/sensors/infrared/proximity)
|
||||
* [pause until](/reference/sensors/infrared/pause-until)
|
||||
* [Infrared beacon](/reference/sensors/beacon)
|
||||
* [on event](/reference/sensors/beacon/on-event)
|
||||
* [pause until](/reference/sensors/beacon/pause-until)
|
||||
@ -102,9 +102,9 @@
|
||||
* [set remote channel](/reference/sensors/beacon/set-remote-channel)
|
||||
* [Color](/reference/sensors/color-sensor)
|
||||
* [on color detected](/reference/sensors/color-sensor/on-color-detected)
|
||||
* [pause for color](/reference/sensors/color-sensor/pause-for-color)
|
||||
* [on light changed](/reference/sensors/color-sensor/on-light-changed)
|
||||
* [pause for light](/reference/sensors/color-sensor/pause-for-light)
|
||||
* [pause until color detected](/reference/sensors/color-sensor/pause-until-color-detected)
|
||||
* [on light detected](/reference/sensors/color-sensor/on-light-detected)
|
||||
* [pause until light condition detected](/reference/sensors/color-sensor/pause-until-light-detected)
|
||||
* [color](/reference/sensors/color-sensor/color)
|
||||
* [light](/reference/sensors/color-sensor/ambient-light)
|
||||
* [Music](/reference/music)
|
||||
@ -129,3 +129,7 @@
|
||||
* [log](/reference/console/log)
|
||||
* [log value](/reference/console/log-value)
|
||||
* [send to screen](/reference/console/send-to-screen)
|
||||
|
||||
## #misc
|
||||
|
||||
## devs
|
||||
|
@ -17,23 +17,31 @@ brick.buttonEnter.onEvent(ButtonEvent.Bumped, () => {
|
||||
})
|
||||
```
|
||||
|
||||
The editor work in [most modern browsers](/browsers), work [offline](/offline) once loaded and do not require any installation.
|
||||
The editor works in [most modern browsers](/browsers). It works [offline](/offline) once loaded and doesn't require any installation. Take a look at some of the [features](/about/editor-features) of the editor.
|
||||
|
||||
## Compile and Flash: Your Program!
|
||||
|
||||
When you have your code ready, you connect your @boardname@ to a computer via a USB cable
|
||||
so it appears as a mounted drive (named **EV3**).
|
||||
When you have your code ready, you connect your EV3 Brick to a computer with a USB cable so it appears as an attached drive (named **@drivename@**).
|
||||
|
||||
Compilation to machine code from [Blocks](/blocks) or [JavaScript](/javascript) happens in the browser. You save the binary
|
||||
program to a **.uf2** file, which you then copy to the **EV3** drive, which flashes the device with the new program.
|
||||
program to a **.uf2** file, which you then copy to the **@drivename@** drive. The process of copying will flash the device with the new program.
|
||||
|
||||
### ~ hint
|
||||
|
||||
**Experimental support** for Bluetooth download is now available. Please read the [Bluetooth](/bluetooth) page for more information.
|
||||
|
||||
### ~
|
||||
|
||||
## Simulator: Test Your Code
|
||||
|
||||
You can run your code using the micro:bit simulator, all within the confines of a web browser.
|
||||
The simulator has support for the LED screen, buttons, as well as compass, accelerometer, and digital I/O pins.
|
||||
You can run your code using the @boardname@ simulator, all inside the same browser window.
|
||||
The simulator has support for the EV3 Brick screen, buttons, sensors, and motors.
|
||||
|
||||
```sim
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Bumped, () => {
|
||||
motors.largeA.run(50)
|
||||
motors.mediumD.run(50)
|
||||
sensors.touch1.pauseUntil(ButtonEvent.Pressed)
|
||||
sensors.ultrasonic4.pauseUntil(UltrasonicSensorEvent.ObjectDetected)
|
||||
})
|
||||
```
|
||||
```
|
81
docs/about/editor-features.md
Normal file
@ -0,0 +1,81 @@
|
||||
# @extends
|
||||
|
||||
#### #blocks-images
|
||||
|
||||
| |
|
||||
|-|
|
||||
|  |
|
||||
| Blocks Toolbox |
|
||||
|
||||
#### #home-images
|
||||
|
||||
| |
|
||||
|-|
|
||||
|  |
|
||||
| Home Button |
|
||||
|
||||
#### #share-images
|
||||
|
||||
| |
|
||||
|-|
|
||||
|  |
|
||||
| Share Button |
|
||||
|
||||
#### #blocksjs-images
|
||||
|
||||
| |
|
||||
|-|
|
||||
|  |
|
||||
| Switch from Blocks to JavaScript |
|
||||
|
||||
#### #help-images
|
||||
|
||||
| |
|
||||
|-|
|
||||
|  |
|
||||
| Help Button |
|
||||
|
||||
#### #moresettings-images
|
||||
|
||||
| |
|
||||
|-|
|
||||
|  |
|
||||
| More Button |
|
||||
|
||||
#### #undoredo-images
|
||||
|
||||
| | | |
|
||||
|-|-|-|
|
||||
|  | |  |
|
||||
| Undo Button | | Redo Button |
|
||||
|
||||
#### #zoom-images
|
||||
|
||||
| | | |
|
||||
|-|-|-|
|
||||
|  | |  |
|
||||
| Zoom In | | Zoom Out |
|
||||
|
||||
#### #saveproject-images
|
||||
|
||||
| |
|
||||
|-|
|
||||
|  |
|
||||
| Save Project |
|
||||
|
||||
#### #download-images
|
||||
|
||||
| |
|
||||
|-|
|
||||
|  |
|
||||
| Download Button |
|
||||
|
||||
#### #explorer-images
|
||||
|
||||
| |
|
||||
|-|
|
||||
|  |
|
||||
| Explorer Button |
|
||||
| |
|
||||
|  |
|
||||
| Explorer File View |
|
62
docs/bluetooth.md
Normal file
@ -0,0 +1,62 @@
|
||||
# Bluetooth
|
||||
|
||||
This page describes the procedure to download MakeCode program to the EV3 brick
|
||||
over Bluetooth.
|
||||
|
||||
## ~ hint
|
||||
|
||||
### WARNING: EXPERIMENTAL FEATURES AHEAD!
|
||||
|
||||
Support for Bluetooth download relies on [Web Serial](https://wicg.github.io/serial/),
|
||||
an experimental browser feature. Web Serial is a work [in progress](https://www.chromestatus.com/feature/6577673212002304);
|
||||
it may change or be removed in future versions without notice.
|
||||
|
||||
By enabling these experimental browser features, you could lose browser data or compromise your device security
|
||||
or privacy.
|
||||
|
||||
## ~
|
||||
|
||||
https://youtu.be/VIq8-6Egtqs
|
||||
|
||||
## Supported browsers
|
||||
|
||||
* Chrome desktop, version 77 and higher, Windows 10 or Mac OS.
|
||||
* [Edge Insider desktop](https://www.microsoftedgeinsider.com), version 77 and higher, Windows 10 or Mac OS.
|
||||
|
||||
To make sure your browser is up to date, go to the '...' menu, click "Help" then "About".
|
||||
|
||||
Next you need to enable the experimental features (this may change in the future)
|
||||
|
||||
* go to **chrome://flags/#enable-experimental-web-platform-features** and **enable**
|
||||
**Experimental Web Platform features**
|
||||
|
||||

|
||||
|
||||
## Machine Setup
|
||||
|
||||
* pair your EV3 brick with your computer over Bluetooth. This is the usual pairing procedure.
|
||||
|
||||
## Download over Bluetooth
|
||||
|
||||
* go to https://makecode.mindstorms.com/
|
||||
* click on **Download** to start a file download as usual
|
||||
* on the download dialog, you should see a **Bluetooth** button. Click on the
|
||||
**Bluetooth** button to enable the mode.
|
||||
* **make sure the EV3 brick is not running a program**
|
||||
* click on **Download** again to download over bluetooth.
|
||||
|
||||
## Choosing the correct serial port
|
||||
|
||||
Unfortunately, the browser dialog does not make it easy to select which serial port is the brick.
|
||||
|
||||
* On Windows, choose ``Standard Serial over Bluetooth``. There might be multiple of those but only one works. Try your luck! Once you know the COM port number, remember it for the next time around.
|
||||
* On Mac OS, choose ``cu.BRICKNAME-SerialPort``
|
||||
|
||||
## Known issues
|
||||
|
||||
* We do not detect properly that the program is running on the brick. Make sure to stop the program before starting the download procedure.
|
||||
* The list of programs on the brick screen is not updated when uploading via bluetooth.
|
||||
|
||||
## Feedback
|
||||
|
||||
Please send us your feedback through https://forum.makecode.com.
|
@ -7,19 +7,19 @@
|
||||
[
|
||||
{
|
||||
"name": "Autonomous Parking",
|
||||
"description": "Design cars that can park by themselves",
|
||||
"description": "Design cars that can park themselves safely without driver intervention.",
|
||||
"url":"/coding/autonomous-parking",
|
||||
"imageUrl": "/static/lessons/autonomous-parking.png",
|
||||
"cardType": "side"
|
||||
}, {
|
||||
"name": "Object Detection",
|
||||
"description": "Design ways to avoid accidents between vehicles and objects",
|
||||
"description": "Design ways to avoid accidents between vehicles and objects in the road.",
|
||||
"url":"/coding/object-detection",
|
||||
"imageUrl": "/static/lessons/object-detection.jpg",
|
||||
"cardType": "side"
|
||||
}, {
|
||||
"name": "Line Detection",
|
||||
"description": "Improve driving safety by helping drivers stay on course",
|
||||
"description": "Design ways to improve driving safety by helping to prevent drivers from falling asleep and causing an accident.",
|
||||
"url":"/coding/line-detection",
|
||||
"imageUrl": "/static/lessons/line-detection.jpg",
|
||||
"cardType": "side"
|
||||
|
@ -12,14 +12,20 @@ Design cars that can park themselves safely without driver intervention.
|
||||
* What would it take to ensure that autonomous cars are safe?
|
||||
* What types of movements do autonomous cars need to perform?
|
||||
|
||||
## Construct
|
||||
## Construct
|
||||
|
||||
### Build
|
||||
|
||||
Build a LEGO MINDSTORMS vehicle that can park itself safely without driver intervention. Start by constructing this model:
|
||||
Build a @boardname@ vehicle that can park itself safely without driver intervention. Start by constructing this model:
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/building-instructions/ev3-rem-driving-base-79bebfc16bd491186ea9c9069842155e.pdf)
|
||||
|
||||
### ~hint
|
||||
|
||||
If clicking the above image doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
### ~
|
||||
|
||||
### Check
|
||||
|
||||
Before you program, check:
|
||||
@ -28,7 +34,7 @@ Before you program, check:
|
||||
* Are the wheels correctly installed?
|
||||
* Are the wheels rotating freely?
|
||||
|
||||
### Program
|
||||
### Program
|
||||
|
||||
Write a program that will make the robot turn three times in various ways.
|
||||
|
||||
@ -109,7 +115,7 @@ Click Download and follow the instructions to get your code onto your EV3 Brick.
|
||||
|
||||
### Differentiation
|
||||
|
||||
Create a program that simulates displaying appropriate warning lights while parking.
|
||||
Create a program that simulates displaying appropriate warning lights while parking.
|
||||
|
||||
### ~hint
|
||||
|
||||
@ -164,8 +170,8 @@ Click Download and follow the instructions to get your code onto your EV3 Brick.
|
||||
|
||||
* Click on the JavaScript tab and experiment with changing the values in the code.
|
||||
* Add a custom image or sounds from the Brick or Music menus.
|
||||
* Create a video of your project, especially your final presentation and your robot’s performance. Explain some important features of your software program.
|
||||
* Include an image of your program with comments.
|
||||
* Add a team photograph!
|
||||
* Create a video of your project, especially your final presentation and your robot’s performance. Explain some important features of your software program.
|
||||
* Include an image of your program with comments.
|
||||
* Add a team photograph!
|
||||
|
||||
Congratulations! What will you design next?
|
||||
|
@ -22,7 +22,7 @@ Play some motor sounds if touch sensor `1` is pressed at the same moment when an
|
||||
|
||||
```blocks
|
||||
while (true) {
|
||||
if (sensors.touch1.wasPressed() &&
|
||||
if (sensors.touch1.isPressed() &&
|
||||
sensors.ultrasonic4.distance() < 10) {
|
||||
music.playSoundEffectUntilDone(sounds.mechanicalMotorStart)
|
||||
music.playSoundEffectUntilDone(sounds.mechanicalMotorIdle);
|
||||
@ -38,8 +38,8 @@ Play some motor sounds if touch sensor `1` is pressed when both the `enter` butt
|
||||
```blocks
|
||||
while (true) {
|
||||
if (sensors.ultrasonic4.distance() < 10 &&
|
||||
sensors.touch1.wasPressed() &&
|
||||
brick.buttonEnter.wasPressed()) {
|
||||
sensors.touch1.isPressed() &&
|
||||
brick.buttonEnter.isPressed()) {
|
||||
music.playSoundEffectUntilDone(sounds.mechanicalMotorStart)
|
||||
music.playSoundEffectUntilDone(sounds.mechanicalMotorIdle);
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
# Light the way Activity 1
|
||||
|
||||
```blocks
|
||||
sensors.color3.onLightChanged(LightIntensityMode.Ambient, LightCondition.Dark, function () {
|
||||
sensors.color3.onLightDetected(LightIntensityMode.Ambient, Light.Dark, function () {
|
||||
brick.showImage(images.objectsLightOn)
|
||||
pause(5000)
|
||||
brick.clearScreen()
|
||||
|
@ -1,10 +1,10 @@
|
||||
# Light the way Activity 2
|
||||
|
||||
```blocks
|
||||
sensors.color3.onLightChanged(LightIntensityMode.Ambient, LightCondition.Bright, function () {
|
||||
sensors.color3.onLightDetected(LightIntensityMode.Ambient, Light.Bright, function () {
|
||||
brick.clearScreen()
|
||||
})
|
||||
sensors.color3.onLightChanged(LightIntensityMode.Ambient, LightCondition.Dark, function () {
|
||||
sensors.color3.onLightDetected(LightIntensityMode.Ambient, Light.Dark, function () {
|
||||
brick.showImage(images.objectsLightOn)
|
||||
})
|
||||
```
|
@ -1,10 +1,10 @@
|
||||
# Light the way Activity 3
|
||||
|
||||
```blocks
|
||||
sensors.color3.onLightChanged(LightIntensityMode.Ambient, LightCondition.Bright, function () {
|
||||
sensors.color3.onLightDetected(LightIntensityMode.Ambient, Light.Bright, function () {
|
||||
brick.clearScreen()
|
||||
})
|
||||
sensors.color3.onLightChanged(LightIntensityMode.Ambient, LightCondition.Dark, function () {
|
||||
sensors.color3.onLightDetected(LightIntensityMode.Ambient, Light.Dark, function () {
|
||||
brick.showImage(images.objectsLightOn)
|
||||
})
|
||||
sensors.touch1.onEvent(ButtonEvent.Pressed, function () {
|
||||
|
@ -16,7 +16,7 @@ Think about:
|
||||
|
||||
### Build
|
||||
|
||||
Build a LEGO MINDSTORMS vehicle that can help prevent drivers from falling asleep and causing an accident. Start by constructing this model:
|
||||
Build a @boardname@ vehicle that can help prevent drivers from falling asleep and causing an accident. Start by constructing this model:
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/building-instructions/ev3-rem-color-sensor-down-driving-base-d30ed30610c3d6647d56e17bc64cf6e2.pdf)
|
||||
|
||||
@ -24,6 +24,12 @@ Build red and green “lights” for your robot to detect. You can use LEGO bric
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/files/support/mindstorms%20ev3/building-instructions/design%20engineering%20projects/color%20squares-0a88dfd98bb2e64b5b8151fc422bae36.pdf)
|
||||
|
||||
### ~hint
|
||||
|
||||
If clicking the above images doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
### ~
|
||||
|
||||
### Check
|
||||
|
||||
Before you program, check:
|
||||
@ -51,10 +57,10 @@ Consider using these blocks in your solution:
|
||||
|
||||
```block
|
||||
loops.forever(function () {
|
||||
|
||||
|
||||
})
|
||||
motors.largeBC.steer(0, 50)
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
motors.stopAll()
|
||||
```
|
||||
|
||||
@ -70,16 +76,16 @@ motors.stopAll()
|
||||
```blocks
|
||||
loops.forever(function () {
|
||||
motors.largeBC.steer(0, 50)
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
motors.stopAll()
|
||||
})
|
||||
```
|
||||
|
||||
### Download and test
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick.
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick.
|
||||
|
||||
Congratulations! Your robot can stop at a red light.
|
||||
Congratulations! Your robot can stop at a red light.
|
||||
|
||||
Now add to your program and have your robot to drive forward again when the light changes from red to green.
|
||||
|
||||
@ -94,15 +100,15 @@ Now add to your program and have your robot to drive forward again when the ligh
|
||||
```blocks
|
||||
loops.forever(function () {
|
||||
motors.largeBC.steer(0, 50)
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
motors.stopAll()
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Green)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Green)
|
||||
})
|
||||
```
|
||||
|
||||
### Download and test
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick.
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick.
|
||||
|
||||
## Contemplate
|
||||
|
||||
@ -116,7 +122,7 @@ Draw a dark line with tape or marker for your robot to cross.
|
||||
|
||||
Consider using these blocks in your solution:
|
||||
|
||||
```block
|
||||
```block
|
||||
motors.largeBC.steer(0, 50)
|
||||
music.playSoundEffect(sounds.systemGeneralAlert)
|
||||
```
|
||||
@ -134,16 +140,16 @@ music.playSoundEffect(sounds.systemGeneralAlert)
|
||||
```blocks
|
||||
loops.forever(function () {
|
||||
motors.largeBC.steer(-30, 20)
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Black)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Black)
|
||||
music.playSoundEffect(sounds.systemGeneralAlert)
|
||||
motors.largeBC.steer(30, 20)
|
||||
sensors.color3.pauseForColor(ColorSensorColor.White)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.White)
|
||||
})
|
||||
```
|
||||
|
||||
#### Download and test
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick.
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick.
|
||||
|
||||
#### Differentiation
|
||||
|
||||
@ -157,7 +163,7 @@ Consider using these blocks in your solution:
|
||||
|
||||
```block
|
||||
while (true) {
|
||||
|
||||
|
||||
}
|
||||
motors.largeBC.steer(0, 50)
|
||||
```
|
||||
@ -166,7 +172,7 @@ motors.largeBC.steer(0, 50)
|
||||
|
||||
```block
|
||||
if (true) {
|
||||
|
||||
|
||||
} else {
|
||||
|
||||
}
|
||||
@ -184,12 +190,10 @@ if (true) {
|
||||
|
||||
```blocks
|
||||
forever(function () {
|
||||
while (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Black)
|
||||
while (sensors.color3.color() == ColorSensorColor.Black) {
|
||||
motors.largeBC.steer(-30, 50)
|
||||
}
|
||||
while (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.White)
|
||||
while (sensors.color3.color() == ColorSensorColor.White) {
|
||||
motors.largeBC.steer(30, 50)
|
||||
}
|
||||
})
|
||||
@ -203,11 +207,9 @@ Else the Color Sensor detects the color white, start motors ``B`` and ``C`` (dri
|
||||
|
||||
```blocks
|
||||
forever(function () {
|
||||
if (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Black)
|
||||
if (sensors.color3.color() == ColorSensorColor.Black) {
|
||||
motors.largeBC.steer(-30, 50)
|
||||
} else {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.White)
|
||||
motors.largeBC.steer(30, 50)
|
||||
}
|
||||
})
|
||||
@ -215,7 +217,7 @@ forever(function () {
|
||||
|
||||
### Download and test
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick.
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick.
|
||||
|
||||
### Share
|
||||
|
||||
@ -232,8 +234,8 @@ Personalize:
|
||||
|
||||
* Click on the **JavaScript** tab and experiment with changing the values in the code.
|
||||
* Add a custom image or sounds from the ``||brick:Brick||`` or ``||music:Music||`` menus.
|
||||
* Create a video of your project, especially your final presentation and your robot’s performance. Explain some important features of your software program.
|
||||
* Include an image of your program with comments.
|
||||
* Add a team photograph!
|
||||
* Create a video of your project, especially your final presentation and your robot’s performance. Explain some important features of your software program.
|
||||
* Include an image of your program with comments.
|
||||
* Add a team photograph!
|
||||
|
||||
Congratulations! What will you design next?
|
||||
|
@ -4,7 +4,7 @@ Design ways to avoid accidents between vehicles and objects in the road.
|
||||
|
||||

|
||||
|
||||
## Connect
|
||||
## Connect
|
||||
|
||||
Think about:
|
||||
|
||||
@ -12,18 +12,24 @@ Think about:
|
||||
* What do you need to be aware of to avoid collisions with obstacles?
|
||||
* What causes traffic jams in high density areas?
|
||||
|
||||
## Construct
|
||||
## Construct
|
||||
|
||||
### Build
|
||||
|
||||
Build a LEGO MINDSTORMS vehicle that can avoid accidents between vehicles and objects in the road. Start by constructing this model:
|
||||
Build a @boardname@ vehicle that can avoid accidents between vehicles and objects in the road. Start by constructing this model:
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/building-instructions/ev3-ultrasonic-sensor-driving-base-61ffdfa461aee2470b8ddbeab16e2070.pdf)
|
||||
|
||||
Build an obstacle for your robot to detect. You can build the **cuboid model** out of LEGO bricks or an obstacle of your choice.
|
||||
Build an obstacle for your robot to detect. You can build the **cuboid model** out of LEGO bricks or an obstacle of your choice.
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/building-instructions/ev3-cuboid-dc93b2e60bed2981e76b3bac9ea04558.pdf)
|
||||
|
||||
### ~hint
|
||||
|
||||
If clicking the above images doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
### ~
|
||||
|
||||
### Check
|
||||
|
||||
Before you program, check:
|
||||
@ -38,7 +44,7 @@ Before you program, check:
|
||||
* Program your robot to detect any obstacles that might appear while the robot is moving forward (or backward).
|
||||
* Make the robot stop when it detects an object that is less than 20 cm away.
|
||||
|
||||
Before you program, think about:
|
||||
Before you program, think about:
|
||||
* How will you program the robot to detect obstacles?
|
||||
* How will you program the robot to stop at obstacles?
|
||||
* Which programming blocks will you use?
|
||||
@ -59,7 +65,7 @@ motors.stopAll()
|
||||
|
||||
### ~
|
||||
|
||||
### Sample Solution
|
||||
### Sample Solution
|
||||
|
||||
1. Start the program when EV3 ``enter`` button is pressed.
|
||||
2. Turn motors ``B`` and ``C`` on at speed ``50``.
|
||||
@ -80,7 +86,7 @@ Click **Download** and follow the instructions to get your code onto your EV3 Br
|
||||
|
||||
## Contemplate
|
||||
|
||||
On the road, when a driver sees and object, they slow their car down before coming to a full stop.
|
||||
On the road, when a driver sees and object, they slow their car down before coming to a full stop.
|
||||
|
||||
Program your EV3 Driving Base to do the same.
|
||||
|
||||
@ -93,7 +99,7 @@ If the Ultrasonic Sensor:
|
||||
### ~hint
|
||||
|
||||
Consider using this block in your solution:
|
||||
|
||||
|
||||
```block
|
||||
if (true) {
|
||||
}
|
||||
@ -101,7 +107,7 @@ if (true) {
|
||||
|
||||
### ~
|
||||
|
||||
### Sample Solution
|
||||
### Sample Solution
|
||||
|
||||
```blocks
|
||||
loops.forever(function () {
|
||||
@ -118,7 +124,7 @@ loops.forever(function () {
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the ``center`` button on the EV3 Brick to run the program.
|
||||
|
||||
## Continue
|
||||
## Continue
|
||||
|
||||
* Get together with other building teams and make a traffic jam by placing all of your robots in a line with varying amounts of space between them.
|
||||
* Have everyone start their robots at the same time and see what happens.
|
||||
@ -130,8 +136,8 @@ Click **Download** and follow the instructions to get your code onto your EV3 Br
|
||||
|
||||
* Share what you think “efficiency in programming” means.
|
||||
* Explore the different solutions other programmers came up with.
|
||||
* Create a video of your project, especially your final presentation and your robot’s performance. Explain some important features of your software program.
|
||||
* Include an image of your program with comments.
|
||||
* Add a team photograph!
|
||||
* Create a video of your project, especially your final presentation and your robot’s performance. Explain some important features of your software program.
|
||||
* Include an image of your program with comments.
|
||||
* Add a team photograph!
|
||||
|
||||
Congratulations! What will you design next?
|
||||
|
@ -3,7 +3,7 @@
|
||||
```blocks
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Bumped, function () {
|
||||
motors.largeBC.tank(20, 20)
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
motors.largeBC.tank(0, 0)
|
||||
})
|
||||
```
|
@ -6,21 +6,21 @@
|
||||
[
|
||||
{
|
||||
"name": "Make It Move Without Wheels",
|
||||
"description": "TBD",
|
||||
"description": "Design, build and program a robot that can move itself using no wheels for locomotion.",
|
||||
"imageUrl": "/static/lessons/make-it-move-without-wheels.png",
|
||||
"url": "/design-engineering/make-it-move",
|
||||
"cardType": "side"
|
||||
},
|
||||
{
|
||||
"name": "Make It Smarter and Faster",
|
||||
"description": "TBD",
|
||||
"description": "Design, build and program a robotic creature that can sense its environment and respond by moving.",
|
||||
"imageUrl": "/static/lessons/make-it-smarter-and-faster.png",
|
||||
"url": "/design-engineering/make-it-smarter",
|
||||
"cardType": "side"
|
||||
},
|
||||
{
|
||||
"name": "Make a System that Communicates",
|
||||
"description": "A robot that tells you what it is doing.",
|
||||
"description": "Design, build and program a robotic system that follows a path and communicates its position at least twice along the way.",
|
||||
"imageUrl": "/static/lessons/make-a-system-that-communicates.png",
|
||||
"url": "/design-engineering/make-it-communicate",
|
||||
"cardType": "side"
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Make A System That Communicates
|
||||
|
||||
## Connect
|
||||
## Connect
|
||||
|
||||
### Design Brief
|
||||
|
||||
@ -20,10 +20,10 @@ Think about:
|
||||
* What kind of motorized mechanism can be used to control the movements of a robot?
|
||||
* How can the robot sense where it is along the path?
|
||||
* How can the robot communicate its position?
|
||||
|
||||
|
||||

|
||||
|
||||
## Construct
|
||||
## Construct
|
||||
|
||||
### Build
|
||||
|
||||
@ -37,13 +37,19 @@ More building ideas:
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/files/support/mindstorms%20ev3/building-instructions/design%20engineering%20projects/color%20sensor_v2-e7fd54b6fa3cdfe36f414c1d2510f9cb.pdf)
|
||||
|
||||
### ~hint
|
||||
|
||||
Build a path for your robot to follow. You can use electrical tape on a floor, or marker on paper. You can use objects as milestones to indicate a path that can be detected by either the Touch Sensor, Color Sensor, or Ultrasonic Sensor.
|
||||
If clicking the above images doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
### Program
|
||||
### ~
|
||||
|
||||
|
||||
Build a path for your robot to follow. You can use electrical tape on a floor, or marker on paper. You can use objects as milestones to indicate a path that can be detected by either the Touch Sensor, Color Sensor, or Ultrasonic Sensor.
|
||||
|
||||
### Program
|
||||
|
||||
Before you program, think about:
|
||||
|
||||
Before you program, think about:
|
||||
|
||||
* How will you program the robot to follow a path?
|
||||
* How will you program the robot to communicate its position?
|
||||
* Which programming blocks will you use?
|
||||
@ -54,7 +60,7 @@ Explore the different Motor and Sensor blocks in the programming menu.
|
||||
|
||||
### ~
|
||||
|
||||
### Sample Solution
|
||||
### Sample Solution
|
||||
|
||||
[](https://legoeducation.23video.com/v.ihtml/player.html?token=79c99735f906403a4dd7f2909935983d&source=embed&photo%5fid=19857954)
|
||||
|
||||
@ -70,15 +76,21 @@ Two copies of the tracks are built: one for the right side and a mirror image fo
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/ev3-dep/building%20instructions/track-rover-bi-6aadb1b053df0c58a0dea108b5ce0eea.pdf)
|
||||
|
||||
### Sample Program Solution
|
||||
### ~hint
|
||||
|
||||
This program works with the Track Rover. If you create a different robot, adjust the program to fit your solution.
|
||||
If clicking the above image doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
Program summary:
|
||||
### ~
|
||||
|
||||
### Sample Program Solution
|
||||
|
||||
This program works with the Track Rover. If you create a different robot, adjust the program to fit your solution.
|
||||
|
||||
Program summary:
|
||||
|
||||
* If the Color Sensor sees black, Motor B runs at -50 power and Motor C turns off.
|
||||
* If the Color Sensor sees white, Motor B turns off and Motor C runs at -50 power.
|
||||
* If the Color Sensor sees green, all motors stop and the green sound plays.
|
||||
* If the Color Sensor sees green, all motors stop and the green sound plays.
|
||||
* The robot waits one second, then motors move forward.
|
||||
* If the Color Sensor sees red, all motors stop, and the red sound plays.
|
||||
* The robot waits one second, then motors move forward.
|
||||
@ -108,44 +120,44 @@ forever(function () {
|
||||
|
||||
Click Download and follow the instructions to get your code onto your EV3 Brick. Press the center button on the EV3 Brick to run the program.
|
||||
|
||||
## Contemplate
|
||||
## Contemplate
|
||||
|
||||
### Test and Analyze
|
||||
### Test and Analyze
|
||||
|
||||
As you work on your solution:
|
||||
|
||||
1. Describe one part of your design that worked especially well.
|
||||
2. Describe one design change that you had to make.
|
||||
3. What will you try next?
|
||||
1. Describe one part of your design that worked especially well.
|
||||
2. Describe one design change that you had to make.
|
||||
3. What will you try next?
|
||||
|
||||
|
||||
### Review and Revise
|
||||
### Review and Revise
|
||||
|
||||
Take a moment to reflect on your robot solution.
|
||||
Take a moment to reflect on your robot solution.
|
||||
|
||||
Think about:
|
||||
|
||||
* Can the robot’s movement be more accurate?
|
||||
* Can the robot’s movement be more accurate?
|
||||
* What are some ways that others have solved the problem?
|
||||
|
||||
Describe two ways you could improve your robot.
|
||||
|
||||
## Continue
|
||||
## Continue
|
||||
|
||||
### Personalize your project
|
||||
|
||||
* Add/remove LEGO elements to improve the way your robot moves.
|
||||
* Add/remove LEGO elements to improve the way your robot moves.
|
||||
* Click on the JavaScript tab and experiment with changing the values in the code.
|
||||
* Add a custom image or sounds by adding blocks from the Brick or Music menus.
|
||||
|
||||
## Communicate
|
||||
## Communicate
|
||||
|
||||
Here are some ideas:
|
||||
|
||||
* Create a video of your project, especially your final presentation and your robot’s performance.
|
||||
* Explain some important features of your software program.
|
||||
* Produce a building guide for your model by taking a series of photographs as you deconstruct it.
|
||||
* Include an image of your program with comments.
|
||||
* Add a team photograph!
|
||||
* Create a video of your project, especially your final presentation and your robot’s performance.
|
||||
* Explain some important features of your software program.
|
||||
* Produce a building guide for your model by taking a series of photographs as you deconstruct it.
|
||||
* Include an image of your program with comments.
|
||||
* Add a team photograph!
|
||||
|
||||
Congratulations! What will you design next?
|
||||
|
@ -6,7 +6,7 @@
|
||||
|
||||
Design, build and program a robot that can move itself using no wheels for locomotion.
|
||||
|
||||

|
||||

|
||||
|
||||
Your robot will:
|
||||
|
||||
@ -22,7 +22,7 @@ In nature, creatures use many methods to get around. None of them, however, use
|
||||
|
||||
### Build
|
||||
|
||||
Think about a creature’s movement for inspiration. Will you make the robot walk, crawl, hop, or wiggle? Your mechanism can be attached or unattached to the EV3 brick. You can start by tinkering with the LEGO elements in the picture above and then build on.
|
||||
Think about a creature’s movement for inspiration. Will you make the robot walk, crawl, hop, or wiggle? Your mechanism can be attached or unattached to the EV3 Brick. You can start by tinkering with the LEGO elements in the picture above and then build on.
|
||||
|
||||
### Building Hint
|
||||
|
||||
@ -30,18 +30,26 @@ If you want some building help you can follow these instructions.
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/files/support/mindstorms%20ev3/building-instructions/design%20engineering%20projects/toddle%20bot-3dcad146d7f5deac4753f93e9dcc0739.pdf)
|
||||
|
||||
Click [here](https://le-www-live-s.legocdn.com/sc/media/files/support/mindstorms%20ev3/building-instructions/design%20engineering%20projects/toddle%20bot-3dcad146d7f5deac4753f93e9dcc0739.pdf)
|
||||
|
||||
### ~hint
|
||||
|
||||
If clicking the above image or link doesn't open the instructions, right-click on the link and choose "Save link as..." to download the PDF.
|
||||
|
||||
### ~
|
||||
|
||||
### Program
|
||||
|
||||
Before you program, think about:
|
||||
|
||||
* How will you program the robot to move?
|
||||
* How will you program the robot to move?
|
||||
* How will you program the robot to stop?
|
||||
* How will you program the robot to display the distance moved?
|
||||
|
||||
Which programming blocks will you use:
|
||||
|
||||
* To turn on and turn off the motor or motors?
|
||||
* To display the distance moved?
|
||||
* To turn on and turn off the motor or motors?
|
||||
* To display the distance moved?
|
||||
|
||||
### Sample Code
|
||||
|
||||
@ -49,7 +57,7 @@ Example code of a robot that moves without wheels using one motor:
|
||||
|
||||
* The robot moves with ``large motor D`` rotating at ``-100`` speed
|
||||
* The robot moves for ``30000`` milliseconds (30 seconds)
|
||||
* The robot stops
|
||||
* The robot stops
|
||||
* The robot displays the text ``"30cm"``
|
||||
|
||||
```blocks
|
||||
@ -65,7 +73,7 @@ brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the center button on the EV3 Brick to run the program.
|
||||
|
||||
## Contemplate
|
||||
## Contemplate
|
||||
|
||||
### Test and Analyze
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Make It Smarter and Faster
|
||||
# Make It Smarter and Faster
|
||||
|
||||
## Connect
|
||||
## Connect
|
||||
|
||||
### Design Brief
|
||||
|
||||
@ -10,52 +10,52 @@ https://www.youtube.com/watch?v=y9-A_C_08KY
|
||||
|
||||
* What do the robots in the video need to be able to sense, plan, and act?
|
||||
* What senses do humans have and why are they important to us?
|
||||
* How many human-like senses do you see the robots demonstrating?
|
||||
* How many human-like senses do you see the robots demonstrating?
|
||||
|
||||
### Brainstorm
|
||||
### Brainstorm
|
||||
|
||||
Discuss different solutions to the design brief.
|
||||
|
||||
Think about:
|
||||
Think about:
|
||||
|
||||
* What kind of creature can it be?
|
||||
* How can it move?
|
||||
* What does it need to be aware so that it stays safe, well fed and warm (or cool)?
|
||||
* Is it looking for food, a safe place to hide or a warm place to soak up the sun?
|
||||
* Will the creature need to move fast or slow?
|
||||
* Will it need to turn?
|
||||
* What kind of creature can it be?
|
||||
* How can it move?
|
||||
* What does it need to be aware so that it stays safe, well fed and warm (or cool)?
|
||||
* Is it looking for food, a safe place to hide or a warm place to soak up the sun?
|
||||
* Will the creature need to move fast or slow?
|
||||
* Will it need to turn?
|
||||
* Will it need to go backward?
|
||||
|
||||

|
||||
|
||||
## Construct
|
||||
|
||||
|
||||
### Build
|
||||
|
||||
Think about a creature’s movement for inspiration. Your mechanism can be attached or unattached to the EV3 brick. You can start by tinkering with the LEGO elements in the picture add then build on.
|
||||
Think about a creature’s movement for inspiration. Your mechanism can be attached or unattached to the EV3 Brick. You can start by tinkering with the LEGO elements in the picture add then build on.
|
||||
|
||||
More building ideas:
|
||||
More building ideas:
|
||||
|
||||
| | | | | |
|
||||
|-|-|-|-|-|
|
||||
|[][EV3 Frames] | |[][Color Sensor 1] | |[][Gyro Sensor] |
|
||||
| [EV3 Frames] | | [Color Sensor 1] | | [Gyro Sensor] |
|
||||
<br/>
|
||||
|
||||
| | | | | |
|
||||
|-|-|-|-|-|
|
||||
|[][Ultrasonic Sensor] | | [][Touch Sensor] | | [][Jaw] |
|
||||
| [Ultrasonic Sensor] | | [Touch Sensor] | | [Jaw] |
|
||||
<br/>
|
||||
* [EV3 Frames]
|
||||
* [Color Sensor 1]
|
||||
* [Gyro Sensor]
|
||||
* [Ultrasonic Sensor]
|
||||
* [Touch Sensor]
|
||||
* [Jaw]
|
||||
* [Leg 1]
|
||||
* [Leg 2]
|
||||
* [Leg 3]
|
||||
|
||||
| | | | | |
|
||||
|-|-|-|-|-|
|
||||
| [][Leg 1] | | [][Leg 2] | | [][Leg 3] |
|
||||
| [Leg 1] | | [Leg 2] | | [Leg 3] |
|
||||
### ~hint
|
||||
|
||||
### Program
|
||||
If clicking the above links doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
Before you program, think about:
|
||||
### ~
|
||||
|
||||
### Program
|
||||
|
||||
Before you program, think about:
|
||||
|
||||
* How will you program the robot to sense?
|
||||
* How will you program the robot to respond?
|
||||
@ -67,7 +67,7 @@ Before you program, think about:
|
||||
|
||||
### ~
|
||||
|
||||
### Sample Solution
|
||||
### Sample Solution
|
||||
|
||||
The Insect uses its Ultrasonic Sensor to sense danger and move away from a threat.
|
||||
|
||||
@ -86,18 +86,24 @@ Building Instructions:
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/files/support/mindstorms%20ev3/building-instructions/design%20engineering%20projects/insect-94b8a46f0dc5082c9d78ddb734626dc9.pdf)
|
||||
|
||||
### Sample Solution
|
||||
### ~hint
|
||||
|
||||
This program checks if the Ultrasonic Sensor senses something near.
|
||||
If clicking the above images or links doesn't open the instructions, right-click on the link and choose "Save link as..." to download the PDF.
|
||||
|
||||
The blocks inside the ``||loops:forever||`` loop have these actions:
|
||||
### ~
|
||||
|
||||
1. Turn on the ``green`` EV3 brick Status Light.
|
||||
### Sample Solution
|
||||
|
||||
This program checks if the Ultrasonic Sensor senses something near.
|
||||
|
||||
The blocks inside the ``||loops:forever||`` loop have these actions:
|
||||
|
||||
1. Turn on the ``green`` EV3 Brick Status Light.
|
||||
2. Wait for Ultrasonic Sensor to detect an object.
|
||||
3. Turn on Motors ``A`` and ``D`` in opposite directions.
|
||||
4. Wait for one quarter of a second (``1500`` milli seconds).
|
||||
4. Wait for one and a half seconds (``1500`` milli seconds).
|
||||
5. Reverse the direction of Motors ``A`` and ``D``.
|
||||
6. Wait for one quarter of a second.
|
||||
6. Wait for one and a half seconds.
|
||||
7. Stop all motors.
|
||||
8. Make an insect chirping sound.
|
||||
9. Loop continuously so that the insect wanders around when the Ultrasonic Sensor is detects something.
|
||||
@ -119,44 +125,44 @@ forever(function () {
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the center button on the EV3 Brick to run the program.
|
||||
|
||||
## Contemplate
|
||||
## Contemplate
|
||||
|
||||
### Test and Analyze
|
||||
### Test and Analyze
|
||||
|
||||
As you work on your solution:
|
||||
1. Describe one part of your design that worked especially well.
|
||||
2. Describe one design change that you had to make.
|
||||
3. What will you try next?
|
||||
As you work on your solution:
|
||||
1. Describe one part of your design that worked especially well.
|
||||
2. Describe one design change that you had to make.
|
||||
3. What will you try next?
|
||||
|
||||
### Review and Revise
|
||||
### Review and Revise
|
||||
|
||||
Take a moment to reflect on your robot solution.
|
||||
Take a moment to reflect on your robot solution.
|
||||
|
||||
Think about:
|
||||
Think about:
|
||||
|
||||
* Does your robot move when the sensor is activated?
|
||||
* If not, what will you change to make the robot’s ability to sense and respond more obvious?
|
||||
* What other behaviors can you add to the robot to make it more realistic?
|
||||
* Does your robot move when the sensor is activated?
|
||||
* If not, what will you change to make the robot’s ability to sense and respond more obvious?
|
||||
* What other behaviors can you add to the robot to make it more realistic?
|
||||
|
||||
Describe two ways you could improve your robot.
|
||||
|
||||
## Continue
|
||||
## Continue
|
||||
|
||||
Personalize your project:
|
||||
|
||||
* Add/remove LEGO elements to improve the way your robot moves.
|
||||
* Add/remove LEGO elements to improve the way your robot moves.
|
||||
* Click on the JavaScript tab and experiment with changing the values in the code.
|
||||
* Add a custom image or sounds by adding blocks from the Brick or Music menus.
|
||||
* Does your robot resemble a creature? Maybe add more craft materials to your project.
|
||||
|
||||
## Communicate
|
||||
## Communicate
|
||||
|
||||
Here are some ideas:
|
||||
Here are some ideas:
|
||||
|
||||
* Create a video of your project, especially your final presentation and your robot’s performance. Explain some important features of your software program.
|
||||
* Produce a building guide for your model by taking a series of photographs as you deconstruct it.
|
||||
* Include an image of your program with comments.
|
||||
* Add a team photograph!
|
||||
* Create a video of your project, especially your final presentation and your robot’s performance. Explain some important features of your software program.
|
||||
* Produce a building guide for your model by taking a series of photographs as you deconstruct it.
|
||||
* Include an image of your program with comments.
|
||||
* Add a team photograph!
|
||||
|
||||
Congratulations! What will you design next?
|
||||
|
||||
|
@ -21,11 +21,11 @@ Here are some fun programs for your @boardname@!
|
||||
"imageUrl": "/static/maker/security-gadget.png"
|
||||
},
|
||||
{
|
||||
"name": "Intruder Detector",
|
||||
"description": "Raise the alarm when an intruder sneaks in",
|
||||
"url":"/maker/intruder-detector",
|
||||
"name": "Movement Detector",
|
||||
"description": "Raise the alarm when an movement sneaks in",
|
||||
"url":"/maker/movement-detector",
|
||||
"cardType": "example",
|
||||
"imageUrl": "/static/maker/intruder-detector.png"
|
||||
"imageUrl": "/static/maker/movement-detector.png"
|
||||
},
|
||||
{
|
||||
"name": "Puppet",
|
||||
@ -212,6 +212,12 @@ Here are some fun programs for your @boardname@!
|
||||
"description": "Keep your brick entertained and happy",
|
||||
"url":"/examples/happy-unhappy",
|
||||
"cardType": "example"
|
||||
}, {
|
||||
{
|
||||
"name": "Turtle",
|
||||
"description": "Encode moves and run them on a driving base",
|
||||
"url":"/examples/turtle",
|
||||
"cardType": "example"
|
||||
}, {
|
||||
"name": "Distance Measurer",
|
||||
"description": "Use a motor to measure angle and distance",
|
||||
|
@ -14,7 +14,7 @@ v = sensors.color3.light(LightIntensityMode.Reflected)
|
||||
min = v
|
||||
max = v
|
||||
setpoint = v
|
||||
while (!(brick.buttonEnter.wasPressed())) {
|
||||
while (!(brick.buttonEnter.isPressed())) {
|
||||
brick.clearScreen()
|
||||
brick.showString("Move robot on terrain", 1)
|
||||
brick.showString("Press ENTER when done", 2)
|
||||
|
@ -1,40 +0,0 @@
|
||||
|
||||
# Print Ports
|
||||
|
||||
```typescript
|
||||
/**
|
||||
* Print the port states on the screen
|
||||
*/
|
||||
//% blockId=brickPrintPorts block="print ports"
|
||||
//% help=brick/print-ports
|
||||
//% weight=1 group="Screen"
|
||||
function printPorts() {
|
||||
const col = 44;
|
||||
clearScreen();
|
||||
|
||||
function scale(x: number) {
|
||||
if (Math.abs(x) > 1000) return Math.round(x / 100) / 10 + "k";
|
||||
return ("" + (x >> 0));
|
||||
}
|
||||
|
||||
// motors
|
||||
const datas = motors.getAllMotorData();
|
||||
for(let i = 0; i < datas.length; ++i) {
|
||||
const data = datas[i];
|
||||
if (!data.actualSpeed && !data.count) continue;
|
||||
const x = i * col;
|
||||
print(`${scale(data.actualSpeed)}%`, x, brick.LINE_HEIGHT)
|
||||
print(`${scale(data.count)}>`, x, 2 * brick.LINE_HEIGHT)
|
||||
print(`${scale(data.tachoCount)}|`, x, 3 * brick.LINE_HEIGHT)
|
||||
}
|
||||
|
||||
// sensors
|
||||
const sis = sensors.internal.getActiveSensors();
|
||||
for(let i =0; i < sis.length; ++i) {
|
||||
const si = sis[i];
|
||||
const x = (si.port() - 1) * col;
|
||||
const v = si._query();
|
||||
print(`${scale(v)}`, x, 9 * brick.LINE_HEIGHT)
|
||||
}
|
||||
}
|
||||
```
|
18
docs/extensions.md
Normal file
@ -0,0 +1,18 @@
|
||||
# Extensions
|
||||
|
||||
## #gallery
|
||||
|
||||
## Using Extensions
|
||||
|
||||
In the web editor, click on ``Settings`` then ``Extensions`` to search and add extensions to the project.
|
||||
The Blocks and JavaScript definitions will be automatically loaded in the editor.
|
||||
|
||||
## Custom extensions
|
||||
|
||||
The [Build Your Own Extension](https://makecode.com/extensions/getting-started) manual is for advanced users who want to publish their own extension.
|
||||
|
||||
## ~ hint
|
||||
|
||||
**Extensions** were previously called **Packages** in MakeCode.
|
||||
|
||||
## ~
|
BIN
docs/file-manager.pdf
Normal file
129
docs/fll.md
Normal file
@ -0,0 +1,129 @@
|
||||
# MakeCode for _FIRST_ LEGO League
|
||||
|
||||

|
||||
|
||||
**For teams participating in City Shaper challenge**, you can use MakeCode for your challenge (see [City Shaper Challenge, page 7 bottom](https://firstinspiresst01.blob.core.windows.net/fll/2020/city-shaper-game-guide-pdf.pdf)!
|
||||
|
||||
We’ve compiled a list of resources and information that we hope will be helpful for you.
|
||||
|
||||
* **Got a question? Post it on the forums** at https://forum.makecode.com/
|
||||
|
||||
## FAQ
|
||||
|
||||
### I found a bug what do I do?
|
||||
|
||||
If you found a bug, please try if it hasn't been fixed yet! Go to https://makecode.mindstorms.com/beta and try if the bug is corrected. Otherwise, please tell us at https://forum.makecode.com/.
|
||||
|
||||
### How do I use MakeCode with my EV3?
|
||||
|
||||
* You will need to install the latest EV3 firmware on your brick. Instructions on how to do that are located here: https://makecode.mindstorms.com/troubleshoot.
|
||||
* You will need a computer with a USB port to connect to the EV3 in order to download your programs.
|
||||
* You will need internet access and a browser on your computer to get to https://makecode.mindstorms.com.
|
||||
* You can [install the app](/offline-app) to use the editor offline.
|
||||
|
||||
### I know LabView, how is MakeCode different?
|
||||
|
||||
We have compiled a guide for EV3 LabView users at https://makecode.mindstorms.com/labview.
|
||||
|
||||
### What’s the best way to get started with MakeCode?
|
||||
|
||||
Go to https://makecode.mindstorms.com. The home screen is filled with videos, tutorials and examples that might be relevant for your missions.
|
||||
|
||||
On the home page, scroll down to the **FLL / City Shaper** section for specific lessons related to Mission 2.
|
||||
|
||||
### Can I load both LEGO MINDSTORMS EV3 Software and MakeCode programs onto my EV3?
|
||||
|
||||
Yes.
|
||||
|
||||
### Can I run the program again on the brick?
|
||||
|
||||

|
||||
|
||||
Use the Brick Buttons and navigate to the File Manager tab. Open the **BrkProg_SAVE** folder,
|
||||
select your program and click the center button to run it again.
|
||||
|
||||
### Does it work without internet?
|
||||
|
||||
No, the editor is cached in your browser cache. However, you can also download the [offline app](/offline-app) in case you need to install it on a computer.
|
||||
|
||||
### How do I figure out what a block does?
|
||||
|
||||
You can right-click on any block and select “Help” in the context menu to open the documentation page describing what that block does.
|
||||
|
||||

|
||||
|
||||
### How do I program in JavaScript?
|
||||
|
||||
Click the **JavaScript** button at the top of the page to get to the JavaScript editor. Students can drag and drop code snippets from the Toolbox on the left, or type directly in the editor. You can switch back and forth between **Blocks** and **JavaScript** as you program.
|
||||
|
||||

|
||||
|
||||
Also, watch the [Text-based Coding](https://legoeducation.videomarketingplatform.co/v.ihtml/player.html?token=3513a83b87fe536b2dc512237465fd1b&source=embed&photo%5fid=35719471) video for more about coding using the JavaScript editor.
|
||||
|
||||
### How do I use the Simulator?
|
||||
|
||||
The Simulator will show the physical representation of your code blocks. For example, based on this code snippet, the Simulator will show the touch sensor on Port 1, and a large motor on Port D.
|
||||
|
||||
```blocks
|
||||
sensors.touch1.onEvent(ButtonEvent.Pressed, function () {
|
||||
motors.largeD.run(50)
|
||||
})
|
||||
```
|
||||
|
||||

|
||||
|
||||
Note that the Simulator is also interactive, so you can simulate inputs with any of the sensors.
|
||||
|
||||
See the video [Block-based Coding and Simulation](https://legoeducation.videomarketingplatform.co/v.ihtml/player.html?token=629730c938e452f0fd7653fbc4708166&source=embed&photo%5fid=35719470) for more about using the simulator.
|
||||
|
||||
### How do I save my programs?
|
||||
|
||||
MakeCode will automatically save your recent projects in the browser. However, you can also save a copy of your project as a file on your computer:
|
||||
|
||||
* From the **Settings** menu, select **Save Project**
|
||||
* This will download your program from the browser as a _lego-myproject.uf2_ file
|
||||
|
||||

|
||||
|
||||
* You can import your saved projects by clicking the Import button on the Home Page
|
||||
|
||||

|
||||
|
||||
### How do I share my programs?
|
||||
|
||||
You can share your projects by clicking on the **share** button in the top left of the screen. This will create a URL which you can send others to open and view your project.
|
||||
|
||||

|
||||
|
||||

|
||||
|
||||
Sharing programs is also shown in the [Tips and Tricks](https://legoeducation.videomarketingplatform.co/v.ihtml/player.html?token=5c594c2373367f7870196f519f3bfc7a&source=embed&photo%5fid=35719472) video.
|
||||
|
||||
### Can I use Bluetooth to transfer my program?
|
||||
|
||||
The official answer is currently no. That being said, we have **Experimental support** for Bluetooth download. Please read the [Bluetooth](/bluetooth) page for more information.
|
||||
|
||||
https://youtu.be/VIq8-6Egtqs
|
||||
|
||||
## Are there YouTube videos on MakeCode for EV3?
|
||||
|
||||
The MakeCode has a [FLL / City Shaper YouTube Channel](https://www.youtube.com/watch?v=IqL0Pyeu5Ng&list=PLMMBk9hE-SeqkOObethhlZtBTEK6FYx3n) with useful videos.
|
||||
|
||||
https://youtu.be/-AirqwC9DL4
|
||||
|
||||
### Why can't I delete my program (*.uf2) files from the Brick?
|
||||
|
||||
There's a bug in the firmware which prevents you from deleting the programs (``*.uf2`` files) from your EV3 Brick. There isn't a firmware update to fix this yet.
|
||||
|
||||
We have prepared a special program that lets you delete UF2 files from the brick.
|
||||
Download [these PDF instructions](/file-manager.pdf) and drop the PDF on the brick drive.
|
||||
This will present you with an menu for deleting files.
|
||||
|
||||
For other common questions, try the FAQ page https://makecode.mindstorms.com/faq.
|
||||
|
||||
## Workarounds
|
||||
|
||||
1. Deleting Programs from the EV3 brick
|
||||
|
||||
>* Description: Unable to delete program files from the EV3 brick after downloading them
|
||||
>* Status: LEGO Education team is working on a fix, no estimated date yet
|
@ -4,10 +4,18 @@
|
||||
|
||||
```codecard
|
||||
[
|
||||
{
|
||||
"name": "Prepare",
|
||||
"imageUrl": "/static/lessons/firmware.png",
|
||||
"description": "To use Microsoft MakeCode with your EV3 Brick, you will need to install the latest LEGO® MINDSTORMS® Education EV3 firmware.",
|
||||
"label": "New? Start Here!",
|
||||
"labelClass": "red ribbon large",
|
||||
"url": "https://makecode.mindstorms.com/troubleshoot"
|
||||
},
|
||||
{
|
||||
"name": "Try",
|
||||
"imageUrl": "/static/lessons/try.png",
|
||||
"description": "Get a quick introduction to programming with EV3.",
|
||||
"description": "Get a quick introduction to programming.",
|
||||
"url": "/getting-started/try",
|
||||
"cardType": "side"
|
||||
},
|
||||
@ -17,6 +25,12 @@
|
||||
"description": "Build a robot and drive into the world of robotics!",
|
||||
"url": "/getting-started/use",
|
||||
"cardType": "side"
|
||||
},
|
||||
{
|
||||
"name": "First LEGO League",
|
||||
"imageUrl": "/static/fll/fll-big.png",
|
||||
"description": "Information about using MakeCode in FLL competitions",
|
||||
"url": "/fll"
|
||||
}
|
||||
]
|
||||
```
|
194
docs/getting-started/try-tutorial.md
Normal file
@ -0,0 +1,194 @@
|
||||
# Try
|
||||
|
||||
## Introduction @unplugged
|
||||
|
||||
Get a quick introduction to programming with EV3.
|
||||
|
||||

|
||||
|
||||
We are excited to help you get started with @boardname@. In this project we will guide you through connecting your EV3 Brick, creating your first program, controlling a Large Motor, a Touch Sensor and a Color Sensor. These steps can take up to 45 minutes.
|
||||
|
||||
## Turn on your EV3 Brick @unplugged
|
||||
|
||||
Power on your EV3 Brick by pressing the Center Button.
|
||||
|
||||

|
||||
|
||||
## Connect Your EV3 Brick to Your Device @unplugged
|
||||
|
||||
Use the USB cable to connect your EV3 Brick to your device.
|
||||
|
||||

|
||||
|
||||
## Handle a button press @fullscreen
|
||||
|
||||
Drag out a ``||brick:on button||`` block from Buttons section in the ``||brick:Brick||`` Toolbox drawer.
|
||||
|
||||
```blocks
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
})
|
||||
```
|
||||
|
||||
## Change of mood @fullscreen
|
||||
|
||||
Drag a Brick Screen ``||brick:show mood||`` block inside the ``||brick:on button||`` block.
|
||||
Change mood to ``neutral``.
|
||||
|
||||
```blocks
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
brick.showMood(moods.neutral)
|
||||
})
|
||||
```
|
||||
|
||||
## Simulate @fullscreen
|
||||
|
||||
**Try out your code in the simulator!**
|
||||
|
||||
Click the center button on the EV3 Brick in the web page. It should display the mood you selected on the screen. Don't hesitate to use the simulator to try out your code during this tutorial!
|
||||
|
||||

|
||||
|
||||
## Play some tunes @fullscreen
|
||||
|
||||
Drag a Music ``||music:play sound effect||`` block below the ``||brick:show mood||`` block.
|
||||
Change sound effect to ``communication hello``.
|
||||
|
||||
```blocks
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
brick.showMood(moods.neutral)
|
||||
music.playSoundEffect(sounds.communicationHello)
|
||||
})
|
||||
```
|
||||
|
||||
## Download to your brick @unplugged
|
||||
|
||||
**Download:** Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the center button on the EV3 Brick to run the program.
|
||||
|
||||
### Did It Work?
|
||||
|
||||
Verify that the program you just created shows eyes on the Brick Display, and that the EV3 Brick played the sound “Hello!”
|
||||
|
||||

|
||||
|
||||
|
||||
**Well done!**
|
||||
|
||||
## Connect a Large Motor @unplugged
|
||||
|
||||
Now you will learn to control the Large Motor.
|
||||
|
||||

|
||||
|
||||
Connect a Large Motor to **Port D** of your EV3 Brick using any of the connector cables.
|
||||
|
||||
## Run a motor @fullscreen
|
||||
|
||||
Drag a ``||motors:run large A motor||`` block inside the ``||brick:on button||`` block.
|
||||
|
||||
```blocks
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
motors.largeA.run(50)
|
||||
})
|
||||
```
|
||||
|
||||
## Tune your motor @fullscreen
|
||||
|
||||
Change ``large motor A`` to ``large motor D``.
|
||||
Click on the **(+)** sign and change to ``1`` rotation.
|
||||
|
||||
```blocks
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
motors.largeD.run(50, 1, MoveUnit.Rotations)
|
||||
})
|
||||
```
|
||||
|
||||
## Download @unplugged
|
||||
|
||||
**Download:** Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the center button on the EV3 Brick to run the program.
|
||||
|
||||
### Did It Rotate?
|
||||
|
||||
Confirm that your motor has turned one rotation at power level 50 before stopping.
|
||||
|
||||
Download and run the program as many times as you want in order to verify this, or tinker with different power levels and different rotations.
|
||||
|
||||

|
||||
|
||||
## Connect a Touch Sensor @unplugged
|
||||
|
||||
We will now control the Large Motor using a Touch Sensor.
|
||||
|
||||
Keeping the Large Motor connected to **Port D**, connect a Touch Sensor to **Port 1** of your EV3 Brick.
|
||||
|
||||

|
||||
|
||||
## Modify Your Program @fullscreen
|
||||
|
||||
* Add a ``||sensors:pause until touch 1 pressed||`` Sensor block on top of the ``||motors:run large motor D||`` block.
|
||||
|
||||
```blocks
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
sensors.touch1.pauseUntil(ButtonEvent.Pressed)
|
||||
motors.largeD.run(50, 1, MoveUnit.Rotations)
|
||||
})
|
||||
```
|
||||
|
||||
## Download @unplugged
|
||||
|
||||
**Download:** Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the center button on the EV3 Brick to run the program.
|
||||
|
||||
### Press the Touch Sensor
|
||||
|
||||
Confirm that the Large Motor has turned one rotation AFTER you press the Touch Sensor.
|
||||
|
||||
Download and run the program as many times as you want in order to verify this, or tinker with different Touch Sensor and Large Motor values.
|
||||
|
||||

|
||||
|
||||
## Connect a Color Sensor @unplugged
|
||||
|
||||
Now we will try to control the Large Motor using another sensor.
|
||||
|
||||

|
||||
|
||||
Keeping the Large Motor connected to **Port D**, connect the Color Sensor to **Port 4**.
|
||||
|
||||
## Update your code @fullscreen
|
||||
|
||||
Using the same program, replace the ``||sensors:pause until touch 1||`` block with a ``||sensors:pause color sensor 3||`` for color block.
|
||||
|
||||
```blocks
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Green)
|
||||
motors.largeD.run(50, 1, MoveUnit.Rotations)
|
||||
})
|
||||
```
|
||||
|
||||
Don't forget to select the color you want to detect (e.g., green)!
|
||||
|
||||
## Download @unplugged
|
||||
|
||||
**Download:** Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the center button on the EV3 Brick to run the program.
|
||||
|
||||
### Place a Colored Brick in Front of the Color Sensor
|
||||
|
||||
Confirm that the Large Motor has turned one rotation AFTER the Color Sensor has detected the colored brick.
|
||||
|
||||
Download and run the program as many times as you want in order to verify this, or tinker with different Color Sensor and Large Motor values.
|
||||
|
||||

|
||||
|
||||
## JavaScript @fullscreen
|
||||
|
||||
Click on the **JavaScript** tab and change the color the Color Sensor detects to Black, Blue, Green, Yellow, Red, White, or Brown. Use Title Case for the color names.
|
||||
|
||||
```typescript
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Blue)
|
||||
motors.largeD.run(50, 1, MoveUnit.Rotations)
|
||||
})
|
||||
```
|
||||
|
||||
## Well Done! @unplugged
|
||||
|
||||
You have now learned how to control some of the inputs and outputs of the EV3.
|
@ -1,10 +1,10 @@
|
||||
# Try
|
||||
# Try
|
||||
|
||||
Get a quick introduction to programming with EV3.
|
||||
|
||||

|
||||
|
||||
We are excited to help you get started with LEGO MINDSTORMS Education EV3. In this project we will guide you through connecting your EV3 brick, creating your first program, controlling a Large Motor, a Touch Sensor and a Color Sensor. These steps can take up to 45 minutes.
|
||||
We are excited to help you get started with @boardname@. In this project we will guide you through connecting your EV3 Brick, creating your first program, controlling a Large Motor, a Touch Sensor and a Color Sensor. These steps can take up to 45 minutes.
|
||||
|
||||
## Turn on your EV3 Brick
|
||||
|
||||
@ -54,6 +54,12 @@ Verify that the program you just created shows eyes on the Brick Display, and th
|
||||
|
||||
**Well done!**
|
||||
|
||||
## Run it Again
|
||||
|
||||

|
||||
|
||||
Use the Brick Buttons and navigate to the File Manager tab. Open the **BrkProg_SAVE** folder, select **Try** and click the center button to run it again.
|
||||
|
||||
## Connect a Large Motor
|
||||
|
||||
Now you will learn to control the Large Motor.
|
||||
@ -135,15 +141,15 @@ Keeping the Large Motor connected to **Port D**, connect the Color Sensor to **P
|
||||
|
||||
```blocks
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Green)
|
||||
sensors.color4.pauseUntilColorDetected(ColorSensorColor.Green)
|
||||
motors.largeD.run(50, 1, MoveUnit.Rotations)
|
||||
})
|
||||
```
|
||||
|
||||
* Using the same program, replace the ``||sensors:pause until touch 1||`` block with a ``||sensors:pause color sensor 3||`` for color block.
|
||||
* Using the same program, replace the ``||sensors:pause until touch 1||`` block with a ``||sensors:pause color sensor 4||`` for color block.
|
||||
|
||||
```block
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Green)
|
||||
sensors.color4.pauseUntilColorDetected(ColorSensorColor.Green)
|
||||
```
|
||||
|
||||
* Select the color you want to detect (e.g., green).
|
||||
|
@ -20,6 +20,12 @@ Build the robot driving base:
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/building-instructions/ev3-rem-driving-base-79bebfc16bd491186ea9c9069842155e.pdf)
|
||||
|
||||
### ~hint
|
||||
|
||||
If clicking the above image doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
### ~
|
||||
|
||||
## Make It Move
|
||||
|
||||
**Code it:** Create a program that makes the Driving Base move forward and stop at the finish line, which is ``1`` meter away.
|
||||
@ -68,6 +74,12 @@ Build and attach an Ultrasonic Sensor to your driving base:
|
||||
|
||||
[](https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/building-instructions/ev3-ultrasonic-sensor-driving-base-61ffdfa461aee2470b8ddbeab16e2070.pdf)
|
||||
|
||||
### ~hint
|
||||
|
||||
If clicking the above image doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
### ~
|
||||
|
||||
## Detect an Object
|
||||
|
||||
**Code it:** Create a program that moves the Driving Base and makes it stop ``6`` cm from the Cuboid.
|
||||
@ -106,4 +118,4 @@ sensors.ultrasonic4.setThreshold(UltrasonicSensorEvent.ObjectDetected, 10)
|
||||
**Congratulations!**
|
||||
|
||||
You are ready to move on to the next steps.
|
||||
Try a LEGO MINDSTORMS [Design Engineering](/design-engineering), [Coding](/coding), or [Maker](/maker) activity.
|
||||
Try a [Design Engineering](/design-engineering), [Coding](/coding), or [Maker](/maker) activity.
|
||||
|
@ -1,3 +1,3 @@
|
||||
{
|
||||
"appref": "v0"
|
||||
"appref": "v1.2.22"
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Coding in MakeCode
|
||||
|
||||
This guide helps users who are used to the LabView LEGO Minstorms editor quickly get familiar with using blocks in MakeCode.
|
||||
This guide helps users who are used to work with @boardname@ to get familiar with using blocks in MakeCode.
|
||||
|
||||
## Snap together the blocks
|
||||
|
||||
@ -29,9 +29,9 @@ motors.largeA.stop()
|
||||
|
||||
## Download to the EV3
|
||||
|
||||
Before you actually run your program on the @boardname@, you can first try it in the simulator. The MakeCode editor includes a simulator in the browser for you to test your code. You can make changes to your program and check them out it the simulator to make sure your code works the way want. The similator knows when you modify your code and it restarts automatically to run the new code.
|
||||
Before you actually run your program on the EV3 Brick, you can first try it in the simulator. The MakeCode editor includes a simulator in the browser for you to test your code. You can make changes to your program and check them out it the simulator to make sure your code works the way want. The similator knows when you modify your code and it restarts automatically to run the new code.
|
||||
|
||||
Once you're ready to transfer your program to the @boardname@, click the ``|Download|`` button and follow the instructions.
|
||||
Once you're ready to transfer your program to the EV3 Brick, click the ``|Download|`` button and follow the instructions.
|
||||
|
||||
## Single motors
|
||||
|
||||
@ -61,6 +61,12 @@ motors.largeBC.steer(0, 50, 1, MoveUnit.Rotations);
|
||||
motors.largeBC.stop();
|
||||
```
|
||||
|
||||
### ~ hint
|
||||
|
||||
The **turn ratio range is -200, 200** unlike LabView who used -100,100.
|
||||
|
||||
### ~
|
||||
|
||||
## Tank
|
||||
|
||||
The **tank** blocks control the speed of two motors. These are commonly used for a differential drive robot. The blocks can also specify the duration, angle, or number of rotations.
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Lessons
|
||||
|
||||
Learning activities for LEGO Mindstorms with MakeCode.
|
||||
Learning activities for @boardname@ with MakeCode.
|
||||
|
||||
## Motors and motion
|
||||
|
||||
|
@ -1,68 +0,0 @@
|
||||
# Classroom Management Tips
|
||||
|
||||
## Lesson Planning
|
||||
|
||||
### Required Materials
|
||||
|
||||
* [LEGO MINDSTORMS Education EV3 Core Set](https://education.lego.com/enus/products/legomindstormseducationev3coreset/5003400)
|
||||
* Lesson plan
|
||||
* Student Worksheet for each activity
|
||||
* Inspirational images for each activity
|
||||
* Modeling materials already available in your classroom
|
||||
|
||||
### How much time do you need?
|
||||
|
||||
Each lesson is designed to take 90 minutes. If you work in shorter class periods, you can break this down into two 45 minute sessions.
|
||||
|
||||
### Preparation
|
||||
|
||||
It is important to establish student groups. Groups of two work well. Ensure that each student has a copy of the Student Worksheet for recording their design process, or alternatively, they can use their own preferred method for recording their design journey. They will also need the LEGO MINDSTORMS Education EV3 Core Set (one set for every two students is recommended).
|
||||
|
||||
### Prior Learning
|
||||
|
||||
Before beginning these Maker activities, it is recommended that students complete the lessons from the Introduction to Robotics Lesson Plan. These lessons can be found in both EV3 Lab and EV3 Programming. These tutorial lessons last between 45 - 90 minutes each, and you will need to factor this into your lesson planning.
|
||||
|
||||
However, if you prefer a more open-ended, explorative method, you can start out with this activity and allow students to find help on their own by referring to the Robot Educator Tutorials.
|
||||
|
||||
## The LEGO Education Maker (Design) Process #design-process
|
||||
|
||||
### Defining the Problem
|
||||
|
||||
It is important that students define a real problem to solve, or find a new design opportunity from the start. The “Connect” images are provided to help students think about designing their solutions. At this stage of the process, it is important that you not show examples of a final or sample solution.
|
||||
|
||||
### Brainstorm
|
||||
|
||||
Brainstorming is an active part of making. Some students will find it easier to explore their thoughts through tinkering (hands-on experimentation) with the LEGO bricks, and others will prefer to record sketches and notes. Group work is essential, but it is important to allow time for students to work alone before sharing their ideas with their groups.
|
||||
|
||||
### Define the Design Criteria
|
||||
|
||||
Discussing and reaching an agreement about the best solution to build can involve a lot of negotiation and may require different techniques that are dependent on the students’ skills. For example:
|
||||
|
||||
* Some students draw well.
|
||||
* Others may build part of a model, and then describe what they mean.
|
||||
* Other students may be good at describing a strategy.
|
||||
|
||||
Encourage an ethos where students can share anything, no matter how abstract it might sound. Be active during this phase and ensure that the ideas the students choose are achievable.
|
||||
|
||||
It is important that students set clear design criteria. Once the solution to the problem has been made, the students will return to these criteria, which will then form the basis for testing how well their solution works.
|
||||
|
||||
### Go Make
|
||||
|
||||
Students must make one of their ideas using the LEGO set, and can use other materials if needed. If they are finding it hard to build their idea, encourage them to break problems down into smaller parts. Explain that they do not have to come up with the whole solution from the start. Remind students that this process is iterative and they must test, analyze, and revise their idea as they go.
|
||||
|
||||
Using this Maker process does not mean you are following an inflexible set of steps. Instead, think of it as a set of practices.
|
||||
For example, brainstorming may be prominent at the beginning of the process. However, students may also need to brainstorm ideas when they are trying to figure out ways to improve their idea, or when they have a bad test result and must change a feature of their design.
|
||||
|
||||
### Review and Revise Your Solution
|
||||
|
||||
To help students develop their critical thinking and communication skills, you may wish to have students from one group observe and critique another group’s solution. Peer review and formative feedback helps both the students giving, and the students receiving the feedback to improve their work.
|
||||
|
||||
### Communicate Your Solution
|
||||
|
||||
The Student Worksheet is helpful for basic documentation of the activity. Students can also refer to it when presenting their work in front of the class. You may also wish to use the Student Worksheet as a portfolio for performance evaluations or for student self-evaluation.
|
||||
|
||||
## Maker (Design) Process Diagram
|
||||
|
||||
Here's a diagram to quickly illustrate the steps of the Maker (Design) Process. You can copy and print this as a poster to give to the students.
|
||||
|
||||

|
@ -3,7 +3,7 @@
|
||||
## Objective
|
||||
|
||||
Design ways to improve driving safety by helping to prevent drivers from falling asleep and causing an accident.
|
||||
|
||||
|
||||

|
||||
|
||||
## Connect
|
||||
@ -20,6 +20,12 @@ Think about what you have learned, then document it. Describe the problem in you
|
||||
|
||||
Start by constructing this model. Read the building instructions [here](https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/building-instructions/ev3-rem-color-sensor-down-driving-base-d30ed30610c3d6647d56e17bc64cf6e2.pdf) first.
|
||||
|
||||
### ~hint
|
||||
|
||||
If clicking the above image doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
### ~
|
||||
|
||||

|
||||
|
||||
## Program
|
||||
@ -44,13 +50,13 @@ Create a program that drives the robot forward until the Color Sensor sees red.
|
||||
|
||||
Place a ``||motors:steer large B+C||`` block from ``||motors:Motors||`` under ``||loops:on start||``. Change the speed to 20%.
|
||||
|
||||
```blocks
|
||||
```blocks
|
||||
motors.largeBC.steer(0, 20)
|
||||
```
|
||||
|
||||
### Step 2
|
||||
|
||||
Place a ``||loops:while||`` loop block under ``||motors:steer large B+C||``.
|
||||
Place a ``||loops:while||`` loop block under ``||motors:steer large B+C||``.
|
||||
|
||||
```blocks
|
||||
motors.largeBC.steer(0, 20)
|
||||
@ -60,18 +66,18 @@ while (true) {
|
||||
|
||||
### Step 3
|
||||
|
||||
Place a ``||sensors:pause for color||`` from ``||sensors:Sensors||`` inside the ``||loops:while||`` loop block. Change the color to red.
|
||||
|
||||
Place a ``||sensors:pause until color detected||`` from ``||sensors:Sensors||`` inside the ``||loops:while||`` loop block. Change the color to red.
|
||||
|
||||
```blocks
|
||||
motors.largeBC.steer(0, 20)
|
||||
while (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
}
|
||||
```
|
||||
|
||||
### Step 4
|
||||
|
||||
Place a ``||motors:stop all motors||`` block under the ``||sensors:pause for color||`` block.
|
||||
Place a ``||motors:stop all motors||`` block under the ``||sensors:pause until color detected||`` block.
|
||||
|
||||
Study the program...what do you think the program will do?
|
||||
|
||||
@ -80,7 +86,7 @@ Study the program...what do you think the program will do?
|
||||
```blocks
|
||||
motors.largeBC.steer(0, 20)
|
||||
while (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
motors.stopAll()
|
||||
}
|
||||
```
|
||||
@ -99,7 +105,7 @@ Place a ``||loops:while||`` loop block under ``||loops:on start||``.
|
||||
|
||||
```blocks
|
||||
while (true) {
|
||||
|
||||
|
||||
}
|
||||
```
|
||||
|
||||
@ -121,33 +127,33 @@ Place a ``||loops:while||`` loop block under the ``||motors:steer large B+C||``
|
||||
while (true) {
|
||||
motors.largeBC.steer(0, 20)
|
||||
while (true) {
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Step 5
|
||||
|
||||
Place a ``||sensors:pause for color||`` block from ``||sensors:Sensors||`` inside the ``||loops:while||`` loop block. Change the color to red.
|
||||
Place a ``||sensors:pause until color detected||`` block from ``||sensors:Sensors||`` inside the ``||loops:while||`` loop block. Change the color to red.
|
||||
|
||||
```blocks
|
||||
while (true) {
|
||||
motors.largeBC.steer(0, 20)
|
||||
while (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Step 6
|
||||
|
||||
Place a ``||motors:stop all motors||`` block under the ``||sensors:pause for color||`` block.
|
||||
Place a ``||motors:stop all motors||`` block under the ``||sensors:pause until color detected||`` block.
|
||||
|
||||
```blocks
|
||||
while (true) {
|
||||
motors.largeBC.steer(0, 20)
|
||||
while (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
motors.stopAll()
|
||||
}
|
||||
}
|
||||
@ -161,32 +167,32 @@ Place a ``||loops:while||`` loop block under the second ``||loops:while||`` loop
|
||||
while (true) {
|
||||
motors.largeBC.steer(0, 20)
|
||||
while (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
motors.stopAll()
|
||||
}
|
||||
while (true) {
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Step 8
|
||||
|
||||
Place a ``||sensors:pause for color||`` block inside the new ``||loops:while||`` loop block. Change the color to red.
|
||||
Place a ``||sensors:pause unril color detected||`` block inside the new ``||loops:while||`` loop block. Change the color to red.
|
||||
|
||||
What do you think the program will do?
|
||||
|
||||
**Hint:** The motors will run until the Color Sensor detects the color red, then it will stop all motors. The motors will also run and not stop when the color sensor detects the color green.
|
||||
|
||||
|
||||
```blocks
|
||||
while (true) {
|
||||
motors.largeBC.steer(0, 20)
|
||||
while (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
motors.stopAll()
|
||||
}
|
||||
while (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
}
|
||||
}
|
||||
```
|
||||
@ -208,16 +214,17 @@ Think about what you have learned, then document it. Describe your pseudocode fo
|
||||
```blocks
|
||||
motors.largeBC.steer(0, 20)
|
||||
while (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Yellow)
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Yellow)
|
||||
music.playSoundEffect(sounds.systemGeneralAlert)
|
||||
}
|
||||
while (true) {
|
||||
while (true) { sensors.color3.pauseForLight(LightIntensityMode.Reflected, LightCondition.Bright)
|
||||
while (true) {
|
||||
sensors.color3.pauseUntilLightDetected(LightIntensityMode.Reflected, Light.Bright)
|
||||
motors.largeB.run(10)
|
||||
motors.largeC.run(-10)
|
||||
}
|
||||
while (true) {
|
||||
sensors.color3.pauseForLight(LightIntensityMode.Reflected, LightCondition.Bright)
|
||||
sensors.color3.pauseUntilLightDetected(LightIntensityMode.Reflected, Light.Bright)
|
||||
motors.largeA.run(-10)
|
||||
motors.largeA.run(10)
|
||||
}
|
||||
@ -234,12 +241,13 @@ You will need to constantly debug your program in order to make your robot trave
|
||||
|
||||
```blocks
|
||||
while (true) {
|
||||
while (true) { sensors.color3.pauseForLight(LightIntensityMode.Reflected, LightCondition.Bright)
|
||||
while (true) {
|
||||
sensors.color3.pauseUntilLightDetected(LightIntensityMode.Reflected, Light.Bright)
|
||||
motors.largeB.run(10)
|
||||
motors.largeC.run(-10)
|
||||
}
|
||||
while (true) {
|
||||
sensors.color3.pauseForLight(LightIntensityMode.Reflected, LightCondition.Bright)
|
||||
sensors.color3.pauseUntilLightDetected(LightIntensityMode.Reflected, Light.Bright)
|
||||
motors.largeB.run(-10)
|
||||
motors.largeC.run(10)
|
||||
}
|
||||
@ -250,10 +258,10 @@ while (true) {
|
||||
|
||||
Consider the following questions:
|
||||
|
||||
1. What challenged you?
|
||||
2. Where there any surprises?
|
||||
1. What challenged you?
|
||||
2. Where there any surprises?
|
||||
3. How could you improve your program?
|
||||
4. Could your program have been more streamlined?
|
||||
4. Could your program have been more streamlined?
|
||||
5. Have you used too many blocks?
|
||||
6. Is there a more efficient way of building your program?
|
||||
7. How could your program be used in real-world scenarios?
|
||||
|
@ -1,139 +0,0 @@
|
||||
|
||||
# Make a Security Gadget
|
||||
|
||||
Invent a Security Gadget that will protect your belongings by warning you!
|
||||
|
||||

|
||||
|
||||
## Connect
|
||||
|
||||
Over time, people have come up with many different ways to help protect their personal belongings from theft. These inventions include simple alarm systems and even traps!
|
||||
|
||||

|
||||
|
||||
Look at the photos and think about:
|
||||
|
||||
* What do you see?
|
||||
* Can you see any new design opportunities?
|
||||
* What problems can you see?
|
||||
* How could you make use of the LEGO bricks, the EV3 Programmable Brick, motors, and sensors?
|
||||
|
||||
### Things You’ll Need
|
||||
|
||||
* [LEGO MINDSTORMS Education EV3 Core Set](https://education.lego.com/enus/products/legomindstormseducationev3coreset/5003400)
|
||||
|
||||
Additional materials to add to your Security Gadget:
|
||||
|
||||
* String
|
||||
* Arts and crafts materials such as:
|
||||
>* Cardboard
|
||||
>* Construction paper
|
||||
>* Pipe cleaners
|
||||
>* Plastic or paper cups
|
||||
>* Recycled materials
|
||||
>* Rubber bands
|
||||
>* Wire
|
||||
|
||||
### Prior Knowledge
|
||||
|
||||
This activity uses sensor inputs. You may want to try the [Use](/getting-started/use) or [Object Detection](/coding/object-detection) activity before this one. Or, you can start out with this activity and tinker with coding sensor inputs on your own.
|
||||
|
||||
## Contemplate
|
||||
|
||||
Follow the steps of the [Maker Design Process](/lessons/classroom-management#design-process) for this lesson:
|
||||
|
||||

|
||||
|
||||
### Defining the Problem
|
||||
|
||||
1. What problems did you imagine?
|
||||
2. Pick one problem and explain it to a partner.
|
||||
|
||||
### Brainstorm
|
||||
|
||||
Now that you have defined a problem, start to generate ideas for solving it.
|
||||
|
||||
### ~hint
|
||||
|
||||
Some things to do while brainstorming:
|
||||
|
||||
* Use the bricks from the LEGO set to help you brainstorm or sketch your ideas on paper.
|
||||
* The goal of brainstorming is to explore as many solutions as possible. You can use the tinkering examples in the Sample Solutions section below as inspiration for getting started.
|
||||
* Share your ideas and get some feedback. It may lead to more ideas!
|
||||
|
||||
### ~
|
||||
|
||||
### Define the Design Criteria
|
||||
|
||||
1. You should have generated a number of ideas. Now select the best one to make.
|
||||
2. Write out two or three specific design criteria your design must meet.
|
||||
|
||||
### Go Make
|
||||
|
||||
It is time to start making!
|
||||
|
||||
* Use the components from the LEGO® MINDSTORMS EV3 Core Set and additional materials to make your chosen solution.
|
||||
* Test and analyze your design as you go and record any improvements that you make.
|
||||
|
||||
### Review and Revise Your Solution
|
||||
|
||||
* Have you managed to solve the problem that you defined?
|
||||
* Look back at your design criteria. How well does your solution work?
|
||||
* How can you improve your design?
|
||||
|
||||
### Communicate Your Solution
|
||||
|
||||
Now that you have finished you can:
|
||||
|
||||
* Make a sketch or take a photo or video of your model.
|
||||
* Label the three most important parts and explain how they work.
|
||||
* Share your work with others.
|
||||
|
||||
## Continue
|
||||
|
||||
### Phone Protector - Sample Solution
|
||||
|
||||
This example program combined with the small model will sound an alarm if someone picks it up. The program activates an alarm when an object is lifted from the Touch Sensor.
|
||||
|
||||

|
||||
|
||||
#### Programming
|
||||
|
||||
1. Drag a ``||sensors:pause until touch||`` block and place it inside the ``||loops:forever||`` loop.
|
||||
2. Drag a ``||music:play sound effect||`` block and place it below the ``||sensors:pause until||`` block.
|
||||
3. Change the sound effect to ``mechanical horn1``.
|
||||
|
||||
```blocks
|
||||
forever(function () {
|
||||
sensors.touch1.pauseUntil(ButtonEvent.Pressed)
|
||||
music.playSoundEffect(sounds.mechanicalHorn1)
|
||||
})
|
||||
```
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the ``center`` button on the EV3 Brick to run the program.
|
||||
|
||||
### Object Detection - Sample Solution
|
||||
|
||||
This example program combined with the small model will sound an alarm if someone (or something) crosses its path! The program activates an alarm when an object moves in front of the Ultrasonic Sensor.
|
||||
|
||||

|
||||
|
||||
#### Programming
|
||||
|
||||
1. Drag a ``||sensors:pause until ultrasonic||`` block and place it inside the ``||loops:forever||`` loop.
|
||||
2. Drag a ``||music:play sound effect||`` block and place it below the ``||sensors:pause until||`` block.
|
||||
3. Change the sound effect to ``mechanical horn1``.
|
||||
|
||||
```blocks
|
||||
forever(function () {
|
||||
sensors.ultrasonic4.pauseUntil(UltrasonicSensorEvent.ObjectDetected)
|
||||
music.playSoundEffect(sounds.mechanicalHorn1)
|
||||
})
|
||||
```
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the ``center`` button on the EV3 Brick to run the program.
|
||||
|
||||
### Well done!
|
||||
|
||||
Click [here](/examples) to try out some more projects!
|
||||
|
@ -1,164 +0,0 @@
|
||||
# Make a Sound Machine
|
||||
|
||||
Make a Sound Machine that can play a rhythm, music or just noise!
|
||||
|
||||

|
||||
|
||||
## Connect
|
||||
|
||||
Music is made up of a combination of sounds, notes and rhythm. A rhythm is a regular movement or repeated pattern of movements that can be used in many different ways. In mechanical machines, a rhythm can help keep a machine running smoothly. It can also be used to generate different sounds in music.
|
||||
|
||||

|
||||
|
||||
Look at the photos and think about:
|
||||
|
||||
* What do you see?
|
||||
* Can you see any new design opportunities?
|
||||
* What problems can you see?
|
||||
* How could you make use of the LEGO bricks, the EV3 Programmable Brick, motors, and sensors?
|
||||
|
||||
### Things You’ll Need
|
||||
|
||||
* [LEGO MINDSTORMS Education EV3 Core Set](https://education.lego.com/enus/products/legomindstormseducationev3coreset/5003400)
|
||||
|
||||
Additional materials to add to your Sound Machine:
|
||||
|
||||
* Small musical instruments, such as chimes, bells, and small drums
|
||||
* Arts and crafts materials such as:
|
||||
>* Cardboard
|
||||
>* Construction paper
|
||||
>* Pipe cleaners
|
||||
>* Plastic or paper cups
|
||||
>* Recycled materials
|
||||
>* Rubber bands
|
||||
>* Wire
|
||||
|
||||
### Prior Knowledge
|
||||
|
||||
This activity uses motor rotations and sensor inputs. You may want to try the [Use](/getting-started/use) or [Object Detection](/coding/object-detection) activity before this one. Or, you can start out with this activity and tinker with coding motor and sensor inputs on your own.
|
||||
|
||||
## Contemplate
|
||||
|
||||
Follow the steps of the [Maker Design Process](/lessons/classroom-management#design-process) for this lesson:
|
||||
|
||||

|
||||
|
||||
### Defining the Problem
|
||||
|
||||
1. What problems did you imagine?
|
||||
2. Pick one problem and explain it to a partner.
|
||||
|
||||
### Brainstorm
|
||||
|
||||
Now that you have defined a problem, start to generate ideas for solving it.
|
||||
|
||||
### ~hint
|
||||
|
||||
Some things to do while brainstorming:
|
||||
|
||||
* Use the bricks from the LEGO set to help you brainstorm or sketch your ideas on paper.
|
||||
* The goal of brainstorming is to explore as many solutions as possible. You can use the tinkering examples in the Sample Solutions section below as inspiration for getting started.
|
||||
* Share your ideas and get some feedback. It may lead to more ideas!
|
||||
|
||||
### ~
|
||||
|
||||
### Define the Design Criteria
|
||||
|
||||
* You should have generated a number of ideas. Now select the best one to make.
|
||||
* Write out two or three specific design criteria your design must meet.
|
||||
|
||||
### Go Make
|
||||
|
||||
It is time to start making!
|
||||
|
||||
* Use the components from the LEGO® MINDSTORMS EV3 Core Set and additional materials to make your chosen solution.
|
||||
* Test and analyze your design as you go and record any improvements that you make.
|
||||
|
||||
### Review and Revise Your Solution
|
||||
|
||||
* Have you managed to solve the problem that you defined?
|
||||
* Look back at your design criteria. How well does your solution work?
|
||||
* How can you improve your design?
|
||||
|
||||
### Communicate Your Solution
|
||||
|
||||
Now that you have finished you can:
|
||||
* Make a sketch or take a photo or video of your model.
|
||||
* Label the three most important parts and explain how they work.
|
||||
* Share your work with others.
|
||||
|
||||
## Continue
|
||||
|
||||
### Rhythm Maker - Sample Solution
|
||||
|
||||
This example program combined with the small model will make a beat and rhythm on any surface when the program is run.
|
||||
|
||||

|
||||
|
||||
#### Programming
|
||||
|
||||
1. Drag a run ``||motors:large motor A||`` block inside the ``||loops:forever||`` loop.
|
||||
2. Press the **(+)**.
|
||||
3. Change the rotations to `2`.
|
||||
4. Drag a ``||loops:pause||`` block and place it under the motor block.
|
||||
5. Change the duration to ``200`` ms.
|
||||
6. Drag a ``||run large motor A||`` block inside the ``||loops:forever||`` loop.
|
||||
7. Press the **(+)**.
|
||||
8. Change the power to `100`.
|
||||
9. Change the rotations to `1`.
|
||||
|
||||
```blocks
|
||||
forever(function () {
|
||||
motors.largeA.run(50, 2, MoveUnit.Rotations)
|
||||
pause(200)
|
||||
motors.largeA.run(100, 1, MoveUnit.Rotations)
|
||||
})
|
||||
```
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the ``center`` button on the EV3 Brick to run the program.
|
||||
|
||||
### Color Sensor Sounds - Sample Solution
|
||||
|
||||
You can also tinker with the use of sensors.
|
||||
|
||||

|
||||
|
||||
#### Programming
|
||||
|
||||
1. Drag an ``||logic:if else||`` Logic block and place it inside the ``||loops:forever||`` loop.
|
||||
2. Drag a ``||sensors:pause color sensor||`` block and place it inside the ``||logic:if true then||`` block.
|
||||
3. Change the color to ``blue``.
|
||||
4. Drag a ``||music:play tone||`` block and place under the sensor block.
|
||||
5. Change the tone to ``Middle G`` (392 Hz).
|
||||
6. Drag a ``||sensors:pause color sensor||`` block and place it inside the ``||logic:else||`` block.
|
||||
7. Change the color to ``red``.
|
||||
8. Drag a ``||music:play tone||`` block and place under the new sensor block.
|
||||
9. Change the tone to ``High C`` (523 Hz).
|
||||
10. Press the **(+)**.
|
||||
11. Drag a ``||sensors:pause color sensor||`` block and place it inside the ``||logic:else if||`` block.
|
||||
12. Change the color to ``green``.
|
||||
13. Drag a ``||music:play tone||`` block and place under the new sensor block.
|
||||
14. Change the tone to ``High D`` (587 Hz).
|
||||
|
||||
```blocks
|
||||
forever(function () {
|
||||
if (true) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Blue)
|
||||
music.playTone(392, music.beat(BeatFraction.Whole))
|
||||
} else if (false) {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Red)
|
||||
music.playTone(523, music.beat(BeatFraction.Half))
|
||||
} else {
|
||||
sensors.color3.pauseForColor(ColorSensorColor.Green)
|
||||
music.playTone(587, music.beat(BeatFraction.Half))
|
||||
}
|
||||
})
|
||||
```
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the ``center`` button on the EV3 Brick to run the program.
|
||||
|
||||
### Well done!
|
||||
|
||||
Click [here](/examples) to try out some more projects!
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
# Make It Move Without Wheels
|
||||
# Make It Move Without Wheels
|
||||
|
||||
## Objective @unplugged
|
||||
|
||||
@ -10,7 +10,7 @@ Your robot will:
|
||||
* Use at least one motor
|
||||
* Use NO wheels for locomotion
|
||||
|
||||

|
||||

|
||||
|
||||
|
||||
## Construct @unplugged
|
||||
@ -24,8 +24,14 @@ The Walker Bot combines an EV3 Frame and two legs that are mirror-images to crea
|
||||
The legs in the Walker Bot are designed to show how to change the rotary motion of a motor to reciprocating motion.
|
||||
|
||||
Start by reading [these](https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/ev3-dep/building%20instructions/walker-bot-bi-180fc24f9298e1dd6201099627d43903.pdf) instructions first.
|
||||
|
||||

|
||||
|
||||
### ~hint
|
||||
|
||||
If clicking the above image doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
### ~
|
||||
|
||||

|
||||
|
||||
|
||||
## Program 1 @fullscreen
|
||||
@ -37,7 +43,7 @@ Place a ``||motors:tank large B+C||`` block from ``||motors:Motors||`` under ``|
|
||||
Change the speed to `-60%` (for motor B) and `+60%` (for motor C).
|
||||
Change the rotations to `9`.
|
||||
|
||||
The ``||motors:tank large B+C||`` block will run for `9` rotations when the **center** button is pressed on the EV3 brick. The motors are set for the reverse direction because they are mounted upside down in this model.
|
||||
The ``||motors:tank large B+C||`` block will run for `9` rotations when the **center** button is pressed on the EV3 Brick. The motors are set for the reverse direction because they are mounted upside down in this model.
|
||||
|
||||
```blocks
|
||||
motors.largeBC.tank(-60, 60, 9, MoveUnit.Rotations)
|
||||
@ -47,7 +53,7 @@ motors.largeBC.tank(-60, 60, 9, MoveUnit.Rotations)
|
||||
|
||||
Place a ``||motors:stop all motors||`` block under ``||motors:tank large B+C||``.
|
||||
|
||||
The ``||motors:tank large B+C||`` block will run for `9` rotations when the **center** button is pressed on the EV3 brick then stop.
|
||||
The ``||motors:tank large B+C||`` block will run for `9` rotations when the **center** button is pressed on the EV3 Brick then stop.
|
||||
|
||||
```blocks
|
||||
motors.largeBC.tank(-60, 60, 9, MoveUnit.Rotations)
|
||||
@ -59,7 +65,7 @@ motors.stopAll()
|
||||
Place a ``||brick:show string||`` block under ``||motors:stop all motors||``.
|
||||
Change the `"Hello World"` text to `"30 cm"`.
|
||||
|
||||
The ``||motors:tank large B+C||`` will run for `9` rotations when the **center** button is pressed on the EV3 brick then stop and display "30 cm" on the EV3 Brick’s screen.
|
||||
The ``||motors:tank large B+C||`` will run for `9` rotations when the **center** button is pressed on the EV3 Brick then stop and display "30 cm" on the EV3 Brick’s screen.
|
||||
|
||||
```blocks
|
||||
motors.largeBC.tank(-60, 60, 9, MoveUnit.Rotations)
|
||||
|
@ -1,4 +1,4 @@
|
||||
# Make It Move Without Wheels
|
||||
# Make It Move Without Wheels
|
||||
|
||||
## Objective
|
||||
|
||||
@ -10,7 +10,7 @@ Your robot will:
|
||||
* Use at least one motor
|
||||
* Use NO wheels for locomotion
|
||||
|
||||

|
||||

|
||||
|
||||
## Construct
|
||||
|
||||
@ -23,8 +23,14 @@ The Walker Bot combines an EV3 Frame and two legs that are mirror-images to crea
|
||||
The legs in the Walker Bot are designed to show how to change the rotary motion of a motor to reciprocating motion.
|
||||
|
||||
Start by reading [these](https://le-www-live-s.legocdn.com/sc/media/lessons/mindstorms-ev3/ev3-dep/building%20instructions/walker-bot-bi-180fc24f9298e1dd6201099627d43903.pdf) instructions first.
|
||||
|
||||

|
||||
|
||||
### ~hint
|
||||
|
||||
If clicking the above image doesn't open the instructions, right-click on the image and choose "Save link as..." to download the PDF.
|
||||
|
||||
### ~
|
||||
|
||||

|
||||
|
||||
|
||||
## Program
|
||||
@ -38,7 +44,7 @@ Place a ``||motors:tank large B+C||`` block from ``||motors:Motors||`` under ``|
|
||||
Change the speed to `-60%` (for motor B) and `+60%` (for motor C).
|
||||
Change the rotations to `9`.
|
||||
|
||||
The ``||motors:tank large B+C||`` block will run for `9` rotations when the **center** button is pressed on the EV3 brick. The motors are set for the reverse direction because they are mounted upside down in this model.
|
||||
The ``||motors:tank large B+C||`` block will run for `9` rotations when the **center** button is pressed on the EV3 Brick. The motors are set for the reverse direction because they are mounted upside down in this model.
|
||||
|
||||
```blocks
|
||||
motors.largeBC.tank(-60, 60, 9, MoveUnit.Rotations)
|
||||
@ -48,7 +54,7 @@ motors.largeBC.tank(-60, 60, 9, MoveUnit.Rotations)
|
||||
|
||||
Place a ``||motors:stop all motors||`` block under ``||motors:tank large B+C||``.
|
||||
|
||||
The ``||motors:tank large B+C||`` block will run for `9` rotations when the **center** button is pressed on the EV3 brick then stop.
|
||||
The ``||motors:tank large B+C||`` block will run for `9` rotations when the **center** button is pressed on the EV3 Brick then stop.
|
||||
|
||||
```blocks
|
||||
motors.largeBC.tank(-60, 60, 9, MoveUnit.Rotations)
|
||||
@ -60,7 +66,7 @@ motors.largeBC.stop()
|
||||
Place a ``||brick:show string||`` block under ``||motors:stop all motors||``.
|
||||
Change the `"Hello World"` text to `"30 cm"`.
|
||||
|
||||
The ``||motors:tank large B+C||`` will run for `9` rotations when the **center** button is pressed on the EV3 brick then stop and display "30 cm" on the EV3 Brick’s screen.
|
||||
The ``||motors:tank large B+C||`` will run for `9` rotations when the **center** button is pressed on the EV3 Brick then stop and display "30 cm" on the EV3 Brick’s screen.
|
||||
|
||||
```blocks
|
||||
motors.largeBC.tank(-60, 60, 9, MoveUnit.Rotations)
|
||||
|
@ -1,16 +1,12 @@
|
||||
# Maker Activites
|
||||
|
||||
These six activities require the LEGO® MINDSTORMS® Education EV3 Core Set (45544). Supporting materials for teachers and middle school students are provided, offering everything teachers and students need to explore their inner makers as they follow the design process to solve open-ended, themed challenges...
|
||||
|
||||
* [Download Curriculum Materials](https://education.lego.com/en-us/downloads/mindstorms-ev3)
|
||||
|
||||
## Activites
|
||||
|
||||
```codecard
|
||||
[
|
||||
{
|
||||
"name": "Make A Sound Machine",
|
||||
"description": "Create instruments with your EV3 Brick!",
|
||||
"description": "Make a Sound Machine that can play a rhythm, music or just noise!",
|
||||
"url":"/maker/sound-machine",
|
||||
"cardType": "example",
|
||||
"imageUrl": "/static/lessons/make-a-sound-machine.png",
|
||||
@ -18,7 +14,7 @@ These six activities require the LEGO® MINDSTORMS® Education EV3 Core Set (455
|
||||
},
|
||||
{
|
||||
"name": "Make A Security Gadget",
|
||||
"description": "TBD",
|
||||
"description": "Invent a Security Gadget that will protect your belongings by warning you!",
|
||||
"url":"/maker/security-gadget",
|
||||
"cardType": "example",
|
||||
"imageUrl": "/static/lessons/make-a-security-device.png",
|
||||
|
@ -1,4 +1,4 @@
|
||||
# Intruder Detector
|
||||
# Movement Detector
|
||||
|
||||
This program will activate an alarm when an object moves in front of the Ultrasonic Sensor.
|
||||
|
@ -1,9 +1,139 @@
|
||||
# Security Gadget
|
||||
|
||||
This program will activate an alarm when an object is lifted from the Touch Sensor.
|
||||
# Make a Security Gadget
|
||||
|
||||
Invent a Security Gadget that will protect your belongings by warning you!
|
||||
|
||||

|
||||
|
||||
## Connect
|
||||
|
||||
Over time, people have come up with many different ways to help protect their personal belongings from theft. These inventions include simple alarm systems and even traps!
|
||||
|
||||

|
||||
|
||||
Look at the photos and think about:
|
||||
|
||||
* What do you see?
|
||||
* Can you see any new design opportunities?
|
||||
* What problems can you see?
|
||||
* How could you make use of the LEGO bricks, the EV3 Programmable Brick, motors, and sensors?
|
||||
|
||||
### Things You’ll Need
|
||||
|
||||
* [@boardname@ Core Set](https://education.lego.com/enus/products/legomindstormseducationev3coreset/5003400)
|
||||
|
||||
Additional materials to add to your Security Gadget:
|
||||
|
||||
* String
|
||||
* Arts and crafts materials such as:
|
||||
>* Cardboard
|
||||
>* Construction paper
|
||||
>* Pipe cleaners
|
||||
>* Plastic or paper cups
|
||||
>* Recycled materials
|
||||
>* Rubber bands
|
||||
>* Wire
|
||||
|
||||
### Prior Knowledge
|
||||
|
||||
This activity uses sensor inputs. You may want to try the [Use](/getting-started/use) or [Object Detection](/coding/object-detection) activity before this one. Or, you can start out with this activity and tinker with coding sensor inputs on your own.
|
||||
|
||||
## Contemplate
|
||||
|
||||
Follow the steps of the _Maker Design Process_ for this lesson:
|
||||
|
||||
* Define the Problem
|
||||
* Brainstorming
|
||||
* Define the Design Criteria
|
||||
* Go Make
|
||||
* Review and Revise Your Solution
|
||||
* Communicate Your Solution
|
||||
|
||||
### Defining the Problem
|
||||
|
||||
1. What problems did you imagine?
|
||||
2. Pick one problem and explain it to a partner.
|
||||
|
||||
### Brainstorm
|
||||
|
||||
Now that you have defined a problem, start to generate ideas for solving it.
|
||||
|
||||
### ~hint
|
||||
|
||||
Some things to do while brainstorming:
|
||||
|
||||
* Use the bricks from the LEGO set to help you brainstorm or sketch your ideas on paper.
|
||||
* The goal of brainstorming is to explore as many solutions as possible. You can use the tinkering examples in the Sample Solutions section below as inspiration for getting started.
|
||||
* Share your ideas and get some feedback. It may lead to more ideas!
|
||||
|
||||
### ~
|
||||
|
||||
### Define the Design Criteria
|
||||
|
||||
1. You should have generated a number of ideas. Now select the best one to make.
|
||||
2. Write out two or three specific design criteria your design must meet.
|
||||
|
||||
### Go Make
|
||||
|
||||
It is time to start making!
|
||||
|
||||
* Use the components from the @boardname@ Core Set and additional materials to make your chosen solution.
|
||||
* Test and analyze your design as you go and record any improvements that you make.
|
||||
|
||||
### Review and Revise Your Solution
|
||||
|
||||
* Have you managed to solve the problem that you defined?
|
||||
* Look back at your design criteria. How well does your solution work?
|
||||
* How can you improve your design?
|
||||
|
||||
### Communicate Your Solution
|
||||
|
||||
Now that you have finished you can:
|
||||
|
||||
* Make a sketch or take a photo or video of your model.
|
||||
* Label the three most important parts and explain how they work.
|
||||
* Share your work with others.
|
||||
|
||||
## Continue
|
||||
|
||||
### Phone Protector - Sample Solution
|
||||
|
||||
This example program combined with the small model will sound an alarm if someone picks it up. The program activates an alarm when an object is lifted from the Touch Sensor.
|
||||
|
||||

|
||||
|
||||
#### Programming
|
||||
|
||||
1. Drag a ``||sensors:pause until touch||`` block and place it inside the ``||loops:forever||`` loop.
|
||||
2. Drag a ``||music:play sound effect||`` block and place it below the ``||sensors:pause until||`` block.
|
||||
3. Change the sound effect to ``mechanical horn1``.
|
||||
|
||||
```blocks
|
||||
sensors.touch1.onEvent(ButtonEvent.Released, function () {
|
||||
music.playSoundEffectUntilDone(sounds.informationActivate);
|
||||
forever(function () {
|
||||
sensors.touch1.pauseUntil(ButtonEvent.Pressed)
|
||||
music.playSoundEffect(sounds.mechanicalHorn1)
|
||||
})
|
||||
```
|
||||
```
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the ``center`` button on the EV3 Brick to run the program.
|
||||
|
||||
### Object Detection - Sample Solution
|
||||
|
||||
This example program combined with the small model will sound an alarm if someone (or something) crosses its path! The program activates an alarm when an object moves in front of the Ultrasonic Sensor.
|
||||
|
||||

|
||||
|
||||
#### Programming
|
||||
|
||||
1. Drag a ``||sensors:pause until ultrasonic||`` block and place it inside the ``||loops:forever||`` loop.
|
||||
2. Drag a ``||music:play sound effect||`` block and place it below the ``||sensors:pause until||`` block.
|
||||
3. Change the sound effect to ``mechanical horn1``.
|
||||
|
||||
```blocks
|
||||
forever(function () {
|
||||
sensors.ultrasonic4.pauseUntil(UltrasonicSensorEvent.ObjectDetected)
|
||||
music.playSoundEffect(sounds.mechanicalHorn1)
|
||||
})
|
||||
```
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the ``center`` button on the EV3 Brick to run the program.
|
||||
|
@ -1,12 +1,163 @@
|
||||
# Sound Machine
|
||||
# Make a Sound Machine
|
||||
|
||||
Make a Sound Machine that can play a rhythm, music or just noise!
|
||||
|
||||

|
||||
|
||||
## Connect
|
||||
|
||||
Music is made up of a combination of sounds, notes and rhythm. A rhythm is a regular movement or repeated pattern of movements that can be used in many different ways. In mechanical machines, a rhythm can help keep a machine running smoothly. It can also be used to generate different sounds in music.
|
||||
|
||||

|
||||
|
||||
Look at the photos and think about:
|
||||
|
||||
* What do you see?
|
||||
* Can you see any new design opportunities?
|
||||
* What problems can you see?
|
||||
* How could you make use of the LEGO bricks, the EV3 Programmable Brick, motors, and sensors?
|
||||
|
||||
### Things You’ll Need
|
||||
|
||||
* [@boardname@ Core Set](https://education.lego.com/enus/products/legomindstormseducationev3coreset/5003400)
|
||||
|
||||
Additional materials to add to your Sound Machine:
|
||||
|
||||
* Small musical instruments, such as chimes, bells, and small drums
|
||||
* Arts and crafts materials such as:
|
||||
>* Cardboard
|
||||
>* Construction paper
|
||||
>* Pipe cleaners
|
||||
>* Plastic or paper cups
|
||||
>* Recycled materials
|
||||
>* Rubber bands
|
||||
>* Wire
|
||||
|
||||
### Prior Knowledge
|
||||
|
||||
This activity uses motor rotations and sensor inputs. You may want to try the [Use](/getting-started/use) or [Object Detection](/coding/object-detection) activity before this one. Or, you can start out with this activity and tinker with coding motor and sensor inputs on your own.
|
||||
|
||||
## Contemplate
|
||||
|
||||
Follow the steps of the _Maker Design Process_ for this lesson:
|
||||
|
||||
* Define the Problem
|
||||
* Brainstorming
|
||||
* Define the Design Criteria
|
||||
* Go Make
|
||||
* Review and Revise Your Solution
|
||||
* Communicate Your Solution
|
||||
|
||||
### Defining the Problem
|
||||
|
||||
1. What problems did you imagine?
|
||||
2. Pick one problem and explain it to a partner.
|
||||
|
||||
### Brainstorm
|
||||
|
||||
Now that you have defined a problem, start to generate ideas for solving it.
|
||||
|
||||
### ~hint
|
||||
|
||||
Some things to do while brainstorming:
|
||||
|
||||
* Use the bricks from the LEGO set to help you brainstorm or sketch your ideas on paper.
|
||||
* The goal of brainstorming is to explore as many solutions as possible. You can use the tinkering examples in the Sample Solutions section below as inspiration for getting started.
|
||||
* Share your ideas and get some feedback. It may lead to more ideas!
|
||||
|
||||
### ~
|
||||
|
||||
### Define the Design Criteria
|
||||
|
||||
* You should have generated a number of ideas. Now select the best one to make.
|
||||
* Write out two or three specific design criteria your design must meet.
|
||||
|
||||
### Go Make
|
||||
|
||||
It is time to start making!
|
||||
|
||||
* Use the components from the @boardname@ Core Set and additional materials to make your chosen solution.
|
||||
* Test and analyze your design as you go and record any improvements that you make.
|
||||
|
||||
### Review and Revise Your Solution
|
||||
|
||||
* Have you managed to solve the problem that you defined?
|
||||
* Look back at your design criteria. How well does your solution work?
|
||||
* How can you improve your design?
|
||||
|
||||
### Communicate Your Solution
|
||||
|
||||
Now that you have finished you can:
|
||||
* Make a sketch or take a photo or video of your model.
|
||||
* Label the three most important parts and explain how they work.
|
||||
* Share your work with others.
|
||||
|
||||
## Continue
|
||||
|
||||
### Rhythm Maker - Sample Solution
|
||||
|
||||
This example program combined with the small model will make a beat and rhythm on any surface when the program is run.
|
||||
|
||||

|
||||
|
||||
#### Programming
|
||||
|
||||
1. Drag a run ``||motors:large motor A||`` block inside the ``||loops:forever||`` loop.
|
||||
2. Press the **(+)**.
|
||||
3. Change the rotations to `2`.
|
||||
4. Drag a ``||loops:pause||`` block and place it under the motor block.
|
||||
5. Change the duration to ``200`` ms.
|
||||
6. Drag a ``||run large motor A||`` block inside the ``||loops:forever||`` loop.
|
||||
7. Press the **(+)**.
|
||||
8. Change the power to `100`.
|
||||
9. Change the rotations to `1`.
|
||||
|
||||
```blocks
|
||||
forever(function () {
|
||||
motors.largeA.run(50)
|
||||
pause(200)
|
||||
motors.largeA.run(100)
|
||||
motors.largeA.run(50, 2, MoveUnit.Rotations)
|
||||
pause(200)
|
||||
motors.largeA.run(100, 1, MoveUnit.Rotations)
|
||||
})
|
||||
```
|
||||
```
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the ``center`` button on the EV3 Brick to run the program.
|
||||
|
||||
### Color Sensor Sounds - Sample Solution
|
||||
|
||||
You can also tinker with the use of sensors.
|
||||
|
||||

|
||||
|
||||
#### Programming
|
||||
|
||||
1. Drag an ``||logic:if else||`` Logic block and place it inside the ``||loops:forever||`` loop.
|
||||
2. Drag a ``||sensors:pause color sensor||`` block and place it inside the ``||logic:if true then||`` block.
|
||||
3. Change the color to ``blue``.
|
||||
4. Drag a ``||music:play tone||`` block and place under the sensor block.
|
||||
5. Change the tone to ``Middle G`` (392 Hz).
|
||||
6. Drag a ``||sensors:pause color sensor||`` block and place it inside the ``||logic:else||`` block.
|
||||
7. Change the color to ``red``.
|
||||
8. Drag a ``||music:play tone||`` block and place under the new sensor block.
|
||||
9. Change the tone to ``High C`` (523 Hz).
|
||||
10. Press the **(+)**.
|
||||
11. Drag a ``||sensors:pause color sensor||`` block and place it inside the ``||logic:else if||`` block.
|
||||
12. Change the color to ``green``.
|
||||
13. Drag a ``||music:play tone||`` block and place under the new sensor block.
|
||||
14. Change the tone to ``High D`` (587 Hz).
|
||||
|
||||
```blocks
|
||||
forever(function () {
|
||||
if (true) {
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Blue)
|
||||
music.playTone(392, music.beat(BeatFraction.Whole))
|
||||
} else if (false) {
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Red)
|
||||
music.playTone(523, music.beat(BeatFraction.Half))
|
||||
} else {
|
||||
sensors.color3.pauseUntilColorDetected(ColorSensorColor.Green)
|
||||
music.playTone(587, music.beat(BeatFraction.Half))
|
||||
}
|
||||
})
|
||||
```
|
||||
|
||||
Click **Download** and follow the instructions to get your code onto your EV3 Brick. Press the ``center`` button on the EV3 Brick to run the program.
|
||||
|
791
docs/offline-app.html
Normal file
@ -0,0 +1,791 @@
|
||||
<!DOCTYPE html>
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:og="http://ogp.me/ns#" xmlns:fb="http://www.facebook.com/2008/fbml">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>LEGO® MINDSTORMS® Education EV3 Offline App</title>
|
||||
<meta name="Description" content="A MakeCode for LEGO® MINDSTORMS® Education EV3 offline app" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<!-- @include indexhead.html -->
|
||||
|
||||
<style>
|
||||
p.item {
|
||||
color: rgba(0, 0, 0, 0.4);
|
||||
}
|
||||
|
||||
.topbar {
|
||||
background: rgb(170, 39, 143) !important;
|
||||
}
|
||||
|
||||
.ui.inverted.content {
|
||||
/* background: #00a5c8; */
|
||||
background: #2a7af3;
|
||||
}
|
||||
|
||||
.content.segment {
|
||||
min-height: 80%;
|
||||
}
|
||||
|
||||
.content .welcomeheader {
|
||||
font-weight: 300;
|
||||
}
|
||||
|
||||
.footer.segment {
|
||||
padding: 5em 0em;
|
||||
}
|
||||
|
||||
.image.left {
|
||||
padding-left: 2em;
|
||||
}
|
||||
|
||||
.image.right {
|
||||
padding-right: 2em;
|
||||
float: right;
|
||||
}
|
||||
|
||||
.segments {
|
||||
max-width: 60%;
|
||||
}
|
||||
|
||||
.segments.terms-container {
|
||||
margin-top: 5em;
|
||||
}
|
||||
|
||||
.terms-container .segment {
|
||||
background-color: rgb(250, 250, 250);
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 800px) {
|
||||
.grid .column .image {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.segments {
|
||||
max-width: 95%;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
<!-- Auto-generated styles for the license terms -->
|
||||
<style type="text/css">
|
||||
.terms ol {
|
||||
margin: 0;
|
||||
padding: 0
|
||||
}
|
||||
|
||||
.terms table td,
|
||||
.terms table th {
|
||||
padding: 0
|
||||
}
|
||||
|
||||
.c2 {
|
||||
margin-left: 22.5pt;
|
||||
padding-top: 6pt;
|
||||
text-indent: -18pt;
|
||||
padding-bottom: 6pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.c8 {
|
||||
margin-left: 40.5pt;
|
||||
padding-top: 6pt;
|
||||
text-indent: -18pt;
|
||||
padding-bottom: 6pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.c15 {
|
||||
padding-top: 0pt;
|
||||
padding-bottom: 12pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left;
|
||||
height: 11pt
|
||||
}
|
||||
|
||||
.c7 {
|
||||
padding-top: 0pt;
|
||||
padding-bottom: 0pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left;
|
||||
height: 11pt
|
||||
}
|
||||
|
||||
.c0 {
|
||||
margin-left: 23pt;
|
||||
padding-top: 6pt;
|
||||
padding-bottom: 6pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.c10 {
|
||||
margin-left: 40.5pt;
|
||||
padding-top: 6pt;
|
||||
padding-bottom: 6pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.c6 {
|
||||
margin-left: 40.5pt;
|
||||
padding-top: 0pt;
|
||||
padding-bottom: 0pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.c20 {
|
||||
padding-top: 0pt;
|
||||
padding-bottom: 0pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: center
|
||||
}
|
||||
|
||||
.c4 {
|
||||
color: #000000;
|
||||
font-weight: 700;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
font-family: "Arial";
|
||||
font-style: normal
|
||||
}
|
||||
|
||||
.c11 {
|
||||
padding-top: 0pt;
|
||||
padding-bottom: 0pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.c12 {
|
||||
padding-top: 6pt;
|
||||
padding-bottom: 6pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.c3 {
|
||||
color: #000000;
|
||||
font-weight: 400;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
font-family: "Arial";
|
||||
font-style: normal
|
||||
}
|
||||
|
||||
.c16 {
|
||||
padding-top: 0pt;
|
||||
padding-bottom: 12pt;
|
||||
line-height: 1.15;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.c13 {
|
||||
color: #000000;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
font-family: "Arial";
|
||||
font-style: italic
|
||||
}
|
||||
|
||||
.c14 {
|
||||
text-decoration-skip-ink: none;
|
||||
-webkit-text-decoration-skip: none;
|
||||
color: #1155cc;
|
||||
text-decoration: underline
|
||||
}
|
||||
|
||||
.c17 {
|
||||
background-color: #ffffff;
|
||||
max-width: 540pt;
|
||||
padding: 36pt 36pt 36pt 36pt
|
||||
}
|
||||
|
||||
.c18 {
|
||||
text-decoration-skip-ink: none;
|
||||
-webkit-text-decoration-skip: none;
|
||||
text-decoration: underline
|
||||
}
|
||||
|
||||
.c9 {
|
||||
color: inherit;
|
||||
text-decoration: inherit
|
||||
}
|
||||
|
||||
.c5 {
|
||||
font-weight: 700
|
||||
}
|
||||
|
||||
.c1 {
|
||||
font-size: 10pt
|
||||
}
|
||||
|
||||
.c19 {
|
||||
font-size: 11pt
|
||||
}
|
||||
|
||||
.terms .title {
|
||||
padding-top: 0pt;
|
||||
color: #000000;
|
||||
font-size: 26pt;
|
||||
padding-bottom: 3pt;
|
||||
font-family: "Arial";
|
||||
line-height: 1.15;
|
||||
page-break-after: avoid;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.terms .subtitle {
|
||||
padding-top: 0pt;
|
||||
color: #666666;
|
||||
font-size: 15pt;
|
||||
padding-bottom: 16pt;
|
||||
font-family: "Arial";
|
||||
line-height: 1.15;
|
||||
page-break-after: avoid;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.terms li {
|
||||
color: #000000;
|
||||
font-size: 11pt;
|
||||
font-family: "Arial"
|
||||
}
|
||||
|
||||
.terms p {
|
||||
margin: 0;
|
||||
color: #000000;
|
||||
font-size: 11pt;
|
||||
font-family: "Arial"
|
||||
}
|
||||
|
||||
.terms h1 {
|
||||
padding-top: 20pt;
|
||||
color: #000000;
|
||||
font-size: 20pt;
|
||||
padding-bottom: 6pt;
|
||||
font-family: "Arial";
|
||||
line-height: 1.15;
|
||||
page-break-after: avoid;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.terms h2 {
|
||||
padding-top: 18pt;
|
||||
color: #000000;
|
||||
font-size: 16pt;
|
||||
padding-bottom: 6pt;
|
||||
font-family: "Arial";
|
||||
line-height: 1.15;
|
||||
page-break-after: avoid;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.terms h3 {
|
||||
padding-top: 16pt;
|
||||
color: #434343;
|
||||
font-size: 14pt;
|
||||
padding-bottom: 4pt;
|
||||
font-family: "Arial";
|
||||
line-height: 1.15;
|
||||
page-break-after: avoid;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.terms h4 {
|
||||
padding-top: 14pt;
|
||||
color: #666666;
|
||||
font-size: 12pt;
|
||||
padding-bottom: 4pt;
|
||||
font-family: "Arial";
|
||||
line-height: 1.15;
|
||||
page-break-after: avoid;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.terms h5 {
|
||||
padding-top: 12pt;
|
||||
color: #666666;
|
||||
font-size: 11pt;
|
||||
padding-bottom: 4pt;
|
||||
font-family: "Arial";
|
||||
line-height: 1.15;
|
||||
page-break-after: avoid;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.terms h6 {
|
||||
padding-top: 12pt;
|
||||
color: #666666;
|
||||
font-size: 11pt;
|
||||
padding-bottom: 4pt;
|
||||
font-family: "Arial";
|
||||
line-height: 1.15;
|
||||
page-break-after: avoid;
|
||||
font-style: italic;
|
||||
orphans: 2;
|
||||
widows: 2;
|
||||
text-align: left
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
$(document).ready(function () {
|
||||
tickEvent = function (id, data) {
|
||||
if (!pxt.aiTrackEvent) return;
|
||||
if (!data) pxt.aiTrackEvent(id);
|
||||
else {
|
||||
var props = {};
|
||||
var measures = {};
|
||||
for (var k in data)
|
||||
if (typeof data[k] == "string") props[k] = data[k];
|
||||
else measures[k] = data[k];
|
||||
pxt.aiTrackEvent(id, props, measures);
|
||||
}
|
||||
}
|
||||
});
|
||||
function agreeCheckboxChanged() {
|
||||
var downloadSegment = document.getElementById("download-segment");
|
||||
downloadSegment.classList.toggle("hidden");
|
||||
}
|
||||
function downloadWin64() {
|
||||
// TODO: Keep this link up-to-date with the desired release version
|
||||
window.open("https://makecode.com/api/release/ev3/v1.2.22/win64");
|
||||
tickEvent("offlineapp.download", { "target": "ev3", "platform": "win64" });
|
||||
}
|
||||
function downloadMac64() {
|
||||
// TODO: Keep this link up-to-date with the desired release version
|
||||
window.open("https://makecode.com/api/release/ev3/v1.2.22/mac64");
|
||||
tickEvent("offlineapp.download", { "target": "ev3", "platform": "mac64" });
|
||||
}
|
||||
</script>
|
||||
|
||||
</head>
|
||||
|
||||
<body id="root" class="root">
|
||||
|
||||
<div class="ui inverted vertical center aligned segment content">
|
||||
|
||||
<div class="ui grid topbar">
|
||||
<div class="three wide column">
|
||||
<img class="ui small image left" src="/static//lego_education_logo_white.png" />
|
||||
</div>
|
||||
<div class="ten wide column">
|
||||
<h1 class="ui inverted welcomeheader">MakeCode Offline App</h1>
|
||||
</div>
|
||||
<div class="three wide column">
|
||||
<img class="ui small image right" src="/static//Microsoft-logo_rgb_c-white.png" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="ui compact segments terms-container">
|
||||
<div class="ui secondary center aligned segment">
|
||||
Please read and accept the following terms to download the app.
|
||||
</div>
|
||||
<div class="ui left aligned segment terms">
|
||||
<div class="c17">
|
||||
<p class="c11">
|
||||
<span class="c4 c1">MICROSOFT PRE-RELEASE SOFTWARE LICENSE TERMS</span>
|
||||
</p>
|
||||
<p class="c11">
|
||||
<span class="c4 c1">MICROSOFT MAKECODE FOR LEGO MINDSTORMS EDUCATION EV3</span>
|
||||
</p>
|
||||
<p class="c7">
|
||||
<span class="c4 c1"></span>
|
||||
</p>
|
||||
<p class="c11">
|
||||
<span class="c3 c1">These license terms are an agreement between Microsoft Corporation (or based on where you live, one
|
||||
of its affiliates) and you. They apply to the software named above. The terms also apply to any
|
||||
Microsoft services or updates for the software, except to the extent those have additional terms.</span>
|
||||
</p>
|
||||
<p class="c7">
|
||||
<span class="c3 c1"></span>
|
||||
</p>
|
||||
<p class="c11">
|
||||
<span class="c4 c1">IF YOU COMPLY WITH THESE LICENSE TERMS, YOU HAVE THE RIGHTS BELOW.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">1.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">INSTALLATION AND USE RIGHTS. </span>
|
||||
<span class="c3 c1">You may install and use any number of copies of the software to evaluate it as you develop and test
|
||||
your software applications for use with Lego Mindstorms Education EV3 hardware.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">2.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">PRE-RELEASE SOFTWARE. </span>
|
||||
<span class="c3 c1">The software is a pre-release version. It may not work the way a final version of the software will.
|
||||
Microsoft may change it for the final, commercial version. We also may not release a commercial
|
||||
version. Microsoft is not obligated to provide maintenance, technical support or updates to you
|
||||
for the software.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">3.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">ASSOCIATED ONLINE SERVICES.</span>
|
||||
<span class="c1"> Some features of the software provide access
|
||||
to, or rely on, online services to provide you information about updates to the software or extensions,
|
||||
or to enable you to retrieve content, collaborate with others, or otherwise supplement your development
|
||||
experience. As used throughout these license terms, the term <q>software</q> includes these online
|
||||
services and features. By using these online services and features you consent to the to the
|
||||
transmission of information as described in Section 5, DATA.
|
||||
</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">4.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">LICENSES FOR OTHER COMPONENTS.</span>
|
||||
<span class="c3 c1"> The software may include third party components with separate legal notices or governed by
|
||||
other agreements, as described in the ThirdPartyNotices file accompanying the software. Even
|
||||
if such components are governed by other agreements, the disclaimers and the limitations on and
|
||||
exclusions of damages below also apply.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">5.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c1 c4">DATA.</span>
|
||||
</p>
|
||||
<p class="c8">
|
||||
<span class="c5 c1">a.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c1 c5">Data Collection. </span>
|
||||
<span class="c1">The software may collect information about you and your use of the software, and send that to Microsoft.
|
||||
Microsoft may use this information to provide services and improve our products and services.
|
||||
You may opt out of many of these scenarios, but not all, as described in the product documentation.
|
||||
In using the software, you must comply with applicable law. You can learn more about data collection
|
||||
and use in the help documentation and the privacy statement at </span>
|
||||
<span class="c14 c1">
|
||||
<a class="c9" href="http://go.microsoft.com/fwlink/?LinkId=398505">http://go.microsoft.com/fwlink/?LinkId=398505</a>
|
||||
</span>
|
||||
<span class="c1">.</span>
|
||||
<span class="c3 c1"> Your use of the software operates as your consent to these practices.</span>
|
||||
</p>
|
||||
<p class="c8">
|
||||
<span class="c5 c1">b.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">Processing of Personal Data. </span>
|
||||
<span class="c1">To the extent Microsoft is a processor or subprocessor of personal data in connection with the software,
|
||||
Microsoft makes the commitments in the European Union General Data Protection Regulation Terms
|
||||
of the Online Services Terms to all customers effective May 25, 2018, at </span>
|
||||
<span class="c1 c14">
|
||||
<a class="c9" href="http://go.microsoft.com/?linkid=9840733">http://go.microsoft.com/?linkid=9840733</a>
|
||||
</span>
|
||||
<span class="c3 c1">.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">6.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">FEEDBACK. </span>
|
||||
<span class="c3 c1">If you give feedback about the software to Microsoft, you give to Microsoft, without charge, the
|
||||
right to use, share and commercialize your feedback in any way and for any purpose. You will
|
||||
not give feedback that is subject to a license that requires Microsoft to license its software
|
||||
or documentation to third parties because we include your feedback in them. These rights survive
|
||||
this agreement.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">7.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">SCOPE OF LICENSE.</span>
|
||||
<span class="c3 c1"> The software is licensed, not sold. This agreement only gives you some rights to use the software.
|
||||
Microsoft reserves all other rights. Unless applicable law gives you more rights despite this
|
||||
limitation, you may use the software only as expressly permitted in this agreement. In
|
||||
doing so, you must comply with any technical limitations in the software that only allow you
|
||||
to use it in certain ways. You may not:</span>
|
||||
</p>
|
||||
<p class="c8">
|
||||
<span class="c3 c1">- work around any technical limitations in the software;</span>
|
||||
</p>
|
||||
<p class="c8">
|
||||
<span class="c3 c1">- reverse engineer, decompile or disassemble the software, or attempt to do so, except
|
||||
and only to the extent required by third party licensing terms governing use of certain open
|
||||
source components that may be included with the software;</span>
|
||||
</p>
|
||||
<p class="c8">
|
||||
<span class="c3 c1">- remove, minimize, block or modify any notices of Microsoft or its suppliers in the
|
||||
software;
|
||||
</span>
|
||||
</p>
|
||||
<p class="c8">
|
||||
<span class="c3 c1">- use the software in any way that is against the law; or</span>
|
||||
</p>
|
||||
<p class="c8">
|
||||
<span class="c3 c1">- share, publish, rent or lease the software, or provide the software as a stand-alone
|
||||
offering for others to use.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">8. UPDATES. </span>
|
||||
<span class="c3 c1">The software may periodically check for updates and download and install them for you. You may obtain
|
||||
updates only from Microsoft or authorized sources. Microsoft may need to update your system to
|
||||
provide you with updates. You agree to receive these automatic updates without any additional
|
||||
notice. Updates may not include or support all existing software features, services, or peripheral
|
||||
devices.
|
||||
</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">9.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">EXPORT RESTRICTIONS.</span>
|
||||
<span class="c3 c1"> You must comply with all domestic and international export laws and regulations that apply
|
||||
to the software, which include restrictions on destinations, end users and end use. For further
|
||||
information on export restrictions, visit (aka.ms/exporting).</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">10.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">SUPPORT SERVICES. </span>
|
||||
<span class="c3 c1">Because the software is “as is,” we may not provide support services for it.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">11.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">ENTIRE AGREEMENT.</span>
|
||||
<span class="c3 c1"> This agreement, and the terms for supplements, updates, Internet-based services and support
|
||||
services that you use, are the entire agreement for the software and support services.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">12.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">APPLICABLE LAW. </span>
|
||||
<span class="c3 c1">If you acquired the software in the United States, Washington State law applies to interpretation
|
||||
of and claims for breach of this agreement, and the laws of the state where you live apply to
|
||||
all other claims. If you acquired the software in any other country, its laws apply.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">13.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">CONSUMER RIGHTS; REGIONAL VARIATIONS. </span>
|
||||
<span class="c3 c1">This agreement describes certain legal rights. You may have other rights, including consumer rights,
|
||||
under the laws of your state or country. Separate and apart from your relationship with Microsoft,
|
||||
you may also have rights with respect to the party from which you acquired the software. This
|
||||
agreement does not change those other rights if the laws of your state or country do not permit
|
||||
it to do so. For example, if you acquired the software in one of the below regions, or mandatory
|
||||
country law applies, then the following provisions apply to you:</span>
|
||||
</p>
|
||||
<p class="c8">
|
||||
<span class="c5 c1">a.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">Australia. </span>
|
||||
<span class="c3 c1">You have statutory guarantees under the Australian Consumer Law and nothing in this agreement is
|
||||
intended to affect those rights.</span>
|
||||
</p>
|
||||
<p class="c8">
|
||||
<span class="c5 c1">b.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">Canada. </span>
|
||||
<span class="c3 c1">If you acquired the software in Canada, you may stop receiving updates by turning off the automatic
|
||||
update feature, disconnecting your device from the Internet (if and when you re-connect to the
|
||||
Internet, however, the software will resume checking for and installing updates), or uninstalling
|
||||
the software. The product documentation, if any, may also specify how to turn off updates for
|
||||
your specific device or software.</span>
|
||||
</p>
|
||||
<p class="c8">
|
||||
<span class="c5 c1">c.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">Germany and Austria</span>
|
||||
<span class="c3 c1">.</span>
|
||||
</p>
|
||||
<p class="c6">
|
||||
<span class="c5 c1">(i)</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">Warranty</span>
|
||||
<span class="c3 c1">. The properly licensed software will perform substantially as described in any Microsoft materials
|
||||
that accompany the software. However, Microsoft gives no contractual guarantee in relation to
|
||||
the licensed software.</span>
|
||||
</p>
|
||||
<p class="c6">
|
||||
<span class="c4 c1"> </span>
|
||||
</p>
|
||||
<p class="c6">
|
||||
<span class="c5 c1">(ii)</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">Limitation of Liability</span>
|
||||
<span class="c3 c1">. In case of intentional conduct, gross negligence, claims based on the Product Liability Act, as
|
||||
well as, in case of death or personal or physical injury, Microsoft is liable according to the
|
||||
statutory law.</span>
|
||||
</p>
|
||||
<p class="c10">
|
||||
<span class="c3 c1">Subject to the foregoing clause (ii), Microsoft will only be liable for slight negligence if Microsoft
|
||||
is in breach of such material contractual obligations, the fulfillment of which facilitate the
|
||||
due performance of this agreement, the breach of which would endanger the purpose of this agreement
|
||||
and the compliance with which a party may constantly trust in (so-called "cardinal obligations").
|
||||
In other cases of slight negligence, Microsoft will not be liable for slight negligence.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">14.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c5 c1">LEGAL EFFECT.</span>
|
||||
<span class="c3 c1"> This agreement describes certain legal rights. You may have other rights under the laws of
|
||||
your country. You may also have rights with respect to the party from whom you acquired the software.
|
||||
This agreement does not change your rights under the laws of your country if the laws of your
|
||||
country do not permit it to do so.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">15.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c4 c1">DISCLAIMER OF WARRANTY. THE SOFTWARE IS LICENSED “AS-IS.” YOU BEAR THE RISK OF
|
||||
USING IT. MICROSOFT GIVES NO EXPRESS WARRANTIES, GUARANTEES OR CONDITIONS. TO THE EXTENT PERMITTED
|
||||
UNDER YOUR LOCAL LAWS, MICROSOFT EXCLUDES THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c5 c1">16.</span>
|
||||
<span class="c1"> </span>
|
||||
<span class="c4 c1">LIMITATION ON AND EXCLUSION OF DAMAGES. YOU CAN RECOVER FROM MICROSOFT AND ITS SUPPLIERS ONLY DIRECT
|
||||
DAMAGES UP TO U.S. $5.00. YOU CANNOT RECOVER ANY OTHER DAMAGES, INCLUDING CONSEQUENTIAL, LOST
|
||||
PROFITS, SPECIAL, INDIRECT OR INCIDENTAL DAMAGES.</span>
|
||||
</p>
|
||||
<p class="c0">
|
||||
<span class="c3 c1">This limitation applies to (a) anything related to the software, services, content (including code)
|
||||
on third party Internet sites, or third party programs; and (b) claims for breach of contract,
|
||||
breach of warranty, guarantee or condition, strict liability, negligence, or other tort to the
|
||||
extent permitted by applicable law.</span>
|
||||
</p>
|
||||
<p class="c0">
|
||||
<span class="c3 c1">It also applies even if Microsoft knew or should have known about the possibility of the damages.
|
||||
The above limitation or exclusion may not apply to you because your country may not allow the
|
||||
exclusion or limitation of incidental, consequential or other damages.</span>
|
||||
</p>
|
||||
<p class="c12">
|
||||
<span class="c4 c1">Please note: As the software is distributed in Quebec, Canada, some of the clauses in this agreement
|
||||
are provided below in French.</span>
|
||||
</p>
|
||||
<p class="c12">
|
||||
<span class="c4 c1">Remarque : Ce logiciel étant distribué au Québec, Canada, certaines des clauses
|
||||
dans ce contrat sont fournies ci-dessous en français.</span>
|
||||
</p>
|
||||
<p class="c11">
|
||||
<span class="c5 c1">EXONÉRATION DE GARANTIE.</span>
|
||||
<span class="c1 c3"> Le logiciel visé par une licence est offert « tel quel ». Toute utilisation
|
||||
de ce logiciel est à votre seule risque et péril. Microsoft n’accorde aucune
|
||||
autre garantie expresse. Vous pouvez bénéficier de droits additionnels en vertu
|
||||
du droit local sur la protection des consommateurs, que ce contrat ne peut modifier. La ou elles
|
||||
sont permises par le droit locale, les garanties implicites de qualité marchande, d’adéquation
|
||||
à un usage particulier et d’absence de contrefaçon sont exclues.
|
||||
</span>
|
||||
</p>
|
||||
<p class="c11">
|
||||
<span class="c5 c1">LIMITATION DES DOMMAGES-INTÉRÊTS ET EXCLUSION DE RESPONSABILITÉ POUR LES DOMMAGES.</span>
|
||||
<span class="c3 c1"> Vous pouvez obtenir de Microsoft et de ses fournisseurs une indemnisation en cas de dommages
|
||||
directs uniquement à hauteur de 5,00 $ US. Vous ne pouvez prétendre à aucune
|
||||
indemnisation pour les autres dommages, y compris les dommages spéciaux, indirects ou
|
||||
accessoires et pertes de bénéfices.</span>
|
||||
</p>
|
||||
<p class="c12">
|
||||
<span class="c3 c1">Cette limitation concerne :</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c3 c1">- tout ce qui est relié au logiciel, aux services ou au contenu
|
||||
(y compris le code) figurant sur des sites Internet tiers ou dans des programmes tiers ; et</span>
|
||||
</p>
|
||||
<p class="c2">
|
||||
<span class="c3 c1">- les réclamations au titre de violation de contrat ou de garantie,
|
||||
ou au titre de responsabilité stricte, de négligence ou d’une autre faute
|
||||
dans la limite autorisée par la loi en vigueur.</span>
|
||||
</p>
|
||||
<p class="c12">
|
||||
<span class="c3 c1">Elle s’applique également, même si Microsoft connaissait ou devrait connaître
|
||||
l’éventualité d’un tel dommage. Si votre pays n’autorise pas
|
||||
l’exclusion ou la limitation de responsabilité pour les dommages indirects, accessoires
|
||||
ou de quelque nature que ce soit, il se peut que la limitation ou l’exclusion ci-dessus
|
||||
ne s’appliquera pas à votre égard.</span>
|
||||
</p>
|
||||
<p class="c16">
|
||||
<span class="c5 c1">EFFET JURIDIQUE.</span>
|
||||
<span class="c3 c1"> Le présent contrat décrit certains droits juridiques. Vous pourriez avoir d’autres
|
||||
droits prévus par les lois de votre pays. Le présent contrat ne modifie pas les
|
||||
droits que vous confèrent les lois de votre pays si celles-ci ne le permettent pas.</span>
|
||||
</p>
|
||||
<p class="c15">
|
||||
<span class="c3 c1"></span>
|
||||
</p>
|
||||
<p class="c16">
|
||||
<span class="c3 c1"> </span>
|
||||
</p>
|
||||
<p class="c11">
|
||||
<span class="c3 c1">LEGO, the LEGO logo, MINDSTORMS and the MINDSTORMS EV3 logo are trademarks and/ or copyrights of
|
||||
the LEGO Group. ©2018 The LEGO Group. All rights reserved.</span>
|
||||
</p>
|
||||
<p class="c11">
|
||||
<span class="c3 c1"> </span>
|
||||
</p>
|
||||
<p class="c20">
|
||||
<span class="c5 c1 c13">Remainder of this page intentionally left blank.</span>
|
||||
</p>
|
||||
<p class="c7">
|
||||
<span class="c3 c19"></span>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ui center aligned segment">
|
||||
<input id="agree-checkbox" type="checkbox" autocomplete="off" onchange="agreeCheckboxChanged(this)">
|
||||
<label for="agree-checkbox">I agree to these Microsoft Software License Terms and to the
|
||||
<a href="https://privacy.microsoft.com/en-us/privacystatement">Microsoft Privacy Statement.</a>
|
||||
</label>
|
||||
</div>
|
||||
<div id="download-segment" class="ui center aligned segment hidden">
|
||||
<div class="ui grid">
|
||||
<div class="eight wide column">
|
||||
<h3 class="ui">Windows</h3>
|
||||
<button class="ui icon button" onclick="downloadWin64()">
|
||||
<i class="download icon"></i>
|
||||
makecode-ev3-setup-win64.exe
|
||||
</button>
|
||||
</div>
|
||||
<div class="eight wide column">
|
||||
<h3 class="ui">Mac OS</h3>
|
||||
<button class="ui icon button" onclick="downloadMac64()">
|
||||
<i class="download icon"></i>
|
||||
makecode-ev3-mac64.zip
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- @include footer.html -->
|
||||
<!-- @include tracking.html -->
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
5
docs/offline.md
Normal file
@ -0,0 +1,5 @@
|
||||
# @extends
|
||||
|
||||
## Offline app #target-app
|
||||
|
||||
The MakeCode editor is available as app which you can install on a computer with Windows or Mac OS. Once installed, the **[MakeCode Offline App](/offline-app)** lets you create, run, and download your projects to the @boardname@. It works the same as the Web application does in your browser but it's a stand-alone application that will work when a connection to the internet is restricted or not available.
|
3
docs/packages-ref.json
Normal file
@ -0,0 +1,3 @@
|
||||
{
|
||||
"redirect": "/extensions"
|
||||
}
|
3
docs/packages/approval-ref.json
Normal file
@ -0,0 +1,3 @@
|
||||
{
|
||||
"redirect": "https://makecode.com/extensions/approval"
|
||||
}
|
3
docs/packages/build-your-own-ref.json
Normal file
@ -0,0 +1,3 @@
|
||||
{
|
||||
"redirect": "https://makecode.com/extensions/getting-started"
|
||||
}
|
3
docs/packages/versioning-ref.json
Normal file
@ -0,0 +1,3 @@
|
||||
{
|
||||
"redirect": "https://makecode.com/extensions/versioning"
|
||||
}
|
@ -1,9 +1,88 @@
|
||||
# Projects
|
||||
|
||||
Here are some cool projects that you can build with your @boardname@!
|
||||
```codecard
|
||||
[
|
||||
{
|
||||
"name": "Getting Started",
|
||||
"url": "/getting-started",
|
||||
"imageUrl": "/static/lessons/firmware.png"
|
||||
},
|
||||
{
|
||||
"name": "Brick Tutorials",
|
||||
"url": "/tutorials/brick",
|
||||
"imageUrl": "/static/tutorials/wake-up.png"
|
||||
},
|
||||
{
|
||||
"name": "Motor Tutorials",
|
||||
"url": "/tutorials/motors",
|
||||
"imageUrl": "/static/tutorials/run-motors.png"
|
||||
},
|
||||
{
|
||||
"name": "Touch Sensor Tutorials",
|
||||
"url": "/tutorials/touch-sensor",
|
||||
"imageUrl": "/static/tutorials/touch-to-run.png"
|
||||
},
|
||||
{
|
||||
"name": "Color Sensor Tutorials",
|
||||
"url": "/tutorials/color-sensor",
|
||||
"imageUrl": "/static/tutorials/what-color.png"
|
||||
},
|
||||
{
|
||||
"name": "Ultrasonic Sensor Tutorials",
|
||||
"url": "/tutorials/ultrasonic-sensor",
|
||||
"imageUrl": "/static/tutorials/object-near.png"
|
||||
},
|
||||
{
|
||||
"name": "Gyro Tutorials",
|
||||
"url": "/tutorials/gyro",
|
||||
"imageUrl": "/static/tutorials/calibrate-gyro.png"
|
||||
},
|
||||
{
|
||||
"name": "Infrared Sensor Tutorials",
|
||||
"url": "/tutorials/infrared-sensor",
|
||||
"imageUrl": "/static/tutorials/security-alert.png"
|
||||
},
|
||||
{
|
||||
"name": "FLL / City Shaper",
|
||||
"url": "/tutorials/city-shaper",
|
||||
"imageUrl": "/static/tutorials/city-shaper/robot1.jpg"
|
||||
},
|
||||
{
|
||||
"name": "Design Engineering",
|
||||
"url": "/design-engineering",
|
||||
"imageUrl": "/static/lessons/make-it-move-without-wheels.png"
|
||||
},
|
||||
{
|
||||
"name": "Coding",
|
||||
"url": "/coding",
|
||||
"imageUrl": "/static/lessons/autonomous-parking.png"
|
||||
},
|
||||
{
|
||||
"name": "Maker",
|
||||
"url": "/maker",
|
||||
"imageUrl": "/static/lessons/make-a-sound-machine.png"
|
||||
},
|
||||
{
|
||||
"name": "Tutorial Videos",
|
||||
"url": "/videos",
|
||||
"imageUrl": "https://legoeducation.videomarketingplatform.co/27288170/35719444/5d009e5f93fbf479c2e5ed2bf87a7990/thumbnail.png"
|
||||
}
|
||||
]
|
||||
```
|
||||
|
||||
## Basic
|
||||
## See Also
|
||||
|
||||
Basic projects to build with your @boardname@.
|
||||
[Getting Started](/getting-started),
|
||||
[Brick Tutorials](/tutorials/brick),
|
||||
[Motor Tutorials](/tutorials/motors),
|
||||
[Touch Sensor Tutorials](/tutorials/touch-sensor),
|
||||
[Color Sensor Tutorials](/tutorials/color-sensor),
|
||||
[Ultrasonic Sensor Tutorials](/tutorials/ultrasonic-sensor),
|
||||
[Gyro Tutorials](/tutorials/gyro),
|
||||
[Infrared Sensor Tutorials](/tutorials/infrared-sensor),
|
||||
[FLL / City Shaper](/tutorials/city-shaper),
|
||||
[Design Engineering](/design-engineering),
|
||||
[Coding](/coding),
|
||||
[Maker](/maker),
|
||||
[Tutorial Videos](/videos)
|
||||
|
||||
Coming soon.
|
69
docs/projects/SUMMARY.md
Normal file
@ -0,0 +1,69 @@
|
||||
# Projects
|
||||
|
||||
* [Getting Started](/getting-started)
|
||||
* [Prepare](https://makecode.mindstorms.com/troubleshoot)
|
||||
* [Try](/getting-started/try)
|
||||
* [Use](/getting-started/use)
|
||||
* [First LEGO League](/fll)
|
||||
* [Brick Tutorials](/tutorials/brick)
|
||||
* [Wake Up!](/tutorials/wake-up)
|
||||
* [Make an Animation](/tutorials/make-an-animation)
|
||||
* [What Animal Am I?](/tutorials/what-animal-am-i)
|
||||
* [Music Brick](/tutorials/music-brick)
|
||||
* [Pause On Start](/tutorials/pause-on-start)
|
||||
* [Motor Tutorials](/tutorials/motors)
|
||||
* [Run Motors](/tutorials/run-motors)
|
||||
* [Spin Turn](/tutorials/spin-turn)
|
||||
* [Pivot Turn](/tutorials/pivot-turn)
|
||||
* [Smooth Turn](/tutorials/smooth-turn)
|
||||
* [Tank ZigZag](/tutorials/tank-zigzag)
|
||||
* [Coast Or Brake](/tutorials/coast-or-brake)
|
||||
* [Turtle](/tutorials/turtle)
|
||||
* [Touch Sensor Tutorials](/tutorials/touch-sensor)
|
||||
* [Touch to Run](/tutorials/touch-to-run)
|
||||
* [Sensor Values](/tutorials/touch-sensor-values)
|
||||
* [Stop At Object](/tutorials/stop-at-object)
|
||||
* [Color Sensor Tutorials](/tutorials/color-sensor)
|
||||
* [What Color?](/tutorials/what-color)
|
||||
* [Line Following](/tutorials/line-following)
|
||||
* [Red Light, Green Light](/tutorials/redlight-greenlight)
|
||||
* [Move To Color](/tutorials/move-to-color)
|
||||
* [Reflected Light Measure](/tutorials/reflected-light-measure)
|
||||
* [Reflected Light Calibration](/tutorials/reflected-light-calibration)
|
||||
* [Ultrasonic Sensor Tutorials](/tutorials/ultrasonic-sensor)
|
||||
* [Object Near](/tutorials/object-near)
|
||||
* [Wall Follower](/tutorials/wall-follower)
|
||||
* [Gyro Tutorials](/tutorials/gyro)
|
||||
* [Calibrate](/tutorials/calibrate-gyro)
|
||||
* [Turn](/tutorials/turn-with-gyro)
|
||||
* [Move Straight](/tutorials/move-straight-with-gyro)
|
||||
* [Drifter](/tutorials/drifter)
|
||||
* [Infrared Sensor Tutorials](/tutorials/infrared-sensor)
|
||||
* [Security Alert](/tutorials/security-alert)
|
||||
* [FLL / City Shaper](/tutorials/city-shaper)
|
||||
* [Crane Mission / Robot 1](/tutorials/city-shaper/robot-1)
|
||||
* [Crane Mission / Robot 2](/tutorials/city-shaper/robot-2)
|
||||
* [Crane Mission / Video 1](https://youtu.be/IqL0Pyeu5Ng)
|
||||
* [Bluetooth download (beta)](https://youtu.be/VIq8-6Egtqs)
|
||||
* [Turn with Gyro](https://youtu.be/I7ncuXAfBwk)
|
||||
* [Moving with Gyro](https://youtu.be/ufiOPvW37xc)
|
||||
* [Line following with 1 color sensor](https://youtu.be/_LeduyKQVjg)
|
||||
* [Proportional line following with 1 color sensor](https://youtu.be/-AirqwC9DL4)
|
||||
* [Proportional line following with 2 color sensors](https://youtu.be/QWOflBuu9Oo)
|
||||
* [Design Engineering](/design-engineering)
|
||||
* [Make It Move Without Wheels](/design-engineering/make-it-move)
|
||||
* [Make It Smarter and Faster](/design-engineering/make-it-smarter)
|
||||
* [Make a System that Communicates](/design-engineering/make-it-communicate)
|
||||
* [Coding](/coding)
|
||||
* [Autonomous Parking](/coding/autonomous-parking)
|
||||
* [Object Detection](/coding/object-detection)
|
||||
* [Line Detection](/coding/line-detection)
|
||||
* [Maker](/maker)
|
||||
* [Make A Sound Machine](/maker/sound-machine)
|
||||
* [Make A Security Gadget](/maker/security-gadget)
|
||||
* [Tutorial Videos](/videos)
|
||||
* [undefined](https://legoeducation.videomarketingplatform.co/v.ihtml/player.html?token=5d009e5f93fbf479c2e5ed2bf87a7990&source=embed&photo%5fid=35719444)
|
||||
* [undefined](https://legoeducation.videomarketingplatform.co/v.ihtml/player.html?token=2008a566f1fb034d58d5ebe19ba8621f&source=embed&photo%5fid=35719467)
|
||||
* [undefined](https://legoeducation.videomarketingplatform.co/v.ihtml/player.html?token=629730c938e452f0fd7653fbc4708166&source=embed&photo%5fid=35719470)
|
||||
* [undefined](https://legoeducation.videomarketingplatform.co/v.ihtml/player.html?token=3513a83b87fe536b2dc512237465fd1b&source=embed&photo%5fid=35719471)
|
||||
* [undefined](https://legoeducation.videomarketingplatform.co/v.ihtml/player.html?token=5c594c2373367f7870196f519f3bfc7a&source=embed&photo%5fid=35719472)
|
@ -9,6 +9,7 @@ brick.showString("Hello world!", 1);
|
||||
brick.showNumber(0, 1);
|
||||
brick.showValue("item", 0, 1);
|
||||
brick.clearScreen();
|
||||
brick.showPorts();
|
||||
```
|
||||
|
||||
## Buttons
|
||||
@ -19,8 +20,8 @@ brick.buttonEnter.onEvent(ButtonEvent.Bumped, function () {
|
||||
});
|
||||
brick.buttonEnter.pauseUntil(ButtonEvent.Bumped);
|
||||
brick.buttonEnter.isPressed()
|
||||
brick.buttonEnter.wasPressed()
|
||||
brick.setStatusLight(StatusLight.Red);
|
||||
brick.buttonEnter.wasPressed()
|
||||
```
|
||||
|
||||
## Other
|
||||
|
47
docs/reference/brick/battery-property.md
Normal file
@ -0,0 +1,47 @@
|
||||
# battery Property
|
||||
|
||||
Return the information about the battery
|
||||
|
||||
```sig
|
||||
brick.batteryInfo(BatteryProperty.Level)
|
||||
```
|
||||
|
||||
## Parameters
|
||||
|
||||
* property: the kind of information
|
||||
|
||||
## Returns
|
||||
|
||||
* a [number](/types/number) which represents the value of the property requested.
|
||||
|
||||
## Example
|
||||
|
||||
Show the battery level percentage on the screen. Also, show a green light if the battery level is above 15%. If the battery level is below 15% but above 5%, show a orange light. But, if the battery level is below 5%, show a pulsing red light.
|
||||
|
||||
```blocks
|
||||
let battery = 0;
|
||||
forever(function() {
|
||||
brick.showString("Battery level:", 1)
|
||||
brick.showNumber(battery, 2)
|
||||
battery = brick.batteryInfo(BatteryProperty.Level);
|
||||
if (battery > 15)
|
||||
{
|
||||
brick.setStatusLight(StatusLight.Green);
|
||||
} else if (battery > 5) {
|
||||
brick.setStatusLight(StatusLight.Orange);
|
||||
} else {
|
||||
brick.setStatusLight(StatusLight.RedPulse)
|
||||
}
|
||||
pause(30000)
|
||||
})
|
||||
```
|
||||
|
||||
Or see all the values
|
||||
|
||||
```blocks
|
||||
forever(function () {
|
||||
brick.showValue("bat V", brick.batteryInfo(BatteryProperty.Voltage), 1)
|
||||
brick.showValue("bat %", brick.batteryInfo(BatteryProperty.Level), 2)
|
||||
brick.showValue("bat I", brick.batteryInfo(BatteryProperty.Current), 3)
|
||||
})
|
||||
```
|
@ -14,7 +14,7 @@ The fact that a button was pressed earlier is remembered. Once **was pressed** i
|
||||
|
||||
Your @boardname@ has touch sensors that work like buttons. Instead of saying `enter` or `left` as the source button, use a touch sensor block with a sensor name like `touch 1`.
|
||||
|
||||
```block
|
||||
```typescript
|
||||
if (sensors.touch1.wasPressed()) {
|
||||
console.log("Hey, I was pressed.");
|
||||
}
|
||||
@ -32,7 +32,7 @@ Read about [touch sensors](/reference/sensors/touch-sensor) and using them as to
|
||||
|
||||
Set the brick light to green if the `right` button was pressed before the `left` button. If not, the brick light is turned off when the `left` button is pressed.
|
||||
|
||||
```blocks
|
||||
```typescript
|
||||
brick.buttonLeft.onEvent(ButtonEvent.Bumped, function() {
|
||||
if (brick.buttonRight.wasPressed()) {
|
||||
brick.setStatusLight(StatusLight.Green)
|
||||
@ -45,6 +45,5 @@ brick.buttonLeft.onEvent(ButtonEvent.Bumped, function() {
|
||||
## See also
|
||||
|
||||
[is pressed](/reference/brick/button/is-pressed),
|
||||
[on event](/reference/brick/button/on-event)
|
||||
|
||||
[on event](/reference/brick/button/on-event),
|
||||
[Touch sensors](/reference/sensors/touch-sensor)
|
18
docs/reference/brick/exit-program.md
Normal file
@ -0,0 +1,18 @@
|
||||
# exit Program
|
||||
|
||||
Stops the program and returns to the brick menu
|
||||
|
||||
```sig
|
||||
brick.exitProgram();
|
||||
```
|
||||
|
||||
## Example
|
||||
|
||||
Do a sequence of motor commands and stop the program.
|
||||
|
||||
```blocks
|
||||
motors.largeA.run(50)
|
||||
pause(500)
|
||||
motors.stopAll()
|
||||
brick.exitProgram();
|
||||
```
|
24
docs/reference/brick/show-ports.md
Normal file
@ -0,0 +1,24 @@
|
||||
# show Ports
|
||||
|
||||
Show the status of everything connected to the ports.
|
||||
|
||||
```sig
|
||||
brick.showPorts()
|
||||
```
|
||||
|
||||
You can find out what's connected to the ports on the brick and show its status. The status information from each sensor or motor connected is displayed on the screen.
|
||||
|
||||
## Example
|
||||
|
||||
Show the status of the ports on the brick. Resets all motors when ENTER is pressed.
|
||||
|
||||
```blocks
|
||||
brick.showPorts()
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
motors.resetAll()
|
||||
})
|
||||
```
|
||||
|
||||
## See also
|
||||
|
||||
[show string](/reference/brick/show-string), [show value](/reference/brick/show-value)
|
@ -8,7 +8,7 @@ console.sendToScreen();
|
||||
|
||||
A "console" is a place for a user to see special messages from a device. It could be something connected to a serial port, a display that shows text, or even a text file. A console is typically used as a place to send information that is added to a message _log_ (a record of messages that are sent from a device). Your program can send log messages using the [console](/reference/console) functions. The MakeCode editor has a console view that lets you see the console output when your program runs in the simulator.
|
||||
|
||||
On the @boardname@, the screen can serve as a console too and you can make your console output go there. Before using the console log functions, set the screen as the console output location.
|
||||
On the EV3 Brick, the screen can serve as a console too and you can make your console output go there. Before using the console log functions, set the screen as the console output location.
|
||||
|
||||
## Example
|
||||
|
||||
|
@ -19,6 +19,5 @@ motors.stopAll()
|
||||
```cards
|
||||
motors.largeA.speed()
|
||||
motors.largeA.angle()
|
||||
motors.largeA.tacho()
|
||||
motors.largeA.clearCounts()
|
||||
```
|
@ -27,5 +27,5 @@ motorAngle = motors.largeA.angle()
|
||||
|
||||
## See also
|
||||
|
||||
[tacho](/reference/motors/motor/tacho), [speed](/reference/motors/motor/speed),
|
||||
[speed](/reference/motors/motor/speed),
|
||||
[reset](/reference/motors/motor/reset), [clear counts](/reference/motors/motor/clear-counts)
|
@ -17,11 +17,11 @@ let tachoCount = 0;
|
||||
motors.largeA.reset()
|
||||
motors.largeA.run(50)
|
||||
pause(10000)
|
||||
tachoCount = motors.largeA.tacho()
|
||||
tachoCount = motors.largeA.angle()
|
||||
motors.largeA.clearCounts()
|
||||
motors.largeA.run(50)
|
||||
pause(10000)
|
||||
if (tachoCount == motors.largeA.tacho()) {
|
||||
if (tachoCount == motors.largeA.angle()) {
|
||||
brick.showString("Motor turns equal.", 1)
|
||||
} else {
|
||||
brick.showString("Motor turns NOT equal.", 1)
|
||||
@ -31,5 +31,5 @@ motors.largeA.stop()
|
||||
|
||||
## See also
|
||||
|
||||
[tacho](/reference/motors/motor/tacho), [angle](/reference/motors/motor/angle),
|
||||
[angle](/reference/motors/motor/angle),
|
||||
[speed](/reference/motors/motor/speed), [reset](/reference/motors/motor/reset)
|
59
docs/reference/motors/motor/ramp.md
Normal file
@ -0,0 +1,59 @@
|
||||
# Ramp
|
||||
|
||||
Schedules an acceleration, constant and deceleration phase at a given speed.
|
||||
|
||||
```sig
|
||||
motors.largeA.ramp(50, 100, 500, 100)
|
||||
```
|
||||
|
||||
The speed setting is a percentage of the motor's full speed. Full speed is the speed that the motor runs when the brick supplies maximum output voltage to the port.
|
||||
|
||||
|
||||
## Parameters
|
||||
|
||||
* **speed**: a [number](/types/number) that is the percentage of full speed. A negative value runs the motor in the reverse direction.
|
||||
* **acceleration**: the [number](/types/number) of movement units to rotate for while accelerating.
|
||||
* **value**: the [number](/types/number) of movement units to rotate for.
|
||||
* **deceleration**: the [number](/types/number) of movement units to rotate for while decelerating.
|
||||
* **unit**: the movement unit of rotation. This can be `milliseconds`, `seconds`, `degrees`, or `rotations`. If the number for **value** is `0`, this parameter isn't used.
|
||||
|
||||
## Example
|
||||
|
||||
This is an interactive program that lets you change the values of
|
||||
the acceleration and deceleration and see the effects.
|
||||
|
||||
```blocks
|
||||
let steady = 0
|
||||
let dec = 0
|
||||
let acc = 0
|
||||
brick.buttonLeft.onEvent(ButtonEvent.Pressed, function () {
|
||||
acc += -100
|
||||
})
|
||||
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
|
||||
motors.largeB.ramp(50, steady, MoveUnit.MilliSeconds, acc, dec)
|
||||
})
|
||||
brick.buttonRight.onEvent(ButtonEvent.Pressed, function () {
|
||||
acc += 100
|
||||
})
|
||||
brick.buttonUp.onEvent(ButtonEvent.Pressed, function () {
|
||||
dec += 100
|
||||
})
|
||||
brick.buttonDown.onEvent(ButtonEvent.Pressed, function () {
|
||||
dec += -100
|
||||
})
|
||||
acc = 500
|
||||
steady = 1000
|
||||
acc = 500
|
||||
forever(function () {
|
||||
brick.showValue("acc", acc, 1)
|
||||
brick.showValue("steady", steady, 2)
|
||||
brick.showValue("dec", dec, 3)
|
||||
brick.showString("acc: left/right", 5)
|
||||
brick.showString("dec: up/down", 6)
|
||||
brick.showString("run large B: enter", 7)
|
||||
})
|
||||
```
|
||||
|
||||
## See also
|
||||
|
||||
[tank](/reference/motors/synced/tank), [steer](/reference/motors/synced/steer), [stop](/reference/motors/motor/stop)
|
@ -6,9 +6,9 @@ Set the rotation speed of the motor as a percentage of maximum speed.
|
||||
motors.largeA.run(50)
|
||||
```
|
||||
|
||||
The speed setting is a pecentage of the motor's full speed. Full speed is the speed that the motor runs when the brick supplies maximum output voltage to the port.
|
||||
The speed setting is a percentage of the motor's full speed. Full speed is the speed that the motor runs when the brick supplies maximum output voltage to the port.
|
||||
|
||||
If you use just the **speed** number, the motor runs continously and won't stop unless you tell it to. You can also give a value for a certain amount of distance you want the motor to rotate for. The **value** can be an amount of time, a turn angle in degrees, or a number of full rotations.
|
||||
If you use just the **speed** number, the motor runs continuously and won't stop unless you tell it to. You can also give a value for a certain amount of distance you want the motor to rotate for. The **value** can be an amount of time, a turn angle in degrees, or a number of full rotations.
|
||||
|
||||
If you decide to use a **value** of rotation distance, you need to choose a type of movement **unit**.
|
||||
|
||||
@ -30,8 +30,8 @@ Here is how you use each different movement unit to run the motor for a fixed ro
|
||||
// Run motor for 700 Milliseconds.
|
||||
motors.largeA.run(25, 700, MoveUnit.MilliSeconds);
|
||||
|
||||
// Run motor for 700 Milliseconds again but no units specified.
|
||||
motors.largeA.run(25, 700);
|
||||
// Run motors B and C for 700 Milliseconds again but no units specified.
|
||||
motors.largeBC.run(25, 700);
|
||||
|
||||
// Run the motor for 45 seconds
|
||||
motors.largeA.run(50, 45, MoveUnit.Seconds);
|
||||
@ -61,6 +61,14 @@ motors.largeB.run(-25)
|
||||
|
||||
## ~
|
||||
|
||||
## Multiple motors
|
||||
|
||||
When using **run** with multiple motors, there is no guarantee that their speed will stay in sync. Use [tank](/reference/motors/tank) or [steer](/reference/motors/steer) for synchronized motor operations.
|
||||
|
||||
```blocks
|
||||
motors.largeBC.run(50)
|
||||
```
|
||||
|
||||
## Examples
|
||||
|
||||
### Drive the motor for 20 seconds
|
||||
|
30
docs/reference/motors/motor/set-brake-settle-time.md
Normal file
@ -0,0 +1,30 @@
|
||||
# set Brake Settle Time
|
||||
|
||||
Set the time to wait after a motor stopped to allow it settle
|
||||
when brake is enabled. Default is 10ms.
|
||||
|
||||
```sig
|
||||
motors.largeA.setBrakeSettleTime(200)
|
||||
```
|
||||
|
||||
When a the motor is stopped and brake is applied, it can still wiggle for a little while. You can use the settle time to automatically way after stopping and let the robot settle.
|
||||
|
||||
## Parameters
|
||||
|
||||
* **time**: a [number](/types/number) value which represents the number of milliseconds to wait after braking.
|
||||
|
||||
## Example
|
||||
|
||||
Set the brake mode and the settle time to 500ms. Run the motor connected to port **A** for 2 seconds at a speed of `30` and stop after 2s.
|
||||
|
||||
```blocks
|
||||
motors.largeA.setBrake(true)
|
||||
motors.largeA.setBrakeSettleTime(500)
|
||||
motors.largeA.run(30)
|
||||
pause(2000)
|
||||
motors.largeA.stop()
|
||||
```
|
||||
|
||||
## See also
|
||||
|
||||
[stop](/reference/motors/motor/stop)
|
@ -1,28 +1,28 @@
|
||||
# set Brake
|
||||
|
||||
Set the brake on the motor so it won't turn when it has no power.
|
||||
Set the brake on the motor so it will brake when it finishes a brake command.
|
||||
|
||||
```sig
|
||||
motors.largeA.setBrake(false)
|
||||
```
|
||||
|
||||
When a the motor is stopped, it can still rotate if an external force is applied to it. This can happen, for example, if your're tanking your brick on a inclined surface and stop the motors. Gravity will push down on the brick and might cause it to start rolling again. You can prevent this movement by setting the brake.
|
||||
When a the motor is stopped, it can still rotate if an external force is applied to it. This can happen, for example, if you're tanking your brick on a inclined surface and stop the motors. Gravity will push down on the brick and might cause it to start rolling again. You can prevent this movement by setting the brake.
|
||||
|
||||
Also, you can use the brake to do simple skid steering for your brick.
|
||||
|
||||
## Paramters
|
||||
## Parameters
|
||||
|
||||
* **brake**: a [boolean](/types/boolean) value which is either `true` to set the brake on or `false` to set the brake off.
|
||||
|
||||
## Example
|
||||
|
||||
Run the motor connected to port **A** for 2 seconds at a speed of `30`. Stop and set the brake.
|
||||
Run the motor connected to port **A** for 2 seconds at a speed of `30` and stop after 2s.
|
||||
|
||||
```blocks
|
||||
motors.largeA.setBrake(true)
|
||||
motors.largeA.run(30)
|
||||
pause(2000)
|
||||
motors.largeA.stop()
|
||||
motors.largeA.setBrake(true)
|
||||
```
|
||||
|
||||
## See also
|
||||
|
26
docs/reference/motors/motor/set-run-phase.md
Normal file
@ -0,0 +1,26 @@
|
||||
# Set Run Phase
|
||||
|
||||
Allows to specify an acceleration or deceleration phases for run commands.
|
||||
|
||||
```sig
|
||||
motors.largeD.setRunPhase(MovePhase.Acceleration, 1, MoveUnit.Seconds)
|
||||
```
|
||||
|
||||
Once the run phase is specified on a motor (or pair of motors),
|
||||
it will be automatically applied to [run](/reference/motors/run) commands.
|
||||
|
||||
## Time vs Rotation
|
||||
|
||||
The phases specified for time units (seconds, milliseconds) only apply to run with time
|
||||
moves. Similarly, the phases specified for rotation units (# rotation, degrees) only
|
||||
apply to run with rotation units.
|
||||
|
||||
## Examples
|
||||
|
||||
```blocks
|
||||
motors.largeB.setRunPhase(MovePhase.Acceleration, 0.5, MoveUnit.Seconds)
|
||||
motors.largeB.setRunPhase(MovePhase.Deceleration, 0.2, MoveUnit.Seconds)
|
||||
forever(function () {
|
||||
motors.largeB.run(50, 1, MoveUnit.Seconds)
|
||||
})
|
||||
```
|
@ -29,5 +29,5 @@ motors.largeA.stop()
|
||||
|
||||
## See also
|
||||
|
||||
[tacho](/reference/motors/motor/tacho), [speed](/reference/motors/motor/speed),
|
||||
[speed](/reference/motors/motor/speed),
|
||||
[reset](/reference/motors/motor/reset), [clear counts](/reference/motors/motor/clear-counts)
|
@ -1,48 +0,0 @@
|
||||
# tacho
|
||||
|
||||
Get the current number of degress of rotation.
|
||||
|
||||
```sig
|
||||
motors.largeA.tacho()
|
||||
```
|
||||
|
||||
The motors that come with your @boardname@ have a way to detect their own turning motion. They count the amount of motor rotation in degrees. The motor will count each degree of angle rotation up to 360 degrees for a full rotation. As the motor continues to turn, the _tacho_ count keeps adding up the degrees even past one full rotation. So, if the motor makes 3 complete rotations, the count will be 1080.
|
||||
|
||||
The name _tacho_ comes from the first part of the word [tachometer](https://en.wikipedia.org/wiki/Tachometer) which is a device to measure how fast something is turning. The motor controller in the brick uses the tacho count to regulate the motor's speed.
|
||||
|
||||
## ~hint
|
||||
|
||||
**Measure RPM**
|
||||
|
||||
A standard way to know how fast a motor is turning is by measuring its _revolutions per minute_ (rpm). One revolution is the same thing as a rotation, or one turn. How do you measure rpm? Well, here's a simple way:
|
||||
|
||||
1. Record the current tacho count
|
||||
2. Run the motor for 60 seconds
|
||||
3. Get the tacho count again
|
||||
4. Subtract the first tacho count from the second one
|
||||
5. Divide that number by `360`
|
||||
|
||||
## ~
|
||||
|
||||
## Returns
|
||||
|
||||
* a [number](/types/number) which is the total count of degrees of rotation that the motor has turned since it was first started or reset.
|
||||
|
||||
## Example
|
||||
|
||||
Run the motor connected to port **A** at half speed for 5 seconds. Display the number of full rotations on the screen.
|
||||
|
||||
```blocks
|
||||
motors.largeA.run(50)
|
||||
pause(5000)
|
||||
motors.largeA.stop()
|
||||
brick.showString("Motor rotations:", 1)
|
||||
brick.showNumber(motors.largeA.tacho() / 360, 3)
|
||||
motors.largeA.run(50)
|
||||
```
|
||||
|
||||
## See also
|
||||
|
||||
[angle](/reference/motors/motor/tacho), [speed](/reference/motors/motor/speed),
|
||||
[set regulated](/reference/motors/motor/set-regulated),
|
||||
[reset](/reference/motors/motor/reset), [clear counts](/reference/motors/motor/clear-counts)
|
25
docs/reference/motors/reset-all.md
Normal file
@ -0,0 +1,25 @@
|
||||
# reset All Motors
|
||||
|
||||
Reset all motors currently running on the brick.
|
||||
|
||||
```sig
|
||||
motors.resetAll();
|
||||
```
|
||||
|
||||
The motors counters are resetted.
|
||||
|
||||
## Example
|
||||
|
||||
Tank the EV3 Brick forward at half speed for 5 seconds and then stop.
|
||||
|
||||
```blocks
|
||||
motors.largeAB.tank(50, 50);
|
||||
pause(5000);
|
||||
motors.stopAll();
|
||||
motors.resetAll();
|
||||
```
|
||||
|
||||
## See also
|
||||
|
||||
[stop all](/reference/motors/motor/stop-all),
|
||||
[reset](/reference/motors/motor/reset)
|
@ -10,7 +10,7 @@ The motors stops but any motion caused from previously running the motors contin
|
||||
|
||||
## Example
|
||||
|
||||
Tank the @boardname@ forward at half speed for 5 seconds and then stop.
|
||||
Tank the EV3 Brick forward at half speed for 5 seconds and then stop.
|
||||
|
||||
```blocks
|
||||
motors.largeAB.tank(50, 50);
|
||||
@ -22,4 +22,5 @@ motors.stopAll();
|
||||
|
||||
[stop](/reference/motors/motor/stop),
|
||||
[reset](/reference/motors/motor/reset),
|
||||
[reset-all](/reference/motors/motor/reset-all),
|
||||
[set brake](/reference/motors/motor/set-brake)
|
@ -8,7 +8,7 @@ motors.largeAB.steer(0, 0)
|
||||
|
||||
A brick driving with two motors can steer itself by changing the speed of one motor compared to the speed of the other. To make a slow turn to the left, you might make the right motor run slightly faster than the left one. To make a fast, or sharp, turn to the right, the left motor could run at least twice as fast as the right one.
|
||||
|
||||
The @boardname@ steers by using a percentage value of _follow_ for one of the motors. This means that the motor in the turn direction will rotate slower than the other. It is the _follower_ motor and the other motor is the _drive_ motor. The drive motor runs at a percentage of full speed set in **speed**. The follower motor runs at a percentage of speed of the drive motor. So, it runs at a percentage of a percentage of full speed.
|
||||
The EV3 Brick steers by using a percentage value of _follow_ for one of the motors. This means that the motor in the turn direction will rotate slower than the other. It is the _follower_ motor and the other motor is the _drive_ motor. The drive motor runs at a percentage of full speed set in **speed**. The follower motor runs at a percentage of speed of the drive motor. So, it runs at a percentage of a percentage of full speed.
|
||||
|
||||
To make the turn happen you give a _turn ratio_ which is a percentage value of steer to the left or right. If you want to steer to the left at 30% of the of the drive motor speed, use the value of `-30` for **turnRatio**. Left turns use negative values and right turns use positive values. A really sharp turn to the right might use a turn ratio value of `80`.
|
||||
|
||||
@ -22,7 +22,7 @@ If you decide to use a **value** of rotation distance, you need to choose a type
|
||||
|
||||
## Parameters
|
||||
|
||||
* **turnRatio**: a [number](/types/number) that is the percentage of speed of the drive motor. The follower motor runs at this speed. A negative number steers to the left and a positive number steers to the right. This is a number between `-100` and `100`.
|
||||
* **turnRatio**: a [number](/types/number) that is the percentage of speed of the drive motor. The follower motor runs at this speed. A negative number steers to the left and a positive number steers to the right. This is a number between `-200` and `200`.
|
||||
* **speed**: a [number](/types/number) that is the percentage of full speed. A negative value runs the motors in the reverse direction. This is the speed that the drive motor runs at.
|
||||
* **value**: the [number](/types/number) of movement units to rotate for. A value of `0` means run the motor continuously.
|
||||
* **unit**: the movement unit of rotation. This can be `milliseconds`, `seconds`, `degrees`, or `rotations`. If the number for **value** is `0`, this parameter isn't used.
|
||||
@ -39,6 +39,13 @@ motors.largeBC.steer(-15, -75)
|
||||
|
||||
## ~
|
||||
|
||||
## ~ hint
|
||||
|
||||
Only one set of synchronized motors will run at the same time. Once you launch tank/steer, it will cancel any existing synchronized speed command.
|
||||
|
||||
## ~
|
||||
|
||||
|
||||
## Examples
|
||||
|
||||
### Make a slight right
|
||||
@ -79,6 +86,51 @@ for (let i = 0; i < 4; i++) {
|
||||
motors.stopAll()
|
||||
```
|
||||
|
||||
### Steer tester
|
||||
|
||||
This program lets you change the values of speed and turn ratio with the buttons.
|
||||
|
||||
```typescript
|
||||
let speed = 0;
|
||||
let turnRatio = 0;
|
||||
|
||||
brick.showString(`steer tester`, 1)
|
||||
brick.showString(`connect motors BC`, 7)
|
||||
brick.showString(`up/down for speed`, 8)
|
||||
brick.showString(`left/right for turn ratio`, 9)
|
||||
|
||||
forever(function () {
|
||||
brick.showString(`motor B speed ${motors.largeB.speed()}%`, 4)
|
||||
brick.showString(`motor C speed ${motors.largeC.speed()}%`, 5)
|
||||
pause(100)
|
||||
})
|
||||
|
||||
function updateSteer() {
|
||||
motors.largeBC.steer(turnRatio, speed);
|
||||
brick.showString(`speed ${speed}%`, 2)
|
||||
brick.showString(`turnRatio ${turnRatio}`, 3)
|
||||
}
|
||||
|
||||
brick.buttonUp.onEvent(ButtonEvent.Pressed, function () {
|
||||
speed += 10
|
||||
updateSteer()
|
||||
})
|
||||
brick.buttonDown.onEvent(ButtonEvent.Pressed, function () {
|
||||
speed -= 10
|
||||
updateSteer()
|
||||
})
|
||||
brick.buttonLeft.onEvent(ButtonEvent.Pressed, function () {
|
||||
turnRatio -= 10
|
||||
updateSteer()
|
||||
})
|
||||
brick.buttonRight.onEvent(ButtonEvent.Pressed, function () {
|
||||
turnRatio += 10
|
||||
updateSteer()
|
||||
})
|
||||
|
||||
updateSteer()
|
||||
```
|
||||
|
||||
## See also
|
||||
|
||||
[tank](/reference/motors/synced/tank), [run](/reference/motors/motor/run)
|
@ -35,6 +35,12 @@ motors.largeBC.tank(-75, -75)
|
||||
|
||||
## ~
|
||||
|
||||
## ~ hint
|
||||
|
||||
Only one set of synchronized motors will run at the same time. Once you launch tank/steer, it will cancel any existing synchronized speed command.
|
||||
|
||||
## ~
|
||||
|
||||
## Examples
|
||||
|
||||
### Tank forward and backward
|
||||
@ -76,6 +82,51 @@ pause(5000)
|
||||
motors.stopAll()
|
||||
```
|
||||
|
||||
### Tank tester
|
||||
|
||||
This program lets you change the tank values using the brick buttons.
|
||||
|
||||
```typescript
|
||||
let tankB = 0;
|
||||
let tankC = 0;
|
||||
|
||||
brick.showString(`tank tester`, 1)
|
||||
brick.showString(`connect motors BC`, 7)
|
||||
brick.showString(`up/down for tank B`, 8)
|
||||
brick.showString(`left/right for tank C`, 9)
|
||||
|
||||
forever(function () {
|
||||
brick.showString(`motor B speed ${motors.largeB.speed()}%`, 4)
|
||||
brick.showString(`motor C speed ${motors.largeC.speed()}%`, 5)
|
||||
pause(100)
|
||||
})
|
||||
|
||||
function updateTank() {
|
||||
brick.showString(`tank A: ${tankB}%`, 2)
|
||||
brick.showString(`tank B: ${tankC}%`, 3)
|
||||
motors.largeBC.tank(tankB, tankC);
|
||||
}
|
||||
|
||||
brick.buttonUp.onEvent(ButtonEvent.Pressed, function () {
|
||||
tankB += 10
|
||||
updateTank();
|
||||
})
|
||||
brick.buttonDown.onEvent(ButtonEvent.Pressed, function () {
|
||||
tankB -= 10
|
||||
updateTank();
|
||||
})
|
||||
brick.buttonRight.onEvent(ButtonEvent.Pressed, function () {
|
||||
tankC += 10
|
||||
updateTank();
|
||||
})
|
||||
brick.buttonLeft.onEvent(ButtonEvent.Pressed, function () {
|
||||
tankC -= 10
|
||||
updateTank();
|
||||
})
|
||||
|
||||
updateTank();
|
||||
```
|
||||
|
||||
## See also
|
||||
|
||||
[steer](/reference/motors/synced/steer), [run](/reference/motors/motor/run)
|
@ -4,9 +4,9 @@
|
||||
|
||||
```cards
|
||||
sensors.color1.onColorDetected(ColorSensorColor.Blue, function () {})
|
||||
sensors.color1.onLightChanged(LightIntensityMode.Reflected, LightCondition.Dark, function () {})
|
||||
sensors.color1.pauseForLight(LightIntensityMode.Reflected, LightCondition.Dark)
|
||||
sensors.color1.pauseForColor(ColorSensorColor.Blue)
|
||||
sensors.color1.onLightDetected(LightIntensityMode.Reflected, Light.Dark, function () {})
|
||||
sensors.color1.pauseUntilLightDetected(LightIntensityMode.Reflected, Light.Dark)
|
||||
sensors.color1.pauseUntilColorDetected(ColorSensorColor.Blue)
|
||||
sensors.color1.color();
|
||||
sensors.color1.light(LightIntensityMode.Ambient)
|
||||
sensors.color(ColorSensorColor.Blue)
|
||||
@ -17,8 +17,8 @@ sensors.color(ColorSensorColor.Blue)
|
||||
```cards
|
||||
sensors.touch1.onEvent(ButtonEvent.Pressed, function () {})
|
||||
sensors.touch1.pauseUntil(ButtonEvent.Pressed)
|
||||
sensors.touch1.wasPressed()
|
||||
sensors.touch1.isPressed()
|
||||
sensors.touch1.wasPressed()
|
||||
```
|
||||
|
||||
## Gyro
|
||||
|
BIN
docs/static/about/blocks-to-js.gif
vendored
Normal file
After Width: | Height: | Size: 102 KiB |
BIN
docs/static/about/blocks-toolbox.png
vendored
Normal file
After Width: | Height: | Size: 22 KiB |
BIN
docs/static/about/download-button.png
vendored
Normal file
After Width: | Height: | Size: 3.0 KiB |
BIN
docs/static/about/explorer-button.png
vendored
Normal file
After Width: | Height: | Size: 2.2 KiB |
BIN
docs/static/about/explorer-view.png
vendored
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
docs/static/about/help-button.png
vendored
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
docs/static/about/home-button.png
vendored
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
docs/static/about/more-settings.png
vendored
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
docs/static/about/redo-button.png
vendored
Normal file
After Width: | Height: | Size: 981 B |
BIN
docs/static/about/save-project.png
vendored
Normal file
After Width: | Height: | Size: 2.7 KiB |
BIN
docs/static/about/share-button.png
vendored
Normal file
After Width: | Height: | Size: 1.0 KiB |
BIN
docs/static/about/share-dialog.png
vendored
Normal file
After Width: | Height: | Size: 24 KiB |
BIN
docs/static/about/undo-button.png
vendored
Normal file
After Width: | Height: | Size: 998 B |
BIN
docs/static/about/zoom-in.png
vendored
Normal file
After Width: | Height: | Size: 1011 B |
BIN
docs/static/about/zoom-out.png
vendored
Normal file
After Width: | Height: | Size: 933 B |
BIN
docs/static/bluetooth/experimental.png
vendored
Normal file
After Width: | Height: | Size: 26 KiB |
BIN
docs/static/download/firmware.png
vendored
Normal file
After Width: | Height: | Size: 4.5 KiB |
529
docs/static/download/firmware.svg
vendored
@ -1,252 +1,279 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="261.3" height="109.3" viewBox="0 0 69.1 28.9" id="svg9461">
|
||||
<defs id="defs9455">
|
||||
<clipPath id="clipPath8689">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8687"/>
|
||||
</clipPath>
|
||||
<clipPath id="clipPath8663">
|
||||
<path d="M309.8 89.4h3.7v3.7h-3.7z" id="path8661"/>
|
||||
</clipPath>
|
||||
<clipPath id="clipPath8647">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8645"/>
|
||||
</clipPath>
|
||||
<linearGradient x2="1" gradientUnits="userSpaceOnUse" gradientTransform="matrix(0 .6661 -.32488 0 300.7 115)" id="linearGradient8637">
|
||||
<stop offset="0" id="stop8633" stop-color="#757575"/>
|
||||
<stop offset="1" id="stop8635" stop-color="#393939"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clipPath8595">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8593"/>
|
||||
</clipPath>
|
||||
<linearGradient x2="1" gradientUnits="userSpaceOnUse" gradientTransform="matrix(0 12.8096 -17.18704 0 300.7 98.4)" id="linearGradient8585">
|
||||
<stop offset="0" id="stop8579" stop-color="#6a6a6a"/>
|
||||
<stop offset=".5" id="stop8581" stop-color="#48e400"/>
|
||||
<stop offset="1" id="stop8583" stop-color="#6a6a6a"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clipPath8561">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8559"/>
|
||||
</clipPath>
|
||||
<linearGradient x2="1" gradientUnits="userSpaceOnUse" gradientTransform="matrix(0 -1.33016 5.597 0 300.7 88.4)" id="linearGradient8551">
|
||||
<stop offset="0" id="stop8547" stop-color="#a9aba9"/>
|
||||
<stop offset="1" id="stop8549" stop-color="#535453"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clipPath8525">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8523"/>
|
||||
</clipPath>
|
||||
<linearGradient x2="1" gradientUnits="userSpaceOnUse" gradientTransform="matrix(0 -.56074 .70884 0 300.7 115.6)" id="linearGradient8515">
|
||||
<stop offset="0" id="stop8511" stop-color="#a9aba9"/>
|
||||
<stop offset="1" id="stop8513" stop-color="#818181"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clipPath8493">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8491"/>
|
||||
</clipPath>
|
||||
<linearGradient x2="1" gradientUnits="userSpaceOnUse" gradientTransform="matrix(0 -2.39765 2.48247 0 300.7 98.1)" id="linearGradient8483">
|
||||
<stop offset="0" id="stop8479" stop-color="#f2f2f2"/>
|
||||
<stop offset="1" id="stop8481" stop-color="#7a7a7a"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clipPath8449">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8447"/>
|
||||
</clipPath>
|
||||
<clipPath id="clipPath8977">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8975"/>
|
||||
</clipPath>
|
||||
<clipPath id="clipPath8951">
|
||||
<path d="M593 101h3.6v3.7H593z" id="path8949"/>
|
||||
</clipPath>
|
||||
<clipPath id="clipPath8935">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8933"/>
|
||||
</clipPath>
|
||||
<linearGradient x2="1" gradientUnits="userSpaceOnUse" gradientTransform="matrix(0 .67046 -.32706 0 583.8 126.8)" id="linearGradient8925">
|
||||
<stop offset="0" id="stop8921" stop-color="#757575"/>
|
||||
<stop offset="1" id="stop8923" stop-color="#393939"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clipPath8883">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8881"/>
|
||||
</clipPath>
|
||||
<linearGradient x2="1" gradientUnits="userSpaceOnUse" gradientTransform="matrix(0 12.89405 -17.29507 0 583.7 110)" id="linearGradient8873">
|
||||
<stop offset="0" id="stop8867" stop-color="#6a6a6a"/>
|
||||
<stop offset=".5" id="stop8869" stop-color="#48e400"/>
|
||||
<stop offset="1" id="stop8871" stop-color="#6a6a6a"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clipPath8849">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8847"/>
|
||||
</clipPath>
|
||||
<linearGradient x2="1" gradientUnits="userSpaceOnUse" gradientTransform="matrix(0 -1.33884 5.6329 0 583.7 100)" id="linearGradient8839">
|
||||
<stop offset="0" id="stop8835" stop-color="#a9aba9"/>
|
||||
<stop offset="1" id="stop8837" stop-color="#535453"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clipPath8813">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8811"/>
|
||||
</clipPath>
|
||||
<linearGradient x2="1" gradientUnits="userSpaceOnUse" gradientTransform="matrix(0 -.56429 .71345 0 583.7 127.4)" id="linearGradient8803">
|
||||
<stop offset="0" id="stop8799" stop-color="#a9aba9"/>
|
||||
<stop offset="1" id="stop8801" stop-color="#818181"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clipPath8781">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8779"/>
|
||||
</clipPath>
|
||||
<linearGradient x2="1" gradientUnits="userSpaceOnUse" gradientTransform="matrix(0 -2.41323 2.4988 0 583.7 109.8)" id="linearGradient8771">
|
||||
<stop offset="0" id="stop8767" stop-color="#f2f2f2"/>
|
||||
<stop offset="1" id="stop8769" stop-color="#7a7a7a"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clipPath8737">
|
||||
<path d="M0 1145.9h1366V0H0z" id="path8735"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
<g id="layer1" transform="translate(0 -268)">
|
||||
<g id="g10860" transform="translate(-20.8 -2)">
|
||||
<g transform="matrix(.35278 0 0 -.35278 62.8 291.4)" id="g8727">
|
||||
<path id="path8729" d="M0 0h24" fill="none" stroke="#000" stroke-width="2"/>
|
||||
</g>
|
||||
<g id="g8731" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g clip-path="url(#clipPath8737)" id="g8733">
|
||||
<g transform="translate(458 159.9)" id="g8739">
|
||||
<path id="path8741" d="M0 0h83a4 4 0 0 0 4-4v-52.5H-4V-4a4 4 0 0 0 4 4" fill="#e6e6e6"/>
|
||||
</g>
|
||||
<g transform="translate(458 158.4)" id="g8743">
|
||||
<path id="path8745" d="M0 0h83c1.3 0 2.4-1.1 2.4-2.5V-52c0-.9-.6-1.5-1.5-1.5H-1c-.8 0-1.5.6-1.5 1.5v49.5C-2.5-1.1-1.4 0 0 0z" fill="none" stroke="#282828" stroke-width="3"/>
|
||||
</g>
|
||||
<g transform="translate(445 102.9)" id="g8747">
|
||||
<path id="path8749" d="M0 0h108.8v-1.2a3 3 0 0 0-3-3H3a3 3 0 0 0-3 3z" fill="#626262"/>
|
||||
</g>
|
||||
<g transform="translate(489.8 102.9)" id="g8751">
|
||||
<path id="path8753" d="M0 0h19.3c0-.8-.6-1.4-1.4-1.4H1.4C.6-1.4 0-.8 0 0" fill="#818181"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8755" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g id="g8757">
|
||||
<g id="g8763">
|
||||
<g id="g8765">
|
||||
<path id="path8773" d="M567.9 139.7a.6.6 0 0 1-.6-.6v-30.6c0-.3.2-.6.6-.6h31.7c.3 0 .5.3.5.6v30.6c0 .3-.2.6-.5.6z" fill="url(#linearGradient8771)"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8775" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g clip-path="url(#clipPath8781)" id="g8777">
|
||||
<g transform="translate(569.7 111.2)" id="g8783">
|
||||
<path id="path8785" d="M0 0h28c.3 0 .6-.3.6-.6V-12c0-.4-.3-.6-.6-.6H0c-.3 0-.6.2-.6.6V-.6c0 .3.3.6.6.6" fill="#f2f2f2"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8787" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g id="g8789">
|
||||
<g id="g8795">
|
||||
<g id="g8797">
|
||||
<path id="path8805" d="M569.4 149.1a.6.6 0 0 1-.6-.6v-22.3c0-.3.3-.6.6-.6H598c.3 0 .6.3.6.6v22.3c0 .3-.3.6-.6.6z" fill="url(#linearGradient8803)"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8807" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g clip-path="url(#clipPath8813)" id="g8809">
|
||||
<g transform="translate(572.7 146)" id="g8815">
|
||||
<path id="path8817" d="M0 0h22.1c.6 0 1.1-.5 1.1-1.1v-12.5c0-.6-.5-1-1-1H0c-.6 0-1.1.4-1.1 1V-1c0 .5.5 1 1.1 1" fill="#393939"/>
|
||||
</g>
|
||||
<g transform="translate(574.4 145.4)" id="g8819">
|
||||
<path id="path8821" d="M0 0h18.8c.4 0 .8-.4.8-.8v-12c0-.4-.4-.8-.8-.8H0c-.4 0-.8.4-.8.8v12c0 .4.4.8.8.8" fill="#98b6a7"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8823" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g id="g8825">
|
||||
<g id="g8831">
|
||||
<g id="g8833">
|
||||
<path id="path8841" d="M569.1 105.6v-6.4c0-.3.3-.6.6-.6h28c.3 0 .6.3.6.6v6.4z" fill="url(#linearGradient8839)"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8843" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g clip-path="url(#clipPath8849)" id="g8845">
|
||||
<g transform="translate(581.7 109.3)" id="g8851">
|
||||
<path id="path8853" d="M0 0l-4.2 4.2v.6h-1a2.5 2.5 0 0 0 0 4.9h1v.5L0 14.5h4l4.2-4.2v-.6h1a2.5 2.5 0 0 0 0-5h-1v-.5L4.2 0z" fill="#6a6a6a"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8855" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g id="g8857">
|
||||
<g id="g8863">
|
||||
<g id="g8865">
|
||||
<path id="path8875" d="M581.7 123.8l-4.2-4.2v-.6h-1a2.5 2.5 0 1 1 0-5v.1h1v-.5l4.2-4.3h4.2l4.2 4.3v.5h1a2.5 2.5 0 0 1-.1 4.9h-1v.7l-4.1 4.1z" fill="url(#linearGradient8873)"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8877" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g clip-path="url(#clipPath8883)" id="g8879">
|
||||
<g transform="translate(576.4 118.4)" id="g8885">
|
||||
<path id="path8887" d="M0 0h3v-3.6H0A1.8 1.8 0 1 0 0 0" fill="#a9aba9"/>
|
||||
</g>
|
||||
<g transform="translate(591 114.8)" id="g8889">
|
||||
<path id="path8891" d="M0 0h-3v3.6h3A1.8 1.8 0 1 0 0 0" fill="#a9aba9"/>
|
||||
</g>
|
||||
<g transform="translate(582 118.4)" id="g8893">
|
||||
<path id="path8895" d="M0 0h3.6v-3.6H-.1V0H0" fill="#393939"/>
|
||||
</g>
|
||||
<g transform="translate(581.9 123.2)" id="g8897">
|
||||
<path id="path8899" d="M0 0h3.8l2.8-2.9L5.5-4v-2H4.3v1c0 .5-.4 1-1 1h-3a.7.7 0 0 1-.8-.8v-1.4h-1V-4l-1.2 1.2z" fill="#a9aba9"/>
|
||||
</g>
|
||||
<g transform="translate(585.6 110)" id="g8901">
|
||||
<path id="path8903" d="M0 0h-3.8l-2.8 2.9 1.2 1.2v2h1V5c0-.5.5-1 1-1h3.2c.5 0 .8.4.8.8v1.4h1.1V4l1.2-1.2z" fill="#a9aba9"/>
|
||||
</g>
|
||||
<path id="path8905" d="M583.3 131.4h.9v-4.1h-.9z" fill="#393939"/>
|
||||
<path id="path8907" d="M583.3 127.4h.9v-1.8h-.9z" fill="#9b9b9b"/>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8909" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g id="g8911">
|
||||
<g id="g8917">
|
||||
<g id="g8919">
|
||||
<path id="path8927" d="M583.3 125.6h.9v1.8h-.9z" fill="url(#linearGradient8925)"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8929" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g clip-path="url(#clipPath8935)" id="g8931">
|
||||
<path id="path8937" d="M583.3 125.6h.9v-1.8h-.9z" fill="#818181"/>
|
||||
<g transform="translate(571.2 125.6)" id="g8939">
|
||||
<path id="path8941" d="M0 0h7v-1.7L5.3-3.5H.6c-.3 0-.6.3-.6.6z" fill="#a9aba9"/>
|
||||
</g>
|
||||
<path id="path8943" d="M593 104.7h3.6V101H593z" fill="#fff"/>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8945" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g clip-path="url(#clipPath8951)" id="g8947">
|
||||
<g transform="translate(596.4 103.2)" id="g8953">
|
||||
<path id="path8955" d="M0 0v-.3C-.3-.8-.4-1-.8-1l-.3.2a.6.6 0 0 0-.5-.2c-.1 0-.2 0-.3.2C-2-1-2.1-1-2.2-1h-.6a.3.3 0 0 0-.3.2l.3 1h.5l.5.2.2-.1h.4c.1.1.3 0 .4 0V.1l.4.2.3-.1L0 0m-3.4-2.1H.2v3.6h-3.6z" fill="#fe0"/>
|
||||
</g>
|
||||
<g transform="translate(596.5 103)" id="g8957">
|
||||
<path id="path8959" d="M0 0c0-.2 0-.3-.2-.5 0-.2-.3-.4-.6-.4l-.4.1a.7.7 0 0 0-.4-.1H-2a.7.7 0 0 0-.4 0H-3c-.2 0-.3.1-.4.3 0 .4.2.7.4 1 0 .2.2.2.4.2h2.1L0 .5V0m-3.5-2H.1v3.6h-3.6z" fill="#d52715"/>
|
||||
</g>
|
||||
<path id="path8961" d="M596.6 101H593v3.6h3.6zm-3.7 0h3.7v3.7H593z" fill="#171714"/>
|
||||
<g transform="translate(596.5 103.7)" id="g8963">
|
||||
<path id="path8965" d="M0 0v-.2.2m0 0v-.2.1m0 0zm0 0z" fill="#171714"/>
|
||||
</g>
|
||||
<g transform="translate(596 103.2)" id="g8967">
|
||||
<path id="path8969" d="M0 0a3 3 0 0 0-.2-.6h-.1c0 .2 0 .4.2.6H0m.3-.2L0-.6C0-.8-.2-1-.3-1c-.2 0-.3 0-.3.3l.1.4c.1.3.2.5.5.5s.3-.3.3-.5M-1 .1V0l-.3-.5.1-.1.2.2c0 .2 0 .2.2.2s.2-.1.1-.2c0-.3-.2-.5-.5-.5a.3.3 0 0 0-.3.3l.2.5c0 .2.2.4.5.4.2 0 .3 0 .3-.2 0-.1 0-.2-.2-.2h-.1v.2m-1-.5v-.2h.3c0-.2-.2-.3-.3-.3-.2 0-.3.1-.3.2 0 .3 0 .5.2.7 0 .2.2.3.4.3l.2-.1c0-.2 0-.2-.2-.2h-.1v-.1c.1 0 .2 0 .1-.2l-.3-.1m-.6-.2h.2c0-.2-.1-.3-.3-.3 0 0-.2 0-.2.2l.3.9s.1.1.2 0h.1c0-.3-.2-.5-.3-.8M0 .4C-.2.4-.3.4-.4.2l-.4.2-.4-.1-.3.1c-.2 0-.3 0-.4-.2v.1l-.3.1c-.1 0-.2 0-.3-.2-.1-.3-.3-.6-.3-1 0 0 .1-.2.3-.2l.3.1c.1 0 .2-.1.4 0h.6l.5.1.4-.2c.3 0 .5.3.6.6V0a.4.4 0 0 1-.3.4" fill="#171714"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8971" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g clip-path="url(#clipPath8977)" id="g8973">
|
||||
<g transform="translate(578 103)" id="g8979">
|
||||
<path id="path8981" d="M0 0v-.3h-.6l-.1-.1v-.4H0v-.4h-1l-.2.2h-.3l-.1-.1v-.6H.7V.5h-2.3v-.6h.5V0H0z" fill="#f2f2f2"/>
|
||||
</g>
|
||||
<g transform="translate(576 103.6)" id="g8983">
|
||||
<path id="path8985" d="M0 0h-.5l-.1-.1-.6-1.3L-2-.1V0h-.5s-.1 0 0-.1l.9-2 .2-.1h.5l1 2L0 0" fill="#f2f2f2"/>
|
||||
</g>
|
||||
<g transform="translate(573 102.8)" id="g8987">
|
||||
<path id="path8989" d="M0 0h.1v-.4L0-.5h-1.5v-.3H0L.1-1v-.4h-2.2v2l.1.2H.1V.4h-1.6V0z" fill="#f2f2f2"/>
|
||||
</g>
|
||||
<g transform="translate(583.5 136.6)" id="g8991">
|
||||
<path id="path8993" d="M0 0l-.8 1.3-1.4-2.9 4-1c-.5.5-.5.7-.9 1.3.5.1 1 .4 1.4.7.8.4 1.5 1 2 1.9a4 4 0 0 1-.6 3.6c-.4 0-.8 0-1.3-.2C3.5 3 3.5 1 0 0" fill="#303030"/>
|
||||
</g>
|
||||
<g transform="translate(583.1 141.4)" id="g8995">
|
||||
<path id="path8997" d="M0 0l.8-1.2 1.4 2.8-3.8 1 .7-1.3-1.3-.7a4.5 4.5 0 0 1-2-2c-.4-1-.2-2.4.5-3.4.4 0 .8 0 1.2.2C-3.3-3-3.3-1 0 0" fill="#303030"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Generator: Adobe Illustrator 22.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
||||
<svg version="1.1" id="svg9461" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
||||
viewBox="0 0 85.6 95.6" style="enable-background:new 0 0 85.6 95.6;" xml:space="preserve">
|
||||
<style type="text/css">
|
||||
.st0{fill:url(#path8773_1_);}
|
||||
.st1{clip-path:url(#SVGID_2_);}
|
||||
.st2{fill:#F2F2F2;}
|
||||
.st3{fill:url(#path8805_1_);}
|
||||
.st4{clip-path:url(#SVGID_4_);}
|
||||
.st5{fill:#393939;}
|
||||
.st6{fill:#98B6A7;}
|
||||
.st7{fill:url(#path8841_1_);}
|
||||
.st8{clip-path:url(#SVGID_6_);}
|
||||
.st9{fill:#6A6A6A;}
|
||||
.st10{fill:url(#path8875_1_);}
|
||||
.st11{clip-path:url(#SVGID_8_);}
|
||||
.st12{fill:#A9ABA9;}
|
||||
.st13{fill:#9B9B9B;}
|
||||
.st14{fill:url(#path8927_1_);}
|
||||
.st15{clip-path:url(#SVGID_10_);}
|
||||
.st16{fill:#818181;}
|
||||
.st17{fill:#FFFFFF;}
|
||||
.st18{clip-path:url(#SVGID_12_);}
|
||||
.st19{fill:#FFEE00;}
|
||||
.st20{fill:#D52715;}
|
||||
.st21{fill:#171714;}
|
||||
.st22{clip-path:url(#SVGID_14_);}
|
||||
.st23{fill:#303030;}
|
||||
</style>
|
||||
<g id="layer1" transform="translate(0 -268)">
|
||||
<g id="g10860" transform="translate(-20.8 -2)">
|
||||
<g id="g8755" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g id="g8757">
|
||||
<g id="g8763">
|
||||
<g id="g8765">
|
||||
|
||||
<linearGradient id="path8773_1_" gradientUnits="userSpaceOnUse" x1="-839.9431" y1="-715.001" x2="-838.9431" y2="-715.001" gradientTransform="matrix(0 -3.2193 3.3335 0 2933.3757 -2723.9758)">
|
||||
<stop offset="0" style="stop-color:#F2F2F2"/>
|
||||
<stop offset="1" style="stop-color:#7A7A7A"/>
|
||||
</linearGradient>
|
||||
<path id="path8773" class="st0" d="M490.2,93.1c-1.3,0-2.3-1-2.3-2.3V-24.8c0-1.1,0.8-2.3,2.3-2.3h119.9
|
||||
c1.1,0,1.9,1.1,1.9,2.3V90.9c0,1.1-0.8,2.3-1.9,2.3H490.2z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8775" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g>
|
||||
<defs>
|
||||
<rect id="SVGID_1_" x="14.3" y="967.1" width="1822.3" height="1528.7"/>
|
||||
</defs>
|
||||
<clipPath id="SVGID_2_">
|
||||
<use xlink:href="#SVGID_1_" style="overflow:visible;"/>
|
||||
</clipPath>
|
||||
<g id="g8777" class="st1">
|
||||
<g id="g8783" transform="translate(569.7 111.2)">
|
||||
<path id="path8785" class="st2" d="M-72.7-125.8H33.2c1.1,0,2.3-1.1,2.3-2.3v-43.1c0-1.5-1.1-2.3-2.3-2.3H-72.7
|
||||
c-1.1,0-2.3,0.8-2.3,2.3v43.1C-75-127-73.8-125.8-72.7-125.8"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8787" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g id="g8789">
|
||||
<g id="g8795">
|
||||
<g id="g8797">
|
||||
|
||||
<linearGradient id="path8805_1_" gradientUnits="userSpaceOnUse" x1="106.3515" y1="93.6155" x2="107.3515" y2="93.6155" gradientTransform="matrix(0 -0.7528 0.9518 0 460.8399 126.682)">
|
||||
<stop offset="0" style="stop-color:#A9ABA9"/>
|
||||
<stop offset="1" style="stop-color:#818181"/>
|
||||
</linearGradient>
|
||||
<path id="path8805" class="st3" d="M495.9,128.7c-1.3,0-2.3-1-2.3-2.3V42.1c0-1.1,1.1-2.3,2.3-2.3H604c1.1,0,2.3,1.1,2.3,2.3
|
||||
v84.3c0,1.1-1.1,2.3-2.3,2.3H495.9z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8807" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g>
|
||||
<defs>
|
||||
<rect id="SVGID_3_" x="14.3" y="967.1" width="1822.3" height="1528.7"/>
|
||||
</defs>
|
||||
<clipPath id="SVGID_4_">
|
||||
<use xlink:href="#SVGID_3_" style="overflow:visible;"/>
|
||||
</clipPath>
|
||||
<g id="g8809" class="st4">
|
||||
<g id="g8815" transform="translate(572.7 146)">
|
||||
<path id="path8817" class="st5" d="M-64.4-29h83.6c2.3,0,4.2-1.9,4.2-4.2v-47.3c0-2.3-1.9-3.8-3.8-3.8h-83.9
|
||||
c-2.3,0-4.2,1.5-4.2,3.8v47.6C-68.5-30.9-66.6-29-64.4-29"/>
|
||||
</g>
|
||||
<g id="g8819" transform="translate(574.4 145.4)">
|
||||
<path id="path8821" class="st6" d="M-59.6-30.7h71.1c1.5,0,3-1.5,3-3v-45.4c0-1.5-1.5-3-3-3h-71.1c-1.5,0-3,1.5-3,3v45.4
|
||||
C-62.7-32.2-61.1-30.7-59.6-30.7"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8823" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g id="g8825">
|
||||
<g id="g8831">
|
||||
<g id="g8833">
|
||||
|
||||
<linearGradient id="path8841_1_" gradientUnits="userSpaceOnUse" x1="-608.1827" y1="-894.7903" x2="-607.1827" y2="-894.7903" gradientTransform="matrix(0 -1.7861 7.5145 0 7273.7993 -1143.2354)">
|
||||
<stop offset="0" style="stop-color:#A9ABA9"/>
|
||||
<stop offset="1" style="stop-color:#535453"/>
|
||||
</linearGradient>
|
||||
<path id="path8841" class="st7" d="M494.7-35.8V-60c0-1.1,1.1-2.3,2.3-2.3h105.9c1.1,0,2.3,1.1,2.3,2.3v24.2H494.7z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8843" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g>
|
||||
<defs>
|
||||
<rect id="SVGID_5_" x="14.3" y="967.1" width="1822.3" height="1528.7"/>
|
||||
</defs>
|
||||
<clipPath id="SVGID_6_">
|
||||
<use xlink:href="#SVGID_5_" style="overflow:visible;"/>
|
||||
</clipPath>
|
||||
<g id="g8845" class="st8">
|
||||
<g id="g8851" transform="translate(581.7 109.3)">
|
||||
<path id="path8853" class="st9" d="M-39.3-131.1l-15.9,15.9v2.3H-59c-5.1,1-8.4,6-7.4,11.1c0.8,3.7,3.7,6.6,7.4,7.4h3.8v1.9
|
||||
l15.9,16.3h15.1l15.9-15.9v-2.3h3.8c5.2,0,9.5-4.2,9.5-9.5c0-5.2-4.2-9.5-9.5-9.5h-3.8v-1.9l-15.1-15.9H-39.3z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8855" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g id="g8857">
|
||||
<g id="g8863">
|
||||
<g id="g8865">
|
||||
|
||||
<linearGradient id="path8875_1_" gradientUnits="userSpaceOnUse" x1="-1182.8013" y1="-1084.7936" x2="-1181.8013" y2="-1084.7936" gradientTransform="matrix(0 17.201 -23.0721 0 -24479.207 20326.2344)">
|
||||
<stop offset="0" style="stop-color:#6A6A6A"/>
|
||||
<stop offset="0.5" style="stop-color:#48E400"/>
|
||||
<stop offset="1" style="stop-color:#6A6A6A"/>
|
||||
</linearGradient>
|
||||
<path id="path8875" class="st10" d="M542.4,33l-15.9-15.9v-2.3h-3.8c-5.2,0-9.5-4.2-9.5-9.5s4.2-9.5,9.5-9.5v0.4h3.8v-1.9
|
||||
l15.9-16.3h15.9l15.9,16.3v1.9h3.8c5.1,1.1,8.3,6.2,7.2,11.3c-0.8,3.7-3.8,6.6-7.5,7.2h-3.8v2.6L558.3,33H542.4z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8877" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g>
|
||||
<defs>
|
||||
<rect id="SVGID_7_" x="14.3" y="967.1" width="1822.3" height="1528.7"/>
|
||||
</defs>
|
||||
<clipPath id="SVGID_8_">
|
||||
<use xlink:href="#SVGID_7_" style="overflow:visible;"/>
|
||||
</clipPath>
|
||||
<g id="g8879" class="st11">
|
||||
<g id="g8885" transform="translate(576.4 118.4)">
|
||||
<path id="path8887" class="st12" d="M-54.1-105.8h11.3v-13.6h-11.3c-3.8,0-6.8,3-6.8,6.8C-60.9-108.9-57.8-105.8-54.1-105.8"
|
||||
/>
|
||||
</g>
|
||||
<g id="g8889" transform="translate(591 114.8)">
|
||||
<path id="path8891" class="st12" d="M-13.5-115.8h-11.3v13.6h11.3c3.8,0,6.8-3,6.8-6.8C-6.6-112.8-9.7-115.8-13.5-115.8"/>
|
||||
</g>
|
||||
<g id="g8893" transform="translate(582 118.4)">
|
||||
<path id="path8895" class="st5" d="M-38.5-105.8h13.6v-13.6h-14v13.6H-38.5"/>
|
||||
</g>
|
||||
<g id="g8897" transform="translate(581.9 123.2)">
|
||||
<path id="path8899" class="st12" d="M-38.8-92.5h14.4l10.6-11l-4.2-4.2v-7.6h-4.5v3.8c0,1.9-1.5,3.8-3.8,3.8h-11.3
|
||||
c-1.4,0.2-2.8-0.8-3-2.2c0-0.3,0-0.5,0-0.8v-5.3h-3.8v8.3L-49-103L-38.8-92.5z"/>
|
||||
</g>
|
||||
<g id="g8901" transform="translate(585.6 110)">
|
||||
<path id="path8903" class="st12" d="M-28.5-129.2h-14.4l-10.6,11l4.5,4.5v7.6h3.8v-4.2c0-1.9,1.9-3.8,3.8-3.8h12.1
|
||||
c1.9,0,3,1.5,3,3v5.3h4.2v-8.3l4.5-4.5L-28.5-129.2z"/>
|
||||
</g>
|
||||
<path id="path8905" class="st5" d="M548.4,61.7h3.4V46.2h-3.4V61.7z"/>
|
||||
<path id="path8907" class="st13" d="M548.4,46.6h3.4v-6.8h-3.4V46.6z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8909" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g id="g8911">
|
||||
<g id="g8917">
|
||||
<g id="g8919">
|
||||
|
||||
<linearGradient id="path8927_1_" gradientUnits="userSpaceOnUse" x1="-2168.2661" y1="-3506.5073" x2="-2167.2661" y2="-3506.5073" gradientTransform="matrix(0 0.8944 -0.4363 0 -979.787 1983.6796)">
|
||||
<stop offset="0" style="stop-color:#757575"/>
|
||||
<stop offset="1" style="stop-color:#393939"/>
|
||||
</linearGradient>
|
||||
<path id="path8927" class="st14" d="M548.4,39.8h3.4v6.8h-3.4V39.8z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8929" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g>
|
||||
<defs>
|
||||
<rect id="SVGID_9_" x="14.3" y="967.1" width="1822.3" height="1528.7"/>
|
||||
</defs>
|
||||
<clipPath id="SVGID_10_">
|
||||
<use xlink:href="#SVGID_9_" style="overflow:visible;"/>
|
||||
</clipPath>
|
||||
<g id="g8931" class="st15">
|
||||
<path id="path8937" class="st16" d="M548.4,39.8h3.4V33h-3.4V39.8z"/>
|
||||
<g id="g8939" transform="translate(571.2 125.6)">
|
||||
<path id="path8941" class="st12" d="M-68.5-85.8h26.5v-6.4l-6.4-6.8h-17.8c-1.1,0-2.3,1.1-2.3,2.3V-85.8z"/>
|
||||
</g>
|
||||
<path id="path8943" class="st17" d="M585.1-39.2h13.6v-14h-13.6V-39.2z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8945" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g>
|
||||
<defs>
|
||||
<rect id="SVGID_11_" x="589.5" y="-48.7" width="4.8" height="4.9"/>
|
||||
</defs>
|
||||
<clipPath id="SVGID_12_">
|
||||
<use xlink:href="#SVGID_11_" style="overflow:visible;"/>
|
||||
</clipPath>
|
||||
<g id="g8947" class="st18">
|
||||
<g id="g8953" transform="translate(596.4 103.2)">
|
||||
<path id="path8955" class="st19" d="M1.6-148.1v-1.1c-1.1-1.9-1.5-2.6-3-2.6l-1.1,0.8c-0.5-0.5-1.2-0.8-1.9-0.8
|
||||
c-0.4,0-0.8,0-1.1,0.8c-0.4-0.8-0.8-0.8-1.1-0.8H-9c-0.5,0-1,0.3-1.1,0.8l1.1,3.8h1.9l1.9,0.8l0.8-0.4H-3c0.4,0.4,1.1,0,1.5,0
|
||||
v-0.8l1.5,0.8l1.1-0.4L1.6-148.1 M-11.3-156H2.3v13.6h-13.6L-11.3-156z"/>
|
||||
</g>
|
||||
<g id="g8957" transform="translate(596.5 103)">
|
||||
<path id="path8959" class="st20" d="M1.8-148.6c0-0.8,0-1.1-0.8-1.9c0-0.8-1.1-1.5-2.3-1.5l-1.5,0.4c-0.5-0.3-1-0.4-1.5-0.4
|
||||
h-1.5c-0.5-0.1-1-0.1-1.5,0h-2.3c-0.8,0-1.1,0.4-1.5,1.1c0,1.5,0.8,2.6,1.5,3.8c0,0.8,0.8,0.8,1.5,0.8H0l1.9-0.4V-148.6
|
||||
M-11.4-156.2H2.2v13.6h-13.6V-156.2z"/>
|
||||
</g>
|
||||
<path id="path8961" class="st21" d="M598.7-53.2h-13.6v13.6h13.6V-53.2z M584.7-53.2h14v14h-13.6L584.7-53.2z"/>
|
||||
<g id="g8963" transform="translate(596.5 103.7)">
|
||||
<path id="path8965" class="st21" d="M1.8-146.7v-0.8V-146.7 M1.8-146.7v-0.8v0.4V-146.7z"/>
|
||||
</g>
|
||||
<g id="g8967" transform="translate(596 103.2)">
|
||||
<path id="path8969" class="st21" d="M0.5-148.1c-0.2-0.8-0.4-1.5-0.8-2.3h-0.4c0,0.8,0,1.5,0.8,2.3H0.5 M1.6-148.8l-1.1-1.5
|
||||
c0-0.8-0.8-1.5-1.1-1.5c-0.8,0-1.1,0-1.1,1.1l0.4,1.5c0.4,1.1,0.8,1.9,1.9,1.9s1.1-1.1,1.1-1.9 M-3.3-147.7v-0.4l-1.1-1.9
|
||||
l0.4-0.4l0.8,0.8c0,0.8,0,0.8,0.8,0.8s0.8-0.4,0.4-0.8c0-1.1-0.8-1.9-1.9-1.9c-0.6,0-1.1,0.5-1.1,1.1l0,0l0.8,1.9
|
||||
c0,0.8,0.8,1.5,1.9,1.5c0.8,0,1.1,0,1.1-0.8c0-0.4,0-0.8-0.8-0.8h-0.4v0.8 M-6.4-149.6v-0.8h1.1c0-0.8-0.8-1.1-1.1-1.1
|
||||
c-0.8,0-1.1,0.4-1.1,0.8c0,1.1,0,1.9,0.8,2.6c0,0.8,0.8,1.1,1.5,1.1l0.8-0.4c0-0.8,0-0.8-0.8-0.8h-0.4v-0.4
|
||||
c0.4,0,0.8,0,0.4-0.8L-6.4-149.6 M-8.6-150.4h0.8c0-0.8-0.4-1.1-1.1-1.1c0,0-0.8,0-0.8,0.8l1.1,3.4c0,0,0.4,0.4,0.8,0h0.4
|
||||
C-7.5-148.5-8.2-149.2-8.6-150.4 M0.5-146.6c-0.8,0-1.1,0-1.5-0.8l-1.5,0.8l-1.5-0.4l-1.1,0.4c-0.8,0-1.1,0-1.5-0.8v0.4
|
||||
l-1.1,0.4c-0.4,0-0.8,0-1.1-0.8c-0.4-1.1-1.1-2.3-1.1-3.8c0,0,0.4-0.8,1.1-0.8l1.1,0.4c0.4,0,0.8-0.4,1.5,0h2.3l1.9,0.4
|
||||
l1.5-0.8c1.1,0,1.9,1.1,2.3,2.3v1.5C1.6-147.4,1.1-146.8,0.5-146.6"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
<g id="g8971" transform="matrix(.35278 0 0 -.35278 -129 330.1)">
|
||||
<g>
|
||||
<defs>
|
||||
<rect id="SVGID_13_" x="14.3" y="967.1" width="1822.3" height="1528.7"/>
|
||||
</defs>
|
||||
<clipPath id="SVGID_14_">
|
||||
<use xlink:href="#SVGID_13_" style="overflow:visible;"/>
|
||||
</clipPath>
|
||||
<g id="g8973" class="st22">
|
||||
<g id="g8979" transform="translate(578 103)">
|
||||
<path id="path8981" class="st2" d="M-49.6-148.6v-1.1h-2.3l-0.4-0.4v-1.5h2.6v-1.5h-3.8l-0.8,0.8h-1.1l-0.4-0.4v-2.3h8.7v8.3
|
||||
h-8.7v-2.3h1.9v0.4H-49.6z"/>
|
||||
</g>
|
||||
<g id="g8983" transform="translate(576 103.6)">
|
||||
<path id="path8985" class="st2" d="M-55.2-147h-1.9l-0.4-0.4l-2.3-4.9l-3,4.9v0.4h-1.9c0,0-0.4,0,0-0.4l3.4-7.6l0.8-0.4h1.9
|
||||
l3.8,7.6L-55.2-147"/>
|
||||
</g>
|
||||
<g id="g8987" transform="translate(573 102.8)">
|
||||
<path id="path8989" class="st2" d="M-63.5-149.2h0.4v-1.5l-0.4-0.4h-5.7v-1.1h5.7l0.4-0.8v-1.5h-8.3v7.6l0.4,0.8h7.9v-1.5
|
||||
h-6.1v-1.5H-63.5z"/>
|
||||
</g>
|
||||
<g id="g8991" transform="translate(583.5 136.6)">
|
||||
<path id="path8993" class="st23" d="M-34.3-55.2l-3,4.9l-5.3-11l15.1-3.8c-1.9,1.9-1.9,2.6-3.4,4.9c1.9,0.4,3.8,1.5,5.3,2.6
|
||||
c3,1.5,5.7,3.8,7.6,7.2c1.5,4.6,0.6,9.7-2.3,13.6c-1.5,0-3,0-4.9-0.8C-21.1-43.8-21.1-51.4-34.3-55.2"/>
|
||||
</g>
|
||||
<g id="g8995" transform="translate(583.1 141.4)">
|
||||
<path id="path8997" class="st23" d="M-35.4-41.8l3-4.5l5.3,10.6L-41.5-32l2.6-4.9l-4.9-2.6c-3.3-1.6-5.9-4.3-7.6-7.6
|
||||
c-1.5-3.8-0.8-9.1,1.9-12.9c1.5,0,3,0,4.5,0.8C-47.9-53.2-47.9-45.6-35.4-41.8"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 12 KiB |
BIN
docs/static/favicon.ico
vendored
Normal file
After Width: | Height: | Size: 15 KiB |
BIN
docs/static/fll/code-js.gif
vendored
Normal file
After Width: | Height: | Size: 349 KiB |
BIN
docs/static/fll/context-help.jpg
vendored
Normal file
After Width: | Height: | Size: 42 KiB |
BIN
docs/static/fll/fll-big.png
vendored
Normal file
After Width: | Height: | Size: 4.4 KiB |
BIN
docs/static/fll/fll-logo.png
vendored
Normal file
After Width: | Height: | Size: 17 KiB |