Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
tutorials:intermediate:pepper_shopping [2020/08/19 09:47] – derrick | tutorials:intermediate:pepper_shopping [2022/02/08 14:11] (current) – [Creating an ASDF system for the cram_pepper_demo] sarthou | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Pepper | + | ====== Pepper |
===== Setting Up The Workspace ===== | ===== Setting Up The Workspace ===== | ||
This process assumes you have already installed CRAM on your laptop. If not, please visit the installation section. | This process assumes you have already installed CRAM on your laptop. If not, please visit the installation section. | ||
- | If you are using the image version of CRAM, please follow the next section. | + | If you are using the image version of CRAM, please follow the next section. Please note that Ubuntu 16.04 was used for this project. |
==== VM Set Up ==== | ==== VM Set Up ==== | ||
Line 11: | Line 11: | ||
< | < | ||
- | $ sudo apt update && sudo apt upgrade | + | $ sudo apt-get update && sudo apt-get upgrade |
</ | </ | ||
Line 17: | Line 17: | ||
< | < | ||
- | $ cd ~/ | + | $ sudo apt-get install ros-kinetic-joint-state-publisher-gui |
- | $ sudo apt install ros-kinetic-joint-state-publisher-gui | + | |
$ sudo apt-get install ros-kinetic-pepper-meshes | $ sudo apt-get install ros-kinetic-pepper-meshes | ||
</ | </ | ||
Line 28: | Line 27: | ||
< | < | ||
$ sudo apt-get install ros-kinetic-ros-control ros-kinetic-ros-controllers | $ sudo apt-get install ros-kinetic-ros-control ros-kinetic-ros-controllers | ||
- | $ sudo apt install ros-melodic-roslisp-common | + | $ sudo apt-get install ros-kinetic-roslisp-common |
</ | </ | ||
- | At this point, we need an older version of CRAM. We a specific branch of the CRAM architecture. Therefore, if you have some work done in the current version of CRAM, please | + | At this point, we need an older version of CRAM. We need a specific branch of the CRAM architecture. Therefore, if you have some work done in the current version of CRAM, please |
Run the following in your terminal. | Run the following in your terminal. | ||
Line 37: | Line 36: | ||
< | < | ||
$ cd ~/ | $ cd ~/ | ||
+ | $ git pull | ||
$ git checkout 3f5b268504cb5226709daa7a5d52364c2b05a93d | $ git checkout 3f5b268504cb5226709daa7a5d52364c2b05a93d | ||
$ git branch | $ git branch | ||
Line 45: | Line 45: | ||
==== Native Set Up ==== | ==== Native Set Up ==== | ||
- | If you did a native installation of ROS and CRAM, you would most likely install all the necessary components. However, you have to go through the setup process for the VM to be sure everything is setup. Otherwise, skip to the part where you change the branch, then you are set to go. | + | If you did a native installation of ROS and CRAM, you would most likely install all the necessary components. However, you have to go through the setup process for the VM to be sure everything is setup. Otherwise, skip to the part where you update the repository and change the branch, then you are set to go. |
Now let's begin. | Now let's begin. | ||
Line 113: | Line 113: | ||
Comment out the following code by putting semi-colon in front of them. It should be on line 40 - 43. | Comment out the following code by putting semi-colon in front of them. It should be on line 40 - 43. | ||
- | < | + | < |
; (desig: | ; (desig: | ||
; 3 robot-current-pose-tf-generator | ; 3 robot-current-pose-tf-generator | ||
Line 252: | Line 252: | ||
Since we have already done an example, let’s go ahead and replace everything in the package.xml with the following: | Since we have already done an example, let’s go ahead and replace everything in the package.xml with the following: | ||
- | < | + | < |
<package format=" | <package format=" | ||
< | < | ||
Line 275: | Line 275: | ||
Next, let us replace everything in the // | Next, let us replace everything in the // | ||
- | < | + | < |
cmake_minimum_required(VERSION 2.8.3) | cmake_minimum_required(VERSION 2.8.3) | ||
project(cram_pepper_description) | project(cram_pepper_description) | ||
Line 290: | Line 290: | ||
By now, you should have done the beginner tutorial, which explains all about .asd files. Therefore let's create one for our cram_pepper_description. Create a file // | By now, you should have done the beginner tutorial, which explains all about .asd files. Therefore let's create one for our cram_pepper_description. Create a file // | ||
- | < | + | < |
(defsystem cram-pepper-description | (defsystem cram-pepper-description | ||
:depends-on (cram-prolog | :depends-on (cram-prolog | ||
Line 316: | Line 316: | ||
Let’s define our package in the "// | Let’s define our package in the "// | ||
- | < | + | < |
(in-package :cl-user) | (in-package :cl-user) | ||
Line 331: | Line 331: | ||
In the “// | In the “// | ||
- | < | + | < |
(in-package : | (in-package : | ||
Line 379: | Line 379: | ||
Next, we need to do the same for the arms of the robot. Again, copy the following code and paste it in the "// | Next, we need to do the same for the arms of the robot. Again, copy the following code and paste it in the "// | ||
- | < | + | < |
(in-package : | (in-package : | ||
Line 494: | Line 494: | ||
Finally, we need to provide a general knowledge of the robot. We do this in the "// | Finally, we need to provide a general knowledge of the robot. We do this in the "// | ||
- | < | + | < |
(in-package : | (in-package : | ||
Line 550: | Line 550: | ||
Now let’s see if we can load our cram package in Emacs. | Now let’s see if we can load our cram package in Emacs. | ||
- | First, run the following. | + | First, run the following |
< | < | ||
Line 607: | Line 607: | ||
As explained before, open the // | As explained before, open the // | ||
- | < | + | < |
<package format=" | <package format=" | ||
< | < | ||
Line 668: | Line 668: | ||
Next, replace open the // | Next, replace open the // | ||
- | < | + | < |
cmake_minimum_required(VERSION 2.8.3) | cmake_minimum_required(VERSION 2.8.3) | ||
project(cram_pepper_demo) | project(cram_pepper_demo) | ||
Line 762: | Line 762: | ||
</ | </ | ||
- | Next, download the following | + | Next, download the resource folder from [[https:// |
Compile the project, make sure to have the " | Compile the project, make sure to have the " | ||
Line 907: | Line 907: | ||
) | ) | ||
- | < | + | </code> |
This function creates the bullet-world, | This function creates the bullet-world, | ||
Line 1823: | Line 1823: | ||
((cram-common-failures: | ((cram-common-failures: | ||
- | ; (print e) | ||
| | ||
Line 1870: | Line 1869: | ||
? | ? | ||
(cram-tf: | (cram-tf: | ||
+ | </ | ||
This function also contains another helper function. Let’s add it. | This function also contains another helper function. Let’s add it. | ||
+ | |||
+ | <code lisp> | ||
;;" | ;;" | ||
;; calculate the new robot-pose-stamped, | ;; calculate the new robot-pose-stamped, | ||
Line 2030: | Line 2032: | ||
Congratulations!!! You just created a shopping assistant using the Pepper robot. | Congratulations!!! You just created a shopping assistant using the Pepper robot. | ||
+ | |||
+ | You can access the entire project from [[https:// | ||