ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

LR1997's profile - activity

2023-03-24 07:08:03 -0500 received badge  Famous Question (source)
2023-02-27 09:06:39 -0500 received badge  Famous Question (source)
2021-12-16 10:49:02 -0500 received badge  Famous Question (source)
2021-09-05 10:38:36 -0500 received badge  Notable Question (source)
2021-05-07 12:40:19 -0500 received badge  Nice Answer (source)
2021-04-22 02:44:49 -0500 received badge  Notable Question (source)
2021-04-21 12:25:11 -0500 received badge  Popular Question (source)
2021-04-21 07:29:43 -0500 asked a question Add a condition in a while loop

Add a condition in a while loop Hi guys, I was wondering how is it possible to introduce a condition in a standard spin

2021-04-14 01:57:18 -0500 marked best answer grouping launch file

Hi everyone, I need to start different nodes in the launch file. At the moment I do it by defining 2 arguments (var1 and var2) and then by grouping the launch files. Something like:

<group if="$(arg var1)"> 
   start some nodes
</group>

<group if="$(arg var2)">
  start  other nodes
</group>

and launching from terminal the following:

roslaunch my_package my_launch_file var1:=true var2:=false

This works, but my question is: is there a way I could launch by defining only one arg? For example what I want to achieve is:

<arg name="variable"/> 

    <group if=**(variable=1)**>        --> How can I implement this?
    start some nodes
        </group>

        <group if=(variable=2)>
start other nodes
        </group>

and therefore using from terminal only:

roslaunch my_package launch_file variable:=1

or

roslaunch my_package launch_file variable:=2
2021-04-14 01:57:18 -0500 received badge  Scholar (source)
2021-04-14 01:50:30 -0500 commented answer grouping launch file

Thank you, this solved my problem :)

2021-04-13 14:40:09 -0500 received badge  Popular Question (source)
2021-04-13 14:27:48 -0500 received badge  Teacher (source)
2021-04-13 10:26:38 -0500 asked a question grouping launch file

grouping launch file Hi everyone, I need to start different nodes in the launch file. At the moment I do it by defining

2021-04-13 10:14:32 -0500 edited answer How to launch node if param equals true?

Hi, I think the easiest way is by defining an arg. Something like: <arg name="var"/> and then grouping the no

2021-04-13 10:14:32 -0500 received badge  Editor (source)
2021-04-13 10:12:48 -0500 edited answer How to launch node if param equals true?

Hi, I think the easiest way is by defining an arg. Something like: <arg name="var"/> and then grouping the no

2021-04-13 10:09:48 -0500 answered a question How to launch node if param equals true?

Hi, I think the easiest way is by defining an arg. Something like: <arg name="var"/> and then grouping the no

2021-04-13 10:09:48 -0500 received badge  Rapid Responder (source)
2021-04-08 01:55:29 -0500 received badge  Enthusiast
2021-03-31 03:21:45 -0500 received badge  Supporter (source)
2021-03-29 00:16:04 -0500 received badge  Notable Question (source)
2021-03-27 09:34:00 -0500 received badge  Popular Question (source)
2021-03-27 09:11:04 -0500 received badge  Student (source)
2021-03-26 10:40:50 -0500 asked a question launch different nodes based on user choice

launch different nodes based on user choice Hi everyone, I am trying to develop a simple program that ask the user if t