roslaunch.py
Go to the documentation of this file.
00001 #!/usr/bin/env python
00002 
00003 import subprocess
00004 
00005 def start_roslaunch_process(package, binary, args=None, log=None):
00006     if args == None:
00007         args = {}
00008     command_args = ['roslaunch', package, binary]
00009     command_args.extend([key + ':=' + value for key, value in args.iteritems()])
00010     command_args.append('--screen')
00011     print "Running command: " + ' '.join(command_args)
00012     return (subprocess.Popen(command_args, stdout=log, stderr=subprocess.STDOUT)
00013             if log != None else subprocess.Popen(command_args))
00014 
00015 def stop_roslaunch_process(process):
00016     process.terminate()


bwi_tools
Author(s): Piyush Khandelwal
autogenerated on Fri Aug 28 2015 10:14:30