convert_ell_params.py
Go to the documentation of this file.
00001 #!/usr/bin/python
00002 
00003 import sys
00004 
00005 import roslib
00006 roslib.load_manifest("hrl_ellipsoidal_control")
00007 import rosbag
00008 
00009 from hrl_ellipsoidal_control.msg import EllipsoidParams
00010 
00011 def main():
00012     old_bag = rosbag.Bag(sys.argv[1], 'r')
00013     for topic, msg, ts in old_bag.read_messages():
00014         old_topic = topic
00015         old_ep = msg
00016     old_bag.close()
00017     new_ep = EllipsoidParams()
00018     new_ep.e_frame = old_ep.e_frame
00019     new_ep.height = old_ep.height
00020     new_ep.E = old_ep.E
00021     new_ep.is_oblate = False
00022     new_bag = rosbag.Bag(sys.argv[1], 'w')
00023     new_bag.write(old_topic, new_ep)
00024     new_bag.close()
00025 
00026 if __name__ == "__main__":
00027     main()


hrl_ellipsoidal_control
Author(s): Kelsey Hawkins
autogenerated on Wed Nov 27 2013 11:41:49