In my master thesis I develop a quadcopter which has two modes of movement:
- Flying
- Rolling on the Ground
Here is a rendered image of the prototype, but it already exists in the real world. It runs with a PXFmini on a 250 frame and surrounded by a fiberglass structure.
Mode 1 is easy – it is the primary task of ArduCopter and the prototype flies without problems (currently in stabilize, but one of the next tasks is to use OptiTrack for indoor positioning).
But mode 2 – rolling on the ground – is more difficult than I expected. Which makes sense, because the code is developed to keep the copter in the air as best as possible.
My problem is: How can I control roll and pitch on the ground? The idea is to spin only one or two motors. ACRO mode is similar to what I need, but without throttle and various compensations.
I spent some days analyzing the code (Copter-3.4 branch). It looks like there is only a single path that can be changed easily: foobar_run()
in the mode controller calls input_rate_foobar()
and set_throttle_out()
in the attitude controller. The task would be to create new code in the attitude controller which sets all global variables that are used in rate_controller_run()
(called in the fast loop) and output()
of the motors library (called via motors.cpp::motors_output()
also in the fast loop).
But the flows/paths of roll/pitch/yaw and throttle are quite complex (partially in the attitude library, partially in the motors library and partially in different ArduCopter files). And the biggest problem with the current implementation: If throttle is zero, no motor will spin. If throttle is greater than zero, all motors will spin (because in many places calculations use a multiplication with throttle_in
). I thought about changing something in the throttle_{rpy,thr}_mix
values, but I think that this won’t be enough.
Maybe someone of you has an idea how to control roll/pitch without actually flying.
As a new member I’m not able to create a new topic in the development section, so I hope that also here are some developers.