First of all some side items:
- add user to dialout group to deal with serial port permissions with the command "usermod -a -G dialout josh"
- add /sbin/ to path in .bashrc
- (optional) add a line to .bashrc to export DISTCC_HOSTS
...
1) Install dependency packages assuming ubuntu derivative. . Note - these steps can potentially be done during SD cart setup on the host machine.
Code Block |
---|
sudo apt-get update sudo apt-get install aptitude sudo aptitude update sudo aptitude install build-essential freeglut3-dev libboost-all-dev xterm libtiff4-dev libpng12-dev libgsl0-dev subversion bzr cmake-curses-gui libxftlibblas-dev libxineramarsync libgmp3-dev fluid default-jre |
2) Download MOOS-IvP from httpDownloads:
Code Block |
---|
cd ~/ svn co https://oceanai.mit.edu/svn/moos-ivp-aro/ |
...
Code Block |
---|
releases/moos-ivp-13.5 moos-ivp bzr co lp:goby/2.0 goby cd goby sudo ./DEPENDENCIES debian cd ~/ svn cocheckout https://oceanaihovergroup.mitgooglecode.educom/svn/moos-ivp-aro/trunk moos-ivptrunk/third-party third-party svn checkout https://hovergroup.googlecode.com/svn/trunk/ivp-extend hovergroup-extend cd ~/ mkdir MOOS cd MOOS git clone https://github.com/themoos/core-moos.git MOOSCore cd MOOSCore git checkout master cd .. git clone https://github.com/themoos/essential-moos.git MOOSEssentials cd MOOSEssentials git checkout devel cd .. git clone https://github.com/themoos/ui-moos.git MOOSToolsUI cd MOOSToolsUI git checkout V10-beta-rc1 cd .. git clone https://github.com/themoos/geodesy-moos.git MOOSGeodesy cd MOOSGeodesy git checkout master cd .. mv ~/MOOS/MOOSCore/Core/libMOOS/Comms/XPCGetProtocol.cpp ~/MOOS/MOOSCore/Core/libMOOS/Comms/XPCGetProtocol_bck.cpp cp ~/third-party/XPCGetProtocol.cpp ~/MOOS/MOOSCore/Core/libMOOS/Comms/ |
3) Build MOOS with the following commands:
Code Block |
---|
export CXX='/usr/local/lib/distcc/arm-linux-gnueabi-g++-4.4' export CC='/usr/local/lib/distcc/arm-linux-gnueabi-gcc-4.4' export DISTCC_HOSTS=192.168.1.4 export DISTCC_POTENTIAL_HOSTS=192.168.1.4 cd ~/moos-ivp/MOOS/MOOSCore cmake -D DISABLE_NAMES_LOOKUP=ON -D USE_ASYNC_COMMS=ON . make -j4j2 cd ../MOOSEssentials cmake . make -j4j2 cd ../MOOSGeodesy cmake . make -j4j2 cd ../MOOSToolsUI cmake -D BUILD_GRAPHICAL_TOOLS=ONOFF . distcc-pump make -j4 |
4) Build MOOS-IvP:
Code Block |
---|
-j2 cd ~/moos-ivp rm MOOS ln -s ../MOOS MOOS cd ~/moos-ivp/ivp/src cmake -D IVP_BUILD_GUI_CODE=ONOFF . distcc-pump make -j4 |
5) Download and install goby
Code Block |
---|
j2 cd ~/ bzr co lp:goby cd goby sudo ./DEPENDENCIES ubuntu cmakecmake -D build_apps=OFF -D build_appsmoos=OFF . make -j4 |
6) Download and build hovergroup svn:
Code Block |
---|
j2 cd ~/ svn checkout https://hovergroup.googlecode.com/svn/trunk/ hovergroup/hovergroup-extend/trunk ./build_proto.sh cmake -D BOOST_146=ON -D BUILD_SHORE_APPS=OFF . make -j2 cd ~/hovergroup/ivp-extend/trunkjosh ./build_proto.sh cmake -D BUILD_SHORE_APPS=OFF . make -j4j2 |
7) Add executable directories to your path (replacing "josh" with your username). Add the following lines to your ~/.bashrc file. 4) Bashrc:
Code Block |
---|
HOME_DIR="/home/josh" IVP_DIR=${HOME_DIR}/moos-ivp MOOS_DIR=${IVP_DIR}/MOOS PATH=$PATH:${MOOS_DIR}/MOOSCore/bin:${MOOS_DIR}/MOOSEssentials/bin:${MOOS_DIR}/MOOSToolsUI/bin PATH=$PATH:${IVP_DIR}/bin HOVERGROUP_DIR=${HOME_DIR}/hovergroup/ivp-extend PATH=$PATH:${HOVERGROUP_DIR}/trunk/bin |
8) Download the latest version of Eclipse CDT from http://www.eclipse.org/cdt/downloads.php and extract to a location of your choosing (no installation required). After starting Eclipse you'll need to add the projects and set their references for the indexer to work.
First I would recommend closing some of the extra windows around the screen. Almost all of the side tabs can be removed; the only ones we need are the project explorer and the console, which can be minimized when we're not building code. Once you have things arranged the way you like you should save your perspective under Window ->
To import a project go to File -> New -> Makefile Project with Existing Code. For each of the following projects you'll need to select the folder location, name the project, and set the tool-chain to Linux GCC. After creating projects you will also need to set their references to other projects. Do this by right clicking on the project in the project explorer and selection properties, then select "project references" on the left.
Name | Path on Disk | Project References |
---|---|---|
MOOSCore | ~/moos-ivp/MOOS/MOOSCore | none |
MOOSEssentials | ~/moos-ivp/MOOS/MOOSEssentials | MOOSCore |
MOOSGeodesy | ~/moos-ivp/MOOS/MOOSGeodesy | MOOSCore |
MOOSToolsUI | ~/moos-ivp/MOOS/MOOSToolsUI | MOOSCore |
MOOS-IvP | ~/moos-ivp/ivp/src | MOOSCore |
Goby | ~/goby | none |
hovergroup | ~/hovergroup/ivp-extend/trunk | MOOSCore |
your personal folder | ~/hovergroup/ivp-extend/josh | MOOSCore |
Some additional changes you should make in eclipse:
PATH=$PATH:/sbin
export DISTCC_HOSTS="192.168.1.100"
export DISTCC_POTENTIAL_HOSTS="192.168.1.100"
export CC="/usr/local/lib/distcc/arm-linux-gnueabi-gcc-4.4"
export CXX="/usr/local/lib/distcc/arm-linux-gnueabi-g++-4.4"
|
5) Rtklib
build:
Code Block |
---|
~/third-party/rtklib/app/makeall.sh
|
Add as launch script: (for some reason this doesn't work when copy pasted - type in manually)
Code Block |
---|
cd /etc/init.d
sudo ln -s /home/josh/third_party/josh_rtklib/start_silvana.sh start_silvana.sh
sudo ln -s /home/josh/third_party/josh_rtklib/start_rtkrcv.sh start_rtkrcv.sh
sudo update-rc.d start_silvana.sh defaults
sudo update-rc.d start_silvana.sh defaults
|
temp fixssh-keygen -t rsa
ssh keygen: ssh-copy-id -i ~/.ssh/id_rsa.pub remote-host
remote host is the kayak
added chmod 777 /var/run/screen to rc.local
default compass update rate is 10Hz
...