0% found this document useful (0 votes)
637 views53 pages

Ottoblockly Manual

Otto Blockly guide summarizes in 3 sentences: The guide introduces Otto Blockly, a block programming environment for coding a robot named Otto. It covers setting up the software, familiarizing with the block programming, and completing simple and complex projects like programming a dance or interacting with sensors. The guide also discusses uploading code to Otto in different ways using Otto Blockly Standalone, the online web app, or Arduino IDE.

Uploaded by

Audrey Berlian
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
637 views53 pages

Ottoblockly Manual

Otto Blockly guide summarizes in 3 sentences: The guide introduces Otto Blockly, a block programming environment for coding a robot named Otto. It covers setting up the software, familiarizing with the block programming, and completing simple and complex projects like programming a dance or interacting with sensors. The guide also discusses uploading code to Otto in different ways using Otto Blockly Standalone, the online web app, or Arduino IDE.

Uploaded by

Audrey Berlian
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 53

Otto

Blockly
guide
Code your own robot
- Setup and installation of software
- Familiarize with the block programming
environment.
- First simple projects, like
programming a dance with Otto.
- Learn the concept of sequential
thinking and conditionals.
- Make a more complex project, interact
with sensors, use advance programming.

Did you read this guide?


Uploading a code, there are 3 ways...

Otto Blockly Standalone: Online Web App, works Arduino IDE: Works
Works offline, easy to use, from browser but you still offline compatible with all
all in one coding & USB need to install an OS, is a more advanced
upload (No need Arduino) extension or Arduino coding
Otto Blockly Otto Scratch AI
Standalone Windows Server based

● It can be installed locally and ● Needs internet connection.


therefore work without internet. ● It can’t upload code but you can
● It can upload code via USB. interact with any Otto robot via BLE
● Lots of blocks to control all kinds of (Bluetooth) instantaneously.
sensors, boards, lights, screens, ● Blocks to control basic functions of
audio, cameras, motors and more. Otto but with AI extensions.
● It can preview and edit text code. ● It have a stage simulator.
● No need to install libraries. ● Only need to upload one code, one
● It has an “online version” too but that time and that will enable live
one can’t upload code you need to coding
copy the generated code to Arduino.
Download
Otto Blockly
*sometimes windows defender or antivirus
might tell you the software is not safe,
just proceed to keep it and open it.
Install
Install USB Driver
Some computers automatically recognize Otto as a
USB device when is connected, but some do not.
If your computer did not recognize the USB device
you need to download and install the USB driver:

USB serial CH340, download it here


This guide covers all OS step by step
or
FT232 USB UART download it here
This guide covers step by step
User interface of
Otto Blockly
Levels Language Examples Board USB port Upload About Serial

Drag, Drop & Connect


Preview
Workspace Arduino code

Blocks

Toolbar
Quick start test
Hi Otto Builder
I am back, ready to help you.
1 Let’s open an example by
clicking the hat button.

2 Select the “Dance” example.


If you are
adventurous
choose a different
example like Walk
3 Connect your robot and
make sure the COM# is
selected in the USB port
dropdown menu*

*If nothing appears then


the USB driver was not
properly installed in your
computer you must restart
your computer and try
again.
4 Click in the upload button.

The upload process should


take less than a minute.
4 Ifmeans
this error appears that
the Arduino Nano*
board is not correct, then try
selecting Arduino Nano (old
bootloader) instead and
click upload again.

Oops! no worries we
can fix that
*Nano boards come with a
different “bootloader”
therefore they use different
settings for uploading but both
work exactly the same in Otto
robots
5 Itupload
only takes few seconds to
the code successfully
when the right board is
selected.

This means your code was


uploaded to Otto! and your
robot should be dancing
now.

Yay you did it congrats!


see you later
Common issues
Otto doesn’t appear connected?
install the CH340 or FTDI USB driver to see the
COM port.

Can't upload code?


Wrong board selected (try Arduino Nano old
bootloader or Arduino Nano) or USB cable

Does Otto reset every now and then?


Low quality batteries or bad connections.

Are Otto legs and feet twisted?


Make sure you centered and aligned your servos
when assembling.

If you do not find answer to your issue, ask for help in the community
Otto Blockly Web App (Alternative for Mac)
Otto Blockly is also a web tool.
Go to this link in a Chrome browser

You can use it from any operative system


including Linux and Chromebooks.

But first you will need to do an initial


setup following the steps here

The USB device will be recognized by


Chrome browser and you can upload code
directly from the browser!
Use the Arduino code
If you had problems setting up online uploading
you can always just download the code or copy
an use it as a normal Arduino code!

Click the save button, that will quickly download


the .ino file

This is also a way to convert blocks into actual code


that you can save and share to other Arduino
projects.
Open the generated code in Arduino
You can open directly the file or open Arduino IDE and paste the code into it.
(follow the setup guide for Arduino in this link)
Check the settings (same as in Otto Blockly)
1) Select tools from menu bar
2) For Board select “Arduino Nano”
3) For Processor select “Atmega328P” (choose Old bootloader if error)
4) For Port select the COM USB where your Otto is connected
Upload the Code to Otto
Once verified you are able to upload the code to Otto.

Lastly select the arrow pointing to the right to upload.

We basically just created a code in C++ for Arduino without actually typing
any line of code!. Your Otto is now a walking dancing machine!
Now let’s learn the
Basics
Levels & Language
Help us improve
and add new
Languages here
Structure Otto Sensors Displays

Math Logic Variable Function

Audio Text Motor Time

IoT Cameras Communication


�� Level 1
Beginner Toolbar with all main Otto movements

Structure: Setup and Loop main brackets for the program.


Otto: Movements, sounds and gestures.
Sensors: Ultrasound, touch, sound and gyro.
LED Eyes: I2C 16x8 Matrix .
LED Mouth: SPI 8x8 Matrix.

Time: Used to delimit the program over time.


Input/Output: Full control of Arduino GPIO ports
Logic: Create conditionals, repetitions and logic programming.
Math: Make calculations or insert numbers.
Functions: create a procedure that can be repeated.
Variable: A named value that can be changed.
��💻 Level 2
Advanced Toolbar with blocks for endless Arduino projects

Sensing: All sort of sensors that can be added to Otto or to


create other Arduino projects,

Motor: Control all kinds of servos steppers and dc motors

LED: RGB, Neopixels and LED matrix.


Displays: LCD, OLED and other screens.
Audio: emit a sound with a buzzeror play mp3 songs
Communication: with modules. Bluetooth, IrDa or Serial.
Keyboard and Mouse: (only for Arduino Leonardo and Micro)
MuVision: Video recording or more advanced Face recognition
Setup / Loop
First click Structure on the right side menu bar.

We will start with the Setup / Loop block

Loop opens and ends a function sequence and it


keeps repeating forever.

If you want to run your code only once use the


Setup brackets.

The setup bracket is also to initialize components.


Drag & drop blocks
From toolbar select Otto, drag from the list of blocks always the configuration
block into the setup bracket and any other block into the loop structure.
Walk before Run
Walk in blocks Walk in C++ code

Otto.walk(1,1000,1);
Can you make Otto
run?
Otto.walk(1,500,1);
Example in Blockly to
Servos wiring
control each motor
Add or duplicate one
more Servo block and a
Time delay

What happens now?


Dance Time!
Make your own dance!
Drag & drop more Otto blocks.

Otto.walk(2,1000,1);
move function (“#steps, Time[ms],
direction”)

Otto.tiptoeSwing(2, 1000, 25);


Otto.moonwalker(5, 1000, 40, 1);
Otto.moonwalker(5, 1000, 40, -1);
Otto.crusaito(5, 1000, 40, 1);
(steps,Time[ms],moveSize,direction);
Can Otto talk?
Piezo Buzzer
It is an actuator used to generate sound,
beep or even make the melody of a song.

Otto can’t talk but he can create sounds


related to his emotions similar to R2D2.

Make sure to identify the positive mark


and connect in the right pin.

Passive type.
PWM GND
Wiring
Compared to other components there are
only 2 pins/cables one goes to GND and
the one with the + sign in the top, we
connect to the signal pin 13.

You can see compared to the parts we


use before this one no need V.
Sound block
You have 19 different predefined sounds
related to emoji emotions. In Arduino code
is translated like this:

Otto.sing(S_superHappy);
sing function (“sound to make”)

(S_surprise); (S_OhOoh); (S_OhOoh2);


(S_cuddly); (S_sleeping); (S_happy);
(S_happy_short); (S_sad); (S_confused);
(S_buttonPushed); (S_fart1)...
What is a gesture?
Otto.playGesture(OttoLove);
play Gesture function (“emotion/mood”)

Otto.playGesture(OttoSuperHappy);
Otto.playGesture(OttoSad);
Otto.playGesture(OttoSleeping);
Movements + Otto.playGesture(OttoConfused);
sounds Otto.playGesture(OttoAngry);
Otto.playGesture(OttoMagic);
to generate Otto.playGesture(OttoWave);
emotions or Otto.playGesture(OttoVictory);
moods. Otto.playGesture(OttoFail);
Otto.playGesture(OttoFart);
How does Otto
“see”?
Ultrasonic Sensor
It is used to measure the
distance to an object by using
ultrasonic waves, have 4 pins:

VCC (Power), GND (Ground)


TRIG receives the control signal
ECHO sends a signal (pulse)

By measuring the duration of


pulse we can calculate the
distance.
Otto can avoid
obstacles!
Avoid example
Measure distance
1. Go to examples/ serial
measure distance.
2. Then click Upload
3. Then open the serial monitor
by clicking on the top right
corner “search icon”.

You must keep Otto connected to


USB
Serial Monitor
In the this Serial monitor window click start.

From here you will be able to see the distance


measured by the sensor in centimeters.

Test it out by putting your hand closer and farther


away from Otto.

You can use a ruler or a measure tape to see how


precise it is.
Play with other components
You can add Arms, all kinds of sensors, LED matrix, OLED
displays and more, the limit is in your imagination!
Otto Scratch AI (Artificial intelligence online)
Otto Scratch AI extensions
What will you
make / code / design?
Share your creations
in our community!

🤗
builders.ottodiy.com

You might also like