Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run real robot from docker container #1135

Open
triwahyuu opened this issue May 14, 2024 · 0 comments
Open

Run real robot from docker container #1135

triwahyuu opened this issue May 14, 2024 · 0 comments

Comments

@triwahyuu
Copy link

I am currently having a difficulty when trying to run Nextage Open robot from inside a docker container.
I am using a version of docker image built from turlucode/ros-docker-gui with the dependencies for the nextage open installed using ROS Kinetic.

Here is the command to run the docker container:

xhost +
docker run --rm -it --privileged --net=host --ipc=host --pid=host \
--cap-add=SYS_PTRACE \
--security-opt seccomp=unconfined \
-v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
-v $HOME/.Xauthority:/root/.Xauthority -e XAUTHORITY=/root/.Xauthority \
-v /home/tri/nextage-open/catkin_ws:/root/catkin_ws \
-e ROS_IP=127.0.0.1 \
-v /dev:/dev \
turlucode/ros-kinetic:cpu

Here is the log I got when running the command to launch the real robot:

root ➜ ~/catkin_ws $ rtmlaunch nextagea_ros_bridge nextagea_ros_bridge_real.launch
[rtmlaunch] default corbaport:= 15005 will be used
[rtmlaunch] Start omniNames at port 15005 

Tue May 14 06:35:24 2024:

Starting omniNames for the first time.
Wrote initial log file.
Read log file successfully.
Root context is IOR:010000002b00000049444c3a6f6d672e6f72672f436f734e616d696e672f4e616d696e67436f6e746578744578743a312e30000001000000000000007400000001010200100000003139322e3136382e3132382e313030009d3a00000b0000004e616d6553657276696365000300000000000000080000000100000000545441010000001c0000000100000001000100010000000100010509010100010000000901010003545441080000002c064366010063d3
Checkpointing Phase 1: Prepare.
Checkpointing Phase 2: Commit.
Checkpointing completed.
... logging to /root/.ros/log/2559d5e2-11bc-11ef-aae0-98bb1e1c2d52/roslaunch-aislaisl-blade-15-base-model-early-2020-rz09-0328-25551.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://127.0.0.1:46093/

SUMMARY
========

PARAMETERS
 * /HrpsysSeqStateROSBridge/publish_sensor_transforms: True
 * /controller_configuration: [{'group_name': '...
 * /diagnostic_aggregator/analyzers/computers/contains: ['HD Temp', 'CPU ...
 * /diagnostic_aggregator/analyzers/computers/path: Computers
 * /diagnostic_aggregator/analyzers/computers/type: diagnostic_aggreg...
 * /diagnostic_aggregator/analyzers/hrpsys/contains: ['hrpEC', 'Emerge...
 * /diagnostic_aggregator/analyzers/hrpsys/path: Hrpsys
 * /diagnostic_aggregator/analyzers/hrpsys/type: diagnostic_aggreg...
 * /diagnostic_aggregator/analyzers/mode/contains: ['Operating Mode'...
 * /diagnostic_aggregator/analyzers/mode/path: Mode
 * /diagnostic_aggregator/analyzers/mode/type: diagnostic_aggreg...
 * /diagnostic_aggregator/analyzers/motor/contains: ['Motor']
 * /diagnostic_aggregator/analyzers/motor/path: Motor
 * /diagnostic_aggregator/analyzers/motor/type: diagnostic_aggreg...
 * /diagnostic_aggregator/base_path: 
 * /diagnostic_aggregator/pub_rate: 1.0
 * /robot_description: <?xml version="1....
 * /rosdistro: kinetic
 * /rosversion: 1.12.17
 * /rtmnameserver_host: nextage
 * /rtmnameserver_port: 15005
 * /rtmnameserver_robotname: RobotHardware0

NODES
  /
    DataLoggerServiceROSBridge (hrpsys_ros_bridge/DataLoggerServiceROSBridgeComp)
    ForwardKinematicsServiceROSBridge (hrpsys_ros_bridge/ForwardKinematicsServiceROSBridgeComp)
    HrpsysJointTrajectoryBridge (hrpsys_ros_bridge/HrpsysJointTrajectoryBridge)
    HrpsysSeqStateROSBridge (hrpsys_ros_bridge/HrpsysSeqStateROSBridge)
    RobotHardwareServiceROSBridge (hrpsys_ros_bridge/RobotHardwareServiceROSBridgeComp)
    SequencePlayerServiceROSBridge (hrpsys_ros_bridge/SequencePlayerServiceROSBridgeComp)
    StateHolderServiceROSBridge (hrpsys_ros_bridge/StateHolderServiceROSBridgeComp)
    diagnostic_aggregator (diagnostic_aggregator/aggregator_node)
    hrpsys_profile (hrpsys_ros_bridge/hrpsys_profile.py)
    hrpsys_py (hironx_ros_bridge/hironx.py)
    hrpsys_ros_diagnostics (hrpsys_ros_bridge/diagnostics.py)
    hrpsys_state_publisher (robot_state_publisher/state_publisher)
    rtmlaunch_hrpsys_ros_bridge (openrtm_tools/rtmlaunch.py)
    sensor_ros_bridge_connect (hrpsys_ros_bridge/sensor_ros_bridge_connect.py)

WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtactivate
WARNING: unrecognized tag rtactivate
WARNING: unrecognized tag rtactivate
WARNING: unrecognized tag rtactivate
WARNING: unrecognized tag rtactivate
WARNING: unrecognized tag rtactivate
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtconnect
WARNING: unrecognized tag rtactivate
auto-starting new master
process[master]: started with pid [25563]
ROS_MASTER_URI=http://127.0.0.1:11311

setting /run_id to 2559d5e2-11bc-11ef-aae0-98bb1e1c2d52
process[rosout-1]: started with pid [25589]
started core service [/rosout]
process[hrpsys_py-2]: started with pid [25606]
process[HrpsysSeqStateROSBridge-3]: started with pid [25609]
process[HrpsysJointTrajectoryBridge-4]: started with pid [25626]
process[hrpsys_state_publisher-5]: started with pid [25634]
process[hrpsys_ros_diagnostics-6]: started with pid [25642]
Failed to import pyassimp, see https://github.com/ros-planning/moveit/issues/86 for more info
configuration ORB with nextage:15005
[hrpsys.py] waiting ModelLoader
[hrpsys.py] start hrpsys
[hrpsys.py] finding RTCManager and RobotHardware
[hrpsys.py]  waitForRTCManagerAndRoboHardware has renamed to waitForRTCManagerAndRoboHardware: Please update your code
process[diagnostic_aggregator-7]: started with pid [25657]
process[hrpsys_profile-8]: started with pid [25665]
process[sensor_ros_bridge_connect-9]: started with pid [25746]
[sensor_ros_bridge_connect.py]  start
configuration ORB with nextage:15005
[sensor_ros_bridge_connect.py]  initSensorRosBridgeConnection
[sensor_ros_bridge_connect.py]  waitForRTCManagerAndRoboHardware has renamed to waitForRTCManagerAndRoboHardware: Please update your code
process[rtmlaunch_hrpsys_ros_bridge-10]: started with pid [25773]
process[SequencePlayerServiceROSBridge-11]: started with pid [25797]
process[DataLoggerServiceROSBridge-12]: started with pid [25809]
process[ForwardKinematicsServiceROSBridge-13]: started with pid [25823]
[rtmlaunch] starting...  /root/catkin_ws/src/rtmros_common/hrpsys_ros_bridge/launch/hrpsys_ros_bridge.launch
[rtmlaunch] RTCTREE_NAMESERVERS nextage:15005 nextage:15005 
[rtmlaunch] SIMULATOR_NAME RobotHardware0 
process[StateHolderServiceROSBridge-14]: started with pid [25835]
process[RobotHardwareServiceROSBridge-15]: started with pid [25841]
[hrpsys.py] wait for RTCmanager : None
[hrpsys.py] wait for RobotHardware : <hrpsys.rtm.RTcomponent instance at 0x7f487a3c04d0> ( timeout 0 < 10)
[hrpsys.py] findComps -> RobotHardware0 : <hrpsys.rtm.RTcomponent instance at 0x7f487a3c04d0> isActive? = False 
[hrpsys.py] simulation_mode : False
[hrpsys.py]  Hrpsys controller version info: 
[hrpsys.py]    ms =  <hrpsys.rtm.RTCmanager instance at 0x7f4877d12638>
[hrpsys.py]    ref =  <RTM._objref_Manager instance at 0x7f4877d12440>
[sensor_ros_bridge_connect.py] wait for RTCmanager : nextage
[sensor_ros_bridge_connect.py] wait for RobotHardware0 : <hrpsys.rtm.RTcomponent instance at 0x7f3e363a62d8> ( timeout 0 < 10)
[sensor_ros_bridge_connect.py] findComps -> RobotHardware0 : <hrpsys.rtm.RTcomponent instance at 0x7f3e363a62d8> isActive? = False 
[sensor_ros_bridge_connect.py] simulation_mode : False
[sensor_ros_bridge_connect.py]   wait for  HrpsysSeqStateROSBridge0  :  None
[sensor_ros_bridge_connect.py]   wait for  HrpsysSeqStateROSBridge0  :  None
[sensor_ros_bridge_connect.py]   wait for  HrpsysSeqStateROSBridge0  :  None
[sensor_ros_bridge_connect.py]   wait for  HrpsysSeqStateROSBridge0  :  None
[sensor_ros_bridge_connect.py]   wait for  HrpsysSeqStateROSBridge0  :  None
[sensor_ros_bridge_connect.py]   wait for  HrpsysSeqStateROSBridge0  :  None
[sensor_ros_bridge_connect.py]   wait for  HrpsysSeqStateROSBridge0  :  None
[sensor_ros_bridge_connect.py]   wait for  HrpsysSeqStateROSBridge0  :  None
[sensor_ros_bridge_connect.py]   wait for  HrpsysSeqStateROSBridge0  :  None

It seems that it was stuck trying to get the RTC from the robot.
I have tested the robot to run on the original development environment, and it works normally.
And I can confirm that the robot can be pinged from inside the docker container.

Am I missing something on the docker run command? or is it not possible to do?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant