ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

Based on uwsim, what can I do to let the auv stop when pid was closed.

asked 2016-03-09 15:36:10 -0500

ZYS gravatar image

I run the pid controller to let the auv moving to a setpoint. When it reached setpoint and pid controller was closed automatically, the auv still moved even though I give the thruster intput zero. I think it is because of inertial phenomenon. I want to let the auv stop when pid was closed. What can I do?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2016-03-10 02:53:27 -0500

Javier Perez gravatar image

Hi,

It really depends on what is your goal. If you want a realistic simulation you shouldn't stop the controller as in real life situation you should keep the position (station keeping). But if you want to stop it anyway you can call the service '/dynamics/reset' which will stop the inertias, but eventually the vehicle will start moving again as it happens at the beginning of simulation. The last option is killing the dynamic simulation node, just have a look at how to stop a ros node and kill: for instance "rosnode kill /dynamics_g500" on a terminal should do it.

edit flag offensive delete link more

Comments

Thanks for your suggestion. Is it possible to design a pid to control velocity and use this pid to make the velocity zero after the auv reach the setpoint?

ZYS gravatar image ZYS  ( 2016-03-10 07:49:06 -0500 )edit

It should be, just left the PID working after you reach the setpoint and if it is well designed it should remain stable around 0 velocity.

Javier Perez gravatar image Javier Perez  ( 2016-03-10 09:30:44 -0500 )edit

The pid_position and pid_rotation use the same thruster, thus if I want the auv rotate, I must close the pid controlling the position. I will try to implement a pid controlling velocity to zero before rotating. Thanks for your suggestion. You are really really nice and helpful!

ZYS gravatar image ZYS  ( 2016-03-10 11:15:51 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2016-03-09 15:36:10 -0500

Seen: 148 times

Last updated: Mar 10 '16