Skip to content

Commit c4ea9ac

Browse files
fengqikai1414quning18
authored andcommitted
platform: add more packages
* pcl_conversions * pcl_msgs * perception_pcl * pcl_ros
1 parent 3f7e4b5 commit c4ea9ac

File tree

161 files changed

+14937
-289
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

161 files changed

+14937
-289
lines changed

ros/dynamic_reconfigure/.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
*.pyc
2+
build/

ros/dynamic_reconfigure/.hgignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.pyc

ros/dynamic_reconfigure/.tar

Lines changed: 0 additions & 2 deletions
This file was deleted.

ros/dynamic_reconfigure/cmake/dynamic_reconfigure-macros.cmake

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,19 +13,19 @@ macro(generate_dynamic_reconfigure_options)
1313
if(NOT IS_ABSOLUTE ${_input})
1414
set(_input ${PROJECT_SOURCE_DIR}/${_input})
1515
endif()
16-
16+
1717
# The .cfg file is its own generator.
18-
set(gencfg_build_files
18+
set(gencfg_build_files
1919
${dynamic_reconfigure_BASE_DIR}/templates/ConfigType.py.template
2020
${dynamic_reconfigure_BASE_DIR}/templates/ConfigType.h.template
21-
)
21+
)
2222

2323
get_filename_component(_cfgonly ${_cfg} NAME_WE)
2424
set(_output_cpp ${CATKIN_DEVEL_PREFIX}/${CATKIN_PACKAGE_INCLUDE_DESTINATION}/${_cfgonly}Config.h)
2525
set(_output_py ${CATKIN_DEVEL_PREFIX}/${CATKIN_PACKAGE_PYTHON_DESTINATION}/cfg/${_cfgonly}Config.py)
2626
set(_output_dox ${CATKIN_DEVEL_PREFIX}/${CATKIN_PACKAGE_SHARE_DESTINATION}/docs/${_cfgonly}Config.dox)
2727
set(_output_wikidoc ${CATKIN_DEVEL_PREFIX}/${CATKIN_PACKAGE_SHARE_DESTINATION}/docs/${_cfgonly}Config.wikidoc)
28-
set(_output_usage ${CATKIN_DEVEL_PREFIX}/${CATKIN_PACKAGE_SHARE_DESTINATION}/docs/${_cfgonly}Config-usage.dox)
28+
set(_output_usage ${CATKIN_DEVEL_PREFIX}/${CATKIN_PACKAGE_SHARE_DESTINATION}/docs/${_cfgonly}Config-usage.dox)
2929

3030
# we need to explicitly add the devel space to the PYTHONPATH
3131
# since it might contain dynamic_reconfigure or Python code of the current package
@@ -54,7 +54,7 @@ macro(generate_dynamic_reconfigure_options)
5454

5555
add_custom_command(OUTPUT
5656
${_output_cpp} ${_output_dox} ${_output_usage} ${_output_py} ${_output_wikidoc}
57-
COMMAND ${_cmd}
57+
COMMAND ${_cmd}
5858
DEPENDS ${_input} ${gencfg_build_files}
5959
COMMENT "Generating dynamic reconfigure files from ${_cfg}: ${_output_cpp} ${_output_py}"
6060
)

ros/dynamic_reconfigure/cmake/dynamic_reconfigure/parameter_generator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
class ParameterGenerator():
4040
@staticmethod
4141
def dummy(*params, **nparams):
42-
return
42+
return
4343

4444
def __getattr__(self, name):
4545
return self.dummy

ros/dynamic_reconfigure/cmake/setup_custom_pythonpath.sh.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#!/usr/bin/env sh
12
# generated from dynamic_reconfigure/cmake/setup_custom_pythonpath.sh.in
23

34
PYTHONPATH=@CATKIN_DEVEL_PREFIX@/@CATKIN_GLOBAL_PYTHON_DESTINATION@:$PYTHONPATH

ros/dynamic_reconfigure/include/dynamic_reconfigure/config_tools.h

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,42 +16,42 @@ class ConfigTools
1616
{
1717
return set.bools;
1818
}
19-
19+
2020
static std::vector<dynamic_reconfigure::IntParameter> &getVectorForType(dynamic_reconfigure::Config &set, const int /*val*/)
2121
{
2222
return set.ints;
2323
}
24-
24+
2525
static std::vector<dynamic_reconfigure::StrParameter> &getVectorForType(dynamic_reconfigure::Config &set, const std::string& /*val*/)
2626
{
2727
return set.strs;
2828
}
29-
29+
3030
static std::vector<dynamic_reconfigure::DoubleParameter> &getVectorForType(dynamic_reconfigure::Config &set, const double /*val*/)
3131
{
3232
return set.doubles;
3333
}
34-
34+
3535
static const std::vector<dynamic_reconfigure::BoolParameter> &getVectorForType(const dynamic_reconfigure::Config &set, const bool /*val*/)
3636
{
3737
return set.bools;
3838
}
39-
39+
4040
static const std::vector<dynamic_reconfigure::IntParameter> &getVectorForType(const dynamic_reconfigure::Config &set, const int /*val*/)
4141
{
4242
return set.ints;
4343
}
44-
44+
4545
static const std::vector<dynamic_reconfigure::StrParameter> &getVectorForType(const dynamic_reconfigure::Config &set, const std::string& /*val*/)
4646
{
4747
return set.strs;
4848
}
49-
49+
5050
static const std::vector<dynamic_reconfigure::DoubleParameter> &getVectorForType(const dynamic_reconfigure::Config &set, const double /*val*/)
5151
{
5252
return set.doubles;
5353
}
54-
54+
5555
static dynamic_reconfigure::BoolParameter makeKeyValuePair(const std::string &name, const bool val)
5656
{
5757
dynamic_reconfigure::BoolParameter param;
@@ -109,7 +109,7 @@ class ConfigTools
109109
}
110110

111111
template<class T>
112-
static void appendGroup(dynamic_reconfigure::Config &set, const std::string &name, int id, int parent, const T &val)
112+
static void appendGroup(dynamic_reconfigure::Config &set, const std::string &name, int id, int parent, const T &val)
113113
{
114114
dynamic_reconfigure::GroupState msg;
115115
msg.name = name;

ros/dynamic_reconfigure/include/dynamic_reconfigure/server.h

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
3838
Author: Blaise Gassend
3939
40-
Handles synchronizing node state with the configuration server, and
40+
Handles synchronizing node state with the configuration server, and
4141
handling of services to get and set configuration.
4242
4343
*/
@@ -60,7 +60,7 @@ namespace dynamic_reconfigure
6060
/**
6161
* Keeps track of the reconfigure callback function.
6262
*/
63-
template <class ConfigType>
63+
template <class ConfigType>
6464
class Server
6565
{
6666
public:
@@ -81,7 +81,7 @@ class Server
8181
}
8282

8383
typedef boost::function<void(ConfigType &, uint32_t level)> CallbackType;
84-
84+
8585
void setCallback(const CallbackType &callback)
8686
{
8787
boost::recursive_mutex::scoped_lock lock(mutex_);
@@ -181,10 +181,10 @@ class Server
181181
boost::recursive_mutex::scoped_lock lock(mutex_);
182182
set_service_ = node_handle_.advertiseService("set_parameters",
183183
&Server<ConfigType>::setConfigCallback, this);
184-
184+
185185
descr_pub_ = node_handle_.advertise<dynamic_reconfigure::ConfigDescription>("parameter_descriptions", 1, true);
186186
descr_pub_.publish(ConfigType::__getDescriptionMessage__());
187-
187+
188188
update_pub_ = node_handle_.advertise<dynamic_reconfigure::Config>("parameter_updates", 1, true);
189189
ConfigType init_config = ConfigType::__getDefault__();
190190
init_config.__fromServer__(node_handle_);
@@ -210,7 +210,7 @@ class Server
210210
ROS_DEBUG("setCallback did not call callback because it was zero."); /// @todo kill this line.
211211
}
212212

213-
bool setConfigCallback(dynamic_reconfigure::Reconfigure::Request &req,
213+
bool setConfigCallback(dynamic_reconfigure::Reconfigure::Request &req,
214214
dynamic_reconfigure::Reconfigure::Response &rsp)
215215
{
216216
boost::recursive_mutex::scoped_lock lock(mutex_);
@@ -219,14 +219,14 @@ class Server
219219
new_config.__fromMessage__(req.config);
220220
new_config.__clamp__();
221221
uint32_t level = config_.__level__(new_config);
222-
222+
223223
callCallback(new_config, level);
224224

225225
updateConfigInternal(new_config);
226226
new_config.__toMessage__(rsp.config);
227227
return true;
228228
}
229-
229+
230230
void updateConfigInternal(const ConfigType &config)
231231
{
232232
boost::recursive_mutex::scoped_lock lock(mutex_);

ros/dynamic_reconfigure/package.xml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
<package>
1+
<?xml version="1.0"?>
2+
<?xml-model href="http://download.ros.org/schema/package_format2.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
3+
<package format="2">
24
<name>dynamic_reconfigure</name>
35
<version>1.5.48</version>
46
<description>
@@ -19,18 +21,16 @@
1921

2022
<buildtool_depend version_gte="0.5.87">catkin</buildtool_depend>
2123

22-
<build_depend>boost</build_depend>
2324
<build_depend>message_generation</build_depend>
24-
<build_depend>roscpp</build_depend>
2525
<build_depend>roscpp_serialization</build_depend>
2626
<build_depend>rostest</build_depend>
27-
<build_depend>std_msgs</build_depend>
2827

29-
<run_depend>boost</run_depend>
30-
<run_depend>message_runtime</run_depend>
31-
<run_depend>roscpp</run_depend>
32-
<run_depend>roslib</run_depend>
33-
<run_depend>rospy</run_depend>
34-
<run_depend>rosservice</run_depend>
35-
<run_depend>std_msgs</run_depend>
28+
<depend>boost</depend>
29+
<depend>roscpp</depend>
30+
<depend>std_msgs</depend>
31+
32+
<exec_depend>message_runtime</exec_depend>
33+
<exec_depend>roslib</exec_depend>
34+
<exec_depend>rospy</exec_depend>
35+
<exec_depend>rosservice</exec_depend>
3636
</package>

ros/dynamic_reconfigure/scripts/dynparam

Lines changed: 19 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,12 @@
3333
# POSSIBILITY OF SUCH DAMAGE.
3434
#
3535
# Revision $Id$
36+
from __future__ import print_function
3637

3738
NAME='dynparam'
3839
import roslib; roslib.load_manifest('dynamic_reconfigure')
3940
import rospy
40-
import optparse
41+
import optparse
4142
import sys
4243
import yaml
4344
import dynamic_reconfigure.client
@@ -46,11 +47,11 @@ def do_list():
4647
connect()
4748
list = dynamic_reconfigure.find_reconfigure_services()
4849
for s in list:
49-
print s
50+
print(s)
5051

5152
def do_set_from_parameters():
5253
usage = """Usage: %prog set_from_parameters [options] node
53-
54+
5455
Example command line:
5556
dynparam set_from_parameters wge100_camera _camera_url:=foo
5657
@@ -77,7 +78,7 @@ Example launch file:
7778
except KeyError:
7879
print >> sys.stderr, 'error updating parameters: no parameters found on parameter server'
7980
return
80-
81+
8182
set_params(node, params, timeout=options.timeout)
8283

8384
def do_set():
@@ -120,13 +121,13 @@ Examples:
120121
try:
121122
set_params(node, values_dict, timeout=options.timeout)
122123
except rospy.service.ServiceException:
123-
print 'couldn\'t set parameters at node %s' % node
124+
print('couldn\'t set parameters at node %s' % node)
124125
except rospy.exceptions.ROSException:
125-
print 'couldn\'t set parameters at node %s' % node
126+
print('couldn\'t set parameters at node %s' % node)
126127

127128
def do_get():
128129
usage = "Usage: %prog get [options] node"
129-
130+
130131
parser = optparse.OptionParser(usage=usage, prog=NAME)
131132
add_timeout_option(parser)
132133
options, args = parser.parse_args(myargv[2:])
@@ -139,11 +140,11 @@ def do_get():
139140
connect()
140141
params = get_params(node, timeout=options.timeout)
141142
if params is not None:
142-
print params
143+
print(params)
143144

144145
def do_load():
145146
usage = "Usage: %prog load [options] node file"
146-
147+
147148
parser = optparse.OptionParser(usage=usage, prog=NAME)
148149
add_timeout_option(parser)
149150
options, args = parser.parse_args(myargv[2:])
@@ -168,7 +169,7 @@ def do_load():
168169

169170
def do_dump():
170171
usage = "Usage: %prog dump [options] node file"
171-
172+
172173
parser = optparse.OptionParser(usage=usage, prog=NAME)
173174
add_timeout_option(parser)
174175
options, args = parser.parse_args(myargv[2:])
@@ -179,7 +180,7 @@ def do_dump():
179180
elif len(args) > 2:
180181
parser.error("too many arguments")
181182
node, path = args[0], args[1]
182-
183+
183184
connect()
184185
params = get_params(node, timeout=options.timeout)
185186
if params is not None:
@@ -190,7 +191,7 @@ def do_dump():
190191
finally:
191192
f.close()
192193

193-
print "couldn't get parameters from node %s" % node
194+
print("couldn't get parameters from node %s" % node)
194195

195196
def get_params(node, timeout=None):
196197
client = dynamic_reconfigure.client.Client(node, timeout=timeout)
@@ -200,14 +201,14 @@ def set_params(node, params, timeout=None):
200201
client = dynamic_reconfigure.client.Client(node, timeout=timeout)
201202
try:
202203
client.update_configuration(params)
203-
except dynamic_reconfigure.DynamicReconfigureParameterException, e:
204-
print 'error updating parameters: ' + str(e)
204+
except dynamic_reconfigure.DynamicReconfigureParameterException as e:
205+
print('error updating parameters: ' + str(e))
205206

206207
def add_timeout_option(parser):
207-
parser.add_option('-t', '--timeout', action='store', type='float', default=None, help='timeout in secs')
208+
parser.add_option('-t', '--timeout', action='store', type='float', default=None, help='timeout in secs')
208209

209210
def print_usage():
210-
print """dynparam is a command-line tool for getting, setting, and
211+
print("""dynparam is a command-line tool for getting, setting, and
211212
deleting parameters of a dynamically configurable node.
212213
213214
Commands:
@@ -219,7 +220,7 @@ Commands:
219220
\tdynparam list list configurable nodes
220221
221222
Type dynparam <command> -h for more detailed usage, e.g. 'dynparam get -h'
222-
"""
223+
""")
223224
sys.exit(1)
224225

225226
def connect():
@@ -230,7 +231,7 @@ if __name__ == '__main__':
230231
if len(myargv) == 1:
231232
print_usage()
232233
else:
233-
cmd = myargv[1]
234+
cmd = myargv[1]
234235
try:
235236
if cmd == 'list': do_list()
236237
elif cmd == 'set_from_parameters': do_set_from_parameters()

ros/dynamic_reconfigure/scripts/reconfigure_gui

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,9 @@
3232
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
3333
# POSSIBILITY OF SUCH DAMAGE.
3434
#
35+
from __future__ import print_function
3536

3637
if __name__ == '__main__':
37-
print '\033[91m' + "reconfigure_gui has moved!\n" + '\033[0m'
38-
print " Try: " + '\033[92m' + "rosrun rqt_reconfigure rqt_reconfigure\n" + '\033[0m'
39-
print " If you see this as part of a tutorial or a script, please update to reflect this change."
38+
print('\033[91m' + "reconfigure_gui has moved!\n" + '\033[0m')
39+
print(" Try: " + '\033[92m' + "rosrun rqt_reconfigure rqt_reconfigure\n" + '\033[0m')
40+
print(" If you see this as part of a tutorial or a script, please update to reflect this change.")

ros/dynamic_reconfigure/src/dynamic_reconfigure/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
# POSSIBILITY OF SUCH DAMAGE.
3232

3333
"""
34-
Python client API for dynamic_reconfigure (L{Client}) as well as
34+
Python client API for dynamic_reconfigure (L{Client}) as well as
3535
example server implementation (L{Server}).
3636
"""
3737

@@ -56,7 +56,7 @@ class DynamicReconfigureCallbackException(DynamicReconfigureException):
5656

5757
def find_reconfigure_services():
5858
import rosservice
59-
return sorted([s[:-len('/set_parameters')] for s in rosservice.get_service_list() if s.endswith('/set_parameters')])
59+
return sorted([s[:-len('/set_parameters')] for s in rosservice.get_service_list() if s.endswith('/set_parameters')])
6060

6161
def get_parameter_names(descr):
6262
return descr.defaults.keys()

0 commit comments

Comments
 (0)