Skip to content
Snippets Groups Projects
Commit 703c6d78 authored by Olivier Stasse's avatar Olivier Stasse
Browse files

Merge branch 'gepgitlab-devel' with cmake-exports

parents d69b33e5 0035a67d
No related branches found
No related tags found
1 merge request!11Improve launch experience
Pipeline #8167 passed with warnings
CMAKE_MINIMUM_REQUIRED(VERSION 2.8.3)
SET(PROJECT_ORG pyrene-dev)
SET(PROJECT_NAME talos_data)
SET(PROJECT_DESCRIPTION "Talos urdf model, srdf model and other data")
SET(PROJECT_URL "https://gepgitlab.laas.fr/${PROJECT_ORG}/${PROJECT_NAME}")
# Export CMake Target
SET(PROJECT_USE_CMAKE_EXPORT TRUE)
# No warning error
set(CXX_DISABLE_WERROR True)
SET(CXX_DISABLE_WERROR True)
SET(CMAKE_CXX_STANDARD 11)
#include(cmake/ros.cmake)
INCLUDE(cmake/base.cmake)
# Specify the project.
cmake_policy(SET CMP0048 NEW)
PROJECT(${PROJECT_NAME}
LANGUAGES
CXX
VERSION
${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}
)
COMPUTE_PROJECT_ARGS(PROJECT_ARGS LANGUAGES CXX)
PROJECT(${PROJECT_NAME} ${PROJECT_ARGS})
find_package(catkin REQUIRED COMPONENTS
roscpp)
......@@ -31,9 +22,9 @@ find_package(catkin REQUIRED COMPONENTS
catkin_package(
# INCLUDE_DIRS include
# LIBRARIES talos_description
CATKIN_DEPENDS roscpp
# DEPENDS system_lib
)
# CATKIN_DEPENDS roscpp
# DEPENDS system_lib
)
# Find xml_reflection
ADD_PROJECT_DEPENDENCY(urdfdom REQUIRED)
......@@ -53,28 +44,19 @@ SET(LIBRARY_NAME ${PROJECT_NAME})
ADD_LIBRARY(${PROJECT_NAME}
SHARED
src/SpringPlugin.cc
)
)
TARGET_INCLUDE_DIRECTORIES(${PROJECT_NAME} PRIVATE ${GAZEBO_INCLUDE_DIRS})
TARGET_INCLUDE_DIRECTORIES(${PROJECT_NAME} PRIVATE ${catkin_INCLUDE_DIRS})
INSTALL(TARGETS
${PROJECT_NAME}
EXPORT ${TARGETS_EXPORT_NAME}
EXPORT ${TARGETS_EXPORT_NAME}
DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
# DESTINATION bin
# LIBRARY DESTINATION lib
)
target_include_directories(${LIBRARY_NAME}
PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src>
$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/../include>
$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/>
)
FOREACH(dir config gazebo meshes robots urdf srdf launch)
INSTALL(DIRECTORY ${dir}/
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/${dir})
ENDFOREACH(dir)
#SETUP_PROJECT_PACKAGE_FINALIZE()
Subproject commit 77f090f48bb32ccaea39a2670a74670a5e3be928
Subproject commit 54ece258eed16da94c7f10979588fcb47b744eb8
......@@ -11,7 +11,7 @@
<buildtool_depend>catkin</buildtool_depend>
<build_depend>roscpp</build_depend>
<exec_depend>talos_description_calibration</exec_depend>
<exec_depend>talos_description_inertial</exec_depend>
<exec_depend>roscpp</exec_depend>
......
......@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
*/
#include "SpringPlugin.hh"
......@@ -23,9 +23,7 @@ using namespace gazebo;
GZ_REGISTER_MODEL_PLUGIN(SpringPlugin)
/////////////////////////////////////////////////
SpringPlugin::SpringPlugin()
{
}
SpringPlugin::SpringPlugin() {}
/////////////////////////////////////////////////
void SpringPlugin::Load(physics::ModelPtr lmodel,
......@@ -35,7 +33,7 @@ void SpringPlugin::Load(physics::ModelPtr lmodel,
// hardcoded params for this test
if (!lsdf->HasElement("joint_spring"))
ROS_ERROR_NAMED("SpringPlugin","No field joint_spring for SpringPlugin");
ROS_ERROR_NAMED("SpringPlugin", "No field joint_spring for SpringPlugin");
else
jointExplicitName_ = lsdf->Get<std::string>("joint_spring");
......@@ -65,11 +63,8 @@ void SpringPlugin::Init()
boost::bind(&SpringPlugin::ExplicitUpdate, this));
}
/////////////////////////////////////////////////
void SpringPlugin::ExplicitUpdate()
{
void SpringPlugin::ExplicitUpdate() {
#if GAZEBO_MAJOR_VERSION < 9
common::Time currTime = model_->GetWorld()->GetSimTime();
#else
......
talos.srdf
\ No newline at end of file
talos_full_v2.urdf
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment