roboticslab-uc3m / asibot-main

ASIBOT assistive robot: super/meta repository.
http://roboticslab.uc3m.es/roboticslab/robot/asibot
GNU Lesser General Public License v2.1
4 stars 0 forks source link

Segmentation fault: cannot render offscreen (cartesianServer and any module that uses RaveBot/OpenRAVE cameras) #3

Closed iagson closed 6 years ago

iagson commented 9 years ago

Hello jgvictores,

I was trying to start an instance of a cartesianServer, to see if all software was installed correctly and the kitchen appears to initialise upside down. That isn't so bad, but when you try to input some extra commands like " cartesianServer --env asibot_kitchen_cameras.env.xml " the GUI doesn't start beacuse of an error (already tried by changing the .ini file)

It's also true that I didn't install the asibot repository from github, but from Subversion, maybe that's the problem.

These are the screen prints I took: ubuntu 14 10probcartesianserver camara2 ubuntu 14 10probcartesianserver camara

Thank you very much.

jgvictores commented 9 years ago

1) On your first screenshot I see a YARP matching protocol error (1 0 0 vs 0 0 0). You should be able to fix that by cleaning and recompiling (may be overkill, but I'd first do it on YARP and then on ASIBOT). 2) Check if the environment that breaks has cameras. There is a known issue regarding the off-screen rendering we use and certain graphic card drivers (especially in Linux).

BTW, don't mind copying and pasting the entire log, it will make things easier!

iagson commented 9 years ago

After recompiling both YARP and ASIBOT the error persists. BTW, I had to rename the asibot-main directory to asibot so to initialise cartesianServer. This is the whole log after trying to access a camera:

iagson@iagson-VirtualBox:~$ cartesianServer --env asibot_kitchen_cameras.env.xml ||| clearing context ||| adding context [cartesianServer/conf] ||| configuring ||| policy set to ASIBOT_ROOT ||| ASIBOT_ROOT: /home/iagson/asibot ||| loading policy from /home/iagson/asibot/ASIBOT_ROOT.ini yarp: cannot read from /home/iagson/asibot/ASIBOT_ROOT.ini ||| loading policy from /home/iagson/.yarp/ASIBOT_ROOT.ini yarp: cannot read from /home/iagson/.yarp/ASIBOT_ROOT.ini ||| loading policy from /etc/yarp/policies/ASIBOT_ROOT.ini yarp: cannot read from /etc/yarp/policies/ASIBOT_ROOT.ini ||| loading policy from /etc/ASIBOT_ROOT.ini yarp: cannot read from /etc/ASIBOT_ROOT.ini ||| loading policy from /usr/local/etc/ASIBOT_ROOT.ini yarp: cannot read from /usr/local/etc/ASIBOT_ROOT.ini ||| failed to load policy from /home/iagson/asibot/ASIBOT_ROOT.ini /home/iagson/.yarp/ASIBOT_ROOT.ini /etc/yarp/policies/ASIBOT_ROOT.ini /etc/ASIBOT_ROOT.ini /usr/local/etc/ASIBOT_ROOT.ini ||| default config file specified as cartesianServer.ini ||| checking /home/iagson/cartesianServer.ini ||| checking [/home/iagson/.config/yarp/robots/default](robot YARP_CONFIG_HOME) ||| checking [/home/iagson/.local/share/yarp/robots/default](robot YARP_DATA_HOME) ||| checking [/etc/xdg/xdg-ubuntu/yarp/robots/default](robot YARP_CONFIG_DIRS) ||| checking [/usr/share/upstart/xdg/yarp/robots/default](robot YARP_CONFIG_DIRS) ||| checking [/etc/xdg/yarp/robots/default](robot YARP_CONFIG_DIRS) ||| checking [/usr/share/ubuntu/yarp/robots/default](robot YARP_DATA_DIRS) ||| checking [/usr/share/gnome/yarp/robots/default](robot YARP_DATA_DIRS) ||| checking [/usr/local/share/yarp/robots/default](robot YARP_DATA_DIRS) ||| checking [/usr/share/yarp/robots/default](robot YARP_DATA_DIRS) ||| checking [/usr/share/ubuntu/yarp/config/path.d](robot path.d YARP_DATA_DIRS) ||| checking [/usr/share/gnome/yarp/config/path.d](robot path.d YARP_DATA_DIRS) ||| checking [/usr/local/share/yarp/config/path.d](robot path.d YARP_DATA_DIRS) ||| checking [/usr/share/yarp/config/path.d](robot path.d YARP_DATA_DIRS) ||| checking /home/iagson/asibot/app/cartesianServer/conf/cartesianServer.ini ||| found /home/iagson/asibot/app/cartesianServer/conf/cartesianServer.ini Run "cartesianServer --help" for options

cartesianServer checking for yarp network... [ok]

CartesianServer using controller: cartesianbot, prefix: /ravebot.

CartesianServer using movjLocal: /ravebot/movjCartesianServer, movjRemote: /ravebot.

CartesianBot using A0: 0.300000, A1: 0.400000, A2: 0.400000, A3: 0.300000. CartesianBot using cmcMs: 30.000000, duration: 20.000000, maxAcc: 0.200000, maxVel: 7.500000. CartesianBot using robotDevice: controlboard, robotSubDevice: ravebot, robotName: /ravebot. CartesianBot using robotLocal: N/A, robotRemote: N/A.

[INFO]ControlBoard subdevice is ravebot

RaveBot using numMotors: 5, env: asibot_kitchen_cameras.env.xml, externObj: none, extraRobot: none. RaveBot using genInitPos: 0.000000, genJointTol: 0.250000, genMaxLimit: 360.000000, genMinLimit: -360.000000. RaveBot using genRefSpeed: 7.500000, genEncRawExposed: 0.017453, genVelRawExposed: 0.017453. RaveBot using jmcMs: 20.000000, jmcMsAcc: 1.000000, modePosVel: 0, physics: none, viewer: 1. RaveBot not using individual initPoss, defaulting to genInitPos. RaveBot not using individual jointTols, defaulting to genJointTol. RaveBot not using individual maxLimits, defaulting to genMaxLimit. RaveBot not using individual minLimits, defaulting to genMinLimit. RaveBot not using individual refSpeeds, defaulting to genRefSpeed. RaveBot not using individual encRawExposeds, defaulting to genEncRawExposed.

RaveBot not using individual velRawExposeds, defaulting to genVelRawExposed.

[plugindatabase.h:577 Create] Failed to create name viewerrecorder, interface module [environment-core.h:800 SetPhysicsEngine] setting ode physics engine [odephysics.h:255 InitEnvironment] ode params: erp=1.000000e-02 (2.000000e-01), cfm=1.000000e-05 (1.000000e-10), itrs=20 (20) [success] RaveBot loaded environment. RaveBot using robot 0 (asibot) as main robot. Sensors found on robot 0 (asibot): 1. Sensor 0 name: asibot_tip Sensor 0 supports ST_Camera. yarp: Port /ravebot/asibot_tip/img:o active at tcp://10.0.2.15:10012 Sensors found on robot 1 (ip): 1. Sensor 0 name: ip_camera Sensor 0 supports ST_Camera. yarp: Port /ravebot/ip_camera/img:o active at tcp://10.0.2.15:10013 [qtcoinviewer.cpp:3041 UpdateFromModel] auto-setting camera location yarp: Port /ravebot/world active at tcp://10.0.2.15:10002 [success] ravebot threadInit() [INFO]created device . See C++ class RaveBot for documentation. yarp: Port /ravebot/rpc:i active at tcp://10.0.2.15:10003 yarp: Port /ravebot/command:i active at tcp://10.0.2.15:10004 yarp: Port /ravebot/state:o active at tcp://10.0.2.15:10005 [RaveBot] getAxes reporting 5 axes are present [RaveBot] getAxes reporting 5 axes are present [RaveBot] getAxes reporting 5 axes are present [INFO]created wrapper . See C++ class yarp::dev::ServerControlBoard for documentation. [CartesianBot] success: Acquired robot interfaces. [INFO]Server control board starting [CartesianBot] success: threadInit() started 30.000000 ms ratethread [INFO]created device . See C++ class CartesianBot for documentation. [CartesianServer] success: Acquired cartesian interface. yarp: Port /ravebot/movjCartesianServer/rpc:o active at tcp://10.0.2.15:10006 yarp: Port /ravebot/movjCartesianServer/command:o active at tcp://10.0.2.15:10007 yarp: Port /ravebot/movjCartesianServer/state:i active at tcp://10.0.2.15:10008 yarp: Port /ravebot/movjCartesianServer/stateExt:i active at tcp://10.0.2.15:10009 yarp: Sending output from /ravebot/movjCartesianServer/rpc:o to /ravebot/rpc:i using tcp yarp: Receiving input from /ravebot/movjCartesianServer/rpc:o to /ravebot/rpc:i using tcp yarp: Sending output from /ravebot/movjCartesianServer/command:o to /ravebot/command:i using tcp yarp: Receiving input from /ravebot/movjCartesianServer/command:o to /ravebot/command:i using tcp yarp: Sending output from /ravebot/state:o to /ravebot/movjCartesianServer/state:i using udp yarp: Receiving input from /ravebot/state:o to /ravebot/movjCartesianServer/state:i using udp * Extended port /ravebot/stateExt:o was not found on the controlBoardWrapper I'm connecting to. Falling back to compatibility beaviour Updating to newer yarp and the usage of controlBoardWrapper2 is suggested* received an unknown request after a VOCAB_GET: prot ERROR, expecting protocol 1 0 0, but remotecontrolboard returned protocol version 0 0 0 WARNING: ignoring error but please update YARP or the remotecontrolboard implementation [RaveBot] getAxes reporting 5 axes are present [INFO]created device . See C++ class yarp::dev::RemoteControlBoard for documentation. [CartesianServer] success: Acquired robot interfaces. yarp: Port /ravebot/cartesianServer/rpc:i active at tcp://10.0.2.15:10010 yarp: Port /ravebot/cartesianServer/command:i active at tcp://10.0.2.15:10011 Coin info in glglue_allow_newer_opengl():

Features of OpenGL version > 1.0 has been disabled, due to the use of a remote display.

This is so because many common OpenGL drivers have problems in this regard.

To force full OpenGL use, set the environment variable COIN_FULL_INDIRECT_RENDERING=1 and re-run the application.

If you don't want this message displayed again, set the environment variable COIN_DONT_INFORM_INDIRECT_RENDERING=1.

[qtcoinviewer.cpp:3417 _GetCameraImage] offscreen renderer failed (check video driver), disabling [qtcoinviewer.cpp:3370 _GetCameraImage] cannot render offscreen Segmentation fault (core dumped)

jgvictores commented 9 years ago

The final segmentation fault is due to "offscreen renderer failed (check video driver)". Here are related issues: http://openrave-users-list.185357.n3.nabble.com/qtcoin-viewer-error-quot-offscreen-renderer-failed-quot-td4025805.html http://openrave-users-list.185357.n3.nabble.com/Vision-sensor-in-c-td2706454.html#a2735645 This is an old issue related to OpenRAVE and deeper. At the asibot-main level, all you can do is avoid simulated environments with cameras.

jgvictores commented 6 years ago

Throughout old emails, I've commented that offscreen rendering was achived via Bumblebee's optirun (only applicable to Optimus NVIDIA technology I guess).

jgvictores commented 6 years ago

This issue was moved to roboticslab-uc3m/openrave-yarp-plugins#48