Git Product home page Git Product logo

Comments (4)

marceloparavisi avatar marceloparavisi commented on June 6, 2024

Hello walidtouzout

In order to apply lift and drag forces using the usv_dynamics_plugin, you should configure the plugin by attaching it to a link.

<plugin name="usv_sail_plugin" filename="libfoil_dynamics_plugin.so">
<link_type>rudder</link_type>
<mult_lift>1.5</mult_lift>
<mult_drag>1</mult_drag>
<cp>-0.2 0 0</cp>
<area>0.02</area>
<fluid_density>1000</fluid_density>
<forward>1 0 0</forward>
<upward>0 1 0</upward>
<link_name>rudder</link_name>
<fluidVelocity>${waterType}</fluidVelocity>
</plugin>

I believe you should develop a plugin to visualize all forces. In last year, I asked for a plugin with this functionality to a OSRF developer and she informed me that it haven't been developed.

Regards,
Marcelo Paravisi

from usv_sim_lsa.

walidtouzout avatar walidtouzout commented on June 6, 2024

from usv_sim_lsa.

davihdsantos avatar davihdsantos commented on June 6, 2024

Hi @walidtouzout

you are correct. you have to modify the lift and drag plugin to publish the forces to a topic. then you visualize it using Rviz.

You can use this plugin as an example https://github.com/uuvsimulator/uuv_simulator/blob/master/uuv_gazebo_plugins/uuv_gazebo_ros_plugins/src/FinROSPlugin.cc

they publish the forces on a topic called joint/wrench.

from usv_sim_lsa.

walidtouzout avatar walidtouzout commented on June 6, 2024

Hi again,
when I was trying to apply Lift/drag forces by configuring the plugin in empty.world file :

<model name="model">
    <link name="link">
           <wind>true</wind>
    </link>
    <plugin name="foil_dynamics_plugin" filename="libfoil_dynamics_plugin.so">
    <link_type>rudder</link_type>
    <mult_lift>1.5</mult_lift>
<mult_drag>1</mult_drag>
<cp>-0.2 0 0</cp>
<area>0.02</area>
<fluid_density>1000</fluid_density>
<forward>1 0 0</forward>
<upward>0 1 0</upward>
<link_name>rudder</link_name>
<fluidVelocity>${waterType}</fluidVelocity>
</plugin>      

I saw in the terminal that the plugin was loaded, but when running a scenario I got this error message:

gzserver: /usr/include/boost/smart_ptr/shared_ptr.hpp:648: typename boost::detail::sp_member_access::type boost::shared_ptr::operator->() const [with T = gazebo::physics::Link; typename boost::detail::sp_member_access::type = gazebo::physics::Link*]: Assertion `px != 0' failed.

and the scenario couldn't be launched, can you help me to solve this problem ?

from usv_sim_lsa.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.