Book Image

Banana Pro Blueprints

By : Tony Zhang
Book Image

Banana Pro Blueprints

By: Tony Zhang

Overview of this book

This book follows a tactical plan that will guide you through the implementation of Banana Pro and its configurations. You will then learn the various programming languages used with Banana Pi with the help of examples. In no time at all, you’ll be working on a wireless project that implements AirPlay servers, hotspots, and so on. Following this, you’ll develop a retro-style arcade kiosk game. Then we’ll move on to explore the multimedia features of Banana Pro by designing and building an enclosure for it. After this, you’ll learn to build a remote-controlled smart car and we’ll examine how to control a robotic arm. The book will conclude with the creation of a home sensor system that has the ability to expand or shrink to suit any home.
Table of Contents (15 chapters)
Banana Pro Blueprints
About the Authors
About the Reviewers


The book mainly focuses on some popular applications and projects using Banana Pro. It first introduces the basic usage of Banana Pro, including its hardware and software, and then some applications, such as a multimedia center and laser engraver. The sole purpose of this book will be to show what you can do with Banana Pro through a number of projects, ranging from home automation projects, cameras around the house, and robotics.

This book follows a tactical plan that will guide you through the implementation of Banana Pro and its configurations. You will then learn the various programming languages used with Banana Pi with the help of in-depth examples.

What this book covers

Chapter 1, Introduction to Banana Pro, introduces the Banana Pro single board computer. It explains all its available interfaces as well as the installation of the Linux OS, which will be used in this book.

Chapter 2, Programming Languages, explains several programming languages, such as Python, C/C++, and Scratch. In several examples, the usage of these programming languages is shown through a step-by-step approach.

Chapter 3, Wireless Projects, introduces wireless projects. It shows how Banana Pro can be used as a wireless hotspot or print server. Additionally, the serving of web pages is explained in combination with content management systems. Finally, a measurement server is set up in order to control an electronic circuit.

Chapter 4, An Arcade Cabinet, describes how to turn Banana Pro into an arcade cabinet. A step-by-step approach shows you how to install and configure different game emulations. This chapter also describes the steps required to set up a cabinet house with the help of a joystick and an LCD display for Banana Pro.

Chapter 5, A Multimedia Center, introduces the usage of Banana Pro as a multimedia center. You will be shown how a DVB receiver is set up through a series of steps. This receiver allows the recording of TV transmissions, watching DVDs, and listening to audio CDs.

Chapter 6, Remote Controlling a Smart Monitor Car, teaches you how to make a small mobile car with the remote monitor function. It describes how to realize the IP camera function on Banana Pro. It also shows you how to set up a small mobile car. Finally, you will see how a web page can be used to control the car and view the video of the camera in the car.

Chapter 7, A Laser Engraver, shows the laser engraver made by Banana Pro along with a laser CPU. You will learn how to design the frame of the laser engraver and use different kinds of software on the Banana Pro. The laser CPU and PC can be used together to engrave patterns on some special types of material such as cardboard.

Chapter 8, Scratch—Building a Smart House, describes how to use Scratch and some other GPIO libraries together to control different sensors. Then, you will learn how to combine all the sensors together in a virtual small house to simulate the smart house.

What you need for this book

You would need Banana Pro, an SD card (a minimum of 4 GB is recommended), an AC plug, a hard disk drive, and a USB DVB receiver (optional).

Who this book is for

This book is for all embedded board enthusiasts who want to use their credit-card-sized computer boards for extraordinary projects. An example of LeMaker's Banana Pro computer as a home entertainment center or a arcade cabinet is described in a step-by-step approach. Get the most out of your embedded board using it in your daily lives or for challenging projects. This book is the perfect guide for these purposes.


In this book, you will find a number of text styles that distinguish between different kinds of information. Here are some examples of these styles and an explanation of their meaning.

Code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles are shown as follows: "On a wired connection, it can be read from the eth0 section by typing the sudo ifconfig command in a shell."

A block of code is set as follows:

#include <stdio.h>
double div(double a, double b)

int main(void)
int a;

    for (a=4; a>0; a--)
printf("10:%d = %lf\n", a, div(10,a));
    return 0;

When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:

ARCH = arm
PLATFORM = generic
PLUGINS = plugins/spunull/ plugins/dfxvideo/ plugins/gpu_unai/ plugins/gpu-gles/

Any command-line input or output is written as follows:

sudo /etc/init.d/ssh start
sudo /etc/init.d/ssh stop

New terms and important words are shown in bold. Words that you see on the screen, for example, in menus or dialog boxes, appear in the text like this: "Go to Scratch-UI-Panes | ScratchFrameMorph | menu/button actions | addServerCommandTo."


Warnings or important notes appear in a box like this.


Tips and tricks appear like this.

Reader feedback

Feedback from our readers is always welcome. Let us know what you think about this book—what you liked or disliked. Reader feedback is important for us as it helps us develop titles that you will really get the most out of.

To send us general feedback, simply e-mail , and mention the book's title in the subject of your message.

If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, see our author guide at

Customer support

Now that you are the proud owner of a Packt book, we have a number of things to help you to get the most from your purchase.

Downloading the example code

You can download the example code files from your account at for all the Packt Publishing books you have purchased. If you purchased this book elsewhere, you can visit and register to have the files e-mailed directly to you.

Downloading the color images of this book

We also provide you with a PDF file that has color images of the screenshots/diagrams used in this book. The color images will help you better understand the changes in the output. You can download this file from:


Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you find a mistake in one of our books—maybe a mistake in the text or the code—we would be grateful if you could report this to us. By doing so, you can save other readers from frustration and help us improve subsequent versions of this book. If you find any errata, please report them by visiting, selecting your book, clicking on the Errata Submission Form link, and entering the details of your errata. Once your errata are verified, your submission will be accepted and the errata will be uploaded to our website or added to any list of existing errata under the Errata section of that title.

To view the previously submitted errata, go to and enter the name of the book in the search field. The required information will appear under the Errata section.


Piracy of copyrighted material on the Internet is an ongoing problem across all media. At Packt, we take the protection of our copyright and licenses very seriously. If you come across any illegal copies of our works in any form on the Internet, please provide us with the location address or website name immediately so that we can pursue a remedy.

Please contact us at with a link to the suspected pirated material.

We appreciate your help in protecting our authors and our ability to bring you valuable content.


If you have a problem with any aspect of this book, you can contact us at , and we will do our best to address the problem.