Skip to content
This repository has been archived by the owner on Dec 13, 2024. It is now read-only.

Commit

Permalink
Get Gazebo Config working (#316)
Browse files Browse the repository at this point in the history
  • Loading branch information
Abishalini authored Jul 23, 2024
1 parent 40976e1 commit 38a79fb
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions src/picknik_ur_gazebo_config/launch/sim/hardware_sim.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,16 +53,13 @@ def path_pattern_change_for_gazebo(urdf_string):


def generate_simulation_description(context, *args, **settings):
world_path = settings.get(
"gazebo_world_path",
"description/simulation_worlds/space_station_blocks_world.sdf",
)
use_gui = settings.get("gazebo_gui", False)
is_verbose = settings.get("gazebo_verbose", False)
world_path = "description/simulation_worlds/space_station_blocks_world.sdf"
use_gui = False
is_verbose = False

# Create a Gazebo world file that swaps out package:// paths with absolute path.
original_world_file = get_ros_path(
settings.get("gazebo_world_package_name", "picknik_ur_gazebo_config"),
"picknik_ur_gazebo_config",
world_path,
)
modified_world_file = os.path.join(
Expand Down Expand Up @@ -92,16 +89,13 @@ def generate_simulation_description(context, *args, **settings):

def generate_launch_description():
system_config_parser = SystemConfigParser()
optional_feature_setting = system_config_parser.get_optional_feature_configs()

# The path to the auto_created urdf files
robot_urdf = system_config_parser.get_processed_urdf()
robot_urdf_ignition = path_pattern_change_for_gazebo(robot_urdf)

# Launch Gazebo
gazebo = OpaqueFunction(
function=generate_simulation_description, kwargs=optional_feature_setting
)
gazebo = OpaqueFunction(function=generate_simulation_description)

init_pose_args = shlex.split("-x 0.0 -y 0.0 -z 1.03 -R 0.0 -P 0.0 -Y 0.0")
spawn_robot = Node(
Expand Down

0 comments on commit 38a79fb

Please sign in to comment.