Coral part III.


Part III. is about getting out from the house with the board. An important sellingpoint of the Coral board that it's a low consumption device that can be deployed as an edge device. So far the Coral board has lived on a table and was connected to a power source and some network.

the rig the rig the rig

wireless access point

According to the Coral boards datasheet, amongst it's features there is Wi-Fi 2x2 MIMO (802.11b/g/n/ac 2.4/5 GHz), and the chip is a Murata LBEE5U91CQ. The chips detailed page shows that it supports Network Topology: AP and STA dual mode. Bingo, AP means it can operate as a wireless network access point. So the next task is to configure Mendel Linux accordingly.

the rig

After some googling I've found a nice article: How to use your Raspberry Pi as a wireless access point. This aritcle explains how to create a network bridge from wlan to eth. As my goal was AP only, here are my steps:
  1. Install hostapd and dnsmasq
  2. Configure a static IP for the wlan0 interface
  3. Configure the DHCP server
  4. Configure the access point host software (hostapd)

Install hostapd and dnsmasq

I only had to install hostapd as dnsmasq is installed by default on Mendel.

mendel@vendel:~$ sudo apt-get install hostapd

Configure a static IP for the wlan0 interface

To configure wlan0 witha static ip, one has to edit /etc/network/interfaces:

# interfaces(5) file used by ifup(8) and ifdown(8)
# Include files from /etc/network/interfaces.d:
source-directory /etc/network/interfaces.d

auto wlan0
iface wlan0 inet static

Configure the DHCP server

To configure the dhcp server (in our case it's dnsmasq), edit /etc/dnsmasq.conf


Configure the access point host software (hostapd)

This step was not easy cause the settings in the Pi article were not working, or resulting a slow network. But a little googling again and I've found Gentoo Linux Hostapd Sample configurations Based on those I came up with my own config, that I entered into /etc/hostapd/hostapd.conf


# driver=nl80211




As it can be seen on the pictures at the intro section of the article, I managed to take my coral board to a ride at the end. My set up was including a mobile charger battery, the Coral board, mounted on a gray LEGO plate, a webcam, an iPad and my laptop. In the car I started up the board, which created a 'CoralNet', with my laptop I connected to the 'CoralNet', and through ssh loged in to the board and started up my servers. Also connected my iPad to 'CoralNet', got out from the car and connected to the frontend server runing on the board. This way I could test most of the models my server is supporting. You can see that a 'car' is detected next to a 'person', face detection model detected my face, and the segmentation model segmented me green.

the rig the rig the rig

I did not mentioned in Part I., but lately I wrote a multi-threaded python server, and a react client. The python server is using opencv and TensorFlow Lite Interpreter, with Edge TPU runtime library as a delegate. After inference on the frames, the python server is streaming the frames and data, using WebScokets, to the React based client. The WebScoket communication is bidirectional so it's possible to control the python server as well ...

... but that is an other story for an other article.

Back to