The Zubi Flyer bridges virtual and physical worlds. Using free open-source development environments you can easily write commands and scripts that turn your Zubi Flyer into an interactive controller. Using drag and drop Scratch Blocks or real code with the Arduino development environment you can program and share interactive media such as stories, games, and animation with people from all over the world.
First, you will need to setup your Zubi Flyer to code using Arduino.
This is the same setup required to modify the 12 fun games that come pre-installed on your Zubi Flyer.
If you have already competed this setup - in other words, you have already opened Arduino and uploaded modified code to your Zubi Flyer printed circuit board - you can jump on over to the next step, 1.2.
Otherwise, CLICK HERE for the Fuze Install Kit that will allow you to code your Zubi Flyer with Arduino!
Second, to use your Zubi Flyer with Scratch you will need to setup the FuzePlay ScratchX Extension AND upload special code to your Zubi Flyer using Arduino.
CLICK HERE for instructions on setting up the FuzePlay ScratchX Extension.
Hat blocks are the blocks that start every script. They are shaped with a rounded top and a bump at the bottom — this is so you can only place blocks below them. There are 11 Hat blocks, six of which are in the Events category, one in the Control category, and four More hat blocks.
Stack blocks are the blocks that perform the main commands. They are shaped with a notch at the top and a bump on the bottom — this is so blocks can be placed above and below them. There are 77 Stack blocks — the most common block shape.
Boolean blocks are the conditions — they are either true or false. It's like asking your friend: "Does 2 + 2 = 4?", and they would either tell you "Yes" or "No". With a hexagonal shape, there are 13 of these blocks.
Reporter blocks are the values. Reporter blocks can hold numbers and strings. It is like asking a friend, for example, "What is 2 + 2?", and they would answer "4". It is not just equations however, it can report a variable, for example, "What is your age?". They may answer: "15". Shaped with rounded edges, there are 37 of these blocks — not counting the theoretically infinite amount of Reporter blocks that can be made for each variable and list.
C blocks are blocks that take the shape of "C's". Also known as "Wrap blocks", these blocks loop the blocks within the Cs or check if a condition is true. There are five C blocks, and they can be found in the Control category. C blocks can be bumped at the bottom, or capped.
Cap blocks are the blocks that end scripts. They are shaped with a notch at the top and a flat bottom — this is so you cannot place any blocks below them. There are two Cap blocks which can both be found in the Control category.
*Because the FuzePlay ScratchX Extension is in beta, you must use a Safari browser.
Confirm your Zubi Flyer board is connected by plugging it into the USB port on your computer. You should see the Zubi Flyer light turn from Yellow > Green.
As long as you seen a green dot on your screen your Zubi Flyer will be communicating with Scratch. Anything you do online will be programmed to your board!!
Notice the 'More Blocks' section. These blocks are specific to your Zubi Flyer. We will come back to them in a minute!
Before we drag and drop blocks - add our Sprite. In this case we have added two!
The Sprite labeled as #1 was added from a file we had on our computer. Sprite #2 was added directly from Scratch. Try whichever seems like more fun for you!
Make sure you pay attention which Sprite is selected. You will drop blocks for the selected Sprite since each sprite is controlled independently.
In this example our Dinosaur Sprite is selected and blocks have been dropped commanding it to say, "Hello FuzePlay!"
In Scratch the Looks Blocks are the most widely used out of all the blocks!
We wanted to say, "Hello," so w dragged in the 'Say Hello!' block. Notice you can change 'Hello!' to whatever you want. We added 'Hello Fuze Play!'.
Because we wanted to create greeting, we wanted our Dinosaur to say hello 'forever'. To do this we dragged a 'forever' block from the Control Block category in Scratch.
In this example we added one more block! We really did . . .
We only wanted our greeting to take place when the Zubi Flyer PCB was plugged in and part of the party!!
We dragged a Hat Block that causes everything under it to start - in this case the script will start when the Zubi Flyer 'device is connected' (ie Zubi Flyer circle is GREEN, not YELLOW).
In 'More Blocks' find the 'read light sensor' reporter block.
Drag this block and replace 'Hello Fuze Play!'.
You should see our Dinosaur friend being to report the amount of light hitting the photocell our your Zubi Flyer. Try using your hand to cover up the sensor and watching the number change!
Let's have our Dinosaur do a little dance.
Drag over a few sound blocks for fun. There are thirteen to chose from. Our pick was the drum #1 for the first block and drum #2 for the second. We decided to have each drum play for half a beat.
Make sure to connect each drum beat by stacking them on top of each other.
It doesn't matter which block you add first. In this example we added the motion blocks second.
There are seventeen motion block to choose from. This dance is going to be simple - a step forward and a step back with a drum beat in between.
Drag the 'move 10 steps' Motion Block between the two Sound Blocks. Then drag another Motion Block and stack beneath the second Sound Block.
Notice a couple things:
We changed the number of steps from '10' to '30' so it is visually more obvious.
This is a dance (step forward, step back), so we changed the second step to '-30'. The second step is negative, indicating it is a step backward, not another step forward.
Click on the block set you just created to run the script.
Click back to More Blocks.
We want our dance to be triggered by the photocell light sensor. We dragged in a Hat Block that will trigger a series of blocks if the light sensor is above or below a reading you set.
Since we are in a very bright room, after testing by waving our hand we set the code to run if the light sensor drops below 70% (the light sensor will show a reading 0-100).
After each drum beat we wanted the LEDs on the Zubi Flyer to change color. You can see one is set to change to red, and the other blue. The last block turns all LEDs off until the script is triggered again!
Lastly, we dragged in a two Control Blocks to create a delay that would allow us to see the light colors longer.
To control a new Sprite you will need to click into that Sprite.
We added a quick stack of code blocks you can easy add using the instructions above.
Now, by pressing the triangle button OR by using the reed switch next to the triangle button Zubi will do a dance and then all lights on the Zubi Flyer printed circuit board will turn bright white.
Wave your hand over the photocell and our Dinosaur will come to life changing the colors again.
Click HERE for the Fuze Install Kit
Click HERE to beta the Fuze ScratchX Extension
The Zubi Flyer is the bomb dot com for makers: 5 PWM pins, 12 DIOs as well as hardware serial connections Rx and Tx. Running at 16MHz and 5V. The onboard switch-mode boost regulator is designed to operate on 3 Volts. Power can be supplied from a 3 Volt CR123A battery or from a USB cable that provides regulated +5 Volts DC to the board. Do not run any power exceeding 5 Volts as the regulator cannot handle step-down voltage.
learn how stuff works!