0
$\begingroup$

Gazebo Answers logo

Hello.

I am trying to get the conveyor belt plugin from Ariac competition to work on my own project, where I need to simulate a conveyor belt moving items.

Is it possible? I have cloned the ariac data from BitBucket, added my own package in the source.

Edit

I created a simple test conveyor, but I don't see any topics popping up.

<?xml version="1.0" encoding="utf-8"?>
<robot name="conveyor_system">
  <link name="frame_link">
    <inertial>
      <origin rpy="0.0 0.0 0.0" xyz="0.0 0.0 0.0"/>
      <mass value="1"/>
      <inertia ixx="1" ixy="0.0" ixz="0.0" iyy="1" iyz="0.0" izz="1"/>
    </inertial>
    <visual>
      <origin rpy="0 0 0" xyz="0.505 0.0 0.05"/>
      <geometry>
        <box size="1.01 0.21 0.1"/>
      </geometry>
      <material name="silver">
        <color rgba="0.7 0.7 0.7 1"/>
      </material>
    </visual>
    <collision>
      <origin rpy="0 0 0" xyz="0.505 0.0 0.05"/>
      <geometry>
        <box size="1.01 0.21 0.1"/>
      </geometry>
    </collision>
  </link>
  <joint name="belt_joint" type="prismatic">
    <parent link="frame_link"/>
    <child link="belt_link"/>
    <axis xyz="0 0 0"/>
    <limit effort="1000.0" lower="-0.5" upper="0.5" velocity="0.5"/>
    <origin rpy="0 0 0" xyz="0 0 0"/>
  </joint>
  <link name="belt_link">
    <inertial>
      <origin rpy="0.0 0.0 0.0" xyz="0.0 0.0 0.0"/>
      <mass value="1"/>
      <inertia ixx="1" ixy="0.0" ixz="0.0" iyy="1" iyz="0.0" izz="1"/>
    </inertial>
    <visual>
      <origin rpy="0 0 0" xyz="0.505 0.0 0.205"/>
      <geometry>
        <box size="1 0.2 0.01"/>
      </geometry>
      <material name="green">
        <color rgba="0 1 0 1"/>
      </material>
    </visual>
    <collision>
      <origin rpy="0 0 0" xyz="0.505 0.0 0.05"/>
      <geometry>
        <box size="1.01 0.21 0.1"/>
      </geometry>
    </collision>
  </link>
  <gazebo reference="belt_link">
    <material>Gazebo/Green</material>
  </gazebo>
  <gazebo>
    <static>true</static>
    <plugin filename="libRosConveyorBeltPlugin.so" name="conveyor_belt_plugin">
      <robot_namespace>/tbelt</robot_namespace>
      <enable_topic>/tbelt/enable</enable_topic>
      <population_rate_modifier_topic>/tbelt/population/rate_modifier</population_rate_modifier_topic>
      <link>belt_link</link>
      <power>0</power>
      <update_rate>10</update_rate>
    </plugin>
  </gazebo>
</robot>

I would appreciate any help, I will also submit more information if needed, since I don't know what to post.


Originally posted by gurnarok on Gazebo Answers with karma: 11 on 2020-10-12

Post score: 1


Original comments

Comment by yah130s on 2020-10-12:
I'm also very interested in utilizing conveyor belt from ARIAC pkgs. That said, you might get better responses by asking concrete questions (otherwise I'm afraid you wouldn't get answers).

Comment by gurnarok on 2020-10-12:
Made a edit, giving a concrete example.

$\endgroup$

2 Answers 2

0
$\begingroup$

Gazebo Answers logo

You need to fix the plugin filename libROSConveyorBeltPlugin.so, the joint limits [0, 1], and the joint axis (1, 0, 0).

These will get the plugin running, but you still need to fix the geometries in your model.


Originally posted by nlamprian with karma: 833 on 2020-10-12

This answer was NOT ACCEPTED on the original site

Post score: 1


Original comments

Comment by gurnarok on 2020-10-13:
Thank you, I didn't notice my typo on the plugin.

I got it to load,but when I run rostopic list, I only get the following topics:

$ rostopic list
/clock
/gazebo/link_states
/gazebo/model_states
/gazebo/parameter_descriptions
/gazebo/parameter_updates
/gazebo/set_link_state
/gazebo/set_model_state
/joint_states
/rosout
/rosout_agg
/tbelt/conveyor/state
/tf
/tf_static

There is no enable topic, so I can't "power on" the belt.

Comment by nlamprian on 2020-10-13:
The enable topic is a gazebo topic. You might wanna fork the plugin and expose a better interface. The implementation is straightforward, should be fairly simple to do it.

Comment by gurnarok on 2020-10-13:
I got it to work, using the service call for it. I just need to reconfigure the geometry of the model and try to get it to work a little bit better. Now it jumps to the side when it tries to reset the position.

Comment by erikkkk on 2020-12-11:
hello, i used your code and corrected it as this answer said. but when i call the service of conveyor control, it always fails "Belt is not currently enabled so power cannot be set. It may be congested." i don't understand whats wrong and as i am not familiar with C++, i cannot fix this problem from reading source code neither... If you had any ideal, could you please help me with this error?

Comment by erikkkk on 2020-12-11:
oh i find your plugin above there and it works. thanks very much!

$\endgroup$
0
$\begingroup$

Gazebo Answers logo

I made a new github repository for the ARIAC conveyor belt. You can find it here: https://github.com/rokokoo/gazebo-conveyor

I am working on making a example package, that shows it working.


Originally posted by gurnarok with karma: 11 on 2020-10-14

This answer was ACCEPTED on the original site

Post score: 0

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.