-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Check if ROS services and nodes are available when perform any flying commands #21
Comments
TODO in flight task manager |
Should work, probably needs testing |
Needs to be fully tested |
Fixed here b17607e, but I still get exceptions from animation lib, when perform flying functions. |
Add lock to get_telemetry function, now there are no service exceptions. But for now, we don't check the copter state from the client's side, only lock some actions in the server GUI. We need to think about checking the copter state on each client independently before flying. |
I think we need to add task "preflight check" to client's task manager before each flight. |
Also, we need to check the nodes, which are used at current time for positioning:
|
So we need the way to get the type(s) of positioning and check corresponding nodes. These nodes can crash, but /get_telemetry will output working-like result, so we need to know if our positioning nodes were crashed. |
This functionality is added to failsafe module |
When ROS services are not available (when restart clever.service for example), the client emits this exception:
Starting takeoff!
Traceback (most recent call last):
File "client.py", line 297, in
play_animation.takeoff(safe_takeoff=SAFE_TAKEOFF)
File "/home/pi/CleverSwarm/Drone/play_animation.py", line 18, in takeoff
FlightLib.takeoff(z=z, wait=True, emergency_land=False)
File "/home/pi/CleverSwarm/Drone/FlightLib/FlightLib.py", line 243, in takeoff
set_rates(thrust=0.1, auto_arm=True)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/rospy/impl/tcpros_service.py", line 435, in call
return self.call(*args, **kwds)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/rospy/impl/tcpros_service.py", line 505, in call
raise ServiceException("unable to connect to service: %s"%e)
rospy.service.ServiceException: unable to connect to service: [Errno 111] Connection refused
Segmentation fault
The text was updated successfully, but these errors were encountered: