Skip to content

Commit

Permalink
small changes, adding course content
Browse files Browse the repository at this point in the history
  • Loading branch information
johnny555 committed Nov 3, 2023
1 parent ac76c96 commit 6cde70d
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 8 deletions.
6 changes: 5 additions & 1 deletion course/day3.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,11 @@ Gazebo is like the world, and this robot is now like a remote controlled car. Yo

## Take some time to play with the simulation.

Notice the number in the bottom right of the screen, this number is the real-time percentage of your simulation. If its at or near 100% this means that the simulation is running at realtime, if its less than 100% then the simulation is running slower than real time. For example, 30% means every 3 real world seconds, only 1 second elapses in the simulated world. It should be running pretty fast right now, but tomorrow it will be different.
Notice the number in the bottom right of the screen, this number is the real-time percentage of your simulation.

If its at or near 100% this means that the simulation is running at realtime, if its less than 100%
then the simulation is running slower than real time. For example, 30% means every 3 real world seconds, only 1 second elapses in the simulated world. It should be running pretty fast right now, but tomorrow it will be different.

That's all I wanted to show you today, but if you want to dive a little deeper, there are two other things I'd like to highlight.

# Launching Your Robot System
Expand Down
1 change: 1 addition & 0 deletions course/day4.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

28 changes: 21 additions & 7 deletions src/start_creating_robots/launch/mapping.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

from os.path import join


def generate_launch_description():
# This allows us to have the with_sensors as an argument on the command line
rviz_config_arg = DeclareLaunchArgument(
Expand All @@ -25,7 +26,8 @@ def generate_launch_description():
launch_arguments=[('with_sensors','true')])

# Extended Gazebo Bridge: To do mapping requires alot more info from the simulation. We need sensor data and estimates of the robot joint positions.
extended_bridge = Node( package='ros_gz_bridge', name="extended_gazebo_bridge", executable='parameter_bridge', arguments=['/model/krytn/odometry@nav_msgs/msg/Odometry[gz.msgs.Odometry',
extended_bridge = Node( package='ros_gz_bridge', name="extended_gazebo_bridge", executable='parameter_bridge',
arguments=['/model/krytn/odometry@nav_msgs/msg/Odometry[gz.msgs.Odometry',
'/model/krytn/tf@tf2_msgs/msg/TFMessage[gz.msgs.Pose_V',

'/lidar@sensor_msgs/msg/LaserScan@gz.msgs.LaserScan',
Expand All @@ -37,19 +39,31 @@ def generate_launch_description():

'/clock@rosgraph_msgs/msg/Clock[gz.msgs.Clock',

'/joint_states@sensor_msgs/msg/JointState[gz.msgs.Model'], output='screen', remappings=[('/model/krytn/odometry','/odom'),
'/joint_states@sensor_msgs/msg/JointState[gz.msgs.Model'],
output='screen', remappings=[('/model/krytn/odometry','/odom'),
('/model/krytn/tf','/tf')]
)

# Gazebo fortress has a bug that won't respect our frame_id tags. So we have to publish a transform
depth_cam_link_tf = Node(package='tf2_ros', executable='static_transform_publisher', name='depthCamLinkTF', output='log', arguments=['0.0', '0.0', '0.0', '0.0', '0.0', '0.0', 'realsense_d435', 'krytn/base_footprint/realsense_d435'])
depth_cam_link_tf = Node(package='tf2_ros',
executable='static_transform_publisher',
name='depthCamLinkTF',
output='log',
arguments=['0.0', '0.0', '0.0', '0.0', '0.0', '0.0',
'realsense_d435', 'krytn/base_footprint/realsense_d435'])

krytn_base_fp_link_tf = Node(package='tf2_ros', executable='static_transform_publisher', name='base_fp_linkTF', output='log', arguments=['0.0', '0.0', '0.0', '0.0', '0.0', '0.0', 'krytn/base_footprint', 'base_footprint'])
krytn_base_fp_link_tf = Node(package='tf2_ros',
executable='static_transform_publisher',
name='base_fp_linkTF',
output='log',
arguments=['0.0', '0.0', '0.0', '0.0', '0.0', '0.0', 'krytn/base_footprint', 'base_footprint'])

# SLAM Toolbox for mapping
slam_toolbox = Node( package='slam_toolbox', executable='async_slam_toolbox_node', parameters=[
get_package_share_directory('start_creating_robots') + '/config/mapping.yaml'
], output='screen'
slam_toolbox = Node( package='slam_toolbox',
executable='async_slam_toolbox_node',
parameters=[
get_package_share_directory('start_creating_robots') + '/config/mapping.yaml'
], output='screen'
)

rviz = Node(
Expand Down

0 comments on commit 6cde70d

Please sign in to comment.