Yoctopuce on BeagleBone Black: Quick Review

Yoctopuce on BeagleBone Black: Quick Review

In the last few years, a great number of cheap mini- (or even micro-) computers have become available on the market. Most use an ARM processor and a Linux operating system. The most well known is obviously the Raspberry Pi. Recently, a new competitor has emerged: the BeagleBone Black. We decided to order one to see what its board is worth.




We already tested a large number of these mini-computers, but we never found a real gem. For personal projects, these machines work well enough, but we would never dare use one of them in production in a system which must work 24/7. The Raspberry Pi, for example, suffers from a more that perfectible USB stack, the MK805 doesn't have a reliable wifi interface, and, more generally, none of these machines provides an official support worthy of the name.

the BeagleBone Black
the BeagleBone Black



The BeagleBone Black (BBB) very clearly targets Raspberry Pi users. These two machines are sold without an enclosure, their boards have approximately the same size. In both machines, there is an HDMI output, an Ethernet port, 512 Mb of RAM, and an ARM processor (a little more powerful on the BeagleBone Black).

We found numerous tests on, and comparisons of, these two machines, but none was actually testing the USB port. Therefore, we decided to test our PiCooker project on the BeagleBone Black.

First positive point, the BBB is sold with an already installed Linux distribution. You only need to power the machine for it to directly boot an Angstrom Linux image. It's very convenient, even if in the long run you are probably going to install your own image with your preferred distribution.

Another positive point for this board is the power supply, and more particularly the power supply of the USB port. The BeagleBone Black provides only one USB port, so using a USB hub is almost compulsory. However, in the opposite to the Raspberry Pi, this port is able to power on its own a USB hub and 4 USB devices (a keyboard, a mouse, and two Yoctopuce modules). To work with Yoctopuce modules, it's a great advantage: no need to power the USB hub on top of the board. The USB port works perfectly in USB 2.0 and is able to support the load of several devices without losing packets. At no time during our tests did we have a USB communication error.

the BeagleBone Black is able to power severals USB devices without droping any packets
the BeagleBone Black is able to power severals USB devices without droping any packets



On the other hand, as for the Raspberry Pi, the BeagleBone Black doesn't have a Real Time Clock (RTC). This means that each time you switch off your system, it loses the time. So you must update the system clock at each boot! You can do this with the command:

ntpdate -b -s -u pool.ntp.org



One would not necessarily think about it, but not having an RTC can lead to real problems if you want to log events on an SD card, for instance if there is a power failure in your building. It's a safe bet that your BeagleBone Black is done booting before your ADSL router has succeeded in establishing a connection with your Internet provider, and you can't update the clock as long as you don't have an Internet connection.

Let's now see how to install the Python Yoctopuce library. We are going to use the version available on PyPi. The pip executable enabling you to install Python libraries is not available by default. You must install it with the opkg tool. Before you start, make sure to have updated the system clock, otherwise most of the following commands won't work correctly.

opkg update opkg install python-setuptools opkg install python-pip



When pip is installed, you can very easily install the Yoctopuce library with the command:

pip install yoctopuce



Before downloading and running PiCooker, you must also install the matplotlib library which is used to draw the graphs:

pip install --upgrade numpy pip install matplotlib




Finally, you can download and run the PiCooker Python script:

git clone git://github.com/yoctopuce-examples/PiCooker.git cd PiCooker ./picooker.py --smtp_host=smtp.gmail.com --smtp_port=465 --smtp_user=myemail@gmail.com --smtp_pass=mypassword



You should be able to connect yourself to the web interface of the PiCooker (http://localhost:8888). If you don't know what the PiCooker does or how to use it, you can read the original article again.

To conclude, the BeagleBone Black is a very interesting solution for people who need a very cheap or very small machine to interact with our modules. For 10$ above the price of a Raspberry Pi, this board provides a working USB port. Installation is quite simple if you know some Linux. Honestly, we don't (yet) recommend using this board in an industrial environment, but for less critical cases, it's a very good solution. We are going to continue testing this system and we will probably post an update in a little while.

Add a comment One comment
Back to blog



1 - Sascha Curth Thursday,july 17,2014 15H26

I also had USB issues with the raspberry, but i could solve these with tuning the rPi a bit:

/boot/config.txt:
arm_freq=850
sdram_freq=450
core_freq=350
force_turbo=1
gpu_mem=16

Since then the yoctopuce modules work stable.

Yoctopuce, get your stuff connected.