Euros will burn.
You do not know how to create a launch file, right?
Let's solve this problem today.
Okay.
What is a launch file?
It's an executable file in which we describe all our nodes that we want to run and all the configuration
we can provide.
And with the single command, we can launch every node and configuration.
And now we will have to create a launch directory.
Launch.
Okay.
And inside the launch, we will create a new file.
Node underscore lounge dot bar.
All right, so this is our lounge file.
In order to use the lounge file, we will need to make some changes and see make list.
We just have to add these lines inside our c make list.
We have to declare the folder that we made.
So we have mentioned it here.
So just copy it.
Come here and open the cmake list and here you can paste that line.
All right, so that's it.
This is what you have to make change inside the list.
And now come to lounge file.
And here's a piece of code copy and paste here.
Let me explain what is it's doing here.
We are just importing lounge and here we are importing a package and it's module actions.
There is a function generate lounge description and which returns the lounge description inside that
we are choosing.
Lounge Ross Action dot Node.
So here node is action which needs several arguments like package name, executable file and node name,
and we will mention our arguments here and it will be launching all the information that we provided.
Our package name is Turtle, same port and our executable is the talker.
And if we want to change the name, we can also do that here, like launch Node.
Okay, so this, this will be the name of the node.
We have to build it because we have made some changes in the quake list.
We're also launch and Turtle sim port.
And our launch file which was the node underscore launch dot pi.
Open up another terminal and check Ross to node list.
Chair launch node and we can also see the topic list.
There is our topic.
So ros2 topic eco.
And there we go to your receiving director.
So can we launch the multiple nodes using the file?
The answer is yes.
And now you can do that.
Will just copy this and paste it.
Here.
And the package will be the turtle same and the executable will be the listener.
Let's make some changes here.
Launch Node CPP Publisher.
Subscriber.
Okay.
Now it will run both publisher and subscriber.
If we open the.
There you go.
Launch North Cape Publisher and they launch North Cape Subscriber.
There is a topic.
We also have a Python publisher.
We will also launch it.
Okay, So I launched it and the refresh.