Skip to content

Commit

Permalink
Merge pull request #413 from bitcraze/krichardsson/stop
Browse files Browse the repository at this point in the history
Call send_notify_setpoint_stop()
  • Loading branch information
tobbeanton committed Aug 29, 2023
2 parents a6c7045 + 4457306 commit f173601
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 0 deletions.
3 changes: 3 additions & 0 deletions examples/autonomy/autonomousSequence.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,9 @@ def run_sequence(scf, sequence):
time.sleep(0.1)

cf.commander.send_stop_setpoint()
# Hand control over to the high level commander to avoid timeout and locking of the Crazyflie
cf.commander.send_notify_setpoint_stop()

# Make sure that the last packet leaves before the link is closed
# since the message queue is not flushed before closing
time.sleep(0.1)
Expand Down
2 changes: 2 additions & 0 deletions examples/positioning/flowsequenceSync.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,3 +79,5 @@
time.sleep(0.1)

cf.commander.send_stop_setpoint()
# Hand control over to the high level commander to avoid timeout and locking of the Crazyflie
cf.commander.send_notify_setpoint_stop()
3 changes: 3 additions & 0 deletions examples/positioning/initial_position.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,9 @@ def run_sequence(scf, sequence, base_x, base_y, base_z, yaw):
time.sleep(0.1)

cf.commander.send_stop_setpoint()
# Hand control over to the high level commander to avoid timeout and locking of the Crazyflie
cf.commander.send_notify_setpoint_stop()

# Make sure that the last packet leaves before the link is closed
# since the message queue is not flushed before closing
time.sleep(0.1)
Expand Down
3 changes: 3 additions & 0 deletions examples/swarm/swarmSequence.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,9 @@ def land(cf, position):
time.sleep(sleep_time)

cf.commander.send_stop_setpoint()
# Hand control over to the high level commander to avoid timeout and locking of the Crazyflie
cf.commander.send_notify_setpoint_stop()

# Make sure that the last packet leaves before the link is closed
# since the message queue is not flushed before closing
time.sleep(0.1)
Expand Down
2 changes: 2 additions & 0 deletions examples/swarm/swarmSequenceCircle.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,8 @@ def run_sequence(scf, params):
poshold(cf, 1, base)

cf.commander.send_stop_setpoint()
# Hand control over to the high level commander to avoid timeout and locking of the Crazyflie
cf.commander.send_notify_setpoint_stop()


if __name__ == '__main__':
Expand Down

0 comments on commit f173601

Please sign in to comment.