Some edits to the 'light monster' project
This commit is contained in:
parent
efda8290cf
commit
e8eb7a9d4e
@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
# Light Monster
|
# Light Monster
|
||||||
|
|
||||||
## @description A monster made of cardboard that responds to light
|
## @description A monster made of coffee cups that responds to light
|
||||||
|
|
||||||
## ~avatar avatar
|
## ~avatar avatar
|
||||||
|
|
||||||
@ -28,7 +28,7 @@ https://youtu.be/BiZLjugXMbM
|
|||||||
|
|
||||||
## Preparation
|
## Preparation
|
||||||
|
|
||||||
* [Equip the microservo with crocodile clips](/device/servo)
|
* [Setup the microservo with crocodile clips](/device/servo)
|
||||||
|
|
||||||
## Activities
|
## Activities
|
||||||
|
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
# Code
|
# Code
|
||||||
## @description code to make the coffee cup monster alive
|
|
||||||
|
## @description Code to make the light monster come alive
|
||||||
|
|
||||||
## ~avatar avatar
|
## ~avatar avatar
|
||||||
|
|
||||||
@ -9,8 +10,7 @@ Add code to open the mouth when light is detected.
|
|||||||
|
|
||||||
## Duration: ~30 minutes
|
## Duration: ~30 minutes
|
||||||
|
|
||||||
We are going to add code to open the mouth proportionally to the amount of light on the @boardname@.
|
We are going to add code to open the mouth proportionally to the amount of light on the @boardname@. The code is in a loop so we'll continually read the light level and map it to an angle using the ``||pins:map||`` function.
|
||||||
In a loop, we will read the light and map it to an angle using the ``pins.map`` function.
|
|
||||||
|
|
||||||
```blocks
|
```blocks
|
||||||
basic.forever(() => {
|
basic.forever(() => {
|
||||||
|
@ -8,9 +8,7 @@ Remote control your monster with another @boardname@
|
|||||||
|
|
||||||
## Duration: ~30 minutes
|
## Duration: ~30 minutes
|
||||||
|
|
||||||
You will need 2 @boardname@ for this part. By using the radio, we can make the inchworm controlled by another @boardname@.
|
In order for the light monster to move, the @boardname@ needs to command the servo to move between ``0`` and ``180`` degrees at a certain pace. The code below starts the inchworm moving when the **A** button is pressed.
|
||||||
Download the code below to the @boardname@ on the inchworm and another "controller" @boardname@.
|
|
||||||
Whenere A is pressed, the monster will open and close it's mouth will move once.
|
|
||||||
|
|
||||||
```blocks
|
```blocks
|
||||||
radio.onDataPacketReceived(({receivedNumber}) => {
|
radio.onDataPacketReceived(({receivedNumber}) => {
|
||||||
|
@ -1,25 +1,27 @@
|
|||||||
# Make
|
# Make
|
||||||
|
|
||||||
## @description Building the light monster
|
## @description Building the light monster
|
||||||
|
|
||||||
## ~avatar avatar
|
## ~avatar avatar
|
||||||
|
|
||||||
Turn a piece of coffee holders into a monster!
|
Turn some coffee cups into a monster that moves to light!
|
||||||
|
|
||||||
## ~
|
## ~
|
||||||
|
|
||||||
## Duration: ~60 minutes
|
## Duration: ~60 minutes
|
||||||
|
|
||||||
## Materials
|
## Materials
|
||||||
* 3 Coffee cup holders
|
|
||||||
* 2 Coffee cup strirer wood sticks
|
|
||||||
* Scissors
|
|
||||||
* glue gun or tape
|
|
||||||
* 1 paper clip
|
|
||||||
|
|
||||||
## Step 1: cardboard
|
* 3 coffee cup holders
|
||||||
|
* 2 ood coffee strirer sticks
|
||||||
|
* scissors
|
||||||
|
* glue gun or tape
|
||||||
|
* 1 paper clip
|
||||||
|
|
||||||
|
## Step 1: Glue the cups and sticks together
|
||||||
|
|
||||||
TODO
|
TODO
|
||||||
|
|
||||||
## ~button /projects/coffee-cup-monster/code
|
## ~button /projects/light-monster/code
|
||||||
NEXT: Code
|
NEXT: Code
|
||||||
## ~
|
## ~
|
Loading…
x
Reference in New Issue
Block a user