Image for technical data about the BERO Robot electronics - APP

In-depth, technical data about the BERO Robot electronics – APP

Review in-depth, technical data about the BERO – Be The Robot electronics – APP.

January 31, 2013 – How the APP works

BERO SD Card Programming – Motion, Light and Sound  Control

Function Write Data String (FWDS)

Each function write data string (FWDS) will consist of a text string beginning with a header string “BERO1.0,” – 8 bytes and ending with tail string “RR,”+CRLF with all the data being comma delimited. The CRLF (ASCII 13 Dec or 0D Hex and ASCII 10 Dec or 0A Hex respectively) allows for later editing of need be using .CSV format. Between the header and tail strings are the Command Strings.

Each FWDS is 140 characters long and is padded for future commands and expansion in order to ensure that it is played back with proper timing. Each FWDS plays back at a fixed time as well as the playback of each FWDS is initiated at a fixed time interval so that strings do not play back faster than others. The onboard system on a chip interpolates the commands to provide smooth motions and quick actions.

The FWDS is send out to BERO from the smartphone at 5 times per second as well as being read from the SD card at 5 times per second.

Each function read data string (FRDS) will consist of a text string beginning with a header string “BERO10OK,” – 9 bytes and ending with tail string “RR,” Between the header and tail strings are Data Receive Strings.

The total length of a FRDS is 50 bytes.


The FWDS are played back at the same time, so that the time between T1, T2, T3…is always the same. This ensures that the motion control timing of BERO will always be the same.

A FWDS is sent to BERO. After BERO responds with a FRDS to indicate the command was received as well as to send back any required data. The FRDS is also comma delimited.

Each string played back in correlation to a sound file or to a fixed time so that predictable motions can be created with BERO.

Commands sent to BERO from Smartphone/SD Card

The below Command Data Strings (CDS) are stored sequentially in the FWDS. They will always be transmitted in the following sequence.

1,2) Sounds playback – 16 bytes


Filename: 8 byte filename for a .WAV file (non case sensitive) – must be alphanumeric and preferably 8k sampling rate for the .WAV file and also must be stored on the SD card of BERO.


Filename: filename doesn’t matter, but it still reads a dummy set of characters to maintain the playback timing.

Command: “PLAYPLAY”+ filename

Continue the play the same filename and do nothing.

3) Left Arm – 8 bytes


Direction: “+” or “-“

Value:000 to 300.

If the direction is “+” then the arm swings forward first towards the back from its current position.

4) Right Arm – 8 bytes

The opposite applies as for the left arm.


Direction: “+” or “-“

Value:000 to 300

5) Head – 8 bytes


Direction: “+” or “-“

“+”=to the right

“-“=to the left

Value:”000” to “090”

Example: “HEAD-000” or “HEAD+090”

6) TILT – 8 bytes



Direction: “+” or “-“

“+”=to the right

“-“=to the left

Value:”000” to “015”

Example: “TILT-000” or “TILT-015”

Drive Train – 8 bytes

7) Command:”DRVL”+direction+value (left track)

8) Command:”DRVR”+direction+value (right track)

Direction: “+” or “-“



Value:”000” to “100”

Example: “DRVL-000” or “DRVR+100”

The Value from 000 to 100 indicates the PWM for the drive motor.

LED Lights – EYES – 8 bytes

9) Command:”LEDL”+value (left LED) + “X”

10) Command:”LEDR”+value (right LED) +”X”

Value:”000” to “999”

Defines the LED intensity LED. 000 – all OFF, 999 – all ON, in between it’s the LED intensity.


LEDL:0000 (all three LEDs if OFF on left side)

LEDL:9990 (all three LED is ON for left side)

LEDR:0000 (all three LEDs if OFF on right side)

LEDR:9990 (all three LED is ON for rightside)

11) LED headphones– 8 bytes


ntensity:00 to 99 – determines the brighness of the current color chosen. Changing this value to 00 means nothing is ON, 99 means this LED at full PWM

Value:”00” to “99”

Example: “LEDANT99” – LED is at maximum brighness

12) Infrared Obstacle Avoidance – 8 bytes


State:0 – OFF

State: 1 – hardware IR Radar Enabled (auto detection and avoidance)

State: 2 – software IR Radar enabled (returns a value and the Android/SD card program needs to react to the obstacle)

Example: “IRRADAR1” – hardware IR Radar Enabled

November 14, 2012 – The Addition of pads to allow for the use of a BLE module

White we were at it, we also modified the PCB a bit to be more friendly for accepting a Bluetooth 4.0 (Bluetooth Low Energy) module.

We submitted the initial draft of the project plan for MFI Approval weeks ago, and found out that it needs more information, so that is being provided as well as working samples to Apple in a week. Fingers crossed we get the project plan approved in a few weeks. And if it takes longer, well that is where we decided to also implement a plan B and make the current PCB friendly for accepting the BLE module (which works with all the new iOS devices from the iphone 4s and onwards).

October 31, 2012 – The PCB layout

Below is a picture of how the layout of the PCB looks and all of its 8 glorious layers.

The BERO Brains

The APP behind BERO’s brain is also progressing. Below are some of the screen shots of the APP development for being able to control BERO.

BERO APP Splash Screen

BERO Dashboard

BERO APP showing the motions for recording/playing back/storing animations.

What’s under the hood?

Below are a couple pics showing you how the PCB layout looks like and what component we have used. In a nutshell, the system on a chip (SOC) handles the routines for the Bluetooth module (115kpbs), SD card, sound file playback, the variable resistors and the motor driver (800mAh per channel) via the onboard firmware.

Through the SOC, the 4 motors with variable resistors act as servos and WAV sound files are effortlessly played back for smooth sound, lights and motion animations! We thought about using an ATMEL IC for this in the beginning, but this one had a lot more bang for the buck. So, through he SPI port, the SOC can easily be hacked and controlled, just like a jockey riding a horse, by adding an Arduino based controller.

From our past week I thought I would share some screen caps of the PCB layout that we are using for BERO. Not sure how many of you this kinda stuff excites, but whenever I see these, they always look like art to me. Computer art. They are like the wires in a brain, created by use and mastered by a computer. Dunno if you have ever seen how these are created, but its pretty cool when ICs are dragged around on a computer screen and dropped in place to see whether the PCB layout program can make the connections work, kinda like neurons in a brain. Anyways, enough about that, let’s see some “artwork.”

Here’s the bottom PCB layout.

FLASH program memory on the top, SOC master brain in the middle, SPI port on the bottom, 7th BONUS motor driver output port on the side.


Share on Google+Share on FacebookShare on LinkedInTweet about this on TwitterShare on TumblrPin on PinterestEmail this to someone

Tags: , , , , , , , , , , , , , , , , , , , ,