A Banana Pi-based router


Before operating the WiFi network, you have a tricky task to perform. The cable for the WiFi antennae needs to be connected. The white sticker in Figure 3 is smaller than a US dime. You should press open the small pigtails of the antenna cable from above. A small book can serve to protect the board from damage.

Figure 3: Connecting the cables for the WiFi antennae requires some skill and a steady hand.

The wireless communication is presently a weak point of the router, because the integrated chip does not work with the access point program hostapd. Luckily, you can find the source code for a working version of hostapd on the Realtek website. An entry in the forum describes in detail the steps required to generate the two binaries, hostapd and hostapd_cli [8].

You should install the compiler and other necessary tools for the build via the metapackage build-essential. The program is saved to the directory /usr/local/sbin. By issuing the command

$ sudo apt-get -y install hostapd

you will install the hostapd package as well as a series of necessary files. Because the version of hostapd you have pulled down does not work, you have to change the path within /etc/init.d/hostapd from /usr/sbin/hostapd to /usr/local/sbin/hostapd.

In the next step, you will be modifying the configuration of hostapd. The corresponding configuration file can be saved wherever you like in the filesystem, but it must be referenced by the file /etc/defaults/hostapd. Listing 8 shows a simple example of a configuration that uses the WiFi network as a separate network. To run a test, you should start the access point manually:

Listing 8

WiFi Configuration

$ sudo /etc/init.d/hostapd start

To specify an automatic start, you can use the following command:

sudo insserv hostapd

The WiFi network will be its own network, or it will be a part of a bridge with the cable network as needed. The theoretical average payload rate attainable by the R1 ranges from about 120Mbps to 50Mbps. The numbers vary a great deal, especially with dependencies from wireless networks located nearby. When in idle mode, operation as an access point does not increase power consumption. When the access point is active, the power consumption increases by about 1W.

If having a WiFi devices called wlan1 on the R1 instead of wlan0 bothers you, you should delete the /etc/udev/rules.d/70-persistent-net.rules file. It still contains an old entry by the Bananian maintenance programmer and the chip it used had, of course, a different MAC address.


The BPi-R1 reveals itself in many ways as a true hobby board. This characterization is intended as a compliment. The board opens the door to numerous possibilities, but realizing the possibilities requires some handiwork with the hardware and the software.

In particular, the R1 is highly suitable as a teaching tool. It cuts a good figure as a server/switch/router combination and beats out competition posed by off-the-shelf systems with its equipment and the availability of Debian packages. SOHO routers running OpenWrt and DD-WRT are limited in this respect because they either have very few packages or the ones that exist have limited functionality.

Some users might find several different applications for the lavish equipment. If the user only has one cable in the living room, then the R1 can act simultaneously as a switch, an access point, and a media player on the TV. However, the weak support for the Mali GPU is the fly in the ointment in this scenario.

In summary, the large number of components that come with this board make it relatively expensive. Moreover, the system is not yet stable enough for continuous operation. A router and a server should run as long as possible without problem. The lack of a case raises doubts about this capability, but at the same time leaves room for startups that want to use the R1 as a foundation for additional functionality.

If the reports in relevant forums are to be believed, LeMaker is already working on a new version that will include components for home automation. The prospects are exciting. Will the future bring boards that have an ever greater number of components, or will the trend revert to small, simple, and specialized solutions?

The Author

Bernhard Bablok works for Allianz Managed Operations & Services SE as a developer for SAP HR. He enjoys music, biking, and hiking. He also likes programming and working with Linux and small-board computers (mailto:mail@bablokb.de).

Buy this article as PDF

Express-Checkout as PDF

Pages: 6

Price $2.95
(incl. VAT)

Buy Raspberry Pi Geek

Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content