diff --git a/hrpsys_gazebo_general/catkin.cmake b/hrpsys_gazebo_general/catkin.cmake
index a2671a17..3c22a193 100644
--- a/hrpsys_gazebo_general/catkin.cmake
+++ b/hrpsys_gazebo_general/catkin.cmake
@@ -2,12 +2,12 @@
cmake_minimum_required(VERSION 2.8.3)
project(hrpsys_gazebo_general)
-find_package(catkin REQUIRED COMPONENTS hrpsys_ros_bridge hrpsys_gazebo_msgs)
+find_package(catkin REQUIRED COMPONENTS hrpsys_ros_bridge hrpsys_gazebo_msgs collada_urdf_jsk_patch)
find_package(PkgConfig)
pkg_check_modules(openrtm_aist openrtm-aist REQUIRED)
pkg_check_modules(openhrp3 openhrp3.1 REQUIRED)
-catkin_package(CATKIN_DEPENDS hrpsys_ros_bridge hrpsys_gazebo_msgs)
+catkin_package(CATKIN_DEPENDS hrpsys_ros_bridge hrpsys_gazebo_msgs collada_urdf_jsk_patch)
## Build only gazebo iob
find_package(PkgConfig)
@@ -56,3 +56,12 @@ add_library(ThermoPlugin src/ThermoPlugin.cpp)
add_dependencies(ThermoPlugin hrpsys_gazebo_msgs_gencpp)
#endif()
+## Convert robot models
+include(${PROJECT_SOURCE_DIR}/cmake/compile_robot_model_for_gazebo.cmake)
+if(EXISTS ${hrpsys_ros_bridge_SOURCE_DIR})
+ set(hrpsys_ros_bridge_PACKAGE_PATH ${hrpsys_ros_bridge_SOURCE_DIR})
+else()
+ set(hrpsys_ros_bridge_PACKAGE_PATH ${hrpsys_ros_bridge_PREFIX}/share/hrpsys_ros_bridge)
+endif()
+generate_gazebo_urdf_file(${hrpsys_ros_bridge_PACKAGE_PATH}/models/SampleRobot.dae)
+add_custom_target(all_robots_compile ALL DEPENDS ${compile_urdf_robots})
diff --git a/hrpsys_gazebo_general/cmake/compile_robot_model_for_gazebo.cmake b/hrpsys_gazebo_general/cmake/compile_robot_model_for_gazebo.cmake
new file mode 100644
index 00000000..2e56486a
--- /dev/null
+++ b/hrpsys_gazebo_general/cmake/compile_robot_model_for_gazebo.cmake
@@ -0,0 +1,53 @@
+##
+## define macros
+##
+macro (generate_gazebo_urdf_file daefile)
+ # set variable
+ if(hrpsys_gazebo_general_SOURCE_DIR)
+ set(hrpsys_gazebo_general_PACKAGE_PATH ${hrpsys_gazebo_general_SOURCE_DIR})
+ elseif(hrpsys_gazebo_general_SOURCE_PREFIX)
+ set(hrpsys_gazebo_general_PACKAGE_PATH ${hrpsys_gazebo_general_SOURCE_PREFIX})
+ else(hrpsys_gazebo_general_SOURCE_PREFIX)
+ set(hrpsys_gazebo_general_PACKAGE_PATH ${hrpsys_gazebo_general_PREFIX}/share/hrpsys_gazebo_general)
+ endif()
+ get_filename_component(_robot_name ${daefile} NAME_WE)
+ set(_workdir ${PROJECT_SOURCE_DIR}/robot_models)
+ set(_out_dir "${_workdir}/${_robot_name}")
+ set(_out_urdf_file "${_out_dir}/${_robot_name}.urdf")
+ set(_out_urdf_gazebo_file "${_out_dir}/${_robot_name}_gazebo.urdf")
+ add_custom_command(OUTPUT ${_out_dir}/meshes
+ COMMAND mkdir ${_out_dir}/meshes)
+ # convert dae to urdf
+ message("generate_gazebo_urdf_file ${daefile}")
+ ## ${compile_robots} is a global target used in compile_robot_model.cmake of hrpsys_ros_bridge.
+ ## this dependency means that converting urdf after executing all of ${compile_robots}.
+ add_custom_command(OUTPUT ${_out_urdf_file}
+ COMMAND ${collada_urdf_jsk_patch_PREFIX}/lib/collada_urdf_jsk_patch/collada_to_urdf ${daefile} -G -A --mesh_output_dir ${_out_dir}/meshes --mesh_prefix "package://${PROJECT_NAME}/robot_models/${_robot_name}/meshes" --output_file=${_out_urdf_file}
+ COMMAND ${_out_dir}/${_robot_name}_additional_urdf_setting.sh ${_out_urdf_file}
+ DEPENDS ${_out_dir}/meshes ${compile_robots})
+ add_custom_command(OUTPUT ${_out_urdf_file}
+ COMMAND ${collada_urdf_jsk_patch_PREFIX}/lib/collada_urdf_jsk_patch/collada_to_urdf ${daefile} -G -A --mesh_output_dir ${_out_dir}/meshes --mesh_prefix "package://${PROJECT_NAME}/robot_models/${_robot_name}/meshes" --output_file=${_out_urdf_file}
+ COMMAND ${_out_dir}/${_robot_name}_additional_urdf_setting.sh ${_out_urdf_file}
+ DEPENDS ${_out_dir}/meshes ${compile_robots})
+ add_custom_command(OUTPUT ${_out_urdf_gazebo_file}
+ COMMAND sed -e "s@package://${PROJECT_NAME}/robot_models/@model://@g" ${_out_urdf_file} > ${_out_urdf_gazebo_file}
+ DEPENDS ${_out_urdf_file})
+ add_custom_target(${_robot_name}_compile DEPENDS ${_out_urdf_gazebo_file})
+ # generate launch and world file
+ set(ROBOT ${_robot_name})
+ string(TOLOWER ${_robot_name} _robot_sname)
+ if(NOT EXISTS ${PROJECT_SOURCE_DIR}/launch/gazebo_${_robot_sname}_no_controllers.launch)
+ configure_file(${hrpsys_gazebo_general_PACKAGE_PATH}/scripts/default_gazebo_robot_no_controllers.launch.in ${PROJECT_SOURCE_DIR}/launch/gazebo_${_robot_sname}_no_controllers.launch)
+ list(APPEND ${_robot_name}_compile ${PROJECT_SOURCE_DIR}/launch/gazebo_${_robot_sname}_no_controllers.launch)
+ endif()
+ if(NOT EXISTS ${PROJECT_SOURCE_DIR}/launch/${_robot_sname}_hrpsys_bringup.launch)
+ configure_file(${hrpsys_gazebo_general_PACKAGE_PATH}/scripts/default_robot_hrpsys_bringup.launch.in ${_robot_sname}_hrpsys_bringup.launch)
+ list(APPEND ${_robot_name}_compile ${PROJECT_SOURCE_DIR}/launch/${_robot_sname}_hrpsys_bringup.launch)
+ endif()
+ if(NOT EXISTS ${_out_dir}/model.config)
+ configure_file(${hrpsys_gazebo_general_PACKAGE_PATH}/scripts/model.config.in ${_out_dir}/model.config)
+ list(APPEND ${_robot_name}_compile ${_out_dir}/model.config)
+ endif()
+ list(APPEND compile_urdf_robots ${_robot_name}_compile)
+ install(DIRECTORY ${_out_dir} DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/robot_models/ PATTERN ".svn" EXCLUDE)
+endmacro()
diff --git a/hrpsys_gazebo_general/config/SampleRobot.yaml b/hrpsys_gazebo_general/config/SampleRobot.yaml
new file mode 100644
index 00000000..f84fe7ea
--- /dev/null
+++ b/hrpsys_gazebo_general/config/SampleRobot.yaml
@@ -0,0 +1,122 @@
+hrpsys_gazebo_configuration:
+## velocity feedback for joint control, use parameter gains/joint_name/p_v
+ use_velocity_feedback: true
+## synchronized hrpsys and gazebo
+# use_synchronized_command: false
+# name of robot (using for namespace)
+ robotname: SampleRobot
+# joint_id (order) conversion from gazebo to hrpsys, joint_id_list[gazebo_id] := hrpsys_id
+ joint_id_list: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]
+# joints list used in gazebo, sizeof(joint_id_list) == sizeof(joints)
+ joints:
+ - RLEG_HIP_R
+ - RLEG_HIP_P
+ - RLEG_HIP_Y
+ - RLEG_KNEE
+ - RLEG_ANKLE_P
+ - RLEG_ANKLE_R
+ - RARM_SHOULDER_P
+ - RARM_SHOULDER_R
+ - RARM_SHOULDER_Y
+ - RARM_ELBOW
+ - RARM_WRIST_Y
+ - RARM_WRIST_P
+ - RARM_WRIST_R
+ - LLEG_HIP_R
+ - LLEG_HIP_P
+ - LLEG_HIP_Y
+ - LLEG_KNEE
+ - LLEG_ANKLE_P
+ - LLEG_ANKLE_R
+ - LARM_SHOULDER_P
+ - LARM_SHOULDER_R
+ - LARM_SHOULDER_Y
+ - LARM_ELBOW
+ - LARM_WRIST_Y
+ - LARM_WRIST_P
+ - LARM_WRIST_R
+ - WAIST_P
+ - WAIST_R
+ - CHEST
+## comment for joint index
+# 0 - RLEG_HIP_R
+# 1 - RLEG_HIP_P
+# 2 - RLEG_HIP_Y
+# 3 - RLEG_KNEE
+# 4 - RLEG_ANKLE_P
+# 5 - RLEG_ANKLE_R
+# 6 - RARM_SHOULDER_P
+# 7 - RARM_SHOULDER_R
+# 8 - RARM_SHOULDER_Y
+# 9 - RARM_ELBOW
+# 10 - RARM_WRIST_Y
+# 11 - RARM_WRIST_P
+# 12 - RARM_WRIST_R
+# 13 - LLEG_HIP_R
+# 14 - LLEG_HIP_P
+# 15 - LLEG_HIP_Y
+# 16 - LLEG_KNEE
+# 17 - LLEG_ANKLE_P
+# 18 - LLEG_ANKLE_R
+# 19 - LARM_SHOULDER_P
+# 20 - LARM_SHOULDER_R
+# 21 - LARM_SHOULDER_Y
+# 22 - LARM_ELBOW
+# 23 - LARM_WRIST_Y
+# 24 - LARM_WRIST_P
+# 25 - LARM_WRIST_R
+# 26 - WAIST_P
+# 27 - WAIST_R
+# 28 - CHEST
+## joint gain settings
+ gains:
+ LLEG_HIP_R: {p: 12000.0, d: 4.0, i: 0.0, vp: 6.0, i_clamp: 0.0, p_v: 250.0}
+ LLEG_HIP_P: {p: 24000.0, d: 6.0, i: 0.0, vp: 20.0, i_clamp: 0.0, p_v: 250.0}
+ LLEG_HIP_Y: {p: 4000.0, d: 4.0, i: 0.0, vp: 1.0, i_clamp: 0.0, p_v: 250.0}
+ LLEG_KNEE: {p: 36000.0, d: 6.0, i: 0.0, vp: 20.0, i_clamp: 0.0, p_v: 250.0}
+ LLEG_ANKLE_P: {p: 18000.0, d: 3.0, i: 0.0, vp: 20.0, i_clamp: 0.0, p_v: 250.0}
+ LLEG_ANKLE_R: {p: 6000.0, d: 2.0, i: 0.0, vp: 4.0, i_clamp: 0.0, p_v: 250.0}
+ RLEG_HIP_R: {p: 12000.0, d: 4.0, i: 0.0, vp: 6.0, i_clamp: 0.0, p_v: 250.0}
+ RLEG_HIP_P: {p: 24000.0, d: 6.0, i: 0.0, vp: 20.0, i_clamp: 0.0, p_v: 250.0}
+ RLEG_HIP_Y: {p: 4000.0, d: 4.0, i: 0.0, vp: 1.0, i_clamp: 0.0, p_v: 250.0}
+ RLEG_KNEE: {p: 36000.0, d: 6.0, i: 0.0, vp: 20.0, i_clamp: 0.0, p_v: 250.0}
+ RLEG_ANKLE_P: {p: 18000.0, d: 3.0, i: 0.0, vp: 20.0, i_clamp: 0.0, p_v: 250.0}
+ RLEG_ANKLE_R: {p: 6000.0, d: 2.0, i: 0.0, vp: 4.0, i_clamp: 0.0, p_v: 250.0}
+ WAIST_P: {p: 8000.0, d: 4.0, i: 0.0, vp: 20.0, i_clamp: 0.0, p_v: 250.0}
+ WAIST_R: {p: 8000.0, d: 4.0, i: 0.0, vp: 20.0, i_clamp: 0.0, p_v: 250.0}
+ CHEST: {p: 6000.0, d: 2.0, i: 0.0, vp: 20.0, i_clamp: 0.0, p_v: 250.0}
+ LARM_SHOULDER_P: {p: 1200.0, d: 1.0, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 160.0}
+ LARM_SHOULDER_R: {p: 500.0, d: 0.5, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 120.0}
+ LARM_SHOULDER_Y: {p: 200.0, d: 0.3, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 100.0}
+ LARM_ELBOW: {p: 1000.0, d: 1.4, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 160.0}
+ LARM_WRIST_Y: {p: 200.0, d: 0.1, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 100.0}
+ LARM_WRIST_P: {p: 300.0, d: 0.2, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 100.0}
+ LARM_WRIST_R: {p: 20.0, d: 0.1, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 100.0}
+ RARM_SHOULDER_P: {p: 1200.0, d: 1.0, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 160.0}
+ RARM_SHOULDER_R: {p: 500.0, d: 0.5, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 120.0}
+ RARM_SHOULDER_Y: {p: 200.0, d: 0.3, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 100.0}
+ RARM_ELBOW: {p: 1000.0, d: 1.4, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 160.0}
+ RARM_WRIST_Y: {p: 200.0, d: 0.1, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 100.0}
+ RARM_WRIST_P: {p: 300.0, d: 0.2, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 100.0}
+ RARM_WRIST_R: {p: 20.0, d: 0.1, i: 0.0, vp: 0.0, i_clamp: 0.0, p_v: 100.0}
+## force sensor settings
+## list of force sensorname
+ force_torque_sensors:
+ - lfsensor
+ - rfsensor
+ - lhsensor
+ - rhsensor
+## configuration of force sensor
+## key of force_torque_sensors_config should be a member of force_torque_sensors
+ force_torque_sensors_config:
+ lfsensor: {joint_name: 'LLEG_ANKLE_R', frame_id: 'LLEG_LINK6', translation: [0, 0, 0], rotation: [1, 0, 0, 0]}
+ rfsensor: {joint_name: 'RLEG_ANKLE_R', frame_id: 'RLEG_LINK6', translation: [0, 0, 0], rotation: [1, 0, 0, 0]}
+ lhsensor: {joint_name: 'LARM_WRIST_R', frame_id: 'LARM_LINK7'}
+ rhsensor: {joint_name: 'RARM_WRIST_R', frame_id: 'RARM_LINK7'}
+## IMU sensor settings
+## configuration of IMU sensor
+## key of imu_sensors_config should be a member of imu_sensors
+ imu_sensors:
+ - imu_sensor0
+ imu_sensors_config:
+ imu_sensor0: {ros_name: 'sample_imu_sensor', link_name: 'WAIST_LINK0', frame_id: 'WAIST_LINK0'}
diff --git a/hrpsys_gazebo_general/launch/gazebo_robot_no_controllers.launch b/hrpsys_gazebo_general/launch/gazebo_robot_no_controllers.launch
new file mode 100644
index 00000000..ae1226ec
--- /dev/null
+++ b/hrpsys_gazebo_general/launch/gazebo_robot_no_controllers.launch
@@ -0,0 +1,55 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/hrpsys_gazebo_general/launch/gazebo_samplerobot_no_controllers.launch b/hrpsys_gazebo_general/launch/gazebo_samplerobot_no_controllers.launch
new file mode 100644
index 00000000..f1c574b1
--- /dev/null
+++ b/hrpsys_gazebo_general/launch/gazebo_samplerobot_no_controllers.launch
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/hrpsys_gazebo_general/launch/robot_hrpsys_bringup.launch b/hrpsys_gazebo_general/launch/robot_hrpsys_bringup.launch
new file mode 100644
index 00000000..588b60ce
--- /dev/null
+++ b/hrpsys_gazebo_general/launch/robot_hrpsys_bringup.launch
@@ -0,0 +1,68 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/hrpsys_gazebo_general/launch/samplerobot_hrpsys_bringup.launch b/hrpsys_gazebo_general/launch/samplerobot_hrpsys_bringup.launch
new file mode 100644
index 00000000..a0b6e2aa
--- /dev/null
+++ b/hrpsys_gazebo_general/launch/samplerobot_hrpsys_bringup.launch
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/hrpsys_gazebo_general/manifest.xml b/hrpsys_gazebo_general/manifest.xml
index 83da6cb3..03fdb3bb 100644
--- a/hrpsys_gazebo_general/manifest.xml
+++ b/hrpsys_gazebo_general/manifest.xml
@@ -14,8 +14,7 @@
-
-
-
+
+
diff --git a/hrpsys_gazebo_general/package.xml b/hrpsys_gazebo_general/package.xml
index f99c73c3..782658d9 100644
--- a/hrpsys_gazebo_general/package.xml
+++ b/hrpsys_gazebo_general/package.xml
@@ -18,14 +18,13 @@
hrpsys_ros_bridge
hrpsys_gazebo_msgs
gazebo_ros
- gazebo_plugins
- gazebo_msgs
+ collada_urdf_jsk_patch
hrpsys_ros_bridge
hrpsys_gazebo_msgs
gazebo_ros
- gazebo_plugins
- gazebo_msgs
+ collada_urdf_jsk_patch
+ xacro
diff --git a/hrpsys_gazebo_general/robot_models/SampleRobot/SampleRobot.urdf.xacro b/hrpsys_gazebo_general/robot_models/SampleRobot/SampleRobot.urdf.xacro
new file mode 100644
index 00000000..ea99ae8a
--- /dev/null
+++ b/hrpsys_gazebo_general/robot_models/SampleRobot/SampleRobot.urdf.xacro
@@ -0,0 +1,47 @@
+
+
+
+
+
+ SampleRobot
+ hrpsys_gazebo_configuration
+
+
+
+
+
+ 1
+ 1000.0
+
+
+ gaussian
+
+ 0.0
+ 2e-4
+ 0.0000075
+ 0.0000008
+
+
+ 0.0
+ 1.7e-2
+ 0.1
+ 0.001
+
+
+
+
+
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
diff --git a/hrpsys_gazebo_general/robot_models/SampleRobot/SampleRobot_additional_urdf_setting.sh b/hrpsys_gazebo_general/robot_models/SampleRobot/SampleRobot_additional_urdf_setting.sh
new file mode 100755
index 00000000..6c358561
--- /dev/null
+++ b/hrpsys_gazebo_general/robot_models/SampleRobot/SampleRobot_additional_urdf_setting.sh
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+function error {
+ exit 1
+}
+trap error ERR
+
+OUTPUT_FILE=$1
+## change foot parameters
+sed -i -e '//{N;N;N;N;s@ \n 0.9\n 0.9\n @ \n 1000000.0\n 100.0\n 1.5\n 1.5\n 1 0 0\n 10.0\n 0.00\n @;}' ${OUTPUT_FILE}
+sed -i -e '//{N;N;N;N;s@ \n 0.9\n 0.9\n @ \n 1000000.0\n 100.0\n 1.5\n 1.5\n 1 0 0\n 10.0\n 0.00\n @;}' ${OUTPUT_FILE}
+# continuous joint not working in GAZEBO
+sed -i -e 's@continuous@revolute@g' ${OUTPUT_FILE}
+## change max effort
+sed -i -e 's@effort="100"@effort="200"@g' ${OUTPUT_FILE}
+## change max velocity
+sed -i -e 's@velocity="0.5"@velocity="6.0"@g' ${OUTPUT_FILE}
diff --git a/hrpsys_gazebo_general/scripts/default_gazebo_robot_no_controllers.launch.in b/hrpsys_gazebo_general/scripts/default_gazebo_robot_no_controllers.launch.in
new file mode 100644
index 00000000..cbdee10e
--- /dev/null
+++ b/hrpsys_gazebo_general/scripts/default_gazebo_robot_no_controllers.launch.in
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/hrpsys_gazebo_general/scripts/default_robot_hrpsys_bringup.launch.in b/hrpsys_gazebo_general/scripts/default_robot_hrpsys_bringup.launch.in
new file mode 100644
index 00000000..360c7d85
--- /dev/null
+++ b/hrpsys_gazebo_general/scripts/default_robot_hrpsys_bringup.launch.in
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/hrpsys_gazebo_general/scripts/gazebo b/hrpsys_gazebo_general/scripts/gazebo
new file mode 100755
index 00000000..916bc630
--- /dev/null
+++ b/hrpsys_gazebo_general/scripts/gazebo
@@ -0,0 +1,8 @@
+#!/bin/bash
+
+rospack find drcsim_gazebo 2> /dev/null
+if [ $? -eq 0 ]; then
+ rosrun drcsim_gazebo run_gazebo $@
+else
+ rosrun gazebo_ros gazebo $@
+fi
diff --git a/hrpsys_gazebo_general/scripts/gzclient b/hrpsys_gazebo_general/scripts/gzclient
new file mode 100755
index 00000000..229a3120
--- /dev/null
+++ b/hrpsys_gazebo_general/scripts/gzclient
@@ -0,0 +1,8 @@
+#!/bin/bash
+
+rospack find drcsim_gazebo 2> /dev/null
+if [ $? -eq 0 ]; then
+ rosrun drcsim_gazebo run_gzclient $@
+else
+ rosrun gazebo_ros gzclient $@
+fi
diff --git a/hrpsys_gazebo_general/scripts/gzserver b/hrpsys_gazebo_general/scripts/gzserver
new file mode 100755
index 00000000..192757ee
--- /dev/null
+++ b/hrpsys_gazebo_general/scripts/gzserver
@@ -0,0 +1,8 @@
+#!/bin/bash
+
+rospack find drcsim_gazebo 2> /dev/null
+if [ $? -eq 0 ]; then
+ rosrun drcsim_gazebo run_gzserver $@
+else
+ rosrun gazebo_ros gzserver $@
+fi
diff --git a/hrpsys_gazebo_general/scripts/model.config.in b/hrpsys_gazebo_general/scripts/model.config.in
new file mode 100644
index 00000000..e492370c
--- /dev/null
+++ b/hrpsys_gazebo_general/scripts/model.config.in
@@ -0,0 +1,13 @@
+
+
+ @ROBOT@
+ 0.1.0
+
+ Masaki Murooka
+ murooka@jsk.t.u-tokyo.ac.jp
+
+ @ROBOT@_gazebo.urdf
+
+ auto generated file ...
+
+
diff --git a/hrpsys_gazebo_general/setup.sh b/hrpsys_gazebo_general/setup.sh
new file mode 100644
index 00000000..08003629
--- /dev/null
+++ b/hrpsys_gazebo_general/setup.sh
@@ -0,0 +1,35 @@
+#!/bin/sh
+
+# DRCSIM_SETUP_SH=/usr/share/drcsim/setup.sh
+DRCSIM_SETUP_SH=/usr/share/gazebo/setup.sh
+
+if [ ! -e $DRCSIM_SETUP_SH ]; then
+ echo -e "\e[31mdrcsim should be installed for using hrpsys_gazebo\e[m"
+ echo -e "\e[31msee http://gazebosim.org/wiki/DRC/Install\e[m"
+ return
+fi
+
+ROS_PACKAGE_PATH_ORG=$ROS_PACKAGE_PATH
+
+unset GAZEBO_MODEL_PATH
+unset GAZEBO_RESOURCE_PATH
+unset GAZEBO_MASTER_URI
+unset GAZEBO_PLUGIN_PATH
+unset GAZEBO_MODEL_DATABASE_URI
+
+source $DRCSIM_SETUP_SH
+
+## append original package path because /opt/ros/groovy/setup.sh have been called in drcsim/setup.sh
+export ROS_PACKAGE_PATH=$ROS_PACKAGE_PATH_ORG:$ROS_PACKAGE_PATH
+## sort package path
+export ROS_PACKAGE_PATH=`echo $(echo $ROS_PACKAGE_PATH | sed -e "s/:/\n/g" | awk '!($0 in A) && A[$0] = 1' | grep -v "opt/ros"; echo $ROS_PACKAGE_PATH | sed -e "s/:/\n/g" | awk '!($0 in A) && A[$0] = 1' | grep "opt/ros") | sed -e "s/ /:/g"`
+
+##
+pkgdir=`rospack find hrpsys_gazebo_general`
+
+if [ -e ${pkgdir} ]; then
+ export GAZEBO_RESOURCE_PATH=${pkgdir}/worlds:$GAZEBO_RESOURCE_PATH
+ export GAZEBO_MODEL_PATH=$GAZEBO_MODEL_PATH:${pkgdir}/robot_models:${pkgdir}/..
+ export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${pkgdir}/plugins
+fi
+
diff --git a/hrpsys_gazebo_general/worlds/empty.world b/hrpsys_gazebo_general/worlds/empty.world
new file mode 100644
index 00000000..0ef0fa70
--- /dev/null
+++ b/hrpsys_gazebo_general/worlds/empty.world
@@ -0,0 +1,31 @@
+
+
+
+
+ 0 0 -9.81
+
+
+ quick
+ 50
+ 1.4
+
+
+ 0.0
+ 0.2
+ 100.0
+ 0.0
+
+
+ 1000
+ 0.001
+
+
+
+ model://sun
+
+
+
+ model://ground_plane
+
+
+