Skip to content

Commit

Permalink
Refactor , delete unnecessary code
Browse files Browse the repository at this point in the history
  • Loading branch information
yambati03 committed May 30, 2024
1 parent ad0794d commit b0fa186
Show file tree
Hide file tree
Showing 21 changed files with 46 additions and 689 deletions.
86 changes: 0 additions & 86 deletions mapping/CMakeLists.txt

This file was deleted.

30 changes: 0 additions & 30 deletions mapping/package.xml

This file was deleted.

9 changes: 4 additions & 5 deletions urc_bringup/launch/bringup_simulation.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ def generate_launch_description():
use_sim_time = LaunchConfiguration("use_sim_time", default="true")

xacro_file = os.path.join(
get_package_share_directory("urc_hw_description"),
"urdf/walli.xacro"
get_package_share_directory("urc_hw_description"), "urdf/walli.xacro"
)
assert os.path.exists(xacro_file), "urdf path doesnt exist in " + str(xacro_file)
robot_description_config = process_file(
Expand Down Expand Up @@ -148,13 +147,13 @@ def generate_launch_description():
)

elevation_mapping_node = Node(
package="mapping",
executable="mapping_ElevationMapping",
package="urc_perception",
executable="urc_perception_ElevationMapping",
output="screen",
parameters=[
PathJoinSubstitution(
[
FindPackageShare("mapping"),
FindPackageShare("urc_perception"),
"config",
"mapping_params.yaml",
]
Expand Down
7 changes: 0 additions & 7 deletions urc_bringup/strategies/bt_test.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@
<LogInfo logger="{ros_log}"
message="Trying to Plan Path..."/>
</Delay>
<StatusLightPublisher topic_name="/cmd_statuslight_color" value="1"/>
<StatusLightPublisher topic_name="/cmd_statuslight_display" value="1"/>
<KeepRunningUntilFailure>
<Inverter>
<Sequence>
Expand Down Expand Up @@ -52,11 +50,6 @@
<input_port name="message"
default="&quot;Replace this with the true message.&quot;">Message to log.</input_port>
</Action>
<Action ID="StatusLightPublisher"
editable="true">
<input_port name="topic_name"/>
<input_port name="value"/>
</Action>
<Action ID="UpdateCurrentPose"
editable="true">
<input_port name="topic_name"/>
Expand Down
65 changes: 24 additions & 41 deletions urc_perception/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,76 +3,63 @@ project(urc_perception)

include(../cmake/default_settings.cmake)

# find dependencies
find_package(ament_cmake REQUIRED)
find_package(rclcpp REQUIRED)
find_package(rclcpp_components REQUIRED)
find_package(urc_msgs REQUIRED)
find_package(std_msgs REQUIRED)
find_package(nav_msgs REQUIRED)
find_package(sensor_msgs REQUIRED)
find_package(diagnostic_updater REQUIRED)
find_package(OpenCV 4 REQUIRED)
find_package(cv_bridge REQUIRED)
find_package(image_transport REQUIRED)
find_package(geometry_msgs REQUIRED)
find_package(tf2 REQUIRED)
find_package(tf2_sensor_msgs REQUIRED)
find_package(tf2_geometry_msgs REQUIRED)
find_package(nav2_costmap_2d REQUIRED)
find_package(pcl_conversions REQUIRED)
find_package(PCL 1.10 REQUIRED)

include_directories(
include
${nav2_costmap_2d_INCLUDE_DIRS}
${PCL_INCLUDE_DIRS}
)
link_directories(${PCL_LIBRARY_DIRS})
add_definitions(${PCL_DEFINITIONS})

# Library creation
add_library(${PROJECT_NAME} SHARED
src/aruco_detector.cpp
src/aruco_location.cpp
src/depth_laserscan.cpp
src/elevation_mapping.cpp
)

target_link_libraries(${PROJECT_NAME}
${PCL_LIBRARIES}
)

set(dependencies
rclcpp
rclcpp_components
urc_msgs
std_msgs
sensor_msgs
diagnostic_updater
cv_bridge
image_transport
OpenCV
geometry_msgs
tf2
tf2_sensor_msgs
tf2_geometry_msgs
nav2_costmap_2d
nav_msgs
pcl_conversions
)

ament_target_dependencies(${PROJECT_NAME}
${dependencies}
)

# Node registration
rclcpp_components_register_node(
${PROJECT_NAME}
PLUGIN "aruco_detector::ArucoDetector"
EXECUTABLE ${PROJECT_NAME}_ArucoDetector
)

rclcpp_components_register_node(
${PROJECT_NAME}
PLUGIN "aruco_location::ArucoLocation"
EXECUTABLE ${PROJECT_NAME}_ArucoLocation
)

rclcpp_components_register_node(
${PROJECT_NAME}
PLUGIN "depth_laserscan::DepthLaserScan"
EXECUTABLE ${PROJECT_NAME}_DepthLaserScan
PLUGIN "urc_perception::ElevationMapping"
EXECUTABLE ${PROJECT_NAME}_ElevationMapping
)

# Install launch files.
install(
DIRECTORY
launch
config
launch
DESTINATION share/${PROJECT_NAME}/
)

Expand All @@ -86,18 +73,14 @@ install(TARGETS

if(BUILD_TESTING)
find_package(ament_lint_auto REQUIRED)
# the following line skips the copyright linker
# the following line skips the linter which checks for copyrights
# comment the line when a copyright and license is added to all source files
set(ament_cmake_copyright_FOUND TRUE)
# the following line skips cpplint (only works in a git repo)
# comment the line when this package is in a git repo and when
# a copyright and license is added to all source files
set(ament_cmake_cpplint_FOUND TRUE)
ament_lint_auto_find_test_dependencies()
endif()

ament_export_include_directories(msg)

ament_export_include_directories(include)

ament_export_libraries(${PROJECT_NAME})
ament_export_dependencies(${dependencies})

ament_package()
17 changes: 0 additions & 17 deletions urc_perception/README.md

This file was deleted.

3 changes: 0 additions & 3 deletions urc_perception/config/aruco_detector_params.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions urc_perception/config/aruco_location_params.yaml

This file was deleted.

Empty file.
File renamed without changes.
54 changes: 0 additions & 54 deletions urc_perception/include/aruco_detector.hpp

This file was deleted.

Loading

0 comments on commit b0fa186

Please sign in to comment.