1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2024-12-01 09:24:10 +01:00

OP-26 GCS/Stabilization First release of stabilization module. Tested using FlightGear, default tuning is for the HITL simulation. Works fairly well but a number of improvements can be made to aid tuning. The ManualControl settings must be first set as you would normally do for HITL simulation, flight mode is changed using the mode channel.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@886 ebee16cc-31ac-478f-84a7-5cbb03baadba
This commit is contained in:
vassilis 2010-06-25 02:27:42 +00:00 committed by vassilis
parent 9e8c4f26e4
commit d652c853d0
17 changed files with 392 additions and 221 deletions

View File

@ -49,7 +49,6 @@ FlightGearBridge::FlightGearBridge()
telStats = GCSTelemetryStats::GetInstance(objManager); telStats = GCSTelemetryStats::GetInstance(objManager);
// Listen to autopilot connection events // Listen to autopilot connection events
// NOTE: Disabled due to linker errors, when fixed uncomment next three lines and comment out fourth
TelemetryManager* telMngr = pm->getObject<TelemetryManager>(); TelemetryManager* telMngr = pm->getObject<TelemetryManager>();
connect(telMngr, SIGNAL(connected()), this, SLOT(onAutopilotConnect())); connect(telMngr, SIGNAL(connected()), this, SLOT(onAutopilotConnect()));
connect(telMngr, SIGNAL(disconnected()), this, SLOT(onAutopilotDisconnect())); connect(telMngr, SIGNAL(disconnected()), this, SLOT(onAutopilotDisconnect()));
@ -149,9 +148,9 @@ void FlightGearBridge::receiveUpdate()
void FlightGearBridge::setupObjects() void FlightGearBridge::setupObjects()
{ {
setupInputObject(actDesired, 50); setupInputObject(actDesired, 75);
setupOutputObject(altActual, 250); setupOutputObject(altActual, 250);
setupOutputObject(attActual, 50); setupOutputObject(attActual, 75);
setupOutputObject(posActual, 250); setupOutputObject(posActual, 250);
} }

View File

@ -43,6 +43,7 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
QStringList FixedWingRoll1ElemNames; QStringList FixedWingRoll1ElemNames;
FixedWingRoll1ElemNames.append("0"); FixedWingRoll1ElemNames.append("0");
QStringList FixedWingRoll1EnumOptions; QStringList FixedWingRoll1EnumOptions;
FixedWingRoll1EnumOptions.append("Channel0");
FixedWingRoll1EnumOptions.append("Channel1"); FixedWingRoll1EnumOptions.append("Channel1");
FixedWingRoll1EnumOptions.append("Channel2"); FixedWingRoll1EnumOptions.append("Channel2");
FixedWingRoll1EnumOptions.append("Channel3"); FixedWingRoll1EnumOptions.append("Channel3");
@ -50,12 +51,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
FixedWingRoll1EnumOptions.append("Channel5"); FixedWingRoll1EnumOptions.append("Channel5");
FixedWingRoll1EnumOptions.append("Channel6"); FixedWingRoll1EnumOptions.append("Channel6");
FixedWingRoll1EnumOptions.append("Channel7"); FixedWingRoll1EnumOptions.append("Channel7");
FixedWingRoll1EnumOptions.append("Channel8");
FixedWingRoll1EnumOptions.append("None"); FixedWingRoll1EnumOptions.append("None");
fields.append( new UAVObjectField(QString("FixedWingRoll1"), QString("channel"), UAVObjectField::ENUM, FixedWingRoll1ElemNames, FixedWingRoll1EnumOptions) ); fields.append( new UAVObjectField(QString("FixedWingRoll1"), QString("channel"), UAVObjectField::ENUM, FixedWingRoll1ElemNames, FixedWingRoll1EnumOptions) );
QStringList FixedWingRoll2ElemNames; QStringList FixedWingRoll2ElemNames;
FixedWingRoll2ElemNames.append("0"); FixedWingRoll2ElemNames.append("0");
QStringList FixedWingRoll2EnumOptions; QStringList FixedWingRoll2EnumOptions;
FixedWingRoll2EnumOptions.append("Channel0");
FixedWingRoll2EnumOptions.append("Channel1"); FixedWingRoll2EnumOptions.append("Channel1");
FixedWingRoll2EnumOptions.append("Channel2"); FixedWingRoll2EnumOptions.append("Channel2");
FixedWingRoll2EnumOptions.append("Channel3"); FixedWingRoll2EnumOptions.append("Channel3");
@ -63,12 +64,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
FixedWingRoll2EnumOptions.append("Channel5"); FixedWingRoll2EnumOptions.append("Channel5");
FixedWingRoll2EnumOptions.append("Channel6"); FixedWingRoll2EnumOptions.append("Channel6");
FixedWingRoll2EnumOptions.append("Channel7"); FixedWingRoll2EnumOptions.append("Channel7");
FixedWingRoll2EnumOptions.append("Channel8");
FixedWingRoll2EnumOptions.append("None"); FixedWingRoll2EnumOptions.append("None");
fields.append( new UAVObjectField(QString("FixedWingRoll2"), QString("channel"), UAVObjectField::ENUM, FixedWingRoll2ElemNames, FixedWingRoll2EnumOptions) ); fields.append( new UAVObjectField(QString("FixedWingRoll2"), QString("channel"), UAVObjectField::ENUM, FixedWingRoll2ElemNames, FixedWingRoll2EnumOptions) );
QStringList FixedWingPitch1ElemNames; QStringList FixedWingPitch1ElemNames;
FixedWingPitch1ElemNames.append("0"); FixedWingPitch1ElemNames.append("0");
QStringList FixedWingPitch1EnumOptions; QStringList FixedWingPitch1EnumOptions;
FixedWingPitch1EnumOptions.append("Channel0");
FixedWingPitch1EnumOptions.append("Channel1"); FixedWingPitch1EnumOptions.append("Channel1");
FixedWingPitch1EnumOptions.append("Channel2"); FixedWingPitch1EnumOptions.append("Channel2");
FixedWingPitch1EnumOptions.append("Channel3"); FixedWingPitch1EnumOptions.append("Channel3");
@ -76,12 +77,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
FixedWingPitch1EnumOptions.append("Channel5"); FixedWingPitch1EnumOptions.append("Channel5");
FixedWingPitch1EnumOptions.append("Channel6"); FixedWingPitch1EnumOptions.append("Channel6");
FixedWingPitch1EnumOptions.append("Channel7"); FixedWingPitch1EnumOptions.append("Channel7");
FixedWingPitch1EnumOptions.append("Channel8");
FixedWingPitch1EnumOptions.append("None"); FixedWingPitch1EnumOptions.append("None");
fields.append( new UAVObjectField(QString("FixedWingPitch1"), QString("channel"), UAVObjectField::ENUM, FixedWingPitch1ElemNames, FixedWingPitch1EnumOptions) ); fields.append( new UAVObjectField(QString("FixedWingPitch1"), QString("channel"), UAVObjectField::ENUM, FixedWingPitch1ElemNames, FixedWingPitch1EnumOptions) );
QStringList FixedWingPitch2ElemNames; QStringList FixedWingPitch2ElemNames;
FixedWingPitch2ElemNames.append("0"); FixedWingPitch2ElemNames.append("0");
QStringList FixedWingPitch2EnumOptions; QStringList FixedWingPitch2EnumOptions;
FixedWingPitch2EnumOptions.append("Channel0");
FixedWingPitch2EnumOptions.append("Channel1"); FixedWingPitch2EnumOptions.append("Channel1");
FixedWingPitch2EnumOptions.append("Channel2"); FixedWingPitch2EnumOptions.append("Channel2");
FixedWingPitch2EnumOptions.append("Channel3"); FixedWingPitch2EnumOptions.append("Channel3");
@ -89,12 +90,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
FixedWingPitch2EnumOptions.append("Channel5"); FixedWingPitch2EnumOptions.append("Channel5");
FixedWingPitch2EnumOptions.append("Channel6"); FixedWingPitch2EnumOptions.append("Channel6");
FixedWingPitch2EnumOptions.append("Channel7"); FixedWingPitch2EnumOptions.append("Channel7");
FixedWingPitch2EnumOptions.append("Channel8");
FixedWingPitch2EnumOptions.append("None"); FixedWingPitch2EnumOptions.append("None");
fields.append( new UAVObjectField(QString("FixedWingPitch2"), QString("channel"), UAVObjectField::ENUM, FixedWingPitch2ElemNames, FixedWingPitch2EnumOptions) ); fields.append( new UAVObjectField(QString("FixedWingPitch2"), QString("channel"), UAVObjectField::ENUM, FixedWingPitch2ElemNames, FixedWingPitch2EnumOptions) );
QStringList FixedWingYawElemNames; QStringList FixedWingYawElemNames;
FixedWingYawElemNames.append("0"); FixedWingYawElemNames.append("0");
QStringList FixedWingYawEnumOptions; QStringList FixedWingYawEnumOptions;
FixedWingYawEnumOptions.append("Channel0");
FixedWingYawEnumOptions.append("Channel1"); FixedWingYawEnumOptions.append("Channel1");
FixedWingYawEnumOptions.append("Channel2"); FixedWingYawEnumOptions.append("Channel2");
FixedWingYawEnumOptions.append("Channel3"); FixedWingYawEnumOptions.append("Channel3");
@ -102,12 +103,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
FixedWingYawEnumOptions.append("Channel5"); FixedWingYawEnumOptions.append("Channel5");
FixedWingYawEnumOptions.append("Channel6"); FixedWingYawEnumOptions.append("Channel6");
FixedWingYawEnumOptions.append("Channel7"); FixedWingYawEnumOptions.append("Channel7");
FixedWingYawEnumOptions.append("Channel8");
FixedWingYawEnumOptions.append("None"); FixedWingYawEnumOptions.append("None");
fields.append( new UAVObjectField(QString("FixedWingYaw"), QString("channel"), UAVObjectField::ENUM, FixedWingYawElemNames, FixedWingYawEnumOptions) ); fields.append( new UAVObjectField(QString("FixedWingYaw"), QString("channel"), UAVObjectField::ENUM, FixedWingYawElemNames, FixedWingYawEnumOptions) );
QStringList FixedWingThrottleElemNames; QStringList FixedWingThrottleElemNames;
FixedWingThrottleElemNames.append("0"); FixedWingThrottleElemNames.append("0");
QStringList FixedWingThrottleEnumOptions; QStringList FixedWingThrottleEnumOptions;
FixedWingThrottleEnumOptions.append("Channel0");
FixedWingThrottleEnumOptions.append("Channel1"); FixedWingThrottleEnumOptions.append("Channel1");
FixedWingThrottleEnumOptions.append("Channel2"); FixedWingThrottleEnumOptions.append("Channel2");
FixedWingThrottleEnumOptions.append("Channel3"); FixedWingThrottleEnumOptions.append("Channel3");
@ -115,12 +116,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
FixedWingThrottleEnumOptions.append("Channel5"); FixedWingThrottleEnumOptions.append("Channel5");
FixedWingThrottleEnumOptions.append("Channel6"); FixedWingThrottleEnumOptions.append("Channel6");
FixedWingThrottleEnumOptions.append("Channel7"); FixedWingThrottleEnumOptions.append("Channel7");
FixedWingThrottleEnumOptions.append("Channel8");
FixedWingThrottleEnumOptions.append("None"); FixedWingThrottleEnumOptions.append("None");
fields.append( new UAVObjectField(QString("FixedWingThrottle"), QString("channel"), UAVObjectField::ENUM, FixedWingThrottleElemNames, FixedWingThrottleEnumOptions) ); fields.append( new UAVObjectField(QString("FixedWingThrottle"), QString("channel"), UAVObjectField::ENUM, FixedWingThrottleElemNames, FixedWingThrottleEnumOptions) );
QStringList VTOLMotorNElemNames; QStringList VTOLMotorNElemNames;
VTOLMotorNElemNames.append("0"); VTOLMotorNElemNames.append("0");
QStringList VTOLMotorNEnumOptions; QStringList VTOLMotorNEnumOptions;
VTOLMotorNEnumOptions.append("Channel0");
VTOLMotorNEnumOptions.append("Channel1"); VTOLMotorNEnumOptions.append("Channel1");
VTOLMotorNEnumOptions.append("Channel2"); VTOLMotorNEnumOptions.append("Channel2");
VTOLMotorNEnumOptions.append("Channel3"); VTOLMotorNEnumOptions.append("Channel3");
@ -128,12 +129,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
VTOLMotorNEnumOptions.append("Channel5"); VTOLMotorNEnumOptions.append("Channel5");
VTOLMotorNEnumOptions.append("Channel6"); VTOLMotorNEnumOptions.append("Channel6");
VTOLMotorNEnumOptions.append("Channel7"); VTOLMotorNEnumOptions.append("Channel7");
VTOLMotorNEnumOptions.append("Channel8");
VTOLMotorNEnumOptions.append("None"); VTOLMotorNEnumOptions.append("None");
fields.append( new UAVObjectField(QString("VTOLMotorN"), QString("channel"), UAVObjectField::ENUM, VTOLMotorNElemNames, VTOLMotorNEnumOptions) ); fields.append( new UAVObjectField(QString("VTOLMotorN"), QString("channel"), UAVObjectField::ENUM, VTOLMotorNElemNames, VTOLMotorNEnumOptions) );
QStringList VTOLMotorNEElemNames; QStringList VTOLMotorNEElemNames;
VTOLMotorNEElemNames.append("0"); VTOLMotorNEElemNames.append("0");
QStringList VTOLMotorNEEnumOptions; QStringList VTOLMotorNEEnumOptions;
VTOLMotorNEEnumOptions.append("Channel0");
VTOLMotorNEEnumOptions.append("Channel1"); VTOLMotorNEEnumOptions.append("Channel1");
VTOLMotorNEEnumOptions.append("Channel2"); VTOLMotorNEEnumOptions.append("Channel2");
VTOLMotorNEEnumOptions.append("Channel3"); VTOLMotorNEEnumOptions.append("Channel3");
@ -141,12 +142,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
VTOLMotorNEEnumOptions.append("Channel5"); VTOLMotorNEEnumOptions.append("Channel5");
VTOLMotorNEEnumOptions.append("Channel6"); VTOLMotorNEEnumOptions.append("Channel6");
VTOLMotorNEEnumOptions.append("Channel7"); VTOLMotorNEEnumOptions.append("Channel7");
VTOLMotorNEEnumOptions.append("Channel8");
VTOLMotorNEEnumOptions.append("None"); VTOLMotorNEEnumOptions.append("None");
fields.append( new UAVObjectField(QString("VTOLMotorNE"), QString("channel"), UAVObjectField::ENUM, VTOLMotorNEElemNames, VTOLMotorNEEnumOptions) ); fields.append( new UAVObjectField(QString("VTOLMotorNE"), QString("channel"), UAVObjectField::ENUM, VTOLMotorNEElemNames, VTOLMotorNEEnumOptions) );
QStringList VTOLMotorEElemNames; QStringList VTOLMotorEElemNames;
VTOLMotorEElemNames.append("0"); VTOLMotorEElemNames.append("0");
QStringList VTOLMotorEEnumOptions; QStringList VTOLMotorEEnumOptions;
VTOLMotorEEnumOptions.append("Channel0");
VTOLMotorEEnumOptions.append("Channel1"); VTOLMotorEEnumOptions.append("Channel1");
VTOLMotorEEnumOptions.append("Channel2"); VTOLMotorEEnumOptions.append("Channel2");
VTOLMotorEEnumOptions.append("Channel3"); VTOLMotorEEnumOptions.append("Channel3");
@ -154,12 +155,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
VTOLMotorEEnumOptions.append("Channel5"); VTOLMotorEEnumOptions.append("Channel5");
VTOLMotorEEnumOptions.append("Channel6"); VTOLMotorEEnumOptions.append("Channel6");
VTOLMotorEEnumOptions.append("Channel7"); VTOLMotorEEnumOptions.append("Channel7");
VTOLMotorEEnumOptions.append("Channel8");
VTOLMotorEEnumOptions.append("None"); VTOLMotorEEnumOptions.append("None");
fields.append( new UAVObjectField(QString("VTOLMotorE"), QString("channel"), UAVObjectField::ENUM, VTOLMotorEElemNames, VTOLMotorEEnumOptions) ); fields.append( new UAVObjectField(QString("VTOLMotorE"), QString("channel"), UAVObjectField::ENUM, VTOLMotorEElemNames, VTOLMotorEEnumOptions) );
QStringList VTOLMotorSEElemNames; QStringList VTOLMotorSEElemNames;
VTOLMotorSEElemNames.append("0"); VTOLMotorSEElemNames.append("0");
QStringList VTOLMotorSEEnumOptions; QStringList VTOLMotorSEEnumOptions;
VTOLMotorSEEnumOptions.append("Channel0");
VTOLMotorSEEnumOptions.append("Channel1"); VTOLMotorSEEnumOptions.append("Channel1");
VTOLMotorSEEnumOptions.append("Channel2"); VTOLMotorSEEnumOptions.append("Channel2");
VTOLMotorSEEnumOptions.append("Channel3"); VTOLMotorSEEnumOptions.append("Channel3");
@ -167,12 +168,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
VTOLMotorSEEnumOptions.append("Channel5"); VTOLMotorSEEnumOptions.append("Channel5");
VTOLMotorSEEnumOptions.append("Channel6"); VTOLMotorSEEnumOptions.append("Channel6");
VTOLMotorSEEnumOptions.append("Channel7"); VTOLMotorSEEnumOptions.append("Channel7");
VTOLMotorSEEnumOptions.append("Channel8");
VTOLMotorSEEnumOptions.append("None"); VTOLMotorSEEnumOptions.append("None");
fields.append( new UAVObjectField(QString("VTOLMotorSE"), QString("channel"), UAVObjectField::ENUM, VTOLMotorSEElemNames, VTOLMotorSEEnumOptions) ); fields.append( new UAVObjectField(QString("VTOLMotorSE"), QString("channel"), UAVObjectField::ENUM, VTOLMotorSEElemNames, VTOLMotorSEEnumOptions) );
QStringList VTOLMotorSElemNames; QStringList VTOLMotorSElemNames;
VTOLMotorSElemNames.append("0"); VTOLMotorSElemNames.append("0");
QStringList VTOLMotorSEnumOptions; QStringList VTOLMotorSEnumOptions;
VTOLMotorSEnumOptions.append("Channel0");
VTOLMotorSEnumOptions.append("Channel1"); VTOLMotorSEnumOptions.append("Channel1");
VTOLMotorSEnumOptions.append("Channel2"); VTOLMotorSEnumOptions.append("Channel2");
VTOLMotorSEnumOptions.append("Channel3"); VTOLMotorSEnumOptions.append("Channel3");
@ -180,12 +181,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
VTOLMotorSEnumOptions.append("Channel5"); VTOLMotorSEnumOptions.append("Channel5");
VTOLMotorSEnumOptions.append("Channel6"); VTOLMotorSEnumOptions.append("Channel6");
VTOLMotorSEnumOptions.append("Channel7"); VTOLMotorSEnumOptions.append("Channel7");
VTOLMotorSEnumOptions.append("Channel8");
VTOLMotorSEnumOptions.append("None"); VTOLMotorSEnumOptions.append("None");
fields.append( new UAVObjectField(QString("VTOLMotorS"), QString("channel"), UAVObjectField::ENUM, VTOLMotorSElemNames, VTOLMotorSEnumOptions) ); fields.append( new UAVObjectField(QString("VTOLMotorS"), QString("channel"), UAVObjectField::ENUM, VTOLMotorSElemNames, VTOLMotorSEnumOptions) );
QStringList VTOLMotorSWElemNames; QStringList VTOLMotorSWElemNames;
VTOLMotorSWElemNames.append("0"); VTOLMotorSWElemNames.append("0");
QStringList VTOLMotorSWEnumOptions; QStringList VTOLMotorSWEnumOptions;
VTOLMotorSWEnumOptions.append("Channel0");
VTOLMotorSWEnumOptions.append("Channel1"); VTOLMotorSWEnumOptions.append("Channel1");
VTOLMotorSWEnumOptions.append("Channel2"); VTOLMotorSWEnumOptions.append("Channel2");
VTOLMotorSWEnumOptions.append("Channel3"); VTOLMotorSWEnumOptions.append("Channel3");
@ -193,12 +194,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
VTOLMotorSWEnumOptions.append("Channel5"); VTOLMotorSWEnumOptions.append("Channel5");
VTOLMotorSWEnumOptions.append("Channel6"); VTOLMotorSWEnumOptions.append("Channel6");
VTOLMotorSWEnumOptions.append("Channel7"); VTOLMotorSWEnumOptions.append("Channel7");
VTOLMotorSWEnumOptions.append("Channel8");
VTOLMotorSWEnumOptions.append("None"); VTOLMotorSWEnumOptions.append("None");
fields.append( new UAVObjectField(QString("VTOLMotorSW"), QString("channel"), UAVObjectField::ENUM, VTOLMotorSWElemNames, VTOLMotorSWEnumOptions) ); fields.append( new UAVObjectField(QString("VTOLMotorSW"), QString("channel"), UAVObjectField::ENUM, VTOLMotorSWElemNames, VTOLMotorSWEnumOptions) );
QStringList VTOLMotorWElemNames; QStringList VTOLMotorWElemNames;
VTOLMotorWElemNames.append("0"); VTOLMotorWElemNames.append("0");
QStringList VTOLMotorWEnumOptions; QStringList VTOLMotorWEnumOptions;
VTOLMotorWEnumOptions.append("Channel0");
VTOLMotorWEnumOptions.append("Channel1"); VTOLMotorWEnumOptions.append("Channel1");
VTOLMotorWEnumOptions.append("Channel2"); VTOLMotorWEnumOptions.append("Channel2");
VTOLMotorWEnumOptions.append("Channel3"); VTOLMotorWEnumOptions.append("Channel3");
@ -206,12 +207,12 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
VTOLMotorWEnumOptions.append("Channel5"); VTOLMotorWEnumOptions.append("Channel5");
VTOLMotorWEnumOptions.append("Channel6"); VTOLMotorWEnumOptions.append("Channel6");
VTOLMotorWEnumOptions.append("Channel7"); VTOLMotorWEnumOptions.append("Channel7");
VTOLMotorWEnumOptions.append("Channel8");
VTOLMotorWEnumOptions.append("None"); VTOLMotorWEnumOptions.append("None");
fields.append( new UAVObjectField(QString("VTOLMotorW"), QString("channel"), UAVObjectField::ENUM, VTOLMotorWElemNames, VTOLMotorWEnumOptions) ); fields.append( new UAVObjectField(QString("VTOLMotorW"), QString("channel"), UAVObjectField::ENUM, VTOLMotorWElemNames, VTOLMotorWEnumOptions) );
QStringList VTOLMotorNWElemNames; QStringList VTOLMotorNWElemNames;
VTOLMotorNWElemNames.append("0"); VTOLMotorNWElemNames.append("0");
QStringList VTOLMotorNWEnumOptions; QStringList VTOLMotorNWEnumOptions;
VTOLMotorNWEnumOptions.append("Channel0");
VTOLMotorNWEnumOptions.append("Channel1"); VTOLMotorNWEnumOptions.append("Channel1");
VTOLMotorNWEnumOptions.append("Channel2"); VTOLMotorNWEnumOptions.append("Channel2");
VTOLMotorNWEnumOptions.append("Channel3"); VTOLMotorNWEnumOptions.append("Channel3");
@ -219,7 +220,6 @@ ActuatorSettings::ActuatorSettings(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTI
VTOLMotorNWEnumOptions.append("Channel5"); VTOLMotorNWEnumOptions.append("Channel5");
VTOLMotorNWEnumOptions.append("Channel6"); VTOLMotorNWEnumOptions.append("Channel6");
VTOLMotorNWEnumOptions.append("Channel7"); VTOLMotorNWEnumOptions.append("Channel7");
VTOLMotorNWEnumOptions.append("Channel8");
VTOLMotorNWEnumOptions.append("None"); VTOLMotorNWEnumOptions.append("None");
fields.append( new UAVObjectField(QString("VTOLMotorNW"), QString("channel"), UAVObjectField::ENUM, VTOLMotorNWElemNames, VTOLMotorNWEnumOptions) ); fields.append( new UAVObjectField(QString("VTOLMotorNW"), QString("channel"), UAVObjectField::ENUM, VTOLMotorNWElemNames, VTOLMotorNWEnumOptions) );
QStringList ChannelUpdateFreqElemNames; QStringList ChannelUpdateFreqElemNames;

View File

@ -65,46 +65,46 @@ public:
// Field information // Field information
// Field FixedWingRoll1 information // Field FixedWingRoll1 information
/* Enumeration options for field FixedWingRoll1 */ /* Enumeration options for field FixedWingRoll1 */
typedef enum { FIXEDWINGROLL1_CHANNEL1=0, FIXEDWINGROLL1_CHANNEL2=1, FIXEDWINGROLL1_CHANNEL3=2, FIXEDWINGROLL1_CHANNEL4=3, FIXEDWINGROLL1_CHANNEL5=4, FIXEDWINGROLL1_CHANNEL6=5, FIXEDWINGROLL1_CHANNEL7=6, FIXEDWINGROLL1_CHANNEL8=7, FIXEDWINGROLL1_NONE=8, } FixedWingRoll1Options; typedef enum { FIXEDWINGROLL1_CHANNEL0=0, FIXEDWINGROLL1_CHANNEL1=1, FIXEDWINGROLL1_CHANNEL2=2, FIXEDWINGROLL1_CHANNEL3=3, FIXEDWINGROLL1_CHANNEL4=4, FIXEDWINGROLL1_CHANNEL5=5, FIXEDWINGROLL1_CHANNEL6=6, FIXEDWINGROLL1_CHANNEL7=7, FIXEDWINGROLL1_NONE=8, } FixedWingRoll1Options;
// Field FixedWingRoll2 information // Field FixedWingRoll2 information
/* Enumeration options for field FixedWingRoll2 */ /* Enumeration options for field FixedWingRoll2 */
typedef enum { FIXEDWINGROLL2_CHANNEL1=0, FIXEDWINGROLL2_CHANNEL2=1, FIXEDWINGROLL2_CHANNEL3=2, FIXEDWINGROLL2_CHANNEL4=3, FIXEDWINGROLL2_CHANNEL5=4, FIXEDWINGROLL2_CHANNEL6=5, FIXEDWINGROLL2_CHANNEL7=6, FIXEDWINGROLL2_CHANNEL8=7, FIXEDWINGROLL2_NONE=8, } FixedWingRoll2Options; typedef enum { FIXEDWINGROLL2_CHANNEL0=0, FIXEDWINGROLL2_CHANNEL1=1, FIXEDWINGROLL2_CHANNEL2=2, FIXEDWINGROLL2_CHANNEL3=3, FIXEDWINGROLL2_CHANNEL4=4, FIXEDWINGROLL2_CHANNEL5=5, FIXEDWINGROLL2_CHANNEL6=6, FIXEDWINGROLL2_CHANNEL7=7, FIXEDWINGROLL2_NONE=8, } FixedWingRoll2Options;
// Field FixedWingPitch1 information // Field FixedWingPitch1 information
/* Enumeration options for field FixedWingPitch1 */ /* Enumeration options for field FixedWingPitch1 */
typedef enum { FIXEDWINGPITCH1_CHANNEL1=0, FIXEDWINGPITCH1_CHANNEL2=1, FIXEDWINGPITCH1_CHANNEL3=2, FIXEDWINGPITCH1_CHANNEL4=3, FIXEDWINGPITCH1_CHANNEL5=4, FIXEDWINGPITCH1_CHANNEL6=5, FIXEDWINGPITCH1_CHANNEL7=6, FIXEDWINGPITCH1_CHANNEL8=7, FIXEDWINGPITCH1_NONE=8, } FixedWingPitch1Options; typedef enum { FIXEDWINGPITCH1_CHANNEL0=0, FIXEDWINGPITCH1_CHANNEL1=1, FIXEDWINGPITCH1_CHANNEL2=2, FIXEDWINGPITCH1_CHANNEL3=3, FIXEDWINGPITCH1_CHANNEL4=4, FIXEDWINGPITCH1_CHANNEL5=5, FIXEDWINGPITCH1_CHANNEL6=6, FIXEDWINGPITCH1_CHANNEL7=7, FIXEDWINGPITCH1_NONE=8, } FixedWingPitch1Options;
// Field FixedWingPitch2 information // Field FixedWingPitch2 information
/* Enumeration options for field FixedWingPitch2 */ /* Enumeration options for field FixedWingPitch2 */
typedef enum { FIXEDWINGPITCH2_CHANNEL1=0, FIXEDWINGPITCH2_CHANNEL2=1, FIXEDWINGPITCH2_CHANNEL3=2, FIXEDWINGPITCH2_CHANNEL4=3, FIXEDWINGPITCH2_CHANNEL5=4, FIXEDWINGPITCH2_CHANNEL6=5, FIXEDWINGPITCH2_CHANNEL7=6, FIXEDWINGPITCH2_CHANNEL8=7, FIXEDWINGPITCH2_NONE=8, } FixedWingPitch2Options; typedef enum { FIXEDWINGPITCH2_CHANNEL0=0, FIXEDWINGPITCH2_CHANNEL1=1, FIXEDWINGPITCH2_CHANNEL2=2, FIXEDWINGPITCH2_CHANNEL3=3, FIXEDWINGPITCH2_CHANNEL4=4, FIXEDWINGPITCH2_CHANNEL5=5, FIXEDWINGPITCH2_CHANNEL6=6, FIXEDWINGPITCH2_CHANNEL7=7, FIXEDWINGPITCH2_NONE=8, } FixedWingPitch2Options;
// Field FixedWingYaw information // Field FixedWingYaw information
/* Enumeration options for field FixedWingYaw */ /* Enumeration options for field FixedWingYaw */
typedef enum { FIXEDWINGYAW_CHANNEL1=0, FIXEDWINGYAW_CHANNEL2=1, FIXEDWINGYAW_CHANNEL3=2, FIXEDWINGYAW_CHANNEL4=3, FIXEDWINGYAW_CHANNEL5=4, FIXEDWINGYAW_CHANNEL6=5, FIXEDWINGYAW_CHANNEL7=6, FIXEDWINGYAW_CHANNEL8=7, FIXEDWINGYAW_NONE=8, } FixedWingYawOptions; typedef enum { FIXEDWINGYAW_CHANNEL0=0, FIXEDWINGYAW_CHANNEL1=1, FIXEDWINGYAW_CHANNEL2=2, FIXEDWINGYAW_CHANNEL3=3, FIXEDWINGYAW_CHANNEL4=4, FIXEDWINGYAW_CHANNEL5=5, FIXEDWINGYAW_CHANNEL6=6, FIXEDWINGYAW_CHANNEL7=7, FIXEDWINGYAW_NONE=8, } FixedWingYawOptions;
// Field FixedWingThrottle information // Field FixedWingThrottle information
/* Enumeration options for field FixedWingThrottle */ /* Enumeration options for field FixedWingThrottle */
typedef enum { FIXEDWINGTHROTTLE_CHANNEL1=0, FIXEDWINGTHROTTLE_CHANNEL2=1, FIXEDWINGTHROTTLE_CHANNEL3=2, FIXEDWINGTHROTTLE_CHANNEL4=3, FIXEDWINGTHROTTLE_CHANNEL5=4, FIXEDWINGTHROTTLE_CHANNEL6=5, FIXEDWINGTHROTTLE_CHANNEL7=6, FIXEDWINGTHROTTLE_CHANNEL8=7, FIXEDWINGTHROTTLE_NONE=8, } FixedWingThrottleOptions; typedef enum { FIXEDWINGTHROTTLE_CHANNEL0=0, FIXEDWINGTHROTTLE_CHANNEL1=1, FIXEDWINGTHROTTLE_CHANNEL2=2, FIXEDWINGTHROTTLE_CHANNEL3=3, FIXEDWINGTHROTTLE_CHANNEL4=4, FIXEDWINGTHROTTLE_CHANNEL5=5, FIXEDWINGTHROTTLE_CHANNEL6=6, FIXEDWINGTHROTTLE_CHANNEL7=7, FIXEDWINGTHROTTLE_NONE=8, } FixedWingThrottleOptions;
// Field VTOLMotorN information // Field VTOLMotorN information
/* Enumeration options for field VTOLMotorN */ /* Enumeration options for field VTOLMotorN */
typedef enum { VTOLMOTORN_CHANNEL1=0, VTOLMOTORN_CHANNEL2=1, VTOLMOTORN_CHANNEL3=2, VTOLMOTORN_CHANNEL4=3, VTOLMOTORN_CHANNEL5=4, VTOLMOTORN_CHANNEL6=5, VTOLMOTORN_CHANNEL7=6, VTOLMOTORN_CHANNEL8=7, VTOLMOTORN_NONE=8, } VTOLMotorNOptions; typedef enum { VTOLMOTORN_CHANNEL0=0, VTOLMOTORN_CHANNEL1=1, VTOLMOTORN_CHANNEL2=2, VTOLMOTORN_CHANNEL3=3, VTOLMOTORN_CHANNEL4=4, VTOLMOTORN_CHANNEL5=5, VTOLMOTORN_CHANNEL6=6, VTOLMOTORN_CHANNEL7=7, VTOLMOTORN_NONE=8, } VTOLMotorNOptions;
// Field VTOLMotorNE information // Field VTOLMotorNE information
/* Enumeration options for field VTOLMotorNE */ /* Enumeration options for field VTOLMotorNE */
typedef enum { VTOLMOTORNE_CHANNEL1=0, VTOLMOTORNE_CHANNEL2=1, VTOLMOTORNE_CHANNEL3=2, VTOLMOTORNE_CHANNEL4=3, VTOLMOTORNE_CHANNEL5=4, VTOLMOTORNE_CHANNEL6=5, VTOLMOTORNE_CHANNEL7=6, VTOLMOTORNE_CHANNEL8=7, VTOLMOTORNE_NONE=8, } VTOLMotorNEOptions; typedef enum { VTOLMOTORNE_CHANNEL0=0, VTOLMOTORNE_CHANNEL1=1, VTOLMOTORNE_CHANNEL2=2, VTOLMOTORNE_CHANNEL3=3, VTOLMOTORNE_CHANNEL4=4, VTOLMOTORNE_CHANNEL5=5, VTOLMOTORNE_CHANNEL6=6, VTOLMOTORNE_CHANNEL7=7, VTOLMOTORNE_NONE=8, } VTOLMotorNEOptions;
// Field VTOLMotorE information // Field VTOLMotorE information
/* Enumeration options for field VTOLMotorE */ /* Enumeration options for field VTOLMotorE */
typedef enum { VTOLMOTORE_CHANNEL1=0, VTOLMOTORE_CHANNEL2=1, VTOLMOTORE_CHANNEL3=2, VTOLMOTORE_CHANNEL4=3, VTOLMOTORE_CHANNEL5=4, VTOLMOTORE_CHANNEL6=5, VTOLMOTORE_CHANNEL7=6, VTOLMOTORE_CHANNEL8=7, VTOLMOTORE_NONE=8, } VTOLMotorEOptions; typedef enum { VTOLMOTORE_CHANNEL0=0, VTOLMOTORE_CHANNEL1=1, VTOLMOTORE_CHANNEL2=2, VTOLMOTORE_CHANNEL3=3, VTOLMOTORE_CHANNEL4=4, VTOLMOTORE_CHANNEL5=5, VTOLMOTORE_CHANNEL6=6, VTOLMOTORE_CHANNEL7=7, VTOLMOTORE_NONE=8, } VTOLMotorEOptions;
// Field VTOLMotorSE information // Field VTOLMotorSE information
/* Enumeration options for field VTOLMotorSE */ /* Enumeration options for field VTOLMotorSE */
typedef enum { VTOLMOTORSE_CHANNEL1=0, VTOLMOTORSE_CHANNEL2=1, VTOLMOTORSE_CHANNEL3=2, VTOLMOTORSE_CHANNEL4=3, VTOLMOTORSE_CHANNEL5=4, VTOLMOTORSE_CHANNEL6=5, VTOLMOTORSE_CHANNEL7=6, VTOLMOTORSE_CHANNEL8=7, VTOLMOTORSE_NONE=8, } VTOLMotorSEOptions; typedef enum { VTOLMOTORSE_CHANNEL0=0, VTOLMOTORSE_CHANNEL1=1, VTOLMOTORSE_CHANNEL2=2, VTOLMOTORSE_CHANNEL3=3, VTOLMOTORSE_CHANNEL4=4, VTOLMOTORSE_CHANNEL5=5, VTOLMOTORSE_CHANNEL6=6, VTOLMOTORSE_CHANNEL7=7, VTOLMOTORSE_NONE=8, } VTOLMotorSEOptions;
// Field VTOLMotorS information // Field VTOLMotorS information
/* Enumeration options for field VTOLMotorS */ /* Enumeration options for field VTOLMotorS */
typedef enum { VTOLMOTORS_CHANNEL1=0, VTOLMOTORS_CHANNEL2=1, VTOLMOTORS_CHANNEL3=2, VTOLMOTORS_CHANNEL4=3, VTOLMOTORS_CHANNEL5=4, VTOLMOTORS_CHANNEL6=5, VTOLMOTORS_CHANNEL7=6, VTOLMOTORS_CHANNEL8=7, VTOLMOTORS_NONE=8, } VTOLMotorSOptions; typedef enum { VTOLMOTORS_CHANNEL0=0, VTOLMOTORS_CHANNEL1=1, VTOLMOTORS_CHANNEL2=2, VTOLMOTORS_CHANNEL3=3, VTOLMOTORS_CHANNEL4=4, VTOLMOTORS_CHANNEL5=5, VTOLMOTORS_CHANNEL6=6, VTOLMOTORS_CHANNEL7=7, VTOLMOTORS_NONE=8, } VTOLMotorSOptions;
// Field VTOLMotorSW information // Field VTOLMotorSW information
/* Enumeration options for field VTOLMotorSW */ /* Enumeration options for field VTOLMotorSW */
typedef enum { VTOLMOTORSW_CHANNEL1=0, VTOLMOTORSW_CHANNEL2=1, VTOLMOTORSW_CHANNEL3=2, VTOLMOTORSW_CHANNEL4=3, VTOLMOTORSW_CHANNEL5=4, VTOLMOTORSW_CHANNEL6=5, VTOLMOTORSW_CHANNEL7=6, VTOLMOTORSW_CHANNEL8=7, VTOLMOTORSW_NONE=8, } VTOLMotorSWOptions; typedef enum { VTOLMOTORSW_CHANNEL0=0, VTOLMOTORSW_CHANNEL1=1, VTOLMOTORSW_CHANNEL2=2, VTOLMOTORSW_CHANNEL3=3, VTOLMOTORSW_CHANNEL4=4, VTOLMOTORSW_CHANNEL5=5, VTOLMOTORSW_CHANNEL6=6, VTOLMOTORSW_CHANNEL7=7, VTOLMOTORSW_NONE=8, } VTOLMotorSWOptions;
// Field VTOLMotorW information // Field VTOLMotorW information
/* Enumeration options for field VTOLMotorW */ /* Enumeration options for field VTOLMotorW */
typedef enum { VTOLMOTORW_CHANNEL1=0, VTOLMOTORW_CHANNEL2=1, VTOLMOTORW_CHANNEL3=2, VTOLMOTORW_CHANNEL4=3, VTOLMOTORW_CHANNEL5=4, VTOLMOTORW_CHANNEL6=5, VTOLMOTORW_CHANNEL7=6, VTOLMOTORW_CHANNEL8=7, VTOLMOTORW_NONE=8, } VTOLMotorWOptions; typedef enum { VTOLMOTORW_CHANNEL0=0, VTOLMOTORW_CHANNEL1=1, VTOLMOTORW_CHANNEL2=2, VTOLMOTORW_CHANNEL3=3, VTOLMOTORW_CHANNEL4=4, VTOLMOTORW_CHANNEL5=5, VTOLMOTORW_CHANNEL6=6, VTOLMOTORW_CHANNEL7=7, VTOLMOTORW_NONE=8, } VTOLMotorWOptions;
// Field VTOLMotorNW information // Field VTOLMotorNW information
/* Enumeration options for field VTOLMotorNW */ /* Enumeration options for field VTOLMotorNW */
typedef enum { VTOLMOTORNW_CHANNEL1=0, VTOLMOTORNW_CHANNEL2=1, VTOLMOTORNW_CHANNEL3=2, VTOLMOTORNW_CHANNEL4=3, VTOLMOTORNW_CHANNEL5=4, VTOLMOTORNW_CHANNEL6=5, VTOLMOTORNW_CHANNEL7=6, VTOLMOTORNW_CHANNEL8=7, VTOLMOTORNW_NONE=8, } VTOLMotorNWOptions; typedef enum { VTOLMOTORNW_CHANNEL0=0, VTOLMOTORNW_CHANNEL1=1, VTOLMOTORNW_CHANNEL2=2, VTOLMOTORNW_CHANNEL3=3, VTOLMOTORNW_CHANNEL4=4, VTOLMOTORNW_CHANNEL5=5, VTOLMOTORNW_CHANNEL6=6, VTOLMOTORNW_CHANNEL7=7, VTOLMOTORNW_NONE=8, } VTOLMotorNWOptions;
// Field ChannelUpdateFreq information // Field ChannelUpdateFreq information
/* Number of elements for field ChannelUpdateFreq */ /* Number of elements for field ChannelUpdateFreq */
static const quint32 CHANNELUPDATEFREQ_NUMELEM = 2; static const quint32 CHANNELUPDATEFREQ_NUMELEM = 2;

View File

@ -45,14 +45,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -64,14 +64,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -83,14 +83,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -102,14 +102,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -121,14 +121,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -140,14 +140,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -159,14 +159,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -178,14 +178,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -197,14 +197,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -216,14 +216,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -235,14 +235,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -254,14 +254,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -273,14 +273,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -292,14 +292,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),

View File

@ -50,6 +50,7 @@ ManualControlSettings::ManualControlSettings(): UAVDataObject(OBJID, ISSINGLEINS
QStringList RollElemNames; QStringList RollElemNames;
RollElemNames.append("0"); RollElemNames.append("0");
QStringList RollEnumOptions; QStringList RollEnumOptions;
RollEnumOptions.append("Channel0");
RollEnumOptions.append("Channel1"); RollEnumOptions.append("Channel1");
RollEnumOptions.append("Channel2"); RollEnumOptions.append("Channel2");
RollEnumOptions.append("Channel3"); RollEnumOptions.append("Channel3");
@ -57,12 +58,12 @@ ManualControlSettings::ManualControlSettings(): UAVDataObject(OBJID, ISSINGLEINS
RollEnumOptions.append("Channel5"); RollEnumOptions.append("Channel5");
RollEnumOptions.append("Channel6"); RollEnumOptions.append("Channel6");
RollEnumOptions.append("Channel7"); RollEnumOptions.append("Channel7");
RollEnumOptions.append("Channel8");
RollEnumOptions.append("None"); RollEnumOptions.append("None");
fields.append( new UAVObjectField(QString("Roll"), QString("channel"), UAVObjectField::ENUM, RollElemNames, RollEnumOptions) ); fields.append( new UAVObjectField(QString("Roll"), QString("channel"), UAVObjectField::ENUM, RollElemNames, RollEnumOptions) );
QStringList PitchElemNames; QStringList PitchElemNames;
PitchElemNames.append("0"); PitchElemNames.append("0");
QStringList PitchEnumOptions; QStringList PitchEnumOptions;
PitchEnumOptions.append("Channel0");
PitchEnumOptions.append("Channel1"); PitchEnumOptions.append("Channel1");
PitchEnumOptions.append("Channel2"); PitchEnumOptions.append("Channel2");
PitchEnumOptions.append("Channel3"); PitchEnumOptions.append("Channel3");
@ -70,12 +71,12 @@ ManualControlSettings::ManualControlSettings(): UAVDataObject(OBJID, ISSINGLEINS
PitchEnumOptions.append("Channel5"); PitchEnumOptions.append("Channel5");
PitchEnumOptions.append("Channel6"); PitchEnumOptions.append("Channel6");
PitchEnumOptions.append("Channel7"); PitchEnumOptions.append("Channel7");
PitchEnumOptions.append("Channel8");
PitchEnumOptions.append("None"); PitchEnumOptions.append("None");
fields.append( new UAVObjectField(QString("Pitch"), QString("channel"), UAVObjectField::ENUM, PitchElemNames, PitchEnumOptions) ); fields.append( new UAVObjectField(QString("Pitch"), QString("channel"), UAVObjectField::ENUM, PitchElemNames, PitchEnumOptions) );
QStringList YawElemNames; QStringList YawElemNames;
YawElemNames.append("0"); YawElemNames.append("0");
QStringList YawEnumOptions; QStringList YawEnumOptions;
YawEnumOptions.append("Channel0");
YawEnumOptions.append("Channel1"); YawEnumOptions.append("Channel1");
YawEnumOptions.append("Channel2"); YawEnumOptions.append("Channel2");
YawEnumOptions.append("Channel3"); YawEnumOptions.append("Channel3");
@ -83,12 +84,12 @@ ManualControlSettings::ManualControlSettings(): UAVDataObject(OBJID, ISSINGLEINS
YawEnumOptions.append("Channel5"); YawEnumOptions.append("Channel5");
YawEnumOptions.append("Channel6"); YawEnumOptions.append("Channel6");
YawEnumOptions.append("Channel7"); YawEnumOptions.append("Channel7");
YawEnumOptions.append("Channel8");
YawEnumOptions.append("None"); YawEnumOptions.append("None");
fields.append( new UAVObjectField(QString("Yaw"), QString("channel"), UAVObjectField::ENUM, YawElemNames, YawEnumOptions) ); fields.append( new UAVObjectField(QString("Yaw"), QString("channel"), UAVObjectField::ENUM, YawElemNames, YawEnumOptions) );
QStringList ThrottleElemNames; QStringList ThrottleElemNames;
ThrottleElemNames.append("0"); ThrottleElemNames.append("0");
QStringList ThrottleEnumOptions; QStringList ThrottleEnumOptions;
ThrottleEnumOptions.append("Channel0");
ThrottleEnumOptions.append("Channel1"); ThrottleEnumOptions.append("Channel1");
ThrottleEnumOptions.append("Channel2"); ThrottleEnumOptions.append("Channel2");
ThrottleEnumOptions.append("Channel3"); ThrottleEnumOptions.append("Channel3");
@ -96,12 +97,12 @@ ManualControlSettings::ManualControlSettings(): UAVDataObject(OBJID, ISSINGLEINS
ThrottleEnumOptions.append("Channel5"); ThrottleEnumOptions.append("Channel5");
ThrottleEnumOptions.append("Channel6"); ThrottleEnumOptions.append("Channel6");
ThrottleEnumOptions.append("Channel7"); ThrottleEnumOptions.append("Channel7");
ThrottleEnumOptions.append("Channel8");
ThrottleEnumOptions.append("None"); ThrottleEnumOptions.append("None");
fields.append( new UAVObjectField(QString("Throttle"), QString("channel"), UAVObjectField::ENUM, ThrottleElemNames, ThrottleEnumOptions) ); fields.append( new UAVObjectField(QString("Throttle"), QString("channel"), UAVObjectField::ENUM, ThrottleElemNames, ThrottleEnumOptions) );
QStringList FlightModeElemNames; QStringList FlightModeElemNames;
FlightModeElemNames.append("0"); FlightModeElemNames.append("0");
QStringList FlightModeEnumOptions; QStringList FlightModeEnumOptions;
FlightModeEnumOptions.append("Channel0");
FlightModeEnumOptions.append("Channel1"); FlightModeEnumOptions.append("Channel1");
FlightModeEnumOptions.append("Channel2"); FlightModeEnumOptions.append("Channel2");
FlightModeEnumOptions.append("Channel3"); FlightModeEnumOptions.append("Channel3");
@ -109,7 +110,6 @@ ManualControlSettings::ManualControlSettings(): UAVDataObject(OBJID, ISSINGLEINS
FlightModeEnumOptions.append("Channel5"); FlightModeEnumOptions.append("Channel5");
FlightModeEnumOptions.append("Channel6"); FlightModeEnumOptions.append("Channel6");
FlightModeEnumOptions.append("Channel7"); FlightModeEnumOptions.append("Channel7");
FlightModeEnumOptions.append("Channel8");
FlightModeEnumOptions.append("None"); FlightModeEnumOptions.append("None");
fields.append( new UAVObjectField(QString("FlightMode"), QString("channel"), UAVObjectField::ENUM, FlightModeElemNames, FlightModeEnumOptions) ); fields.append( new UAVObjectField(QString("FlightMode"), QString("channel"), UAVObjectField::ENUM, FlightModeElemNames, FlightModeEnumOptions) );
QStringList ChannelMaxElemNames; QStringList ChannelMaxElemNames;

View File

@ -59,19 +59,19 @@ public:
typedef enum { INPUTMODE_PWM=0, INPUTMODE_PPM=1, INPUTMODE_SPEKTRUM=2, } InputModeOptions; typedef enum { INPUTMODE_PWM=0, INPUTMODE_PPM=1, INPUTMODE_SPEKTRUM=2, } InputModeOptions;
// Field Roll information // Field Roll information
/* Enumeration options for field Roll */ /* Enumeration options for field Roll */
typedef enum { ROLL_CHANNEL1=0, ROLL_CHANNEL2=1, ROLL_CHANNEL3=2, ROLL_CHANNEL4=3, ROLL_CHANNEL5=4, ROLL_CHANNEL6=5, ROLL_CHANNEL7=6, ROLL_CHANNEL8=7, ROLL_NONE=8, } RollOptions; typedef enum { ROLL_CHANNEL0=0, ROLL_CHANNEL1=1, ROLL_CHANNEL2=2, ROLL_CHANNEL3=3, ROLL_CHANNEL4=4, ROLL_CHANNEL5=5, ROLL_CHANNEL6=6, ROLL_CHANNEL7=7, ROLL_NONE=8, } RollOptions;
// Field Pitch information // Field Pitch information
/* Enumeration options for field Pitch */ /* Enumeration options for field Pitch */
typedef enum { PITCH_CHANNEL1=0, PITCH_CHANNEL2=1, PITCH_CHANNEL3=2, PITCH_CHANNEL4=3, PITCH_CHANNEL5=4, PITCH_CHANNEL6=5, PITCH_CHANNEL7=6, PITCH_CHANNEL8=7, PITCH_NONE=8, } PitchOptions; typedef enum { PITCH_CHANNEL0=0, PITCH_CHANNEL1=1, PITCH_CHANNEL2=2, PITCH_CHANNEL3=3, PITCH_CHANNEL4=4, PITCH_CHANNEL5=5, PITCH_CHANNEL6=6, PITCH_CHANNEL7=7, PITCH_NONE=8, } PitchOptions;
// Field Yaw information // Field Yaw information
/* Enumeration options for field Yaw */ /* Enumeration options for field Yaw */
typedef enum { YAW_CHANNEL1=0, YAW_CHANNEL2=1, YAW_CHANNEL3=2, YAW_CHANNEL4=3, YAW_CHANNEL5=4, YAW_CHANNEL6=5, YAW_CHANNEL7=6, YAW_CHANNEL8=7, YAW_NONE=8, } YawOptions; typedef enum { YAW_CHANNEL0=0, YAW_CHANNEL1=1, YAW_CHANNEL2=2, YAW_CHANNEL3=3, YAW_CHANNEL4=4, YAW_CHANNEL5=5, YAW_CHANNEL6=6, YAW_CHANNEL7=7, YAW_NONE=8, } YawOptions;
// Field Throttle information // Field Throttle information
/* Enumeration options for field Throttle */ /* Enumeration options for field Throttle */
typedef enum { THROTTLE_CHANNEL1=0, THROTTLE_CHANNEL2=1, THROTTLE_CHANNEL3=2, THROTTLE_CHANNEL4=3, THROTTLE_CHANNEL5=4, THROTTLE_CHANNEL6=5, THROTTLE_CHANNEL7=6, THROTTLE_CHANNEL8=7, THROTTLE_NONE=8, } ThrottleOptions; typedef enum { THROTTLE_CHANNEL0=0, THROTTLE_CHANNEL1=1, THROTTLE_CHANNEL2=2, THROTTLE_CHANNEL3=3, THROTTLE_CHANNEL4=4, THROTTLE_CHANNEL5=5, THROTTLE_CHANNEL6=6, THROTTLE_CHANNEL7=7, THROTTLE_NONE=8, } ThrottleOptions;
// Field FlightMode information // Field FlightMode information
/* Enumeration options for field FlightMode */ /* Enumeration options for field FlightMode */
typedef enum { FLIGHTMODE_CHANNEL1=0, FLIGHTMODE_CHANNEL2=1, FLIGHTMODE_CHANNEL3=2, FLIGHTMODE_CHANNEL4=3, FLIGHTMODE_CHANNEL5=4, FLIGHTMODE_CHANNEL6=5, FLIGHTMODE_CHANNEL7=6, FLIGHTMODE_CHANNEL8=7, FLIGHTMODE_NONE=8, } FlightModeOptions; typedef enum { FLIGHTMODE_CHANNEL0=0, FLIGHTMODE_CHANNEL1=1, FLIGHTMODE_CHANNEL2=2, FLIGHTMODE_CHANNEL3=3, FLIGHTMODE_CHANNEL4=4, FLIGHTMODE_CHANNEL5=5, FLIGHTMODE_CHANNEL6=6, FLIGHTMODE_CHANNEL7=7, FLIGHTMODE_NONE=8, } FlightModeOptions;
// Field ChannelMax information // Field ChannelMax information
/* Number of elements for field ChannelMax */ /* Number of elements for field ChannelMax */
static const quint32 CHANNELMAX_NUMELEM = 8; static const quint32 CHANNELMAX_NUMELEM = 8;

View File

@ -58,14 +58,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -77,14 +77,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -96,14 +96,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -115,14 +115,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),
@ -134,14 +134,14 @@ _fields = [ \
'0', '0',
], ],
{ {
'0' : 'Channel1', '0' : 'Channel0',
'1' : 'Channel2', '1' : 'Channel1',
'2' : 'Channel3', '2' : 'Channel2',
'3' : 'Channel4', '3' : 'Channel3',
'4' : 'Channel5', '4' : 'Channel4',
'5' : 'Channel6', '5' : 'Channel5',
'6' : 'Channel7', '6' : 'Channel6',
'7' : 'Channel8', '7' : 'Channel7',
'8' : 'None', '8' : 'None',
} }
), ),

View File

@ -40,6 +40,9 @@ StabilizationSettings::StabilizationSettings(): UAVDataObject(OBJID, ISSINGLEINS
{ {
// Create fields // Create fields
QList<UAVObjectField*> fields; QList<UAVObjectField*> fields;
QStringList UpdatePeriodElemNames;
UpdatePeriodElemNames.append("0");
fields.append( new UAVObjectField(QString("UpdatePeriod"), QString("ms"), UAVObjectField::UINT16, UpdatePeriodElemNames, QStringList()) );
QStringList RollMaxElemNames; QStringList RollMaxElemNames;
RollMaxElemNames.append("0"); RollMaxElemNames.append("0");
fields.append( new UAVObjectField(QString("RollMax"), QString("degrees"), UAVObjectField::FLOAT32, RollMaxElemNames, QStringList()) ); fields.append( new UAVObjectField(QString("RollMax"), QString("degrees"), UAVObjectField::FLOAT32, RollMaxElemNames, QStringList()) );
@ -49,6 +52,33 @@ StabilizationSettings::StabilizationSettings(): UAVDataObject(OBJID, ISSINGLEINS
QStringList ThrottleMaxElemNames; QStringList ThrottleMaxElemNames;
ThrottleMaxElemNames.append("0"); ThrottleMaxElemNames.append("0");
fields.append( new UAVObjectField(QString("ThrottleMax"), QString("%"), UAVObjectField::FLOAT32, ThrottleMaxElemNames, QStringList()) ); fields.append( new UAVObjectField(QString("ThrottleMax"), QString("%"), UAVObjectField::FLOAT32, ThrottleMaxElemNames, QStringList()) );
QStringList PitchKpElemNames;
PitchKpElemNames.append("0");
fields.append( new UAVObjectField(QString("PitchKp"), QString(""), UAVObjectField::FLOAT32, PitchKpElemNames, QStringList()) );
QStringList PitchKiElemNames;
PitchKiElemNames.append("0");
fields.append( new UAVObjectField(QString("PitchKi"), QString(""), UAVObjectField::FLOAT32, PitchKiElemNames, QStringList()) );
QStringList PitchKdElemNames;
PitchKdElemNames.append("0");
fields.append( new UAVObjectField(QString("PitchKd"), QString(""), UAVObjectField::FLOAT32, PitchKdElemNames, QStringList()) );
QStringList RollKpElemNames;
RollKpElemNames.append("0");
fields.append( new UAVObjectField(QString("RollKp"), QString(""), UAVObjectField::FLOAT32, RollKpElemNames, QStringList()) );
QStringList RollKiElemNames;
RollKiElemNames.append("0");
fields.append( new UAVObjectField(QString("RollKi"), QString(""), UAVObjectField::FLOAT32, RollKiElemNames, QStringList()) );
QStringList RollKdElemNames;
RollKdElemNames.append("0");
fields.append( new UAVObjectField(QString("RollKd"), QString(""), UAVObjectField::FLOAT32, RollKdElemNames, QStringList()) );
QStringList YawKpElemNames;
YawKpElemNames.append("0");
fields.append( new UAVObjectField(QString("YawKp"), QString(""), UAVObjectField::FLOAT32, YawKpElemNames, QStringList()) );
QStringList YawKiElemNames;
YawKiElemNames.append("0");
fields.append( new UAVObjectField(QString("YawKi"), QString(""), UAVObjectField::FLOAT32, YawKiElemNames, QStringList()) );
QStringList YawKdElemNames;
YawKdElemNames.append("0");
fields.append( new UAVObjectField(QString("YawKd"), QString(""), UAVObjectField::FLOAT32, YawKdElemNames, QStringList()) );
// Initialize object // Initialize object
initializeFields(fields, (quint8*)&data, NUMBYTES); initializeFields(fields, (quint8*)&data, NUMBYTES);
@ -82,9 +112,19 @@ UAVObject::Metadata StabilizationSettings::getDefaultMetadata()
*/ */
void StabilizationSettings::setDefaultFieldValues() void StabilizationSettings::setDefaultFieldValues()
{ {
data.UpdatePeriod = 10;
data.RollMax = 35; data.RollMax = 35;
data.PitchMax = 35; data.PitchMax = 35;
data.ThrottleMax = 100; data.ThrottleMax = 1;
data.PitchKp = 0.04;
data.PitchKi = 4e-06;
data.PitchKd = 0.01;
data.RollKp = 0.02;
data.RollKi = 4e-06;
data.RollKd = 0.01;
data.YawKp = 1;
data.YawKi = 0;
data.YawKd = 0;
} }

View File

@ -41,20 +41,40 @@ class UAVOBJECTS_EXPORT StabilizationSettings: public UAVDataObject
public: public:
// Field structure // Field structure
typedef struct { typedef struct {
quint16 UpdatePeriod;
float RollMax; float RollMax;
float PitchMax; float PitchMax;
float ThrottleMax; float ThrottleMax;
float PitchKp;
float PitchKi;
float PitchKd;
float RollKp;
float RollKi;
float RollKd;
float YawKp;
float YawKi;
float YawKd;
} __attribute__((packed)) DataFields; } __attribute__((packed)) DataFields;
// Field information // Field information
// Field UpdatePeriod information
// Field RollMax information // Field RollMax information
// Field PitchMax information // Field PitchMax information
// Field ThrottleMax information // Field ThrottleMax information
// Field PitchKp information
// Field PitchKi information
// Field PitchKd information
// Field RollKp information
// Field RollKi information
// Field RollKd information
// Field YawKp information
// Field YawKi information
// Field YawKd information
// Constants // Constants
static const quint32 OBJID = 1855169608U; static const quint32 OBJID = 2185681924U;
static const QString NAME; static const QString NAME;
static const bool ISSINGLEINST = 1; static const bool ISSINGLEINST = 1;
static const bool ISSETTINGS = 1; static const bool ISSETTINGS = 1;

View File

@ -37,6 +37,16 @@ from collections import namedtuple
# This is a list of instances of the data fields contained in this object # This is a list of instances of the data fields contained in this object
_fields = [ \ _fields = [ \
uavobject.UAVObjectField(
'UpdatePeriod',
'H',
1,
[
'0',
],
{
}
),
uavobject.UAVObjectField( uavobject.UAVObjectField(
'RollMax', 'RollMax',
'f', 'f',
@ -67,12 +77,102 @@ _fields = [ \
{ {
} }
), ),
uavobject.UAVObjectField(
'PitchKp',
'f',
1,
[
'0',
],
{
}
),
uavobject.UAVObjectField(
'PitchKi',
'f',
1,
[
'0',
],
{
}
),
uavobject.UAVObjectField(
'PitchKd',
'f',
1,
[
'0',
],
{
}
),
uavobject.UAVObjectField(
'RollKp',
'f',
1,
[
'0',
],
{
}
),
uavobject.UAVObjectField(
'RollKi',
'f',
1,
[
'0',
],
{
}
),
uavobject.UAVObjectField(
'RollKd',
'f',
1,
[
'0',
],
{
}
),
uavobject.UAVObjectField(
'YawKp',
'f',
1,
[
'0',
],
{
}
),
uavobject.UAVObjectField(
'YawKi',
'f',
1,
[
'0',
],
{
}
),
uavobject.UAVObjectField(
'YawKd',
'f',
1,
[
'0',
],
{
}
),
] ]
class StabilizationSettings(uavobject.UAVObject): class StabilizationSettings(uavobject.UAVObject):
## Object constants ## Object constants
OBJID = 1855169608 OBJID = 2185681924
NAME = "StabilizationSettings" NAME = "StabilizationSettings"
METANAME = "StabilizationSettingsMeta" METANAME = "StabilizationSettingsMeta"
ISSINGLEINST = 1 ISSINGLEINST = 1

View File

@ -49,6 +49,7 @@ SystemAlarms::SystemAlarms(): UAVDataObject(OBJID, ISSINGLEINST, ISSETTINGS, NAM
AlarmElemNames.append("Telemetry"); AlarmElemNames.append("Telemetry");
AlarmElemNames.append("ManualControl"); AlarmElemNames.append("ManualControl");
AlarmElemNames.append("Actuator"); AlarmElemNames.append("Actuator");
AlarmElemNames.append("Stabilization");
QStringList AlarmEnumOptions; QStringList AlarmEnumOptions;
AlarmEnumOptions.append("OK"); AlarmEnumOptions.append("OK");
AlarmEnumOptions.append("Warning"); AlarmEnumOptions.append("Warning");

View File

@ -41,7 +41,7 @@ class UAVOBJECTS_EXPORT SystemAlarms: public UAVDataObject
public: public:
// Field structure // Field structure
typedef struct { typedef struct {
quint8 Alarm[8]; quint8 Alarm[9];
} __attribute__((packed)) DataFields; } __attribute__((packed)) DataFields;
@ -50,9 +50,9 @@ public:
/* Enumeration options for field Alarm */ /* Enumeration options for field Alarm */
typedef enum { ALARM_OK=0, ALARM_WARNING=1, ALARM_ERROR=2, ALARM_CRITICAL=3, } AlarmOptions; typedef enum { ALARM_OK=0, ALARM_WARNING=1, ALARM_ERROR=2, ALARM_CRITICAL=3, } AlarmOptions;
/* Array element names for field Alarm */ /* Array element names for field Alarm */
typedef enum { ALARM_OUTOFMEMORY=0, ALARM_STACKOVERFLOW=1, ALARM_CPUOVERLOAD=2, ALARM_EVENTSYSTEM=3, ALARM_SDCARD=4, ALARM_TELEMETRY=5, ALARM_MANUALCONTROL=6, ALARM_ACTUATOR=7, } AlarmElem; typedef enum { ALARM_OUTOFMEMORY=0, ALARM_STACKOVERFLOW=1, ALARM_CPUOVERLOAD=2, ALARM_EVENTSYSTEM=3, ALARM_SDCARD=4, ALARM_TELEMETRY=5, ALARM_MANUALCONTROL=6, ALARM_ACTUATOR=7, ALARM_STABILIZATION=8, } AlarmElem;
/* Number of elements for field Alarm */ /* Number of elements for field Alarm */
static const quint32 ALARM_NUMELEM = 8; static const quint32 ALARM_NUMELEM = 9;
// Constants // Constants

View File

@ -40,7 +40,7 @@ _fields = [ \
uavobject.UAVObjectField( uavobject.UAVObjectField(
'Alarm', 'Alarm',
'b', 'b',
8, 9,
[ [
'OutOfMemory', 'OutOfMemory',
'StackOverflow', 'StackOverflow',
@ -50,6 +50,7 @@ _fields = [ \
'Telemetry', 'Telemetry',
'ManualControl', 'ManualControl',
'Actuator', 'Actuator',
'Stabilization',
], ],
{ {
'0' : 'OK', '0' : 'OK',

View File

@ -1,19 +1,19 @@
<xml> <xml>
<object name="ActuatorSettings" singleinstance="true" settings="true"> <object name="ActuatorSettings" singleinstance="true" settings="true">
<field name="FixedWingRoll1" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="FixedWingRoll1" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="FixedWingRoll2" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="FixedWingRoll2" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="FixedWingPitch1" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="FixedWingPitch1" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="FixedWingPitch2" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="FixedWingPitch2" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="FixedWingYaw" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="FixedWingYaw" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="FixedWingThrottle" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="FixedWingThrottle" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="VTOLMotorN" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="VTOLMotorN" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="VTOLMotorNE" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="VTOLMotorNE" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="VTOLMotorE" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="VTOLMotorE" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="VTOLMotorSE" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="VTOLMotorSE" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="VTOLMotorS" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="VTOLMotorS" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="VTOLMotorSW" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="VTOLMotorSW" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="VTOLMotorW" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="VTOLMotorW" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="VTOLMotorNW" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="None"/> <field name="VTOLMotorNW" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="None"/>
<field name="ChannelUpdateFreq" units="Hz" type="int16" elements="2" defaultvalue="50"/> <field name="ChannelUpdateFreq" units="Hz" type="int16" elements="2" defaultvalue="50"/>
<field name="ChannelMax" units="us" type="int16" elements="8" defaultvalue="2000"/> <field name="ChannelMax" units="us" type="int16" elements="8" defaultvalue="2000"/>
<field name="ChannelNeutral" units="us" type="int16" elements="8" defaultvalue="1500"/> <field name="ChannelNeutral" units="us" type="int16" elements="8" defaultvalue="1500"/>

View File

@ -1,11 +1,11 @@
<xml> <xml>
<object name="ManualControlSettings" singleinstance="true" settings="true"> <object name="ManualControlSettings" singleinstance="true" settings="true">
<field name="InputMode" units="" type="enum" elements="1" options="PWM,PPM,Spektrum" defaultvalue="PWM"/> <field name="InputMode" units="" type="enum" elements="1" options="PWM,PPM,Spektrum" defaultvalue="PWM"/>
<field name="Roll" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="Channel1"/> <field name="Roll" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="Channel0"/>
<field name="Pitch" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="Channel2"/> <field name="Pitch" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="Channel1"/>
<field name="Yaw" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="Channel3"/> <field name="Yaw" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="Channel2"/>
<field name="Throttle" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="Channel4"/> <field name="Throttle" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="Channel3"/>
<field name="FlightMode" units="channel" type="enum" elements="1" options="Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,Channel8,None" defaultvalue="Channel5"/> <field name="FlightMode" units="channel" type="enum" elements="1" options="Channel0,Channel1,Channel2,Channel3,Channel4,Channel5,Channel6,Channel7,None" defaultvalue="Channel4"/>
<field name="ChannelMax" units="us" type="int16" elements="8" defaultvalue="2000"/> <field name="ChannelMax" units="us" type="int16" elements="8" defaultvalue="2000"/>
<field name="ChannelNeutral" units="us" type="int16" elements="8" defaultvalue="1500"/> <field name="ChannelNeutral" units="us" type="int16" elements="8" defaultvalue="1500"/>
<field name="ChannelMin" units="us" type="int16" elements="8" defaultvalue="1000"/> <field name="ChannelMin" units="us" type="int16" elements="8" defaultvalue="1000"/>

View File

@ -1,8 +1,18 @@
<xml> <xml>
<object name="StabilizationSettings" singleinstance="true" settings="true"> <object name="StabilizationSettings" singleinstance="true" settings="true">
<field name="UpdatePeriod" units="ms" type="uint16" elements="1" defaultvalue="10"/>
<field name="RollMax" units="degrees" type="float" elements="1" defaultvalue="35"/> <field name="RollMax" units="degrees" type="float" elements="1" defaultvalue="35"/>
<field name="PitchMax" units="degrees" type="float" elements="1" defaultvalue="35"/> <field name="PitchMax" units="degrees" type="float" elements="1" defaultvalue="35"/>
<field name="ThrottleMax" units="%" type="float" elements="1" defaultvalue="100.0"/> <field name="ThrottleMax" units="%" type="float" elements="1" defaultvalue="1.0"/>
<field name="PitchKp" units="" type="float" elements="1" defaultvalue="0.04"/>
<field name="PitchKi" units="" type="float" elements="1" defaultvalue="0.000004"/>
<field name="PitchKd" units="" type="float" elements="1" defaultvalue="0.01"/>
<field name="RollKp" units="" type="float" elements="1" defaultvalue="0.02"/>
<field name="RollKi" units="" type="float" elements="1" defaultvalue="0.000004"/>
<field name="RollKd" units="" type="float" elements="1" defaultvalue="0.01"/>
<field name="YawKp" units="" type="float" elements="1" defaultvalue="1.0"/>
<field name="YawKi" units="" type="float" elements="1" defaultvalue="0.0"/>
<field name="YawKd" units="" type="float" elements="1" defaultvalue="0.0"/>
<access gcs="readwrite" flight="readwrite"/> <access gcs="readwrite" flight="readwrite"/>
<telemetrygcs acked="true" updatemode="onchange" period="0"/> <telemetrygcs acked="true" updatemode="onchange" period="0"/>
<telemetryflight acked="true" updatemode="onchange" period="0"/> <telemetryflight acked="true" updatemode="onchange" period="0"/>

View File

@ -1,7 +1,7 @@
<xml> <xml>
<object name="SystemAlarms" singleinstance="true" settings="false"> <object name="SystemAlarms" singleinstance="true" settings="false">
<field name="Alarm" units="" type="enum" options="OK,Warning,Error,Critical" <field name="Alarm" units="" type="enum" options="OK,Warning,Error,Critical"
elementnames="OutOfMemory,StackOverflow,CPUOverload,EventSystem,SDCard,Telemetry,ManualControl,Actuator"/> elementnames="OutOfMemory,StackOverflow,CPUOverload,EventSystem,SDCard,Telemetry,ManualControl,Actuator,Stabilization"/>
<access gcs="readwrite" flight="readwrite"/> <access gcs="readwrite" flight="readwrite"/>
<telemetrygcs acked="true" updatemode="onchange" period="0"/> <telemetrygcs acked="true" updatemode="onchange" period="0"/>
<telemetryflight acked="true" updatemode="periodic" period="4000"/> <telemetryflight acked="true" updatemode="periodic" period="4000"/>