Åland Sailing Robot is a research project at Åland University of Applied Sciences that develops autonomous sailing boats. This repository contains the embedded software executed on the different autonomous boats of the project and various useful tools for its development (simulator, unit-tests, UI...).
The following Autonomous sailboats are equipped with this software :
- Janet
- ASPire
The sailingrobot repository is divided into different directories :
- ArduinoSketches contains the code executed on the arduino boards of the autonomous sailboats (Janet, ASPire,...).
- CBoat is tool that displays the current boat state.
- Mission regroups predefined missions.
- Navigation System contains the source code of the control system running on the Raspberry Pi of the autonomous sailboats.
- sailing_simulator contains the simulation environment used to test and develop the control system. (Submodule)
- Xbee remote contains the code used to establish a radio communication between the embedded system and a laptop by using XBee modules.
Additional packages are required for building the Navigation System.
- With Ubuntu :
$ sudo apt-get install libncurses5-dev libncursesw5-dev libgps-dev
- With Arch Linux :
$ pacman -S i2c-tools gpsd
If you clone the repository, either use:
$ git clone --recursive https://github.com/AlandSailingRobots/sailingrobot.git
or if you have already cloned it, use:
$ cd sailingrobot
$ git submodule init # Initialises all the submodules (Only need to be done once)
$ git submodule update # Updates the submodule to the latest version
Install the wiringPi library:
$ cd NavigationSystem/Libs/wiringPi
$ ./build #Install wiringPi as a dynamic library
$ cd ../../..
Install the database:
$ ./installdb.sh
To build the Control system in NavigationSystem, type:
$ make [target] [ext variable 1] [ext variable 2]
Targets:
all
: Default, same as make ASPireASPire
: Build the control system for ASPireJanet
: Build the control system for Janetunit_tests
: Build the unit testsintegration_tests_ASPire
: Build the integration test for ASPire
External Variables (Only for building a control system):
USE_SIM
:=1
: To run with the sailing_simulator=0
: To run on the Pi (default)
USE_LNM
: Chooses which navigation algorithm you want to use.=1
: Local Navigation Module (Voter System)=0
: Line-follow algorithm (default)
Example :
Build the ASPire control system with the line-follow algorithm, to be executed with the simulator.
$ make ASPire USE_SIM=1
The database has two functionalities:
- Logging navigation datas
- Storing the sailboat parameters and mission
To update the configuration tables in the database, you run the update_config.py script with one of the configuration json files as a parameter.
$ ./update_config.py config_ASPire.json
To change the waypoints you use the waypoints.py together with one of the json in the Mission Folder.
$ ./update_waypoints.py Mission/ASS.json
To run the control system previously build, use (no parameters needed):
$ ./NavigationSystem/sr