Skip to content
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

Automatically disarm after N seconds without flying #1441

Merged
merged 5 commits into from
Dec 9, 2024

Conversation

gemenerik
Copy link
Member

@gemenerik gemenerik commented Dec 5, 2024

This PR introduces automatic disarming of the Crazyflie if no flight is started within 30 seconds after arming. This time-out is configurable. Implementation largely identical to post-flight auto-disarming.

Since we currently print to console when ready to fly and when disarming, this introduces "spam" to the console when using auto-arming. Considering removing these printouts.

Possible discussion points:

  • Trigger disarm after how many seconds?
  • Removing disarming and ready to fly debug prints.

Copy link
Member

@ataffanel ataffanel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The change looks good to me. 30s might be a good time to start with.

About the spamming: what about not printing arming states only when auto-arming is enabled. We can just write in the console that auto-arming is enabled and nothing else.

Otherwise this looks good to merge to me!

Crashed and locked are already covered with other prints, so the only case this uniquely covers is being tumbled (CF lingo for upside down). This should be obvious to the user and requires nothing other than putting the Crazyflie upright.
@gemenerik gemenerik merged commit 9c9e7e0 into master Dec 9, 2024
25 checks passed
@gemenerik gemenerik deleted the rik/auto_disarm branch December 9, 2024 10:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants