mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-23 00:04:02 -04:00
SITL: added plane-3d for aerobatic plane
This commit is contained in:
parent
d04f4d8178
commit
256addc0f0
@ -82,6 +82,11 @@ Plane::Plane(const char *frame_str) :
|
||||
thrust_scale *= 1.5;
|
||||
}
|
||||
|
||||
if (strstr(frame_str, "-3d")) {
|
||||
aerobatic = true;
|
||||
thrust_scale *= 1.5;
|
||||
}
|
||||
|
||||
if (strstr(frame_str, "-ice")) {
|
||||
ice_engine = true;
|
||||
}
|
||||
@ -142,7 +147,7 @@ Vector3f Plane::getTorque(float inputAileron, float inputElevator, float inputRu
|
||||
//calculate aerodynamic torque
|
||||
float effective_airspeed = airspeed;
|
||||
|
||||
if (tailsitter) {
|
||||
if (tailsitter || aerobatic) {
|
||||
/*
|
||||
tailsitters get airspeed from prop-wash
|
||||
*/
|
||||
@ -321,7 +326,7 @@ void Plane::calculate_forces(const struct sitl_input &input, Vector3f &rot_accel
|
||||
angle_of_attack = atan2f(velocity_air_bf.z, velocity_air_bf.x);
|
||||
beta = atan2f(velocity_air_bf.y,velocity_air_bf.x);
|
||||
|
||||
if (tailsitter) {
|
||||
if (tailsitter || aerobatic) {
|
||||
/*
|
||||
tailsitters get 4x the control surfaces
|
||||
*/
|
||||
|
@ -99,6 +99,7 @@ protected:
|
||||
bool reverse_elevator_rudder;
|
||||
bool ice_engine;
|
||||
bool tailsitter;
|
||||
bool aerobatic;
|
||||
bool copter_tailsitter;
|
||||
bool have_launcher;
|
||||
float launch_accel;
|
||||
|
Loading…
Reference in New Issue
Block a user