aTao wrote:Going to have to disagree with recurry on the RPi's control abilities here.
Sure, if you bit-bash a GPIO pin then you will suffer from using a non real time OS (although RISC does quite well here, and then there is always your own OS option). But that would be a daft approach. Some GPIO pins on the RPi have hardware PWM capabilities and there is a library to provide fast, reliable PWM on all GPIOs.
So, how fast is the RPi? Using Java on Raspbian with no overclocking I have bit-bashed a GPIO at 3MHz, C++ has got 7MHz. Having taken the PWM timing away from the CPU you then have bags of time and response to control the motors faster than they could respond anyway.
As for payload weight, well that depends on your 'copter.
The points you make don't really disagree with me - they actually support points that I made about performance/speed and weight. You seemed to have missed the points about "latency" and "determinism" though. It's not about how fast you can toggle an I/O or whether you can generate PWM. It's about whether you can guarantee that you'll always be able to respond to events in a deterministic fashion with sufficiently low event->response latency. As I stated the RPI is PLENTY fast enough and has probably 10x the compute power needed but it's I/O's aren't designed for that and standard Linux isn't either. There are versions of Linux that have been optimized for real-time applications that you could use perhaps.
Having built probably 20+ multi-copters personally on as many controller designs as well as having been part of the dev team for the Arducopter I can tell you there is much more to having a multi-copter flying than just speed and compute performance. Just getting something off the ground and hovering in calm air for more than a few secondes is an accomplishment in itself but it's not the same as having a stable, useful platform that can actually maneuver reliably without crashing in reasonable, real-world conditions.
As far as weight, you said the same thing I did which is the multi-copter will need to be large enough to be able to carry the weight of a RPI and alls the other stuff you have to add to it to make it a multi-copter controller.
Hey, one can experiment and try anything one wishes and likely even get an RPI based multi-copter off the ground for a short period of time. You'd definitely have a shot at it if you can find a way to make your control loops absolutely the highest priority task such that they are reliably deterministic and the latency between sensor change event and system response are short enough. I don't know how you do that using Linux without a substantially modified kernel. It might be fun to try if you wish but trying to claim the RPI is well-suited for multi-copter applications just denies the technical facts.
One approach might be to buy one of the Arduino plates and run the control loops on that with the RPI providing the other functions but it's way overly complex and over-kill.
Anyway, if you want to disagree credibly you need to address the determinism and latency issues because it's not an I/O or processor speed issue at all.
Good luck though and post a video when you get it working!
Cheers...