diff --git a/src/ui/DebugConsole.cc b/src/ui/DebugConsole.cc index 86bd96b847961884825f5560147ecba0a1a242ae..b687e998f7e11bf67ce1366125836f58dc44d77a 100644 --- a/src/ui/DebugConsole.cc +++ b/src/ui/DebugConsole.cc @@ -40,9 +40,6 @@ This file is part of the QGROUNDCONTROL project #include "protocol.h" #include "QGC.h" -// Set the snapshot interval to 500ms. -#define DEBUGCONSOLE_SNAPSHOT_INTERVAL 500 - DebugConsole::DebugConsole(QWidget *parent) : QWidget(parent), currLink(NULL), @@ -60,9 +57,7 @@ DebugConsole::DebugConsole(QWidget *parent) : lastLineBuffer(0), lineBufferTimer(), snapShotTimer(), - snapShotInterval(DEBUGCONSOLE_SNAPSHOT_INTERVAL), lowpassInDataRate(0.0f), - inDataRateThreshold(0.4), lowpassOutDataRate(0.0f), commandIndex(0), m_ui(new Ui::DebugConsole) diff --git a/src/ui/DebugConsole.h b/src/ui/DebugConsole.h index 611e01670e10301b5d291bfbe8188b6bef67a7e1..4d9dd648a8f40dfa94b4bd2d309fed944577f8d0 100644 --- a/src/ui/DebugConsole.h +++ b/src/ui/DebugConsole.h @@ -137,9 +137,9 @@ protected: quint64 lastLineBuffer; ///< Last line buffer emission time QTimer lineBufferTimer; ///< Line buffer timer QTimer snapShotTimer; ///< Timer for measuring traffic snapshots - int snapShotInterval; ///< Set the time between UI updates for the data rate (ms) + static const int snapShotInterval = 500; ///< Set the time between UI updates for the data rate (ms) float lowpassInDataRate; ///< Lowpass filtered data rate (kilobytes/s) - float inDataRateThreshold; ///< Threshold where to enable auto-hold (kilobytes/s) + static const float inDataRateThreshold = 0.4; ///< Threshold where to enable auto-hold (kilobytes/s) float lowpassOutDataRate; ///< Low-pass filtered outgoing data rate (kilobytes/s) QStringList commandHistory; QString currCommand;