gazebo-yarp-digit-plugin

所属分类:机器人/智能制造
开发工具:C++
文件大小:13363KB
下载次数:0
上传日期:2023-03-03 08:12:17
上 传 者sh-1993
说明:  基于Python的数字触觉传感器仿真的C++包装器
(A tentative C++ wrapper for the Python based Digit tactile sensor simulation)

文件列表:
CMakeLists.txt (608, 2023-02-28)
ControlDigitPlugin (0, 2023-02-28)
ControlDigitPlugin\CMakeLists.txt (1032, 2023-02-28)
ControlDigitPlugin\src (0, 2023-02-28)
ControlDigitPlugin\src\ControlDigitPlugin.cpp (4952, 2023-02-28)
ControlDigitPlugin\src\ControlDigitPlugin.h (1679, 2023-02-28)
ControlPlugin (0, 2023-02-28)
ControlPlugin\CMakeLists.txt (1235, 2023-02-28)
ControlPlugin\src (0, 2023-02-28)
ControlPlugin\src\ControlPlugin.cpp (17526, 2023-02-28)
ControlPlugin\src\ControlPlugin.h (3300, 2023-02-28)
ControlPlugin\src\TrajectoryGenerator.cpp (4556, 2023-02-28)
ControlPlugin\src\TrajectoryGenerator.h (1530, 2023-02-28)
ControlPlugin\thrift (0, 2023-02-28)
ControlPlugin\thrift\idl.thrift (1211, 2023-02-28)
GraspExample (0, 2023-02-28)
GraspExample\CMakeLists.txt (1275, 2023-02-28)
GraspExample\script.sh (400, 2023-02-28)
GraspExample\src (0, 2023-02-28)
GraspExample\src\GraspExample.cpp (9462, 2023-02-28)
GraspExample\src\GraspExample.h (2367, 2023-02-28)
GraspExample\src\main.cpp (618, 2023-02-28)
GraspExample\thrift (0, 2023-02-28)
GraspExample\thrift\idl.thrift (873, 2023-02-28)
RendererDigitPlugin (0, 2023-02-28)
RendererDigitPlugin\CMakeLists.txt (1274, 2023-02-28)
RendererDigitPlugin\src (0, 2023-02-28)
RendererDigitPlugin\src\RendererDigitPlugin.cpp (15654, 2023-02-28)
RendererDigitPlugin\src\RendererDigitPlugin.h (2040, 2023-02-28)
models (0, 2023-02-28)
models\CMakeLists.txt (703, 2023-02-28)
models\digit (0, 2023-02-28)
models\digit\digit.STL (1461584, 2023-02-28)
models\digit\model.config (319, 2023-02-28)
models\digit\model.sdf (2522, 2023-02-28)
models\env_table (0, 2023-02-28)
models\env_table\model.config (325, 2023-02-28)
models\env_table\model.rsdf (4017, 2023-02-28)
... ...

# gazebo-yarp-digit-plugin (WIP) A tentative C++-based Gazebo-YARP plugin for the python-based DIGIT tactile sensor simulator. This is a work in progress and very likely to change often: - No connections to a physical environment are considered - The interaction between the sensor and a single object is considered ## Dependencies - [pybind11](https://github.com/pybind/pybind11) > can be installed, e.g. on Ubuntu, using `apt install pybind11-dev` - [TACTO](https://github.com/facebookresearch/tacto.git) > it is **not** required to download it as the provided `CMakeLists.txt` take care of it - [Gazebo-YARP plugins](https://github.com/robotology/gazebo-yarp-plugins) > To install it, refer to this [quick start guide](http://robotology.github.io/gazebo-yarp-plugins/master/) ## How to build **We strongly advise to create a Python virtual environment before proceeding**. ```console git clone https://github.com/robotology-playground/gazebo-yarp-digit-plugin.git cd gazebo-yarp-digit-plugin mkdir build cd build cmake ../ ``` > At this point, please wait for the `TACTO` repository to be cloned. ```console pip install -r _deps/tacto-src/requirements/requirements.txt make -j ``` > Then, put the following lines of code in the ~/.bashrc: ```console export GAZEBO_PLUGIN_PATH=$GAZEBO_PLUGIN_PATH:/path/to/the/repo/gazebo-yarp-digit-plugin/build/lib export GAZEBO_MODEL_PATH=$GAZEBO_MODEL_PATH:/path/to/the/repo/gazebo-yarp-digit-plugin/models ``` (Remember to source the .bashrc) ## How to attach a DIGIT to your model The following snippet code is an example on how to add the DIGIT link to your robot ```xml "your_pose" 0 0 0.015 0 0 0 .1 1 0 0 1 0 1 0 0 0 0 0 0 "path to the digit.STL file into the models/digit directory" "path to the digit.STL file into the models directory " "your_collision_name" 30 ``` The following snippet shows how to declare the RendererDigitPlugin ```xml your_object the relative path of your object mesh N(number of sensors used) base contact_digit ... base contact_digit s ``` The `ObjectName` parameter is the name of the object the sensors are sensitive to. The `ObjectMeshAbsolutePath` parameter is the path of the mesh of the object. The `NumberOfSensors` parameter indicates the number of sensors in the model. The `LinkName` and `SensorName` parameters indicate the name of the links and sensors attached to them. The `UpdatePeriod` parameters indicates the sleep time of the rendering thread in seconds. The following snippet shows how to declare the ControlDigitPlugin ```xml 10 ``` The following snippet shows how to declare the ControlPlugin ```xml 10 link_name /name/of/the/output/port /name/of/the/rpc/port ``` The `Link` parameter indicates the name of the link that is controlled. The `PortOutputPoseName` and `PortRpcName` indicates the names of the port which outputs the real time pose of the link and the name of the rpc port to send command to. At the moment, the urdf snippet code is not available. ## How to run the examples ### DIGIT and ball The code simulates the contact between the sensor and a small ball which touches the sensor periodically. 1. Run the `yarpserver` 2. Run the executable ```console gazebo ../world/digit_and_ball.world ``` 3. Open a terminals and write `yarpview --name /in:i` 4. In another terminal, connect ports ```console yarp connect /gazebo-yarp-digit-plugin/output:o /in:i ``` ### Left hand mk3 with one sensor 1. Run the `yarpserver` 2. Run the executable ```console gazebo world/hand_one_sensor.world ``` 3. Open a terminals and write `yarpview --name /medium:i` 4. In another terminal, connect ports ```console yarp connect /gazebo-yarp-digit-plugin-sensor_link_medium"/output:o /medium:i ``` 5. Launch the binary `./build/bin/grasp-example` 6. In another terminal, launch the script `GraspExample/script.sh` ### Left hand mk3 with 3 sensors 1. Run the `yarpserver` 2. Run the executable ```console gazebo world/hand_three_sensors.world ``` 3. Open 3 terminals and write `yarpview --name /thumb:i` `yarpview --name /index:i` `yarpview --name /medium:i` 4. In another terminal, connect ports ```console yarp connect /gazebo-yarp-digit-plugin-sensor_link_thumb/output:o /in1:i yarp connect /gazebo-yarp-digit-plugin-sensor_link_index/output:o /in2:i yarp connect /gazebo-yarp-digit-plugin-sensor_link_medium/output:o /in3:i ```

近期下载者

相关文件


收藏者