From 4e941d4777006c00c3d020c691176be6fce0b6ca Mon Sep 17 00:00:00 2001 From: MasakiMurooka Date: Wed, 19 Oct 2016 14:17:46 +0900 Subject: [PATCH] [README.md] add document to convert from stl to urdf, eus. --- README.md | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) diff --git a/README.md b/README.md index 8fc21a234..e34da89b5 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,75 @@ jsk_model_tools [![Build Status](https://travis-ci.org/jsk-ros-pkg/jsk_model_tools.png?branch=master)](https://travis-ci.org/jsk-ros-pkg/jsk_model_tools) =============== + +# Model Convert + +## Convert from CAD manually +(cf. PR of function to automatically convert: https://github.com/euslisp/jskeus/pull/248) + +- Convert1. export stl mesh with SolidEdge + +=> my_model.stl is generated. + +- Convert2. generate urdf +generate urdf with following contents. +(assume that my_model.stl is located at /home/leus/my_model.stl) +``` + + + + + + + + + + + + + + + + + + + + + +``` +=> generate my_model.urdf + +- Convert3. convert to collada +``` +rosrun collada_urdf_jsk_patch urdf_to_collada my_model.urdf my_model.dae +``` +=> my_model.dae is generated. + +- Convert4. convert to eus +``` +rosrun euscollada collada2eus my_model.dae my_model.l +``` +=> my_model.l is generated. + +- Visualize1. visualize urdf with Rviz +``` +roslaunch urdf_tutorial display.launch model:=/home/leus/my_model.urdf +``` + +- Visualize2. spawn urdf to gazebo +``` +roslaunch gazebo_ros empty_world.launch +rosrun gazebo_ros spawn_model -file my_model.urdf -urdf -model my_model +``` + +- Visualize3. visualize eus with irtviewer +``` +roseus my_model.l +(objects (list (my_model))) +``` + +- Visualize4. visualize stl with irtviewer +``` +(load "package://eus_assimp/euslisp/eus-assimp.l" ) +(setq glv (load-mesh-file "my_model.stl" :scale 1000.0)) +(objects (list glv)) +```