Welcome to Tiberius’s documentation!¶
Contents:
Quickstart¶
Tiberius - an introduction¶
Tiberius is the name of a robotics R&D platform developed by J.T Herd and his Masters students at Heriot-Watt University.

Tiberius II Development Platform
Development Teams (2005 to Present)¶
The following section lists all known major contributors to the Tiberius project.
2015/16 Development Team¶
- Cameron Craig - Control API/Web Interface, IMDB
- Stuart Thain - Navigation Algorithms
- Euan Mutch - Communications, Robotic Arm Design
- Duncan Robertson - Suspension/Steering Design
- Andrew Rigg - Power Management
- Aidan Gallagher - SLAM (Simulataneous Localisation and Mapping)
2014/15 Development Team¶
- Sean Cunningham - Power System
- Tasos Deligiannis - Image Processing
- Dionysis Koutavas - Databases/Communication
- Denis Melehovs - Autonomy
Installation¶
The tiberius-robot package can be fully installed by running the setup script, found in the top level folder. The setup.py script attempts to install all necessary dependencies for tiberius-robot.
Tutorials¶
Tutorials - an introduction¶
Please find the following tutorials useful. Each tutorial is designed to be as unambiguous as possible
Scope¶
These tutorials are designed to be read by developers. Whether they are part of the Tiberius development team at Heriot-Watt University, or an external developer interested in using, extending, forking, or developing the existing software repository.
Getting Started¶
The following tutorial will guide you through all the steps necessary to build a system using compatible hardware, and getting the system up and running. The instructions are ordered with the biggest steps at the start, so you don’t get a head of yourself doing the easy bits at the beginning. In summary, in order to get a robot up and running you will need to set up a network, make sure you have compatible hardware, get a hold of our software, and configure our software for your hardware.
- Installing compatible hardware
The following pieces of hardware have been tested to work with the Tiberius Software Suite:
- Raspberry Pi 1A+,1B,1B+,2B,3B
- NEO-M8N (GPS Module, serial interface)
- CMPS11 (Tilt Compensated Compass, I2C interface supported)
- RPLIDAR (LIDAR, basic scan supported)
- MD03 (Motor Driver, I2C interface supported)
- RAMPS (3D Printer Driver Board, used to drive our robotic arm, serial interface)
The exact model of DC motors used is not important, we have used wiper motors and motors from Como Drills.
Our software assumes you’ll have four driven wheels, any other number of wheels will require modification of the software. However this shouldn’t be too difficult - modification of actuators.py to add or remove motors.
Here two of our vehicles to get an idea of what we’re talking about:
A thorough hardware installation tutorial is available.
- Getting a hold of the Tiberius software repository
Once you have some hardware, you can think about getting a copy of our software. The way we would normally go about this is connecting the Raspberry Pi to the internet, through your LAN. The the separate tutorial (Networking Tutorial) for network configuration instructions.
Note
It is essential to clone our git repository into into
/home/pi/git/
. This should result in the following folder being created:/home/pi/git/tiberius-robot/
This is due to the hardcoded path names that are used in
setup.py
, in order to move files into a known location. Yes, we know, we know. This is not by any means ideal, but it is what currently works. This is an area that could be looked into if you feel like contributing.Here’s an example of the commands that we use to clone our repository (assuming that you are currently in your home directory):
cd git/ git clone https://github.com/IonSystems/tiberius-robot.git
- Installing the Tiberius Software Suite
Now that you have the hardware and have cloned the repository, you can now think about installing our software.
Note
We have tried to make our setup script as thorough and reliable as possible, although we cannot guarantee success. Unless you have done some funny things to file permissions, it should work.
You should now locate yourself in the top level of our repository using
cd tiberius-robot/
. You can then run the setup script by typingsudo python setup.py install
. They above commands are provided below for copy-paste convenience:cd tiberius-robot/ sudo python setup.py install
- Configuring your installation
A number of configuration settings need to be edited to suit the particulars of your hardware setup. The configuration directory is the same for every installation, so your config file should appear in
/etc/tiberius/tiberius_conf.conf
It is important to ensure the correct hardware is enabled, and unavailable hardware is disabled. As this configuration file is used by the software to determine whether or not to communicate with the respective device. The configuration file is also used by the API to decide whether or not to allow access to the particular device through the API.
It is also important to ensure the correct ports are set for the enabled devices. There is a test script to detect the USB devices available here:
tiberius/testing/scripts/gps_dev_path
. An alternative approach would be to runstart_tiberius.py
and you’ll know if the ports are wrong if you see error messages for the device in question.Last, but not least, ensure the I2C addresses are set correctly. To list all I2C slaves on the bus, run
i2cdetect 1
. You’ll need to work out the correspondence between the addresses and the devices by process of elimination, or by reading data sheets for default addresses.
- Getting the software running
This should be the easy part! We have a script in the top level of our repository called
start_tiberius.py
. This script takes care of starting everything in the correct order. If this starts successfully, then there is a good chance that everything is now operational.For a more in-depth discussion of what
start_tiberius.py
does, see docstrings.
Networking¶
Hardware Installation¶
User Guide¶
User Guides - an introduction¶
Tiberius the name of a robotics R&D platform developed by J.T Herd his Masters students at Heriot-Watt University.
Using the quickstart.py script¶
quickstart.py is located in the top level directory of this package, and provides shortcuts to common applications for convenience.
Tiberius’s Database Module¶
Introduction¶
Tiberius’s database module provides a consistent interface between your Python programs and a number of database technologies.
Installation¶
Installation of the database package is included in the setup script.
Tiberius’s Database Interface¶
The database module currently supports the following SQL features: - INSERT - DELETE - DROP - UPDATE - SELECT
These SQL features are hidden behind the scenes in our wrapper classes, to give a consistent interface for multiple database technologies.
Example Usage¶
The following example shows all currently supported database interactions:
#Create a new Database
db = PolyhedraDatabase('example_db')
#Create a table with a few columns.
db.create('example_table', {'id': 'int primary key', 'example_column':'varchar(100)'})
#Insert a row into the table
db.insert('example_table', {'id': 0, 'example_column':'Example text value.'})
#Query the table for all rows an columns
results = db.query('example_table', '*')
print results
#Update the value we previously put in
db.update('example_table',
{
'example_column': 'Example new updates value.',
},
{
'clause':'WHERE',
'data': [
{
'column' : 'id',
'assertion' : '=',
'value': '0'
}
]
})
#Drop the table
db.drop('example_table')
Tiberius’s Architecture¶
Introduction¶
ROS (Robot Operating System) is an extremely popular development framework for robots. The publish-subscribe data model that is used by ROS works wonders, and rightly so no alternative data architecture has aver been considered. But, how would an alternative architecture compare? This is the question that we ask. And we hope to get part of the answer by implementing a super-fast in-memory database, and churning through all our data/messages. This will operate similar to the Blackboard (https://en.wikipedia.org/wiki/Blackboard_(design_pattern)) design pattern.
Our central database architecture will allow any device to access any piece of information, making it easy to integrate multiple devices, irrespective of the hardware or software it uses.
System Architecture Diagram¶
The following diagram illustrates an example system utilising our central database architecture:

Example System Architecture
Our database engine of choice is Polyhedra Lite, the free version of a commercial in-memory database. Although we have developed a Python wrapper class that creates a common Python interface between any database engine with minimal effort required.
Why not just use ROS?¶
This is a question that we asked ourselves when first presented with the Tiberius project. Well, you most definitely should use ROS, given the option. This project is motivated by the research interests of our project supervisor, Jim T. Herd. However, should you wish to explore a ROS alternative and be willing to to re-write a lot of Python to fit your hardware, then my all means, feel free.
Testing¶
Test Environment¶
Tiberius’s test environment is designed to provide a consistent physical environment, where functional tests can be executed.
Note
The test environment and supporting functional tests are still in development, and not currently available for use.
Unit Testing¶
All new code should come with basic unit tests, although we don’t guarantee this. All our unit tests are in the testing module. When creating unit tests we typically create all the test cases for the class/script/module in it’s own file. Just have a look to see what I mean.