Ask Your Question
0

How to specify default arguments in a Service or Action

asked 2016-05-03 21:33:59 -0500

Cerin gravatar image

Is it possible to define default arguments in a Service or Action message? I want to expose several options in services and actions, but it seems by default, ROS makes all fields required. How do you specify defaults?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2016-05-04 00:50:27 -0500

ahendrix gravatar image

The ROS message, service and action formats do not allow you to specify defaults for any of the fields.

It may be better to expose several services, or you may want to write a C++ or python wrapper class around the service or actionlib client that provides the defaults.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2016-05-03 21:33:59 -0500

Seen: 213 times

Last updated: May 04 '16