From deeb7c350255a1e94060f4d1f816a8b118e57be1 Mon Sep 17 00:00:00 2001 From: m_thread Date: Sat, 21 Mar 2015 10:14:32 +0100 Subject: [PATCH] OP-1777 Added some more information from configuration to uploaded data. --- .../usagetracker/usagetrackerplugin.cpp | 33 ++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) diff --git a/ground/openpilotgcs/src/plugins/usagetracker/usagetrackerplugin.cpp b/ground/openpilotgcs/src/plugins/usagetracker/usagetrackerplugin.cpp index f38e34ee3..10a1cb294 100644 --- a/ground/openpilotgcs/src/plugins/usagetracker/usagetrackerplugin.cpp +++ b/ground/openpilotgcs/src/plugins/usagetracker/usagetrackerplugin.cpp @@ -194,10 +194,41 @@ void UsageTrackerPlugin::collectUsageParameters(QMap ¶mete parameters["conf_uport"] = getUAVFieldValue(objManager, "HwSettings", "USB_HIDPort"); parameters["conf_vport"] = getUAVFieldValue(objManager, "HwSettings", "USB_VCPPort"); - parameters["conf_rotation"] = QString("%1:%2:%3") + parameters["conf_rotation"] = QString("[%1:%2:%3]") .arg(getUAVFieldValue(objManager, "AttitudeSettings", "BoardRotation", 0)) .arg(getUAVFieldValue(objManager, "AttitudeSettings", "BoardRotation", 1)) .arg(getUAVFieldValue(objManager, "AttitudeSettings", "BoardRotation", 2)); + parameters["conf_pidr"] = QString("[%1:%2:%3:%4][%5:%6:%7:%8][%9:%10:%11:%12]") + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "RollRatePID", 0)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "RollRatePID", 1)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "RollRatePID", 2)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "RollRatePID", 3)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "PitchRatePID", 0)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "PitchRatePID", 1)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "PitchRatePID", 2)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "PitchRatePID", 3)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "YawRatePID", 0)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "YawRatePID", 1)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "YawRatePID", 2)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "YawRatePID", 3)); + parameters["conf_pia"] = QString("[%1:%2:%3][%4:%5:%6][%7:%8:%9]") + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "RollPI", 0)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "RollPI", 1)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "RollPI", 2)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "PitchPI", 0)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "PitchPI", 1)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "PitchPI", 2)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "YawPI", 0)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "YawPI", 1)) + .arg(getUAVFieldValue(objManager, "StabilizationSettingsBank1", "YawPI", 2)); + + parameters["conf_tps"] = getUAVFieldValue(objManager, "StabilizationSettingsBank1", "EnableThrustPIDScaling"); + parameters["conf_piro"] = getUAVFieldValue(objManager, "StabilizationSettingsBank1", "EnablePiroComp"); + + parameters["conf_fmcount"] = getUAVFieldValue(objManager, "ManualControlSettings", "FlightModeNumber"); + parameters["conf_fmodes"] = QString("[%1:%2:%3]").arg(getUAVFieldValue(objManager, "FlightModeSettings", "FlightModePosition", 0)) + .arg(getUAVFieldValue(objManager, "FlightModeSettings", "FlightModePosition", 1)) + .arg(getUAVFieldValue(objManager, "FlightModeSettings", "FlightModePosition", 2)); } }