ardrone_tag_recognition
Differences
This shows you the differences between two versions of the page.
ardrone_tag_recognition [2016/11/01 11:01] – created dwallace | ardrone_tag_recognition [2016/11/06 02:18] (current) – dwallace | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Tag Recognition Using Webcam ====== | ====== Tag Recognition Using Webcam ====== | ||
- | =Introduction= | + | ===== Introduction ===== |
We will learn to do tag recognition using your web-cam. Before we continue any further lets make sure you have the necessary package. | We will learn to do tag recognition using your web-cam. Before we continue any further lets make sure you have the necessary package. | ||
- | < | + | |
This should take you to the folder of the package " | This should take you to the folder of the package " | ||
- | < | + | |
+ | |||
+ | ===== Print out a tag ===== | ||
- | =Print out a tag= | ||
We obviously need an image tag before we test the code. | We obviously need an image tag before we test the code. | ||
- | < | ||
- | < | ||
- | < | ||
- | =Test the code= | + | Step 1:Go to the folder of the package " |
+ | Step 2:open up the file " | ||
+ | Step 3:Print out your desired image tag. | ||
+ | |||
+ | ===== Test the code ===== | ||
1. Enter the following commands each in a new terminal. | 1. Enter the following commands each in a new terminal. | ||
- | < | + | |
- | roscore | + | rosrun gscam gscam |
- | rosrun gscam gscam | + | |
- | </ | + | |
2.Open up a new terminal and enter the lines one after the other : | 2.Open up a new terminal and enter the lines one after the other : | ||
- | <pre> | + | |
- | roscd ar_recog | + | roscd ar_recog |
- | cmake . | + | cmake . |
- | rosmake | + | rosmake |
- | </ | + | |
Make sure you get 0 failures for rosmake. | Make sure you get 0 failures for rosmake. | ||
- | < | + | |
- | cd bin | + | rosparam set aov .67 |
- | rosparam set aov .67 | + | rosrun ar_recog ar_recog image: |
- | rosrun ar_recog ar_recog image: | + | |
- | </ | + | |
Enter the following commands each in a new terminal: | Enter the following commands each in a new terminal: | ||
- | <pre> | ||
- | rosrun image_view image_view image: | ||
- | rosrun image_view image_view image: | ||
- | </ | ||
- | =Testing the image tag= | + | rosrun image_view image_view image: |
+ | rosrun image_view image_view image: | ||
+ | |||
+ | ===== Testing the image tag ===== | ||
Considering the fact that you have a printed image tag. | Considering the fact that you have a printed image tag. | ||
Hold it in-front of the camera in such a way that your fingers don't touch the surface of the tag. | Hold it in-front of the camera in such a way that your fingers don't touch the surface of the tag. | ||
I pasted the tag on to the surface of a box lid. | I pasted the tag on to the surface of a box lid. | ||
- | <br> | ||
- | [[image: | + | {{dylanw: |
- | <br> | ||
When you test with the image tag you should see a green line outlining the image tag. | When you test with the image tag you should see a green line outlining the image tag. | ||
- | + | {{dylanw:image1.png}}\\ | |
- | [[image:image1.png|200px|ar_recog]] | + | |
+ | {{dylanw: | ||
- | [[image: | + | ===== Getting the coordinates ===== |
- | =Getting the coordinates= | ||
To have a deeper insight of the image tag being recognized open up a terminal and enter: | To have a deeper insight of the image tag being recognized open up a terminal and enter: | ||
- | < | + | |
This shows you the movement of image tag along the x,y,z axes. | This shows you the movement of image tag along the x,y,z axes. |
ardrone_tag_recognition.txt · Last modified: 2016/11/06 02:18 by dwallace