-
Notifications
You must be signed in to change notification settings - Fork 132
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Use grouped low level components for simulation #583
[WIP] Use grouped low level components for simulation #583
Conversation
grouping legacy components and applying new structure for cob3-2 |
@ipa-mdl @ipa-fmw @ipa-nhg @ipa-bnm @ipa-mig feedback welcome! |
1c07fcf
to
44319a0
Compare
Still missing are the raw's Still, feel free to drop in feedback already! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Getting impatient? ;-)
I like this. Seems to reduce a lot of duplication.
(Note that I did not check all robot specific launch and xml files for now)
<arg name="raw_cmd_vel_topic" default="velocity_smoother/command"/> | ||
<arg name="smooth_cmd_vel_topic" default="twist_controller/command"/> | ||
<arg name="robot_cmd_vel_topic" default="twist_controller/command"/> | ||
<arg name="odom_topic" default="odometry_controller/odometry"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mixed tabs and spaces
<arg name="name" default="head_cam"/> | ||
<arg name="sim" default="false"/> | ||
|
||
<include unless="$(arg sim)" file="$(find cob_bringup)/drivers/usb_camera_node.launch"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tabs vs spaces
<arg name="camera_name" value="$(arg name)"/> | ||
<arg name="colorimage_in" value="/$(arg name)/image_rect_color"/> | ||
<arg name="colorimage_out" value="/$(arg name)_upright/image_rect_color"/> | ||
</include> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
2 tabs
<include file="$(find cob_bringup)/controllers/cob_trajectory_controller.launch"> | ||
<arg name="robot" value="$(arg robot)"/> | ||
<arg name="component_name" value="$(arg component_name)"/> | ||
</include> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tabs vs spaces
<arg name="robot" value="$(arg robot)" /> | ||
<arg name="component_name" value="$(arg component_name)" /> | ||
</include> | ||
<include file="$(find cob_bringup)/controllers/cob_trajectory_controller.launch"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
imo, it would improve readability to add an empty line between includes. what do you think?
</group> | ||
<include file="$(find cob_bringup)/components/canopen_base.launch" unless="$(arg use_old_base_drive_chain)"> | ||
<arg name="robot" value="$(arg robot)"/> | ||
</include> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't the group
block below be exchanged with the legacy_base.launch
file`?
</include> | ||
<!--include file="$(find cob_bringup)/tools/wifi_monitor.launch" > | ||
<arg name="robot" value="$(arg robot)" /> | ||
</include--> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason to comment out the wifi_monitor
?
Please try roslaunch-dump it should dump the fully parsed launchfile with all entries sorted for comparison. |
@ipa-mdl, I tried to figure out how to use your script...can you give a usage example? |
as you would run |
|
68e3400
to
4281c06
Compare
For travis to be happy, https://github.com/ipa320/cob_common/pull/202 is required I consider this restructuring done....for now...more iterations will follow...(see suggested steps below) Simulation is working for all robots and basic functionality tests (move around using dashboard) were successful In case you guys agree with this approach, I would like to merge this quite soon, as it will almost be impossible to resolve merge conflicts in case other PRs get merged in the meantime... |
e0cf511
to
5cfdc20
Compare
In future PRs
...among other things...tbd |
|
||
<include file="$(find cob_bringup)/drivers/usb_camera_node.launch"> | ||
<include unless="$(arg sim)" file="$(find cob_bringup)/drivers/usb_camera_node.launch"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
alignment was wrong
@@ -8,6 +8,7 @@ | |||
|
|||
<include unless="$(arg sim)" file="$(find realsense_camera)/launch/r200_nodelet_rgbd.launch"> | |||
<arg name="camera" value="$(arg name)"/> | |||
<arg name="num_worker_threads" default="$(arg num_worker_threads)" /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
default -> value?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
copy-paste...:wink:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the woes of commit-based review ;)
5cfdc20
to
0a5f1d0
Compare
<arg name="robot" value="$(arg robot)"/> | ||
<arg name="yaml_name" value="$(arg name)"/> | ||
</include> | ||
<include file="$(find cob_bringup)/drivers/image_flip_nodelet.launch"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use flip
argument
<arg name="robot" value="$(arg robot)"/> | ||
<arg name="yaml_name" value="$(arg name)"/> | ||
</include> | ||
<include file="$(find cob_bringup)/drivers/image_flip.launch"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use flip
argument
4bcb15d
to
cd4b234
Compare
tag eol-cob3 has been added |
* refactored generic canopen&config into canopen_generic.launch * refactored base driver+config into canopen_base.launch * added components/cob4_head_camera.launch * added components/cam3d_openni2.launch * added components/cam3d_r200_rgbd.launch * introduce sim arg for components * use sim arg in robot.xml * remove nodes started within robot.xml from default_controllers_robot.launch * introducing legacy components * reorganize and sim toggle for more components * adjust cob4-1 to latest changes * use new structure for cob3-2 * use new structure for cob3-6 * use new structure for cob3-9 * use new structure for cob4-2 * use new structure for remaining cob4s * travis fixes * syntax styling * use new structure for raws * more travis fixes * harmonize old vs. new behavior cob4-1 * guarantee same hw behavior as before * add flip argument
builds on top of #575
I then introduced a
sim
launch-argument and made use of it incob_bringup/robot.xml
There I followed the scheme:
Within each
machine
-tag:group unless="$(arg sim)"
, where hardware specific nodes are startedsim
argument is passedAfterwards I removed from
cob_configuration_controller_gazebo/default_controllers_robot.launch
all the parts that are now covered by the new robot.xml file. What is left there is simulation-specific.To use this in simulation ipa320/cob_simulation#131 is required
This is part of #437