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

openni_camera error "bad parameter"

asked 2011-07-15 01:44:34 -0500

qdocehf gravatar image

updated 2016-10-24 08:33:45 -0500

ngrennan gravatar image

I am able to use the openni_camera node with the command "roslaunch openni_camera openni_node.launch". However, if I try to use any other nodes that require openni_camera (such as openni_tracker or rviz), openni_camera fails. Previously, I had a different error that was solved, but I do not know if this new error is a result of the solution or not. This is what is output. The problem is in the last few lines.

robot@peoplebot2:~$ roslaunch openni_camera openni_node.launch
... logging to /home/robot/.ros/log/dd0d89ac-a8ae-11e0-85d5-a088b4402bbc/roslaunch-peoplebot2-4636.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://peoplebot2:56174/

SUMMARY
========

PARAMETERS
 * /rosdistro
 * /openni_node1/use_indices
 * /openni_node1/depth_registration
 * /openni_node1/image_time_offset
 * /openni_node1/depth_frame_id
 * /openni_node1/depth_mode
 * /openni_node1/debayering
 * /rosversion
 * /openni_node1/projector_depth_baseline
 * /openni_node1/rgb_frame_id
 * /openni_node1/depth_rgb_translation
 * /openni_node1/depth_time_offset
 * /openni_node1/image_mode
 * /openni_node1/shift_offset
 * /openni_node1/device_id
 * /openni_node1/depth_rgb_rotation

NODES
  /
    openni_node1 (openni_camera/openni_node)
    kinect_base_link (tf/static_transform_publisher)
    kinect_base_link1 (tf/static_transform_publisher)
    kinect_base_link2 (tf/static_transform_publisher)
    kinect_base_link3 (tf/static_transform_publisher)

auto-starting new master
process[master]: started with pid [4650]
ROS_MASTER_URI=http://localhost:11311

setting /run_id to dd0d89ac-a8ae-11e0-85d5-a088b4402bbc
process[rosout-1]: started with pid [4663]
started core service [/rosout]
process[openni_node1-2]: started with pid [4675]
process[kinect_base_link-3]: started with pid [4676]
process[kinect_base_link1-4]: started with pid [4682]
process[kinect_base_link2-5]: started with pid [4689]
process[kinect_base_link3-6]: started with pid [4690]
[ INFO] [1310052981.236117554]: [/openni_node1] Number devices connected: 1
[ INFO] [1310052981.236264275]: [/openni_node1] 1. device on bus 002:07 is a Xbox NUI Camera (2ae) from Microsoft (45e) with serial id 'B00362205337039B'
[ INFO] [1310052981.240329298]: [/openni_node1] searching for device with index = 1
[ INFO] [1310052981.304115108]: [/openni_node1] Opened 'Xbox NUI Camera' on bus 2:7 with serial number 'B00362205337039B'
[ INFO] [1310052981.336603405]: rgb_frame_id = '/openni_rgb_optical_frame' 
[ INFO] [1310052981.341586992]: depth_frame_id = '/openni_depth_optical_frame' 
terminate called after throwing an instance of 'openni_wrapper::OpenNIException'
  what():  virtual void openni_wrapper::OpenNIDevice::startImageStream() @ /tmp/buildd/ros-diamondback-openni-kinect-0.2.1/debian/ros-diamondback-openni-kinect/opt/ros/diamondback/stacks/openni_kinect/openni_camera/src/openni_device.cpp @ 158 : starting image stream failed. Reason: Bad Parameter sent to the device!
[openni_node1-2] process has died [pid 4675, exit code -6].
log files: /home/robot/.ros/log/dd0d89ac-a8ae-11e0-85d5-a088b4402bbc/openni_node1-2*.log
edit retag flag offensive close merge delete

3 Answers

Sort by ยป oldest newest most voted
0

answered 2011-09-02 11:56:09 -0500

kwc gravatar image

no activity > 1 month, closing

edit flag offensive delete link more
0

answered 2011-07-24 02:16:24 -0500

Are you using USB 3.0 Ports? See here.

Do you use an extension cord? I had problems with too long cables.

edit flag offensive delete link more

Comments

I do not use an extension cord. I do not think that it has USB 3.0 ports, but I am not 100% sure. However, the computer was able to run openni_camera properly for a short time before bugs began to occur, so I do not think that this would be the problem. Also, it can run libfreenect correctly.
qdocehf gravatar image qdocehf  ( 2011-07-24 23:52:39 -0500 )edit
0

answered 2016-09-25 23:21:03 -0500

elpidiovaldez gravatar image

I think the 'bad parameter' error comes when openni calls InitFromXmlFile to parse an xml file containing the setup for the sensor. The error output tells you where to look in the C++ code. Have a look at the code to see the directory path of the xml file. Any syntax error in the file will cause the error, but I recently had this error because the rgb image node was declared BEFORE the depth image node. Changing the order of the nodes fixed the problem. Strangely this error occurred only after installing ROS. I had used the same xml file for years without this problem.

edit flag offensive delete link more

Question Tools

Stats

Asked: 2011-07-15 01:44:34 -0500

Seen: 1,626 times

Last updated: Sep 25 '16