44 m_deviceAPI(deviceAPI),
47 m_deviceDescription("FileSink"),
48 m_fileName("./test.sdriq"),
49 m_startingTimeStamp(0),
50 m_masterTimer(deviceAPI->getMasterTimer())
52 m_deviceAPI->setNbSinkStreams(1);
83 qDebug() <<
"FileSinkOutput::openFileStream: " <<
m_fileName.toStdString().c_str();
93 QMutexLocker mutexLocker(&
m_mutex);
94 qDebug() <<
"FileSinkOutput::start";
104 mutexLocker.unlock();
106 qDebug(
"FileSinkOutput::start: started");
119 qDebug() <<
"FileSourceInput::stop";
120 QMutexLocker mutexLocker(&
m_mutex);
214 qDebug() <<
"FileSinkOutput::handleMessage: MsgStartStop: " << (cmd.
getStartStop() ?
"start" :
"stop");
232 qDebug() <<
"FileSinkOutput::handleMessage: MsgConfigureFileSink";
276 QMutexLocker mutexLocker(&
m_mutex);
277 bool forwardChange =
false;
282 forwardChange =
true;
294 forwardChange =
true;
306 forwardChange =
true;
311 qDebug(
"FileSinkOutput::applySettings: forward: m_centerFrequency: %llu m_sampleRate: %llu m_log2Interp: %d",
323 QString& errorMessage)
333 QString& errorMessage)
virtual ~FileSinkOutput()
virtual int webapiRun(bool run, SWGSDRangel::SWGDeviceState &response, QString &errorMessage)
bool startDeviceEngine()
Start the device engine corresponding to the stream type.
static MsgReportFileSinkStreamTiming * create(std::size_t samplesCount)
void push(Message *message, bool emitSignal=true)
Push message onto queue.
void stopDeviceEngine()
Stop the device engine corresponding to the stream type.
bool deserialize(const QByteArray &data)
MessageQueue * getDeviceEngineInputMessageQueue()
Device engine message queue.
void setLog2Interpolation(int log2Interpolation)
virtual const QString & getDeviceDescription() const
void applySettings(const FileSinkSettings &settings, bool force=false)
bool initDeviceEngine()
Init the device engine corresponding to the stream type.
virtual int getSampleRate() const
Sample rate exposed by the sink.
virtual void init()
initializations to be done when all collaborating objects are created and possibly connected ...
virtual bool handleMessage(const Message &message)
MessageQueue m_inputMessageQueue
Input queue to the sink.
static MsgStartStop * create(bool startStop)
virtual quint64 getCenterFrequency() const
Center frequency exposed by the sink.
const QTimer & m_masterTimer
#define MESSAGE_CLASS_DEFINITION(Name, BaseClass)
virtual int webapiRunGet(SWGSDRangel::SWGDeviceState &response, QString &errorMessage)
static bool match(const Message *message)
virtual QByteArray serialize() const
void getDeviceEngineStateStr(QString &state)
virtual void setCenterFrequency(qint64 centerFrequency)
FileSinkSettings m_settings
std::size_t getSamplesCount() const
QByteArray serialize() const
SampleSourceFifo m_sampleSourceFifo
void connectTimer(const QTimer &timer)
static MsgReportFileSinkGeneration * create(bool acquisition)
virtual bool deserialize(const QByteArray &data)
quint64 m_centerFrequency
std::time_t getStartingTimeStamp() const
MessageQueue * getMessageQueueToGUI()
QString m_deviceDescription
FileSinkThread * m_fileSinkThread
std::time_t m_startingTimeStamp
MessageQueue * m_guiMessageQueue
Input message queue to the GUI.
void setSamplerate(int samplerate)
bool getStartStop() const