ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

mister_kay's profile - activity

2017-08-24 14:20:26 -0500 marked best answer running image_view with pointgrey flea3 camera

Hello,

I installed the driver for two Flea3 Pointgrey cameras whose accessibility are (successfully) verified via:

rosrun pointgrey_camera_driver list_cameras

12062824 12062828

Now "starting" one of those cameras with

roslaunch pointgrey_camera_driver camera.launch camera_serial:=12062824

I would like to display my images with

rosrun image_view image_view image:=/camera/image

but I receive the following error code:

[ERROR] [1404221648.972130708]: Client [/image_view_1404220593387350082] wants topic /camera/image to have datatype/md5sum [sensor_msgs/Image/060021388200f6f0f447d0fcd9c64743], but our version has [wfov_camera_msgs/WFOVImage/807d0db423ab5e1561cfeba09a10bc88]. Dropping connection. [ERROR] [1404221696.898906591]: Client [/image_view_1404221696410391988] wants topic /camera/image to have datatype/md5sum [sensor_msgs/Image/060021388200f6f0f447d0fcd9c64743], but our version has [wfov_camera_msgs/WFOVImage/807d0db423ab5e1561cfeba09a10bc88]. Dropping connection.

It seems like the camera.launch script publishes the images in a message format which is not known to image_view.

As I am a beginner to Linux as well as ROS I would like to ask for some tips how to publish my images (or edit camera.launch) in a certain way, eg. under the topic "left_camera/image".

Also how would I take a first step in displaying my images from the camera?

Thank you!

2017-04-06 11:21:02 -0500 marked best answer How to start creating a package/node in ROS?

Hello,

I started some weeks ago with ROS, now I want to write a node (or nodelet or package) for my stereo-camera-system (2 Point Grey Flea3 GigE-Cameras).

The pointgrey-camera-driver for ROS doesnt let me handle things like the polarity of the trigger or setting a fixed IP.

Basically my program already exists as a Visual Studio 2010 (yes, PointGrey doesnot support VS2012) project. The program checks the system for exisiting cameras and then sets them up with fixed IP's, enables a trigger, selects a ROI and so on. In the end the settings are stored to the cameras' memory channels where they persist.

Basically I have the problem that I dont know with which ROS tutorial to start and whether I want to create an own ROS package or if it makes sense to define my program as a node/nodelet of the pointgrey-camera package.

I think my node should not subscribe to any topics, it really is more of a c++ program working on its own. I have the compiled library files (eqivalent to windows dlls in Linux I guess) for the FlyCap SDK.

So my idea is to put that node (if succesfully) into my launch file before starting the camera, ideally the node should return a boolean true/false on sucess/failure to the system. How can that be done?

My supervisor told me for Linux there exists a good IDE called QtCreator, so far I have used VS and eclipse in Windows.

Do you have any ideas/suggestions for me?

----UPDATE---

This is the code of my node "stereo_setup" in stereo_setup.cpp. What happens to lines like std::cout << "xyz" or printf(...) in ROS?

I am still uncertain how to set the info that the camera_setup was successfull.

#include <ros.h>

#include<iostream>

#include "FlyCapture2_Axel.h"

using namespace std;
using namespace FlyCapture2;


const char * const mac_address_char_12062824 = "00:B0:9D:B8:10:68";
const char * const mac_address_char_12062828 = "00:B0:9D:B8:10:6C";

const char * const ip_address_char_12062824 = "192.168.1.2";
const char * const ip_address_char_12062828 = "192.168.1.3";

const char * const ip_address_char_submask = "255.255.0.0";
const char * const ip_address_char_gateway= "0.0.0.0";

const unsigned int SN_12062824 = 12062824;
const unsigned int SN_12062828 = 12062828;


const Mode k_fmt7Mode = MODE_0;
const unsigned int image_width =  1344;
const unsigned int image_height = 1032;
const unsigned int MAX_image_width =  1384;
const unsigned int MAX_image_height =  1032;
const PixelFormat pixel_format = PIXEL_FORMAT_RGB;

//turn shutter to manual mode
const bool SHUTTER_MANUAL_MODE = false;
//shutter duration in milliseconds
const unsigned int SHUTTER_DURATION = 8;



//turn on filewriting
//const bool WRITE_TO_FILE = true;

// File Format

// File Format
//const char  * file_format = "bmp";


bool initialize_cameras();
bool connect_cameras(Camera * cam_12062824, Camera * cam_12062828, PGRGuid * pgr_guid_12062824, PGRGuid * pgr_guid_12062828);
bool setup_cameras(Camera * cam_12062824, Camera * cam_12062828);
void PrintBuildInfo();
void PrintError( Error error );
void PrintCameraInfo( CameraInfo* pCamInfo );
void PrintFormat7Capabilities( Format7Info fmt7Info);



int main(int argc, char** argv )

{

    ros::init(argc, argv, "stereo_setup");

    PrintBuildInfo();

    Error error;
    //BusManager busmanager;


    Camera cam_12062824, cam_12062828;
    PGRGuid pgr_guid_12062824, pgr_guid_12062828;

    bool ini = initialize_cameras();
    if(ini == false)
    {
    std::cout << "Could not successfully initialize the two cameras!" << std ...
(more)
2017-03-06 08:39:18 -0500 received badge  Great Question (source)
2017-02-14 08:47:12 -0500 received badge  Good Question (source)
2016-12-12 03:37:37 -0500 received badge  Nice Question (source)
2016-12-12 03:29:43 -0500 marked best answer can "rosbag filter" create a new bag file with multiple topics within it?

Hello,

I have a bagfile with a lot of topics in it. For some reason I would like to filter out 4 topics of that bagfile into a new bagfile:

   rosbag filter old_bag.bag new_bag.bag "topic=='/stereo/left/image_rect' '/stereo/right/image_rect' '/stereo/left/camera_info'  '/stereo/right/camera_info'"

Unfortunately this doesn't work. Does anyone have a clue what the correct syntax is?

2016-09-08 13:37:09 -0500 marked best answer How to create directories in a ROS launch file

Hello,

I would like to create a directory in a ROS launch file in order store images in the specified folder. How can this be done?

2016-06-13 12:28:10 -0500 marked best answer catkin_make fails weirdly after trying to create a new package

Hello,

I am trying to build a new package in a catkin_workspace. After trying to build this package everything seems to be malfunctioning. E.g. if i delete the package under construction and only leave one surely working package in my catkin_ws (e.g. image_view, viso2_ros) i still get the following errors when doing catkin_make.

.......

  CMake Error at /opt/ros/hydro/share/catkin/cmake/catkinConfig.cmake:75 (find_package):
  Could not find a configuration file for package cv_bridge.

  Set cv_bridge_DIR to the directory containing a CMake configuration file
  for cv_bridge.  The file will have one of the following names:

    cv_bridgeConfig.cmake
    cv_bridge-config.cmake

Call Stack (most recent call first):
  viso2-hydro/viso2_ros/CMakeLists.txt:4 (find_package)


CMake Error at /opt/ros/hydro/share/catkin/cmake/catkinConfig.cmake:75 (find_package):
  Could not find a configuration file for package image_geometry.

  Set image_geometry_DIR to the directory containing a CMake configuration
  file for image_geometry.  The file will have one of the following names:

    image_geometryConfig.cmake
    image_geometry-config.cmake

Call Stack (most recent call first):
  viso2-hydro/viso2_ros/CMakeLists.txt:4 (find_package)


-- checking for module 'openni-dev'
--   package 'openni-dev' not found
-- checking for module 'openni-dev'
--   package 'openni-dev' not found
-- checking for module 'openni-dev'
--   package 'openni-dev' not found
-- looking for PCL_COMMON

........

What the f** has happened. Did my package under construction destroy anything? Sidenote: I am a beginner to ROS!

Also here is my original CMakeLists.txt for my new package "stereo_setup":

 cmake_minimum_required(VERSION 2.8.3)
project(stereo_setup)
find_package(catkin REQUIRED)
catkin_package(
   INCLUDE_DIRS include)

# set include directories for headers and libraries
include_directories($(stereo_setup_INCLUDE_DIRS), include, lib)

FIND_LIBRARY(FLYCAP_SDK NAMES libflycapture.so library
  PATHS /lib)

# set the executable for executing ROS cmds
add_executable(stereo_setup_exe src/stereo_setup.cpp)

#set the properties 
SET_TARGET_PROPERTIES(stereo_setup_exe PROPERTIES OUTPUT_NAME stereo_setup)


# add the sourcecode as a "library"
#add_library(stereo_setup src/stereo_setup.cpp)

# target; link against 
target_link_libraries(stereo_setup ${FLYCAP_SDK})

target_link_libraries(stereo_setup ${catkin_LIBRARIES})