Writing /var/lib/dokuwiki/data/meta/tutorials/ros_seek_cam.meta failed
tutorials:ros_seek_cam
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
tutorials:ros_seek_cam [2019/11/20 05:39] – created lrodriguezp | tutorials:ros_seek_cam [2022/09/20 00:08] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 6: | Line 6: | ||
http:// | http:// | ||
====== Install pyseek ====== | ====== Install pyseek ====== | ||
- | The library to use the camera must be downloaded | + | The library to use the camera must be downloaded. It is recommended to place it in the catkin_ws folder. |
- | $ git clone git@github.com:adrobinoga/ | + | $ git clone https://github.com/adrobinoga/ |
In order to use this lib you must append the path to this lib to PYTHONPATH, you may do this appending the next line at the end of your .bashrc file | In order to use this lib you must append the path to this lib to PYTHONPATH, you may do this appending the next line at the end of your .bashrc file | ||
export PYTHONPATH=" | export PYTHONPATH=" | ||
- | You must also install pyUSB with | + | You need install pyUSB with |
pip install pyusb | pip install pyusb | ||
- | Finally, you must have image-transport-plugins and image-view for ROS. Usually, you already have it. You can check with the apt cache search command. | + | And also install scipy as a requirement |
+ | sudo apt-get install python-scipy | ||
+ | Finally, you must have image-transport-plugins and image-view for your ROS distribution. Usually, you already have it. You can check with the apt-cache search command. | ||
**Note: The path of export and source (on the next step) must be complete. You can get the full path with pwd command. | **Note: The path of export and source (on the next step) must be complete. You can get the full path with pwd command. | ||
- | ====== | + | ====== |
- | + | Use the following commands to get and build the ROS node. It is recommended to place it in the catkin_ws folder.: | |
- | $ git clone git@github.com:arcoslab/ | + | $ git clone https:// |
$ cd ros_seek_cam/ | $ cd ros_seek_cam/ | ||
- | $ catkin_make | + | If you are using the catkin_ws folder, use catkin_make |
- | then source setup.bash | + | Then append the following command to .bashrc file: |
- | | + | source |
- | this last step must be executed from every terminal before | + | To access the camera you need to create a new file / |
+ | With the line: | ||
+ | SUBSYSTEM==" | ||
+ | Where the vendor id and the product id, can be obtained with the dmesg command after connecting the seek camera. The last camara used on the humanoid robot had 289d as idVendor and 0010 as idProduct. | ||
+ | Then restart the udev service (if you are using a docker container you can skip this step, because udev doesn' | ||
+ | $ sudo service udev restart | ||
====== Run ====== | ====== Run ====== | ||
Line 29: | Line 36: | ||
We may run the launch file view_seek.launch to see the camera' | We may run the launch file view_seek.launch to see the camera' | ||
$ roslaunch seek_cam view_seek.launch | $ roslaunch seek_cam view_seek.launch | ||
- | We may also use rosrun | + | ====== Debug ====== |
+ | When running with the roslaunch program it is hard to find errors in the setup. | ||
+ | You may perform the roslaunch tasks manually. | ||
+ | First, launch roscore: | ||
$ roscore | $ roscore | ||
+ | Then in another terminal, launch the main node: | ||
$ rosrun seek_cam seek_cam_node.py | $ rosrun seek_cam seek_cam_node.py | ||
- | and see the published messages | + | Open another terminal |
- | $ rostopic echo / | + | $ rosrun image_view image_view image: |
+ | ===== API Reference ===== | ||
+ | ==== Topic ==== | ||
+ | The node publishes png images in / | ||
+ | ==== Change Image Rotation ==== | ||
+ | To change rotation angle of the published image, you may change the angle argument, when using roslaunch: | ||
+ | $ roslaunch seek_cam view_seek.launch angle: | ||
+ | When no value is given, the default value set in launch file is used. | ||
+ | Where the camera angle is set according to the position of the usb port of the camera,the " | ||
+ | The camera angle parameter can also be passed with a rosrun instruction: | ||
+ | $ rosrun seek_cam seek_cam_node.py angle=90 | ||
+ | When no value is given the default value set in seek_cam_node.py is used. | ||
===== Author ===== | ===== Author ===== |
tutorials/ros_seek_cam.1574228381.txt.gz · Last modified: 2022/09/20 00:08 (external edit)