WEBVTT

00:00.170 --> 00:08.270
We are finally ready to start our node that uses the movie API to set a goal for our robot, plan a

00:08.270 --> 00:12.320
trajectory, and then execute the planned trajectory.

00:12.530 --> 00:15.770
To execute all of these, let's open a new terminal.

00:15.800 --> 00:20.540
Let's go to the workspace and let's build it with Qualcomm Build.

00:22.190 --> 00:24.290
Then in a new window of the terminal.

00:24.290 --> 00:27.560
Let's start by launching the gazebo simulation of the robot.

00:27.560 --> 00:31.190
So let's source the file setup bash.

00:31.190 --> 00:39.920
And let's launch with Ros2 launch from the Arduino board description the gazebo launch dot Pi.

00:39.950 --> 00:46.370
So now this is starting the gazebo simulation of our robot in the empty word perfect.

00:46.370 --> 00:47.540
So here we go.

00:48.320 --> 00:54.770
Now let's make this terminal a little bit bigger as we are going to start also the control system of

00:54.770 --> 00:55.550
the robot.

00:55.550 --> 01:01.550
So in a new window again let's source the file setup dot bash.

01:01.550 --> 01:07.320
And then let's launch with rocket to launch from the Arduino bot controller.

01:07.350 --> 01:08.430
The control system.

01:08.430 --> 01:10.500
So the controller dot launch dot pi.

01:10.530 --> 01:12.300
So let's press enter.

01:12.330 --> 01:13.140
Perfect.

01:13.140 --> 01:16.380
And so with this we are starting the control system of the robot.

01:16.380 --> 01:22.080
And so we get the confirmation that both the arm controller and the gripper controller are properly

01:22.080 --> 01:22.950
running.

01:22.980 --> 01:28.350
Now if we open also a new window of the terminal we can finally start also move it.

01:28.740 --> 01:34.590
So again let's source the file setup dot bash and let's launch move it.

01:34.620 --> 01:43.770
So with Ros2 launch and from the Arduino bot move it package, let's start the move it dot launchpad.

01:43.800 --> 01:45.540
So let's press enter.

01:45.540 --> 01:49.350
And this is starting now the move it interface.

01:49.350 --> 01:55.320
And also we can see that here we have the service window that we configured and used in the previous

01:55.320 --> 01:56.700
lesson to move the robot.

01:56.700 --> 02:02.130
But now we are not going to use it as we want to move our robot using the node that we created.

02:02.130 --> 02:05.580
And so using the C plus plus or the Python API.

02:05.700 --> 02:09.810
So in order to start our code, let's open a new terminal.

02:09.810 --> 02:13.200
And here again let's source the workspace.

02:13.200 --> 02:18.600
And now I'm going to start the C plus plus implementation of the Python API.

02:18.630 --> 02:25.650
So I'm going to try to move our robot using the Python API that we developed in the C plus plus node.

02:25.650 --> 02:29.670
So I'm going to use the command Ros2 run.

02:29.670 --> 02:32.760
And from the Arduino robot CP examples.

02:32.760 --> 02:36.840
Let's start the simple move it interface.

02:36.840 --> 02:39.750
So this will start the C plus plus implementation.

02:39.750 --> 02:45.000
Otherwise if you want to start the Python implementation here, I will show you the command that you

02:45.000 --> 02:46.410
need to execute.

02:46.560 --> 02:53.700
And so again this is the Ros2 launch this time because for the Python implementation we developed a

02:53.700 --> 02:54.600
launch file.

02:54.600 --> 03:02.790
And from the Arduino bot Pi examples we want to start the simple move it interface to launch dot pi.

03:02.790 --> 03:06.390
So this one here starts the Python interface.

03:06.390 --> 03:12.790
So the node that uses the movie Python APIs to move the robot, and instead this one here that I'm going

03:12.790 --> 03:16.390
to use in this lesson starts the Cplusplus implementation.

03:16.390 --> 03:21.700
So let's close this terminal and let's instead launch this node here.

03:21.700 --> 03:26.200
So let's run this node here for the Arduino bot CP examples.

03:26.200 --> 03:28.150
So let's press enter.

03:28.840 --> 03:33.640
And as we can see as we press enter our robot moves in the simulated environment.

03:33.640 --> 03:38.590
So we can see that it reaches the desired position.

03:40.300 --> 03:43.240
And also the gripper now is opening.

03:43.240 --> 03:48.130
And so this is exactly the configuration that we have set in our Cplusplus node.

03:48.130 --> 03:50.500
So we wanted just the base.

03:50.500 --> 03:55.060
So this one here the motor of the base to rotate 90 degrees.

03:55.060 --> 03:58.150
And so the robot moved from this initial configuration to this one.

03:58.150 --> 04:00.700
And we also wanted the gripper to be opened.

04:00.700 --> 04:03.460
And so as we can see everything worked.

04:03.460 --> 04:08.710
So move it was able to plan the trajectory to the desired goal and also to execute it.
