Ping Pong Ball Project Idea: See any problems?

All discussions related to the Loco Positioning system
Post Reply
jwells
Beginner
Posts: 2
Joined: Thu Jan 04, 2018 8:58 pm

Ping Pong Ball Project Idea: See any problems?

Post by jwells »

I have a project idea that I want to work on with my son. It would be a great teaching tool.

I want to drop a ping pong ball from the Crazyflie onto a target utilizing the LPS as a positioning guide. I envision flying the quadcopter to any point with a hand controller, then hitting a button. The system then calculates where it needs to autonomously fly to release the ball. It's a bomber.

For any xyz point, the only thing that matters is the horizontal release velocity (assume no vertical component of velocity at this time). Calculating this value is a common numerical integration problem. No problem there.

I can design and build a lightweight release mechanism to attach to an expansion deck. The ball can be slung under the drone. I don't think it would mess up the CG or flight characteristics much (maybe I'm wrong?) My first question is how to activate the release. Does the crazyflie have something equivalent to an Arduino where I can drive a pin high (+5v)?

The second question is how to control the flight path. I assume I can write a program on the client side that sends positional data to the crazyflie. Right? If I can guide it's path with respect to time, then I can make it have the correct velocity at the xyzt point for release.

I'm an engineer, and an amateur coder, but definitely not a professional programmer. It seems that the people experimenting with crazyflie are real experts. Is this something that I can expect to accomplish? I'm ok spending the money for the complete LPS, but I'd like some hint that this is physically possible.

What do you guys think?
tobias
Bitcraze
Posts: 2339
Joined: Mon Jan 28, 2013 7:17 pm
Location: Sweden

Re: Ping Pong Ball Project Idea: See any problems?

Post by tobias »

Welcome to the forum and a great idea!

I see two potential problems.
  1. Will the position accuracy be enough to drop the ball at the right place. Could be handled with increased target size.
  2. How much will the propeller air flow effect the ping pong ball trajectory. Needs to be tested I guess.
As for the other concerns they shouldn't be to complicated. There is a deck api were you can set pin outputs pretty easily. Sending set-points can be more or less complicated depending on the level of control that is needed. Have a look at this python example for an idea how to send xyz setpoints.

Last x-mas we did a x-mas video were we released a x-mas tree ball (unfortunately the code was never published but we can probably dig it up if needed :oops: )
jwells
Beginner
Posts: 2
Joined: Thu Jan 04, 2018 8:58 pm

Re: Ping Pong Ball Project Idea: See any problems?

Post by jwells »

Thanks Tobias!

I think working out the precision and the effect of air turbulence will be the fun part. Through experimentation, it should be possible to work out the circular error probability based on the proximity to the target. So if you want a 75% chance of a hit, you need to either be a certain distance away from the target, or the target needs to be of a certain size. It may be necessary to momentarily stop the rotors to give the ping pong ball a clean release.

There are a lot of extra possibilities if the basic concept works. The drone could pull up before release to create a lob shot, or it could dive to the target. If the position control is good enough, it might even be possible to calculate a bounce shot off of the floor.

I appreciate you confirming the basic feasibility of the idea. I'm looking forward to working on it.
tobias
Bitcraze
Posts: 2339
Joined: Mon Jan 28, 2013 7:17 pm
Location: Sweden

Re: Ping Pong Ball Project Idea: See any problems?

Post by tobias »

If you carry on keep us posted!
Post Reply