1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2026-07-25 11:34:09 -04:00

File record default file name fix (2)

This commit is contained in:
f4exb
2018-05-09 17:39:48 +02:00
parent 2d57d6d7e0
commit 775b2a270d
49 changed files with 187 additions and 39 deletions
@@ -687,9 +687,18 @@ bool LimeSDRInput::handleMessage(const Message& message)
MsgFileRecord& conf = (MsgFileRecord&) message;
qDebug() << "LimeSDRInput::handleMessage: MsgFileRecord: " << conf.getStartStop();
if (conf.getStartStop()) {
if (conf.getStartStop())
{
if (m_settings.m_fileRecordName.size() != 0) {
m_fileSink->setFileName(m_settings.m_fileRecordName);
} else {
m_fileSink->setFileName(QString("rec%1_%2.sdriq").arg(m_deviceAPI->getDeviceUID()).arg(QDateTime::currentDateTimeUtc().toString("yyyy-MM-ddThh:mm:ss")));
}
m_fileSink->startRecording();
} else {
}
else
{
m_fileSink->stopRecording();
}
@@ -33,7 +33,7 @@
const PluginDescriptor LimeSDRInputPlugin::m_pluginDescriptor = {
QString("LimeSDR Input"),
QString("3.14.5"),
QString("3.14.6"),
QString("(c) Edouard Griffiths, F4EXB"),
QString("https://github.com/f4exb/sdrangel"),
true,
@@ -45,6 +45,7 @@ void LimeSDRInputSettings::resetToDefaults()
m_extClockFreq = 10000000; // 10 MHz
m_transverterMode = false;
m_transverterDeltaFrequency = 0;
m_fileRecordName = "";
}
QByteArray LimeSDRInputSettings::serialize() const
@@ -18,6 +18,7 @@
#define PLUGINS_SAMPLESOURCE_LIMESDRINPUT_LIMESDRINPUTSETTINGS_H_
#include <QByteArray>
#include <QString>
#include <stdint.h>
/**
@@ -64,6 +65,7 @@ struct LimeSDRInputSettings
uint32_t m_extClockFreq; //!< Frequency (Hz) of external clock source
bool m_transverterMode;
qint64 m_transverterDeltaFrequency;
QString m_fileRecordName;
LimeSDRInputSettings();
void resetToDefaults();