| @@ -0,0 +1,94 @@ | ||
| #!/usr/bin/env sh | ||
| # generated from catkin/cmake/template/setup.sh.in | ||
|
|
||
| # Sets various environment variables and sources additional environment hooks. | ||
| # It tries it's best to undo changes from a previously sourced setup file before. | ||
| # Supported command line options: | ||
| # --extend: skips the undoing of changes from a previously sourced setup file | ||
|
|
||
| # since this file is sourced either use the provided _CATKIN_SETUP_DIR | ||
| # or fall back to the destination set at configure time | ||
| : ${_CATKIN_SETUP_DIR:=/home/2013/ncolot/rosa1/devel} | ||
| _SETUP_UTIL="$_CATKIN_SETUP_DIR/_setup_util.py" | ||
| unset _CATKIN_SETUP_DIR | ||
|
|
||
| if [ ! -f "$_SETUP_UTIL" ]; then | ||
| echo "Missing Python script: $_SETUP_UTIL" | ||
| return 22 | ||
| fi | ||
|
|
||
| # detect if running on Darwin platform | ||
| _UNAME=`uname -s` | ||
| _IS_DARWIN=0 | ||
| if [ "$_UNAME" = "Darwin" ]; then | ||
| _IS_DARWIN=1 | ||
| fi | ||
| unset _UNAME | ||
|
|
||
| # make sure to export all environment variables | ||
| export CMAKE_PREFIX_PATH | ||
| export CPATH | ||
| if [ $_IS_DARWIN -eq 0 ]; then | ||
| export LD_LIBRARY_PATH | ||
| else | ||
| export DYLD_LIBRARY_PATH | ||
| fi | ||
| unset _IS_DARWIN | ||
| export PATH | ||
| export PKG_CONFIG_PATH | ||
| export PYTHONPATH | ||
|
|
||
| # remember type of shell if not already set | ||
| if [ -z "$CATKIN_SHELL" ]; then | ||
| CATKIN_SHELL=sh | ||
| fi | ||
|
|
||
| # invoke Python script to generate necessary exports of environment variables | ||
| # use TMPDIR if it exists, otherwise fall back to /tmp | ||
| if [ -d "${TMPDIR}" ]; then | ||
| _TMPDIR="${TMPDIR}" | ||
| else | ||
| _TMPDIR=/tmp | ||
| fi | ||
| _SETUP_TMP=`mktemp "${_TMPDIR}/setup.sh.XXXXXXXXXX"` | ||
| unset _TMPDIR | ||
| if [ $? -ne 0 -o ! -f "$_SETUP_TMP" ]; then | ||
| echo "Could not create temporary file: $_SETUP_TMP" | ||
| return 1 | ||
| fi | ||
| CATKIN_SHELL=$CATKIN_SHELL "$_SETUP_UTIL" $@ >> "$_SETUP_TMP" | ||
| _RC=$? | ||
| if [ $_RC -ne 0 ]; then | ||
| if [ $_RC -eq 2 ]; then | ||
| echo "Could not write the output of '$_SETUP_UTIL' to temporary file '$_SETUP_TMP': may be the disk if full?" | ||
| else | ||
| echo "Failed to run '\"$_SETUP_UTIL\" $@': return code $_RC" | ||
| fi | ||
| unset _RC | ||
| unset _SETUP_UTIL | ||
| rm -f "$_SETUP_TMP" | ||
| unset _SETUP_TMP | ||
| return 1 | ||
| fi | ||
| unset _RC | ||
| unset _SETUP_UTIL | ||
| . "$_SETUP_TMP" | ||
| rm -f "$_SETUP_TMP" | ||
| unset _SETUP_TMP | ||
|
|
||
| # source all environment hooks | ||
| _i=0 | ||
| while [ $_i -lt $_CATKIN_ENVIRONMENT_HOOKS_COUNT ]; do | ||
| eval _envfile=\$_CATKIN_ENVIRONMENT_HOOKS_$_i | ||
| unset _CATKIN_ENVIRONMENT_HOOKS_$_i | ||
| eval _envfile_workspace=\$_CATKIN_ENVIRONMENT_HOOKS_${_i}_WORKSPACE | ||
| unset _CATKIN_ENVIRONMENT_HOOKS_${_i}_WORKSPACE | ||
| # set workspace for environment hook | ||
| CATKIN_ENV_HOOK_WORKSPACE=$_envfile_workspace | ||
| . "$_envfile" | ||
| unset CATKIN_ENV_HOOK_WORKSPACE | ||
| _i=$((_i + 1)) | ||
| done | ||
| unset _i | ||
|
|
||
| unset _CATKIN_ENVIRONMENT_HOOKS_COUNT |
| @@ -0,0 +1,8 @@ | ||
| #!/usr/bin/env zsh | ||
| # generated from catkin/cmake/templates/setup.zsh.in | ||
|
|
||
| CATKIN_SHELL=zsh | ||
|
|
||
| # source setup.sh from same directory as this file | ||
| _CATKIN_SETUP_DIR=$(builtin cd -q "`dirname "$0"`" > /dev/null && pwd) | ||
| emulate -R zsh -c 'source "$_CATKIN_SETUP_DIR/setup.sh"' |
| @@ -0,0 +1 @@ | ||
| /opt/ros/indigo/share/catkin/cmake/toplevel.cmake |
| @@ -0,0 +1,14 @@ | ||
| # generated from catkin/cmake/template/pkgConfig-version.cmake.in | ||
| set(PACKAGE_VERSION "2.2.2") | ||
|
|
||
| set(PACKAGE_VERSION_EXACT False) | ||
| set(PACKAGE_VERSION_COMPATIBLE False) | ||
|
|
||
| if("${PACKAGE_FIND_VERSION}" VERSION_EQUAL "${PACKAGE_VERSION}") | ||
| set(PACKAGE_VERSION_EXACT True) | ||
| set(PACKAGE_VERSION_COMPATIBLE True) | ||
| endif() | ||
|
|
||
| if("${PACKAGE_FIND_VERSION}" VERSION_LESS "${PACKAGE_VERSION}") | ||
| set(PACKAGE_VERSION_COMPATIBLE True) | ||
| endif() |
| @@ -0,0 +1,191 @@ | ||
| # generated from catkin/cmake/template/pkgConfig.cmake.in | ||
|
|
||
| # append elements to a list and remove existing duplicates from the list | ||
| # copied from catkin/cmake/list_append_deduplicate.cmake to keep pkgConfig | ||
| # self contained | ||
| macro(_list_append_deduplicate listname) | ||
| if(NOT "${ARGN}" STREQUAL "") | ||
| if(${listname}) | ||
| list(REMOVE_ITEM ${listname} ${ARGN}) | ||
| endif() | ||
| list(APPEND ${listname} ${ARGN}) | ||
| endif() | ||
| endmacro() | ||
|
|
||
| # append elements to a list if they are not already in the list | ||
| # copied from catkin/cmake/list_append_unique.cmake to keep pkgConfig | ||
| # self contained | ||
| macro(_list_append_unique listname) | ||
| foreach(_item ${ARGN}) | ||
| list(FIND ${listname} ${_item} _index) | ||
| if(_index EQUAL -1) | ||
| list(APPEND ${listname} ${_item}) | ||
| endif() | ||
| endforeach() | ||
| endmacro() | ||
|
|
||
| # pack a list of libraries with optional build configuration keywords | ||
| # copied from catkin/cmake/catkin_libraries.cmake to keep pkgConfig | ||
| # self contained | ||
| macro(_pack_libraries_with_build_configuration VAR) | ||
| set(${VAR} "") | ||
| set(_argn ${ARGN}) | ||
| list(LENGTH _argn _count) | ||
| set(_index 0) | ||
| while(${_index} LESS ${_count}) | ||
| list(GET _argn ${_index} lib) | ||
| if("${lib}" MATCHES "^(debug|optimized|general)$") | ||
| math(EXPR _index "${_index} + 1") | ||
| if(${_index} EQUAL ${_count}) | ||
| message(FATAL_ERROR "_pack_libraries_with_build_configuration() the list of libraries '${ARGN}' ends with '${lib}' which is a build configuration keyword and must be followed by a library") | ||
| endif() | ||
| list(GET _argn ${_index} library) | ||
| list(APPEND ${VAR} "${lib}${CATKIN_BUILD_CONFIGURATION_KEYWORD_SEPARATOR}${library}") | ||
| else() | ||
| list(APPEND ${VAR} "${lib}") | ||
| endif() | ||
| math(EXPR _index "${_index} + 1") | ||
| endwhile() | ||
| endmacro() | ||
|
|
||
| # unpack a list of libraries with optional build configuration keyword prefixes | ||
| # copied from catkin/cmake/catkin_libraries.cmake to keep pkgConfig | ||
| # self contained | ||
| macro(_unpack_libraries_with_build_configuration VAR) | ||
| set(${VAR} "") | ||
| foreach(lib ${ARGN}) | ||
| string(REGEX REPLACE "^(debug|optimized|general)${CATKIN_BUILD_CONFIGURATION_KEYWORD_SEPARATOR}(.+)$" "\\1;\\2" lib "${lib}") | ||
| list(APPEND ${VAR} "${lib}") | ||
| endforeach() | ||
| endmacro() | ||
|
|
||
|
|
||
| if(overhead_bullshit_CONFIG_INCLUDED) | ||
| return() | ||
| endif() | ||
| set(overhead_bullshit_CONFIG_INCLUDED TRUE) | ||
|
|
||
| # set variables for source/devel/install prefixes | ||
| if("FALSE" STREQUAL "TRUE") | ||
| set(overhead_bullshit_SOURCE_PREFIX /tmp/buildd/ros-indigo-bullshitbot-gazebo-2.2.2-0trusty-20160110-0705) | ||
| set(overhead_bullshit_DEVEL_PREFIX /tmp/buildd/ros-indigo-bullshitbot-gazebo-2.2.2-0trusty-20160110-0705/obj-x86_64-linux-gnu/devel) | ||
| set(overhead_bullshit_INSTALL_PREFIX "") | ||
| set(overhead_bullshit_PREFIX ${overhead_bullshit_DEVEL_PREFIX}) | ||
| else() | ||
| set(overhead_bullshit_SOURCE_PREFIX "") | ||
| set(overhead_bullshit_DEVEL_PREFIX "") | ||
| set(overhead_bullshit_INSTALL_PREFIX /opt/ros/indigo) | ||
| set(overhead_bullshit_PREFIX ${overhead_bullshit_INSTALL_PREFIX}) | ||
| endif() | ||
|
|
||
| # warn when using a deprecated package | ||
| if(NOT "" STREQUAL "") | ||
| set(_msg "WARNING: package 'overhead_bullshit' is deprecated") | ||
| # append custom deprecation text if available | ||
| if(NOT "" STREQUAL "TRUE") | ||
| set(_msg "${_msg} ()") | ||
| endif() | ||
| message("${_msg}") | ||
| endif() | ||
|
|
||
| # flag project as catkin-based to distinguish if a find_package()-ed project is a catkin project | ||
| set(overhead_bullshit_FOUND_CATKIN_PROJECT TRUE) | ||
|
|
||
| if(NOT " " STREQUAL " ") | ||
| set(overhead_bullshit_INCLUDE_DIRS "") | ||
| set(_include_dirs "") | ||
| foreach(idir ${_include_dirs}) | ||
| if(IS_ABSOLUTE ${idir} AND IS_DIRECTORY ${idir}) | ||
| set(include ${idir}) | ||
| elseif("${idir} " STREQUAL "include ") | ||
| get_filename_component(include "${overhead_bullshit_DIR}/../../../include" ABSOLUTE) | ||
| if(NOT IS_DIRECTORY ${include}) | ||
| message(FATAL_ERROR "Project 'overhead_bullshit' specifies '${idir}' as an include dir, which is not found. It does not exist in '${include}'. Ask the maintainer 'Marcus Liebhardt <marcus.liebhardt@yujinrobot.com>' to fix it.") | ||
| endif() | ||
| else() | ||
| message(FATAL_ERROR "Project 'overhead_bullshit' specifies '${idir}' as an include dir, which is not found. It does neither exist as an absolute directory nor in '/opt/ros/indigo/${idir}'. Ask the maintainer 'Marcus Liebhardt <marcus.liebhardt@yujinrobot.com>' to fix it.") | ||
| endif() | ||
| _list_append_unique(overhead_bullshit_INCLUDE_DIRS ${include}) | ||
| endforeach() | ||
| endif() | ||
|
|
||
| set(libraries "") | ||
| foreach(library ${libraries}) | ||
| # keep build configuration keywords, target names and absolute libraries as-is | ||
| if("${library}" MATCHES "^(debug|optimized|general)$") | ||
| list(APPEND overhead_bullshit_LIBRARIES ${library}) | ||
| elseif(TARGET ${library}) | ||
| list(APPEND overhead_bullshit_LIBRARIES ${library}) | ||
| elseif(IS_ABSOLUTE ${library}) | ||
| list(APPEND overhead_bullshit_LIBRARIES ${library}) | ||
| else() | ||
| set(lib_path "") | ||
| set(lib "${library}-NOTFOUND") | ||
| # since the path where the library is found is returned we have to iterate over the paths manually | ||
| foreach(path /opt/ros/indigo/lib;/opt/ros/indigo/lib) | ||
| find_library(lib ${library} | ||
| PATHS ${path} | ||
| NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH) | ||
| if(lib) | ||
| set(lib_path ${path}) | ||
| break() | ||
| endif() | ||
| endforeach() | ||
| if(lib) | ||
| _list_append_unique(overhead_bullshit_LIBRARY_DIRS ${lib_path}) | ||
| list(APPEND overhead_bullshit_LIBRARIES ${lib}) | ||
| else() | ||
| # as a fall back for non-catkin libraries try to search globally | ||
| find_library(lib ${library}) | ||
| if(NOT lib) | ||
| message(FATAL_ERROR "Project '${PROJECT_NAME}' tried to find library '${library}'. The library is neither a target nor built/installed properly. Did you compile project 'overhead_bullshit'? Did you find_package() it before the subdirectory containing its code is included?") | ||
| endif() | ||
| list(APPEND overhead_bullshit_LIBRARIES ${lib}) | ||
| endif() | ||
| endif() | ||
| endforeach() | ||
|
|
||
| set(overhead_bullshit_EXPORTED_TARGETS "") | ||
| # create dummy targets for exported code generation targets to make life of users easier | ||
| foreach(t ${overhead_bullshit_EXPORTED_TARGETS}) | ||
| if(NOT TARGET ${t}) | ||
| add_custom_target(${t}) | ||
| endif() | ||
| endforeach() | ||
|
|
||
| set(depends "") | ||
| foreach(depend ${depends}) | ||
| string(REPLACE " " ";" depend_list ${depend}) | ||
| # the package name of the dependency must be kept in a unique variable so that it is not overwritten in recursive calls | ||
| list(GET depend_list 0 overhead_bullshit_dep) | ||
| list(LENGTH depend_list count) | ||
| if(${count} EQUAL 1) | ||
| # simple dependencies must only be find_package()-ed once | ||
| if(NOT ${overhead_bullshit_dep}_FOUND) | ||
| find_package(${overhead_bullshit_dep} REQUIRED) | ||
| endif() | ||
| else() | ||
| # dependencies with components must be find_package()-ed again | ||
| list(REMOVE_AT depend_list 0) | ||
| find_package(${overhead_bullshit_dep} REQUIRED ${depend_list}) | ||
| endif() | ||
| _list_append_unique(overhead_bullshit_INCLUDE_DIRS ${${overhead_bullshit_dep}_INCLUDE_DIRS}) | ||
|
|
||
| # merge build configuration keywords with library names to correctly deduplicate | ||
| _pack_libraries_with_build_configuration(overhead_bullshit_LIBRARIES ${overhead_bullshit_LIBRARIES}) | ||
| _pack_libraries_with_build_configuration(_libraries ${${overhead_bullshit_dep}_LIBRARIES}) | ||
| _list_append_deduplicate(overhead_bullshit_LIBRARIES ${_libraries}) | ||
| # undo build configuration keyword merging after deduplication | ||
| _unpack_libraries_with_build_configuration(overhead_bullshit_LIBRARIES ${overhead_bullshit_LIBRARIES}) | ||
|
|
||
| _list_append_unique(overhead_bullshit_LIBRARY_DIRS ${${overhead_bullshit_dep}_LIBRARY_DIRS}) | ||
| list(APPEND overhead_bullshit_EXPORTED_TARGETS ${${overhead_bullshit_dep}_EXPORTED_TARGETS}) | ||
| endforeach() | ||
|
|
||
| set(pkg_cfg_extras "") | ||
| foreach(extra ${pkg_cfg_extras}) | ||
| if(NOT IS_ABSOLUTE ${extra}) | ||
| set(extra ${overhead_bullshit_DIR}/${extra}) | ||
| endif() | ||
| include(${extra}) | ||
| endforeach() |
| @@ -0,0 +1,18 @@ | ||
| <launch> | ||
| <!-- Map server --> | ||
| <arg name="map_file" default="$(env TURTLEBOT_GAZEBO_MAP_FILE)"/> | ||
| <node name="map_server" pkg="map_server" type="map_server" args="$(arg map_file)" /> | ||
|
|
||
| <!-- Localization --> | ||
| <arg name="initial_pose_x" default="0.0"/> | ||
| <arg name="initial_pose_y" default="0.0"/> | ||
| <arg name="initial_pose_a" default="0.0"/> | ||
| <include file="$(find turtlebot_navigation)/launch/includes/amcl.launch.xml"> | ||
| <arg name="initial_pose_x" value="$(arg initial_pose_x)"/> | ||
| <arg name="initial_pose_y" value="$(arg initial_pose_y)"/> | ||
| <arg name="initial_pose_a" value="$(arg initial_pose_a)"/> | ||
| </include> | ||
|
|
||
| <!-- Move base --> | ||
| <include file="$(find turtlebot_navigation)/launch/includes/move_base.launch.xml"/> | ||
| </launch> |
| @@ -0,0 +1,3 @@ | ||
| <launch> | ||
| <include file="$(find turtlebot_navigation)/launch/includes/gmapping.launch.xml"/> | ||
| </launch> |
| @@ -0,0 +1,32 @@ | ||
| <launch> | ||
| <arg name="base"/> | ||
| <arg name="stacks"/> | ||
| <arg name="3d_sensor"/> | ||
|
|
||
| <arg name="urdf_file" default="$(find xacro)/xacro.py '$(find turtlebot_description)/robots/$(arg base)_$(arg stacks)_$(arg 3d_sensor).urdf.xacro'" /> | ||
| <param name="robot_description" command="$(arg urdf_file)" /> | ||
|
|
||
| <!-- Gazebo model spawner --> | ||
| <node name="spawn_turtlebot_model" pkg="gazebo_ros" type="spawn_model" | ||
| args="$(optenv ROBOT_INITIAL_POSE) -unpause -urdf -param robot_description -model turtlebot"/> | ||
|
|
||
| <!-- Odometry estimator --> | ||
| <node pkg="robot_pose_ekf" type="robot_pose_ekf" name="robot_pose_ekf"> | ||
| <remap from="imu_data" to="turtlebot_node/imu/data"/> | ||
| <remap from="robot_pose_ekf/odom" to="odom_combined"/> | ||
| <param name="freq" value="30.0"/> | ||
| <param name="sensor_timeout" value="1.0"/> | ||
| <param name="odom_used" value="true"/> | ||
| <param name="imu_used" value="true"/> | ||
| <param name="vo_used" value="false"/> | ||
| <param name="output_frame" value="odom"/> | ||
| </node> | ||
|
|
||
| <!-- Velocity muxer --> | ||
| <node pkg="nodelet" type="nodelet" name="mobile_base_nodelet_manager" args="manager"/> | ||
| <node pkg="nodelet" type="nodelet" name="cmd_vel_mux" | ||
| args="load yocs_cmd_vel_mux/CmdVelMuxNodelet mobile_base_nodelet_manager"> | ||
| <param name="yaml_cfg_file" value="$(find turtlebot_bringup)/param/mux.yaml" /> | ||
| <remap from="cmd_vel_mux/output" to="turtlebot_node/cmd_vel" /> | ||
| </node> | ||
| </launch> |
| @@ -0,0 +1,23 @@ | ||
| <launch> | ||
| <arg name="base"/> | ||
| <arg name="stacks"/> | ||
| <arg name="3d_sensor"/> | ||
|
|
||
| <arg name="urdf_file" default="$(find xacro)/xacro.py '$(find turtlebot_description)/robots/$(arg base)_$(arg stacks)_$(arg 3d_sensor).urdf.xacro'" /> | ||
| <param name="robot_description" command="$(arg urdf_file)" /> | ||
|
|
||
| <!-- Gazebo model spawner --> | ||
| <node name="spawn_turtlebot_model" pkg="gazebo_ros" type="spawn_model" | ||
| args="$(optenv ROBOT_INITIAL_POSE) -unpause -urdf -param robot_description -model mobile_base"/> | ||
|
|
||
| <!-- Velocity muxer --> | ||
| <node pkg="nodelet" type="nodelet" name="mobile_base_nodelet_manager" args="manager"/> | ||
| <node pkg="nodelet" type="nodelet" name="cmd_vel_mux" | ||
| args="load yocs_cmd_vel_mux/CmdVelMuxNodelet mobile_base_nodelet_manager"> | ||
| <param name="yaml_cfg_file" value="$(find turtlebot_bringup)/param/mux.yaml" /> | ||
| <remap from="cmd_vel_mux/output" to="mobile_base/commands/velocity"/> | ||
| </node> | ||
|
|
||
| <!-- Bumper/cliff to pointcloud (not working, as it needs sensors/core messages) --> | ||
| <include file="$(find turtlebot_bringup)/launch/includes/kobuki/bumper2pc.launch.xml"/> | ||
| </launch> |
| @@ -0,0 +1,32 @@ | ||
| <launch> | ||
| <arg name="base"/> | ||
| <arg name="stacks"/> | ||
| <arg name="3d_sensor"/> | ||
|
|
||
| <arg name="urdf_file" default="$(find xacro)/xacro.py '$(find turtlebot_description)/robots/$(arg base)_$(arg stacks)_$(arg 3d_sensor).urdf.xacro'" /> | ||
| <param name="robot_description" command="$(arg urdf_file)" /> | ||
|
|
||
| <!-- Gazebo model spawner --> | ||
| <node name="spawn_turtlebot_model" pkg="gazebo_ros" type="spawn_model" | ||
| args="$(optenv ROBOT_INITIAL_POSE) -unpause -urdf -param robot_description -model turtlebot"/> | ||
|
|
||
| <!-- Odometry estimator --> | ||
| <node pkg="robot_pose_ekf" type="robot_pose_ekf" name="robot_pose_ekf"> | ||
| <remap from="imu_data" to="turtlebot_node/imu/data"/> | ||
| <remap from="robot_pose_ekf/odom" to="odom_combined"/> | ||
| <param name="freq" value="30.0"/> | ||
| <param name="sensor_timeout" value="1.0"/> | ||
| <param name="odom_used" value="true"/> | ||
| <param name="imu_used" value="true"/> | ||
| <param name="vo_used" value="false"/> | ||
| <param name="output_frame" value="odom"/> | ||
| </node> | ||
|
|
||
| <!-- Velocity muxer --> | ||
| <node pkg="nodelet" type="nodelet" name="mobile_base_nodelet_manager" args="manager"/> | ||
| <node pkg="nodelet" type="nodelet" name="cmd_vel_mux" | ||
| args="load yocs_cmd_vel_mux/CmdVelMuxNodelet mobile_base_nodelet_manager"> | ||
| <param name="yaml_cfg_file" value="$(find turtlebot_bringup)/param/mux.yaml" /> | ||
| <remap from="cmd_vel_mux/output" to="turtlebot_node/cmd_vel" /> | ||
| </node> | ||
| </launch> |
| @@ -0,0 +1,41 @@ | ||
| <launch> | ||
| <arg name="world_file" default="$(env TURTLEBOT_GAZEBO_WORLD_FILE)"/> | ||
|
|
||
| <arg name="base" value="$(optenv TURTLEBOT_BASE kobuki)"/> <!-- create, roomba --> | ||
| <arg name="battery" value="$(optenv TURTLEBOT_BATTERY /proc/acpi/battery/BAT0)"/> <!-- /proc/acpi/battery/BAT0 --> | ||
| <arg name="gui" default="true"/> | ||
| <arg name="stacks" value="$(optenv TURTLEBOT_STACKS hexagons)"/> <!-- circles, hexagons --> | ||
| <arg name="3d_sensor" value="$(optenv TURTLEBOT_3D_SENSOR kinect)"/> <!-- kinect, asus_xtion_pro --> | ||
|
|
||
| <include file="$(find gazebo_ros)/launch/empty_world.launch"> | ||
| <arg name="use_sim_time" value="true"/> | ||
| <arg name="debug" value="false"/> | ||
| <arg name="gui" value="$(arg gui)" /> | ||
| <arg name="world_name" value="$(arg world_file)"/> | ||
| </include> | ||
|
|
||
| <include file="$(find turtlebot_gazebo)/launch/includes/$(arg base).launch.xml"> | ||
| <arg name="base" value="$(arg base)"/> | ||
| <arg name="stacks" value="$(arg stacks)"/> | ||
| <arg name="3d_sensor" value="$(arg 3d_sensor)"/> | ||
| </include> | ||
|
|
||
| <node pkg="robot_state_publisher" type="robot_state_publisher" name="robot_state_publisher"> | ||
| <param name="publish_frequency" type="double" value="30.0" /> | ||
| </node> | ||
|
|
||
| <node name="robotController" pkg="overhead_bullshit" type="GoForward.py" respawn="false" output="screen" > | ||
|
|
||
| </node> | ||
|
|
||
| <!-- Fake laser --> | ||
| <node pkg="nodelet" type="nodelet" name="laserscan_nodelet_manager" args="manager"/> | ||
| <node pkg="nodelet" type="nodelet" name="depthimage_to_laserscan" | ||
| args="load depthimage_to_laserscan/DepthImageToLaserScanNodelet laserscan_nodelet_manager"> | ||
| <param name="scan_height" value="10"/> | ||
| <param name="output_frame_id" value="/camera_depth_frame"/> | ||
| <param name="range_min" value="0.45"/> | ||
| <remap from="image" to="/camera/depth/image_raw"/> | ||
| <remap from="scan" to="/scan"/> | ||
| </node> | ||
| </launch> |
| @@ -0,0 +1,6 @@ | ||
| free_thresh: 0.196 | ||
| image: playground.pgm | ||
| negate: 0 | ||
| occupied_thresh: 0.65 | ||
| origin: [-6.8999999999999915, -5.8999999999999915, 0.0] | ||
| resolution: 0.05 |
| @@ -0,0 +1,74 @@ | ||
| #!/usr/bin/env python | ||
|
|
||
| ''' | ||
| Copyright (c) 2015, Mark Silliman | ||
| All rights reserved. | ||
| Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: | ||
| 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. | ||
| 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. | ||
| 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. | ||
| THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
| ''' | ||
|
|
||
| # A very basic TurtleBot script that moves TurtleBot forward indefinitely. Press CTRL + C to stop. To run: | ||
| # On TurtleBot: | ||
| # roslaunch turtlebot_bringup minimal.launch | ||
| # On work station: | ||
| # python goforward.py | ||
|
|
||
| import rospy | ||
| from geometry_msgs.msg import Twist | ||
|
|
||
| class GoForward(): | ||
| def __init__(self): | ||
| # initiliaze | ||
| rospy.init_node('GoForward', anonymous=False) | ||
|
|
||
| # tell user how to stop TurtleBot | ||
| rospy.loginfo("To stop TurtleBot CTRL + C") | ||
|
|
||
| # What function to call when you ctrl + c | ||
| rospy.on_shutdown(self.shutdown) | ||
|
|
||
| # Create a publisher which can "talk" to TurtleBot and tell it to move | ||
| # Tip: You may need to change cmd_vel_mux/input/navi to /cmd_vel if you're not using TurtleBot2 | ||
| self.cmd_vel = rospy.Publisher('cmd_vel_mux/input/navi', Twist, queue_size=10) | ||
|
|
||
| #TurtleBot will stop if we don't keep telling it to move. How often should we tell it to move? 10 HZ | ||
| r = rospy.Rate(10); | ||
|
|
||
| # Twist is a datatype for velocity | ||
| move_cmd = Twist() | ||
| # let's go forward at 0.2 m/s | ||
| move_cmd.linear.x = 0.2 | ||
| # let's turn at 0 radians/s | ||
| move_cmd.angular.z = 0 | ||
|
|
||
| # as long as you haven't ctrl + c keeping doing... | ||
| while not rospy.is_shutdown(): | ||
| # publish the velocity | ||
| self.cmd_vel.publish(move_cmd) | ||
| # wait for 0.1 seconds (10 HZ) and publish again | ||
| r.sleep() | ||
|
|
||
|
|
||
| def shutdown(self): | ||
| # stop turtlebot | ||
| rospy.loginfo("Stop TurtleBot") | ||
| # a default Twist has linear.x of 0 and angular.z of 0. So it'll stop TurtleBot | ||
| self.cmd_vel.publish(Twist()) | ||
| # sleep just makes sure TurtleBot receives the stop command prior to shutting down the script | ||
| rospy.sleep(1) | ||
|
|
||
| if __name__ == '__main__': | ||
| try: | ||
| GoForward() | ||
| except: | ||
| rospy.loginfo("GoForward node terminated.") | ||
|
|
||
|
|
| @@ -0,0 +1,26 @@ | ||
| <package> | ||
| <name>overhead_bullshit</name> | ||
| <version>2.2.2</version> | ||
| <description>Gazebo launchers and worlds for TurtleBot simulation</description> | ||
| <maintainer email="marcus.liebhardt@yujinrobot.com">Marcus Liebhardt</maintainer> | ||
| <license>BSD</license> | ||
| <url type="website">http://ros.org/wiki/turtlebot_gazebo</url> | ||
| <url type="repository">https://github.com/turtlebot/turtlebot_simulator</url> | ||
| <url type="bugtracker">https://github.com/turtlebot/turtlebot_simulator/issues</url> | ||
| <author email="turtlebot@willowgarage.com">Willow Garage</author> | ||
|
|
||
| <buildtool_depend>catkin</buildtool_depend> | ||
|
|
||
| <run_depend>yocs_cmd_vel_mux</run_depend> | ||
| <!-- <run_depend>create_gazebo_plugins</run_depend> disable irobot create due to the compile error in plugin--> | ||
| <run_depend>diagnostic_aggregator</run_depend> | ||
| <run_depend>depthimage_to_laserscan</run_depend> | ||
| <run_depend>gazebo_ros</run_depend> | ||
| <run_depend>kobuki_gazebo_plugins</run_depend> | ||
| <run_depend>robot_pose_ekf</run_depend> | ||
| <run_depend>robot_state_publisher</run_depend> | ||
| <run_depend>turtlebot_bringup</run_depend> | ||
| <run_depend>turtlebot_description</run_depend> | ||
| <run_depend>turtlebot_navigation</run_depend> | ||
| <run_depend>xacro</run_depend> | ||
| </package> |
| @@ -0,0 +1,20 @@ | ||
| <?xml version="1.0" ?> | ||
| <sdf version="1.4"> | ||
| <world name="default"> | ||
| <!-- A global light source --> | ||
| <include> | ||
| <uri>model://sun</uri> | ||
| </include> | ||
| <!-- A ground plane --> | ||
| <include> | ||
| <uri>model://ground_plane</uri> | ||
| </include> | ||
| <!-- Own physics settings to speed up simulation --> | ||
| <physics type='ode'> | ||
| <max_step_size>0.01</max_step_size> | ||
| <real_time_factor>1</real_time_factor> | ||
| <real_time_update_rate>100</real_time_update_rate> | ||
| <gravity>0 0 -9.8</gravity> | ||
| </physics> | ||
| </world> | ||
| </sdf> |