Initial commit
This commit is contained in:
commit
b7d90b9afe
16245 files changed
+3396666
No files matched your search
+50
@@ -0,0 +1,50 @@
|
||||
/**
|
||||
* @RDE_HEADER@
|
||||
* TTCI-Server Library - handler for a specific TTCI channel
|
||||
* $Id$
|
||||
* $HeadURL$
|
||||
* $Author$
|
||||
* Created by Patric Karwat, NLS, 2019-01-17
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <QObject>
|
||||
|
||||
namespace NGL
|
||||
{
|
||||
class INGLLogger;
|
||||
}
|
||||
namespace TrainingAreaBaseOC
|
||||
{
|
||||
class Device;
|
||||
|
||||
// a single TTCI channel
|
||||
class Channel : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
Channel(QChar channel, bool bIsBinary, QObject *parent = nullptr);
|
||||
|
||||
void setDevice(Device *dev);
|
||||
|
||||
bool writeData(const QByteArray &data);
|
||||
|
||||
QChar channel() const { return m_channel; }
|
||||
|
||||
signals:
|
||||
void dataAvailable(const QByteArray &);
|
||||
void disconnectedFromEq();
|
||||
|
||||
|
||||
protected slots:
|
||||
void onDeviceDestroyed();
|
||||
void onDataAvailable(const QByteArray &data);
|
||||
|
||||
protected:
|
||||
QChar m_channel;
|
||||
bool m_bIsBinary;
|
||||
Device *m_device;
|
||||
NGL::INGLLogger &m_logger;
|
||||
};
|
||||
} // namespace TrainingAreaBaseOC
|
||||
Reference in new issue
Block a user