pixmoving-moveit / mv-camera-ros

MindVision camera driver
Apache License 2.0
14 stars 3 forks source link

How to use the driver? #1

Open ghost opened 6 years ago

ghost commented 6 years ago

I have a mindvision camera.when I use the driver , I get a error.

SUMMARY
========

PARAMETERS
 * /rosdistro: kinetic
 * /rosversion: 1.12.13

NODES
  /
    mv_camera_ros_node (mv_camera_ros/mv_camera_ros)

ROS_MASTER_URI=http://192.168.0.11:11311

ERROR: cannot launch node of type [mv_camera_ros/mv_camera_ros]: mv_camera_ros
ROS path [0]=/opt/ros/kinetic/share/ros
ROS path [1]=/opt/ros/kinetic/share
No processes to monitor
shutting down processing monitor...
... shutting down processing monitor complete

can you help me? thanks

awesomebytes commented 6 years ago

Looks like you don't have the binary. Have you successfully compiled the package?

Is your ROS_PACKAGE_PATH environment variable correct?

(Note that I don't really know the specifics of the package, I just saw it's a generic error)

On Mar 17, 2018 16:45, "Yuying Jin" notifications@github.com wrote:

I have a mindvision camera.when I use the driver , I get a error.

SUMMARY

PARAMETERS

  • /rosdistro: kinetic
  • /rosversion: 1.12.13

NODES / mv_camera_ros_node (mv_camera_ros/mv_camera_ros)

ROS_MASTER_URI=http://192.168.0.11:11311

ERROR: cannot launch node of type [mv_camera_ros/mv_camera_ros]: mv_camera_ros ROS path [0]=/opt/ros/kinetic/share/ros ROS path [1]=/opt/ros/kinetic/share No processes to monitor shutting down processing monitor... ... shutting down processing monitor complete

can you help me? thanks

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/pixmoving-moveit/mv-camera-ros/issues/1, or mute the thread https://github.com/notifications/unsubscribe-auth/ABpFdCCktH2F7fPVCvDx6p503Nx3_5J1ks5tfM0ggaJpZM4SuuTC .

vixtor-qm commented 6 years ago

try to build it fisrt

ghost commented 6 years ago

I compiled the package, i got error

xiluna@xiluna-MS-7996:~/catkin_ws/catkin_ws_mindvision/catkin_ws$ roslaunch mv_camera_ros mv-camera-ros.launch
... logging to /home/xiluna/.ros/log/bcf0552c-29d6-11e8-883d-4ccc6a4a9e4b/roslaunch-xiluna-MS-7996-3763.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://192.168.0.14:33308/

SUMMARY
========

PARAMETERS
 * /rosdistro: kinetic
 * /rosversion: 1.12.13

NODES
  /
    mv_camera_ros_node (mv_camera_ros/mv_camera_ros)

ROS_MASTER_URI=http://192.168.0.14:11311

process[mv_camera_ros_node-1]: started with pid [3780]
openin the camera device id 
Camera SDK init status : 0
hCamera = 1
[ERROR] [1521286350.541128971]: cv camera open failed: device_id0 cannot be opened
[mv_camera_ros_node-1] process has died [pid 3780, exit code 1, cmd /home/xiluna/catkin_ws/catkin_ws_mindvision/catkin_ws/devel/lib/mv_camera_ros/mv_camera_ros /mv_camera_ros_node/image_raw:=/image_raw __name:=mv_camera_ros_node __log:=/home/xiluna/.ros/log/bcf0552c-29d6-11e8-883d-4ccc6a4a9e4b/mv_camera_ros_node-1.log].
log file: /home/xiluna/.ros/log/bcf0552c-29d6-11e8-883d-4ccc6a4a9e4b/mv_camera_ros_node-1*.log
all processes on machine have died, roslaunch will exit
shutting down processing monitor...
... shutting down processing monitor complete
done
vixtor-qm commented 6 years ago

you should launch the driver as a root due to a bug in the libMVSDK.so

vixtor-qm commented 6 years ago

there is a script in the dir "scripts" named run_camera_sudo.sh take a look what it does and modify it to match your installation directory. then it should work

awesomebytes commented 6 years ago

Pro-tip: give the executable root ownership and add the SUID bit so you don't need to do that in the future.

# go wherever your binary is
cd your_ws/devel/bin/
sudo chown root:root mv_camera_ros
sudo chmod +s mv_camera_ros
vixtor-qm commented 6 years ago

Admin tip: contact driver's support team and ask for a fix. It is not good that app gains more permissions than it actually needs. It is a security rules violation that may lead to undesired behavior.

ghost commented 6 years ago

yes! I did it .but i have a iamge

why?

vixtor-qm commented 6 years ago

this is caused by the mismatch between number of image channels in the image from driver and its OpenCV wrapper. check for channel number and set it to correct value

ghost commented 6 years ago

I have succeeded!thanks~

Is this driver available on the ARM processor?

awesomebytes commented 6 years ago

I doubt it as the third party folder contains only the x86 64b .so of the library of the camera.

If you manage to find it for arm, maybe.

On Mar 18, 2018 16:34, "Yuying Jin" notifications@github.com wrote:

I have succeeded!thanks~

Is this driver available on the ARM processor?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/pixmoving-moveit/mv-camera-ros/issues/1#issuecomment-373981380, or mute the thread https://github.com/notifications/unsubscribe-auth/ABpFdJ5z_AhdKg51C5enAayY2O54qd26ks5tfhwggaJpZM4SuuTC .

ghost commented 6 years ago

I find libMVSDK.so for arm . I can build it . when i run it .i got error

setting /run_id to 40d594ba-2c2f-11e8-8c61-001e0631da75
process[rosout-1]: started with pid [5337]
started core service [/rosout]
process[mv_camera_ros_node-2]: started with pid [5340]
terminate called after throwing an instance of 'std::bad_cast'
  what():  std::bad_cast
[mv_camera_ros_node-2] process has died [pid 5340, exit code -6, cmd /home/odroid/catkin_ws/catkin_mindvision/devel/lib/mv_camera_ros/mv_camera_ros /mv_camera_ros_node/image_raw:=/image_raw __name:=mv_camera_ros_node __log:=/root/.ros/log/40d594ba-2c2f-11e8-8c61-001e0631da75/mv_camera_ros_node-2.log].
log file: /root/.ros/log/40d594ba-2c2f-11e8-8c61-001e0631da75/mv_camera_ros_node-2*.log
awesomebytes commented 6 years ago

Well, I guess you should run it on gdb or start adding prints to check out where it's crashing and fix that cast :)

On Tue, Mar 20, 2018, 22:15 Yuying Jin notifications@github.com wrote:

I find libMVSDK.so for arm . I can build it . when i run it .i got error

setting /run_id to 40d594ba-2c2f-11e8-8c61-001e0631da75 process[rosout-1]: started with pid [5337] started core service [/rosout] process[mv_camera_ros_node-2]: started with pid [5340] terminate called after throwing an instance of 'std::bad_cast' what(): std::bad_cast [mv_camera_ros_node-2] process has died [pid 5340, exit code -6, cmd /home/odroid/catkin_ws/catkin_mindvision/devel/lib/mv_camera_ros/mv_camera_ros /mv_camera_ros_node/image_raw:=/image_raw __name:=mv_camera_ros_node __log:=/root/.ros/log/40d594ba-2c2f-11e8-8c61-001e0631da75/mv_camera_ros_node-2.log]. log file: /root/.ros/log/40d594ba-2c2f-11e8-8c61-001e0631da75/mv_camera_ros_node-2*.log

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/pixmoving-moveit/mv-camera-ros/issues/1#issuecomment-374560797, or mute the thread https://github.com/notifications/unsubscribe-auth/ABpFdC0iUZqMGXb-9eluqFC3VQZhIkuYks5tgOTPgaJpZM4SuuTC .

ghost commented 6 years ago

Here is my debug information on the ARM platform

Cannot parse expression
warning: Probes-based dynamic linker interface failed.
[Thread debugging using libthread_db enabled]
terminate called after throwing an instance of 'std::bad_cast'
  what():  std::bad_cast

I don't know how to solve this problem

vixtor-qm commented 6 years ago

camera is supplied by MindVision http://www.mindvision.com.cn/index_en.aspx. Could you please contact them and ask for fix?

woshicaijihahahaha commented 1 year ago

I compiled the package, i got error

xiluna@xiluna-MS-7996:~/catkin_ws/catkin_ws_mindvision/catkin_ws$ roslaunch mv_camera_ros mv-camera-ros.launch
... logging to /home/xiluna/.ros/log/bcf0552c-29d6-11e8-883d-4ccc6a4a9e4b/roslaunch-xiluna-MS-7996-3763.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://192.168.0.14:33308/

SUMMARY
========

PARAMETERS
 * /rosdistro: kinetic
 * /rosversion: 1.12.13

NODES
  /
    mv_camera_ros_node (mv_camera_ros/mv_camera_ros)

ROS_MASTER_URI=http://192.168.0.14:11311

process[mv_camera_ros_node-1]: started with pid [3780]
openin the camera device id 
Camera SDK init status : 0
hCamera = 1
[ERROR] [1521286350.541128971]: cv camera open failed: device_id0 cannot be opened
[mv_camera_ros_node-1] process has died [pid 3780, exit code 1, cmd /home/xiluna/catkin_ws/catkin_ws_mindvision/catkin_ws/devel/lib/mv_camera_ros/mv_camera_ros /mv_camera_ros_node/image_raw:=/image_raw __name:=mv_camera_ros_node __log:=/home/xiluna/.ros/log/bcf0552c-29d6-11e8-883d-4ccc6a4a9e4b/mv_camera_ros_node-1.log].
log file: /home/xiluna/.ros/log/bcf0552c-29d6-11e8-883d-4ccc6a4a9e4b/mv_camera_ros_node-1*.log
all processes on machine have died, roslaunch will exit
shutting down processing monitor...
... shutting down processing monitor complete
done

你好 请问你是如何解决这个问题的,我也遇到了这个问题