Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
/build

*.make
cmake_install*
*.internal
*.o
*.dirstamp
*.a
*.swp
camera/.deps/
main/.deps/
Expand Down
9 changes: 1 addition & 8 deletions CMakeLists.txt
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cmake_minimum_required(VERSION 3.0.2)
project("UTAT UAV")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -pthread")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")

option(USE_ARAVIS "Use Aravis Library for GenieCam" ON)
option(USE_GPHOTO "Use Gphoto Library for DSLR" OFF)
Expand All @@ -10,16 +10,9 @@ set(CMAKE_VERBOSE_MAKEFILE OFF)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/modules/")
FIND_PACKAGE(OpenCV REQUIRED)
FIND_PACKAGE(Gpsd REQUIRED)
FIND_PACKAGE(PkgConfig REQUIRED)
pkg_check_modules(GLIB_PKG glib-2.0)
include_directories(${OpenCV_INCLUDE_DIRS})
include_directories(${LIBGPS_INCLUDE_DIR})
include_directories(${GLIB_PKG_INCLUDE_DIRS})

configure_file (
"${PROJECT_SOURCE_DIR}/config.h.in"
"${PROJECT_BINARY_DIR}/config.h"
)
include_directories("${PROJECT_BINARY_DIR}")

if (USE_ARAVIS)
Expand Down
19 changes: 19 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# utat_payload
Payload Control Software for UTAT UAV

Build:

mkdir build
cd build
cmake ..
make

Dependencies:

1) Need to build Opencv for ARM - install all its dependencies
Might need to download and build a few dependencies yourselves: ffmpeg, v4l2,

2) Need to download and build aravis 3.0.0 :
https://wiki.gnome.org/action/show/Projects/Aravis?action=show&redirect=Aravis

3) Need to install gpsd
12 changes: 6 additions & 6 deletions camera/CMakeLists.txt
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
if(USE_ARAVIS)
add_library(uavcam araviscamera.cpp webcamera.cpp)
else(USE_ARAVIS)
add_library(uavcam webcamera.cpp)
endif(USE_ARAVIS)
if(USE_ARAVIS)
add_library(uavcam araviscamera.cpp webcamera.cpp)
else(USE_ARAVIS)
add_library(uavcam webcamera.cpp)
endif(USE_ARAVIS)

63 changes: 26 additions & 37 deletions camera/Makefile
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -34,27 +34,27 @@ cmake_force:
SHELL = /bin/sh

# The CMake executable.
CMAKE_COMMAND = /usr/bin/cmake
CMAKE_COMMAND = /usr/local/bin/cmake

# The command to remove a file.
RM = /usr/bin/cmake -E remove -f
RM = /usr/local/bin/cmake -E remove -f

# Escaping for special characters.
EQUALS = =

# The top-level source directory on which CMake was run.
CMAKE_SOURCE_DIR = /home/odroid/UTAT/utat_payload
CMAKE_SOURCE_DIR = /home/odroid/uav/utat_payload

# The top-level build directory on which CMake was run.
CMAKE_BINARY_DIR = /home/odroid/UTAT/utat_payload
CMAKE_BINARY_DIR = /home/odroid/uav/utat_payload

#=============================================================================
# Targets provided globally by CMake.

# Special rule for the target edit_cache
edit_cache:
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "No interactive CMake dialog available..."
/usr/bin/cmake -E echo No\ interactive\ CMake\ dialog\ available.
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake cache editor..."
/usr/local/bin/ccmake -H$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)
.PHONY : edit_cache

# Special rule for the target edit_cache
Expand All @@ -64,35 +64,25 @@ edit_cache/fast: edit_cache
# Special rule for the target install
install: preinstall
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Install the project..."
/usr/bin/cmake -P cmake_install.cmake
/usr/local/bin/cmake -P cmake_install.cmake
.PHONY : install

# Special rule for the target install
install/fast: preinstall/fast
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Install the project..."
/usr/bin/cmake -P cmake_install.cmake
/usr/local/bin/cmake -P cmake_install.cmake
.PHONY : install/fast

# Special rule for the target install/local
install/local: preinstall
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Installing only the local directory..."
/usr/bin/cmake -DCMAKE_INSTALL_LOCAL_ONLY=1 -P cmake_install.cmake
/usr/local/bin/cmake -DCMAKE_INSTALL_LOCAL_ONLY=1 -P cmake_install.cmake
.PHONY : install/local

# Special rule for the target install/local
install/local/fast: install/local
.PHONY : install/local/fast

# Special rule for the target install/strip
install/strip: preinstall
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Installing the project stripped..."
/usr/bin/cmake -DCMAKE_INSTALL_DO_STRIP=1 -P cmake_install.cmake
.PHONY : install/strip

# Special rule for the target install/strip
install/strip/fast: install/strip
.PHONY : install/strip/fast

# Special rule for the target list_install_components
list_install_components:
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Available install components are: \"Unspecified\""
Expand All @@ -105,7 +95,7 @@ list_install_components/fast: list_install_components
# Special rule for the target rebuild_cache
rebuild_cache:
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake to regenerate build system..."
/usr/bin/cmake -H$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)
/usr/local/bin/cmake -H$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)
.PHONY : rebuild_cache

# Special rule for the target rebuild_cache
Expand All @@ -114,14 +104,14 @@ rebuild_cache/fast: rebuild_cache

# The main all target
all: cmake_check_build_system
cd /home/odroid/UTAT/utat_payload && $(CMAKE_COMMAND) -E cmake_progress_start /home/odroid/UTAT/utat_payload/CMakeFiles /home/odroid/UTAT/utat_payload/camera/CMakeFiles/progress.marks
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f CMakeFiles/Makefile2 camera/all
$(CMAKE_COMMAND) -E cmake_progress_start /home/odroid/UTAT/utat_payload/CMakeFiles 0
cd /home/odroid/uav/utat_payload && $(CMAKE_COMMAND) -E cmake_progress_start /home/odroid/uav/utat_payload/CMakeFiles /home/odroid/uav/utat_payload/camera/CMakeFiles/progress.marks
cd /home/odroid/uav/utat_payload && $(MAKE) -f CMakeFiles/Makefile2 camera/all
$(CMAKE_COMMAND) -E cmake_progress_start /home/odroid/uav/utat_payload/CMakeFiles 0
.PHONY : all

# The main clean target
clean:
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f CMakeFiles/Makefile2 camera/clean
cd /home/odroid/uav/utat_payload && $(MAKE) -f CMakeFiles/Makefile2 camera/clean
.PHONY : clean

# The main clean target
Expand All @@ -130,22 +120,22 @@ clean/fast: clean

# Prepare targets for installation.
preinstall: all
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f CMakeFiles/Makefile2 camera/preinstall
cd /home/odroid/uav/utat_payload && $(MAKE) -f CMakeFiles/Makefile2 camera/preinstall
.PHONY : preinstall

# Prepare targets for installation.
preinstall/fast:
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f CMakeFiles/Makefile2 camera/preinstall
cd /home/odroid/uav/utat_payload && $(MAKE) -f CMakeFiles/Makefile2 camera/preinstall
.PHONY : preinstall/fast

# clear depends
depend:
cd /home/odroid/UTAT/utat_payload && $(CMAKE_COMMAND) -H$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 1
cd /home/odroid/uav/utat_payload && $(CMAKE_COMMAND) -H$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 1
.PHONY : depend

# Convenience name for target.
camera/CMakeFiles/uavcam.dir/rule:
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f CMakeFiles/Makefile2 camera/CMakeFiles/uavcam.dir/rule
cd /home/odroid/uav/utat_payload && $(MAKE) -f CMakeFiles/Makefile2 camera/CMakeFiles/uavcam.dir/rule
.PHONY : camera/CMakeFiles/uavcam.dir/rule

# Convenience name for target.
Expand All @@ -154,55 +144,55 @@ uavcam: camera/CMakeFiles/uavcam.dir/rule

# fast build rule for target.
uavcam/fast:
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/build
cd /home/odroid/uav/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/build
.PHONY : uavcam/fast

araviscamera.o: araviscamera.cpp.o
.PHONY : araviscamera.o

# target to build an object file
araviscamera.cpp.o:
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/araviscamera.cpp.o
cd /home/odroid/uav/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/araviscamera.cpp.o
.PHONY : araviscamera.cpp.o

araviscamera.i: araviscamera.cpp.i
.PHONY : araviscamera.i

# target to preprocess a source file
araviscamera.cpp.i:
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/araviscamera.cpp.i
cd /home/odroid/uav/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/araviscamera.cpp.i
.PHONY : araviscamera.cpp.i

araviscamera.s: araviscamera.cpp.s
.PHONY : araviscamera.s

# target to generate assembly for a file
araviscamera.cpp.s:
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/araviscamera.cpp.s
cd /home/odroid/uav/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/araviscamera.cpp.s
.PHONY : araviscamera.cpp.s

webcamera.o: webcamera.cpp.o
.PHONY : webcamera.o

# target to build an object file
webcamera.cpp.o:
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/webcamera.cpp.o
cd /home/odroid/uav/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/webcamera.cpp.o
.PHONY : webcamera.cpp.o

webcamera.i: webcamera.cpp.i
.PHONY : webcamera.i

# target to preprocess a source file
webcamera.cpp.i:
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/webcamera.cpp.i
cd /home/odroid/uav/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/webcamera.cpp.i
.PHONY : webcamera.cpp.i

webcamera.s: webcamera.cpp.s
.PHONY : webcamera.s

# target to generate assembly for a file
webcamera.cpp.s:
cd /home/odroid/UTAT/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/webcamera.cpp.s
cd /home/odroid/uav/utat_payload && $(MAKE) -f camera/CMakeFiles/uavcam.dir/build.make camera/CMakeFiles/uavcam.dir/webcamera.cpp.s
.PHONY : webcamera.cpp.s

# Help Target
Expand All @@ -214,7 +204,6 @@ help:
@echo "... edit_cache"
@echo "... install"
@echo "... install/local"
@echo "... install/strip"
@echo "... list_install_components"
@echo "... rebuild_cache"
@echo "... uavcam"
Expand All @@ -235,6 +224,6 @@ help:
# No rule that depends on this can have commands that come from listfiles
# because they might be regenerated.
cmake_check_build_system:
cd /home/odroid/UTAT/utat_payload && $(CMAKE_COMMAND) -H$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 0
cd /home/odroid/uav/utat_payload && $(CMAKE_COMMAND) -H$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 0
.PHONY : cmake_check_build_system

Loading