Coder Social home page Coder Social logo

Comments (2)

marcusvinicius178 avatar marcusvinicius178 commented on August 17, 2024

The solution was switch the default complex physics:

    <physics type="ode">
      <real_time_update_rate>1000.0</real_time_update_rate>
      <max_step_size>0.013</max_step_size> <!-- Smaller for more accuracy -->
      <real_time_factor>1</real_time_factor>
      <ode>
        <solver>
          <type>quick</type>
          <iters>100</iters> <!-- Reduced from 150 to potentially soften the simulation, lower to reduce computational load -->
          <precon_iters>0</precon_iters>
          <sor>1.4</sor> <!-- Lower to potentially reduce rigidity -->
          <use_dynamic_moi_rescaling>1</use_dynamic_moi_rescaling>
        </solver>
        <constraints>
          <cfm>0.001</cfm> <!-- Lower for a tighter simulation, reducing "sponginess" -->
          <erp>0.15</erp> <!-- Increase to ensure error correction is more effective -->
          <contact_max_correcting_vel>500.000000</contact_max_correcting_vel> <!-- Lower to reduce the aggressiveness of contact corrections -->
          <contact_surface_layer>0.01</contact_surface_layer> <!-- Lower to minimize penetration without increasing rigidity -->
        </constraints>
      </ode>
    </physics>

for this basic one, based on Prius Repository

    <physics name='default_physics' default='0' type='ode'>
      <max_step_size>0.001</max_step_size>
      <real_time_factor>1</real_time_factor>
      <real_time_update_rate>1000</real_time_update_rate>
    </physics>

However I am still facing an issue, which is the joints of my truck does not let it static, even if I publish a cmd_vel = 0 to emulate a handbrake. It starts falling down on reverse as the video below shows:

Truck Sliding on Reverse

I am trying to implement a fake anchor, kind of handbrake, to attach the truck to the ground, but not sure if it is going to work.

Otherwise I will need to switch the simple ackermman gazeboplugin for a more complex dynamic truck model, which assigns torque, force, power, etc to the truck's whell joints such as Prius Hybrid Plugins

from gazebo-classic.

marcusvinicius178 avatar marcusvinicius178 commented on August 17, 2024

Hi, I have realized that the gazebo Ackermann plugin just simulates kinematics, which is why my truck is not able to move on inclined terrains with high friction. If someone has developed an Ackermann Dynamic model plugin for Gazebo simulations, which handles with Effort, Torque, Force, Power, please let me know. I guess something similar to Prius control from ROS1 could work: https://github.com/osrf/car_demo/blob/master/car_demo/plugins/PriusHybridPlugin.cc

from gazebo-classic.

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.