1. Linux Installation¶
MetaSensors are supported on Linux.
For this tutorial, we will use Ubuntu Desktop. Ubuntu is one of the most popular distrubutions in existence today.
Please note that as a result, some installation steps may change or look slightly different depending on your distro of choice.
You will need to consider the following before starting the installation:
- Make sure your hardware supports Bluetooth
- Make sure you are comfortable working with Linux
Simply follow the Ubuntu install steps on the Ubuntu website: https://tutorials.ubuntu.com/tutorial/tutorial-install-ubuntu-desktop#0
The great thing about Ubuntu is that it comes with many packages installed. Please note that if you choose to install a bare-bones Linux distro, you may need to install many utilities, libraries and packages needed to support MetaWear development.
1.3. Post Check¶
If Ubuntu asks for an update, be kind and update!
At the very least, run:
>>> sudo apt-get update
1.4. Bluetooth Check¶
Now, just make sure that the Bluetooth hardware (adapter) is recognized by your OS by using the following command:
>>> hcitool dev
If your distro does not come with Bluetooth drivers installed, open a terminal window and install the required packages with their dependencies:
>>> sudo apt-get install bluez-utils
Connect your Bluetooth device and restart the Bluetooth services:
>>> sudo /etc/init.d/bluetooth restart
Verify your Bluetooth device is detected along with the appropriate modules:
>>> lsusb >>>> Device 005: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
Finally review the output of
>>> hcitool dev >>>> Devices: >>>> hci0 00:11:95:00:1A:CF
If you are having difficulties, please consult the community forum and manual for your OS of choice. The Ubuntu forum has already addressed many issues you may come upon.
1.5. Internet Check¶
You also need to make sure you have internet access. The quickest way to test this is to use ping in the terminal:
>>> ping www.google.com
Also check with:
>>> ip address show >>> ip link show
If you are having trouble, you can Google “How to connect to the internet on Ubuntu” or similar.
1.5.1. How to Connect to a Wireless Network With Ubuntu Desktop¶
If you have a wireless-enabled computer running the Ubuntu operating system, you can connect to a nearby wireless network to get to the internet. To do this:
- Open the System Menu on the right side of the top bar.
- Click on Wi-Fi Not Connected to expand the menu.
- Click on Select Network.
- Look through the names of the nearby networks. Select the one you want. If you don’t see the name of the network you want, click More to see additional networks. If you still don’t see the network you want, it may be hidden or you may be out of range.
- Enter the password for the network and click Connect.
1.5.2. How to Configure the network interface using the Terminal¶
You can configure a network interface from the command line using the networking utilities. You configure your network client hosts with the command line by using commands to change your current settings or by editing a number of system files.
To configure your network interface card to automatically connect when wired cable is connected you can follow these steps:
Configuring DHCP address for your network card
To configure DHCP address, edit the
/etc/network/interfaces and enter the following lines replacing
eth0 in the example with your network interface card:
>>> sudo nano /etc/network/interfaces
You should see something similar to this:
>>> auto eth0 >>> iface eth0 inet dhcp
Configure a static IP address for your network card
Same procedure as item 1 above but replace
eth0 with your networks card name:
>>> sudo nano /etc/network/interfaces
auto eth0 iface eth0 inet static address 192.168.0.100 gateway 192.168.0.1 netmask 255.255.255.0 network 192.168.0.0 broadcast 192.168.0.255
After entering all the details which are needed for your static IP, restart networking services using the following command:
>>> sudo /etc/init.d/networking restart
Setting up DNS
You can add a hostname and/or IP addresses to the file
/etc/hosts for static lookups.
To cause your machine to consult with a particular server for name lookups you simply add their addresses to
For example a machine which should perform lookups from the DNS server at IP address
192.168.0.1 would have a
resolv.conf file looking like this:
>>> sudo nano /etc/resolv.conf >>> search test.com >>> nameserver 192.168.0.1