osrf / uctf

Unmanned Capture the Flag (U-CTF) project.
Apache License 2.0
24 stars 10 forks source link

set_mode custom_mode can take mode name, no reason for numeric repr #34

Open vooon opened 8 years ago

vooon commented 8 years ago

https://github.com/osrf/uctf/blob/master/src/uctf/control.py#L210

I think it more intuitive to write:

    req.custom_mode = 'AUTO.MISSION'

http://wiki.ros.org/mavros/CustomModes

And:

    try:
        service = rospy.ServiceProxy(service_name, SetMode)
        resp = service(base_mode=0, custom_mode='AUTO.MISSION')
    except rospy.ServiceException as e:
dirk-thomas commented 8 years ago

Thank you for the suggestion. The file control.py is only a test and will soon be removed.