vortexntnu / rov-control

Complete control system for Vortex' ROV
13 stars 9 forks source link

Should allocator keep publishing if the messages doesn't change? #48

Closed mortenfyhn closed 6 years ago

mortenfyhn commented 6 years ago

If the allocator receives multiple identical rov_forces messages in a row, it currently only publishes thruster_forces only for the first of the identical messages.

See https://github.com/vortexntnu/rov-control/blob/32ac0de16fb7b2aa430bf051ce8a843192619a7d/vortex_allocator/src/allocator_ros.cpp#L81

I don't think this is the desired behaviour. It was probably done at some point for performance reasons, but I suggest removing this feature so that one message in always causes one message out.

Actually I think the reason was that out manipulator code was very CPU heavy, and we usually used the manipulators only when not using the thrusters, so this feature would avoid taking resources away from the manipulators.

sindrehan commented 6 years ago

This makes sense for safety reasons as well, currently if the stop message is dropped then the thrusters will keep running.

mortenfyhn commented 6 years ago

Exactly.