From 8dc1a12f6f54c305f45fd9433de660ab1c215f25 Mon Sep 17 00:00:00 2001 From: Lucien Date: Mon, 24 Nov 2014 15:26:14 +1100 Subject: [PATCH] Fixed CmakeList files so code is detected on the robot --- src/commands/auton/CMakeLists.txt | 15 --------------- src/commands/pid/CMakeLists.txt | 4 ++++ src/commands/systems/CMakeLists.txt | 7 +++++++ src/commands/vision/CMakeLists.txt | 8 ++++++++ src/subsystems/CMakeLists.txt | 2 +- src/subsystems/move/CMakeLists.txt | 6 ++++++ src/subsystems/move/Chassis.cpp | 2 +- src/subsystems/pid/CMakeLists.txt | 5 +++++ src/subsystems/sensors/CMakeLists.txt | 5 +++++ 9 files changed, 37 insertions(+), 17 deletions(-) create mode 100644 src/commands/pid/CMakeLists.txt create mode 100644 src/commands/systems/CMakeLists.txt create mode 100644 src/commands/vision/CMakeLists.txt create mode 100644 src/subsystems/move/CMakeLists.txt create mode 100644 src/subsystems/pid/CMakeLists.txt create mode 100644 src/subsystems/sensors/CMakeLists.txt diff --git a/src/commands/auton/CMakeLists.txt b/src/commands/auton/CMakeLists.txt index 1f4ef69..4d4e60c 100644 --- a/src/commands/auton/CMakeLists.txt +++ b/src/commands/auton/CMakeLists.txt @@ -1,19 +1,4 @@ -project(Holly) -macro (add_sources) - file (RELATIVE_PATH _relPath "${CMAKE_SOURCE_DIR}" "${CMAKE_CURRENT_SOURCE_DIR}") - foreach (_src ${ARGN}) - if (_relPath) - list (APPEND SOURCE_CODE "${_relPath}/${_src}") - else() - list (APPEND SOURCE_CODE "${_src}") - endif() - endforeach() - if (_relPath) - # propagate SOURCE_CODE to parent directory - set (SOURCE_CODE ${SOURCE_CODE} PARENT_SCOPE) - endif() -endmacro() add_sources ( AutonomousCommandGroup.cpp diff --git a/src/commands/pid/CMakeLists.txt b/src/commands/pid/CMakeLists.txt new file mode 100644 index 0000000..d99af72 --- /dev/null +++ b/src/commands/pid/CMakeLists.txt @@ -0,0 +1,4 @@ +add_sources ( +GyroReset.cpp +TogglePimpin.cpp +) diff --git a/src/commands/systems/CMakeLists.txt b/src/commands/systems/CMakeLists.txt new file mode 100644 index 0000000..176a5c2 --- /dev/null +++ b/src/commands/systems/CMakeLists.txt @@ -0,0 +1,7 @@ + + +add_sources ( +HolonomicDrive.cpp +WinchLoosen.cpp +WinchTension.cpp +) diff --git a/src/commands/vision/CMakeLists.txt b/src/commands/vision/CMakeLists.txt new file mode 100644 index 0000000..204a4ca --- /dev/null +++ b/src/commands/vision/CMakeLists.txt @@ -0,0 +1,8 @@ + + +add_sources ( +DemoCommandGroup.cpp +FindTarget.cpp +PositionRobot.cpp +SpinOneEighty.cpp +) diff --git a/src/subsystems/CMakeLists.txt b/src/subsystems/CMakeLists.txt index b285074..f1834df 100644 --- a/src/subsystems/CMakeLists.txt +++ b/src/subsystems/CMakeLists.txt @@ -27,5 +27,5 @@ AUX_SOURCE_DIRECTORY(sensors SensorsSources) add_sources( ${MoveSources} ${SubPidSources} - ${SystemsSources} + ${SensorsSources} ) diff --git a/src/subsystems/move/CMakeLists.txt b/src/subsystems/move/CMakeLists.txt new file mode 100644 index 0000000..ce0407c --- /dev/null +++ b/src/subsystems/move/CMakeLists.txt @@ -0,0 +1,6 @@ + + +add_sources ( +Chassis.cpp +Winch.cpp +) diff --git a/src/subsystems/move/Chassis.cpp b/src/subsystems/move/Chassis.cpp index 32e697f..35fd43c 100644 --- a/src/subsystems/move/Chassis.cpp +++ b/src/subsystems/move/Chassis.cpp @@ -5,7 +5,7 @@ #include #include -#define GYRO_P (-0.6) +#define GYRO_P (-0.8) #define GYRO_I (-0.00) #define GYRO_D (-0.0) #define MOMENTUM_THRESHOLD (deg2rad(30.0)) // rad/s diff --git a/src/subsystems/pid/CMakeLists.txt b/src/subsystems/pid/CMakeLists.txt new file mode 100644 index 0000000..a18bb55 --- /dev/null +++ b/src/subsystems/pid/CMakeLists.txt @@ -0,0 +1,5 @@ + + +add_sources ( +GyroCorrection.cpp +) diff --git a/src/subsystems/sensors/CMakeLists.txt b/src/subsystems/sensors/CMakeLists.txt new file mode 100644 index 0000000..9de8302 --- /dev/null +++ b/src/subsystems/sensors/CMakeLists.txt @@ -0,0 +1,5 @@ + + +add_sources ( +EyeBone.cpp +)