mirror of
https://github.com/f4exb/sdrangel.git
synced 2025-02-03 09:44:01 -05:00
SDRdaemonSink: GUI: display queue length and quality metrics received from remote Tx
This commit is contained in:
parent
7b63657fb7
commit
5b48a3f4a9
@ -22,6 +22,8 @@
|
||||
#include <QFileDialog>
|
||||
#include <QMessageBox>
|
||||
|
||||
#include <boost/algorithm/string.hpp>
|
||||
|
||||
#include <nanomsg/nn.h>
|
||||
#include <nanomsg/pair.h>
|
||||
|
||||
@ -532,7 +534,19 @@ void SDRdaemonSinkGui::tick()
|
||||
if ((len > 0) && msgBuf)
|
||||
{
|
||||
std::string msg((char *) msgBuf, len);
|
||||
qDebug("SDRdaemonSinkGui::tick: received NN msg: %s", msg.c_str());
|
||||
std::vector<std::string> strs;
|
||||
boost::split(strs, msg, boost::is_any_of(":"));
|
||||
unsigned int nbTokens = strs.size();
|
||||
|
||||
if (nbTokens > 0) // at least the queue length is given
|
||||
{
|
||||
ui->queueLengthText->setText(QString::fromStdString(strs[0]));
|
||||
}
|
||||
|
||||
if (nbTokens > 1) // the quality indicator is given also
|
||||
{
|
||||
ui->qualityStatusText->setText(QString::fromStdString(strs[1]));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -7,7 +7,7 @@
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>372</width>
|
||||
<height>190</height>
|
||||
<height>217</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
@ -378,6 +378,69 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="Line" name="line_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="queueLengthLabel">
|
||||
<property name="text">
|
||||
<string>QL:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="queueLengthText">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>18</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Current transmitter queue length in number of vectors</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>00</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="Line" name="line_3">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="qualityStatusLabel">
|
||||
<property name="text">
|
||||
<string>Q:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="qualityStatusText">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>80</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Average number of blocks received / Average number of blocks used for recovery</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>100.0/100.0</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<property name="orientation">
|
||||
@ -391,28 +454,6 @@
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="absTimeText">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>90</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Record time from start</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>2015-01-01 00:00:00.000</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
|
Loading…
Reference in New Issue
Block a user