working on add device and syncing the devices
This commit is contained in:
parent
a37f282f6f
commit
ea11aae5c9
@ -3,7 +3,7 @@ folder_01.source = qml/hive_client
|
|||||||
folder_01.target = qml
|
folder_01.target = qml
|
||||||
DEPLOYMENTFOLDERS = folder_01
|
DEPLOYMENTFOLDERS = folder_01
|
||||||
|
|
||||||
QT += core qml quick
|
QT += core qml quick declarative
|
||||||
|
|
||||||
|
|
||||||
# Additional import path used to resolve QML modules in Creator's code model
|
# Additional import path used to resolve QML modules in Creator's code model
|
||||||
|
|||||||
@ -1,29 +1,28 @@
|
|||||||
#include "hiveclientcore.h"
|
#include "hiveclientcore.h"
|
||||||
#include <QtQml>
|
#include <QtQml>
|
||||||
#include <QQmlEngine>
|
#include <QQmlEngine>
|
||||||
#include <QQmlApplicationEngine>
|
#include <QQuickWindow>
|
||||||
|
|
||||||
HiveClientCore::HiveClientCore(QObject *parent) :
|
HiveClientCore::HiveClientCore(QObject *parent) :
|
||||||
QObject(parent)
|
QObject(parent)
|
||||||
{
|
{
|
||||||
|
|
||||||
m_id = 0;
|
m_id = 0;
|
||||||
|
|
||||||
m_settings = new Settings(this);
|
|
||||||
m_client = new Client(this);
|
m_client = new Client(this);
|
||||||
|
|
||||||
|
// QML Typs
|
||||||
|
qmlRegisterType<Settings>("hive",1,0,"Settings");
|
||||||
|
|
||||||
// QML application window
|
// QML application window
|
||||||
m_engine = new QQmlApplicationEngine(this);
|
m_engine = new QQmlApplicationEngine(this);
|
||||||
m_engine->load(QUrl("qml/hive_client/main.qml"));
|
m_engine->load(QUrl("qml/hive_client/main.qml"));
|
||||||
|
|
||||||
m_engine->rootContext()->setContextProperty("client", m_client);
|
m_engine->rootContext()->setContextProperty("client", m_client);
|
||||||
m_engine->rootContext()->setContextProperty("settings", m_settings);
|
|
||||||
|
|
||||||
topLevel = m_engine->rootObjects().value(0);
|
topLevel = m_engine->rootObjects().value(0);
|
||||||
QQuickWindow *window = qobject_cast<QQuickWindow *>(topLevel);
|
QQuickWindow *window = qobject_cast<QQuickWindow *>(topLevel);
|
||||||
window->show();
|
window->show();
|
||||||
|
|
||||||
connect(m_client,SIGNAL(connected()),this,SLOT(onConnected()));
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -3,7 +3,6 @@
|
|||||||
|
|
||||||
#include <QObject>
|
#include <QObject>
|
||||||
#include <QQmlApplicationEngine>
|
#include <QQmlApplicationEngine>
|
||||||
#include <QQuickWindow>
|
|
||||||
|
|
||||||
#include "client.h"
|
#include "client.h"
|
||||||
#include "settings.h"
|
#include "settings.h"
|
||||||
@ -16,7 +15,7 @@ public:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
Client *m_client;
|
Client *m_client;
|
||||||
Settings *m_settings;
|
//Settings *m_settings;
|
||||||
|
|
||||||
QQmlApplicationEngine *m_engine;
|
QQmlApplicationEngine *m_engine;
|
||||||
QObject *topLevel;
|
QObject *topLevel;
|
||||||
|
|||||||
115
hive/client/hive_client/qml/hive_client/AddDevicePage.qml
Normal file
115
hive/client/hive_client/qml/hive_client/AddDevicePage.qml
Normal file
@ -0,0 +1,115 @@
|
|||||||
|
import QtQuick 2.0
|
||||||
|
import QtQuick.Controls 1.0
|
||||||
|
import QtQuick.Layouts 1.0
|
||||||
|
|
||||||
|
Component {
|
||||||
|
|
||||||
|
Rectangle{
|
||||||
|
anchors.fill: parent
|
||||||
|
|
||||||
|
ColumnLayout{
|
||||||
|
id: addDeviceColumn
|
||||||
|
|
||||||
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
|
||||||
|
GroupBox{
|
||||||
|
id: nameGroupBox
|
||||||
|
title: "Name"
|
||||||
|
|
||||||
|
Row{
|
||||||
|
spacing: 5
|
||||||
|
Text{
|
||||||
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
text: "Name:"
|
||||||
|
}
|
||||||
|
|
||||||
|
TextField{
|
||||||
|
id: nameText
|
||||||
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
placeholderText: "Device Name"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
GroupBox{
|
||||||
|
id: deviceTypeGroupBox
|
||||||
|
title: "Device Type"
|
||||||
|
|
||||||
|
ComboBox {
|
||||||
|
id: deviceComboBox
|
||||||
|
model: ["actor","sensor"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
GroupBox{
|
||||||
|
id: communicationTypeGroupBox
|
||||||
|
title: "Communication Type"
|
||||||
|
|
||||||
|
ComboBox {
|
||||||
|
id: communicationTypeComboBox
|
||||||
|
model: ["RC433","RC868","ZigBee"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
GroupBox{
|
||||||
|
id: linecodeGroupBox
|
||||||
|
title: "Linecode"
|
||||||
|
visible: communicationTypeComboBox.currentText == "RC868" || communicationTypeComboBox.currentText == "RC433" ? true : false
|
||||||
|
|
||||||
|
ComboBox {
|
||||||
|
id: linecodeComboBox
|
||||||
|
model: ["Switch","Light","Unicode","Manchester","Differential Manchester"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
GroupBox{
|
||||||
|
id: switchGroupBox
|
||||||
|
title: "Switchsettings"
|
||||||
|
visible: (linecodeComboBox.currentText == "Switch") && (communicationTypeComboBox.currentText == "RC868" || communicationTypeComboBox.currentText == "RC433") ? true : false
|
||||||
|
|
||||||
|
RowLayout{
|
||||||
|
GridLayout{
|
||||||
|
columns: 6
|
||||||
|
Label{
|
||||||
|
text: "1"
|
||||||
|
}
|
||||||
|
Label{
|
||||||
|
text: "2"
|
||||||
|
}
|
||||||
|
Label{
|
||||||
|
text: "3"
|
||||||
|
}
|
||||||
|
Label{
|
||||||
|
text: "4"
|
||||||
|
}
|
||||||
|
Label{
|
||||||
|
text: "5"
|
||||||
|
}
|
||||||
|
Label{
|
||||||
|
text: "6"
|
||||||
|
}
|
||||||
|
CheckBox{
|
||||||
|
id: channel1
|
||||||
|
}
|
||||||
|
CheckBox{
|
||||||
|
id: channel2
|
||||||
|
}
|
||||||
|
CheckBox{
|
||||||
|
id: channel3
|
||||||
|
}
|
||||||
|
CheckBox{
|
||||||
|
id: channel4
|
||||||
|
}
|
||||||
|
CheckBox{
|
||||||
|
id: channel5
|
||||||
|
}
|
||||||
|
CheckBox{
|
||||||
|
id: channel6
|
||||||
|
}
|
||||||
|
}
|
||||||
|
ComboBox {
|
||||||
|
id: switchComboBox
|
||||||
|
model: ["A","B","C","D","E"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
53
hive/client/hive_client/qml/hive_client/ConnectionPage.qml
Normal file
53
hive/client/hive_client/qml/hive_client/ConnectionPage.qml
Normal file
@ -0,0 +1,53 @@
|
|||||||
|
import QtQuick 2.0
|
||||||
|
import QtQuick.Controls 1.0
|
||||||
|
import QtQuick.Layouts 1.0
|
||||||
|
|
||||||
|
Component {
|
||||||
|
Rectangle{
|
||||||
|
anchors.fill: parent
|
||||||
|
|
||||||
|
GroupBox {
|
||||||
|
id: connectionGroupBox
|
||||||
|
anchors.centerIn: parent
|
||||||
|
|
||||||
|
title: "Connection"
|
||||||
|
|
||||||
|
RowLayout{
|
||||||
|
anchors.fill: parent
|
||||||
|
Button{
|
||||||
|
id: connectButton
|
||||||
|
text: "Connect"
|
||||||
|
onClicked: {
|
||||||
|
settings.ipaddress = ipTextInput.text
|
||||||
|
settings.port = portTextInput.text
|
||||||
|
client.connectToHost(ipTextInput.text,portTextInput.text)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Text {
|
||||||
|
id: ipLable
|
||||||
|
text: "IP:"
|
||||||
|
horizontalAlignment: Text.AlignHCenter
|
||||||
|
}
|
||||||
|
TextField {
|
||||||
|
id: ipTextInput
|
||||||
|
text: settings.ipaddress
|
||||||
|
horizontalAlignment: TextInput.AlignHCenter
|
||||||
|
font.pointSize: 9
|
||||||
|
}
|
||||||
|
Text {
|
||||||
|
id: portLable
|
||||||
|
text: "Port:"
|
||||||
|
wrapMode: Text.NoWrap
|
||||||
|
verticalAlignment: Text.AlignTop
|
||||||
|
horizontalAlignment: Text.AlignHCenter
|
||||||
|
}
|
||||||
|
TextField {
|
||||||
|
id: portTextInput
|
||||||
|
text: settings.port
|
||||||
|
horizontalAlignment: TextInput.AlignHCenter
|
||||||
|
font.pointSize: 9
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
43
hive/client/hive_client/qml/hive_client/MainPage.qml
Normal file
43
hive/client/hive_client/qml/hive_client/MainPage.qml
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
import QtQuick 2.0
|
||||||
|
import QtQuick.Controls 1.0
|
||||||
|
import QtQuick.Layouts 1.0
|
||||||
|
|
||||||
|
Component {
|
||||||
|
|
||||||
|
Rectangle{
|
||||||
|
anchors.fill: parent
|
||||||
|
|
||||||
|
Column{
|
||||||
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
anchors.top: parent.top
|
||||||
|
anchors.topMargin: 30
|
||||||
|
|
||||||
|
Rectangle{
|
||||||
|
id: addDeviceButton
|
||||||
|
width: 150
|
||||||
|
height: 70
|
||||||
|
color: "#c8c8c8"
|
||||||
|
border.color: "black"
|
||||||
|
radius: 10
|
||||||
|
Text{
|
||||||
|
anchors.centerIn: parent
|
||||||
|
text: "Add Device"
|
||||||
|
}
|
||||||
|
MouseArea{
|
||||||
|
id: addDeviceButtonMousArea
|
||||||
|
anchors.fill: parent
|
||||||
|
onPressed: addDeviceButton.color = "steelblue"
|
||||||
|
onReleased: addDeviceButton.color = "#c8c8c8"
|
||||||
|
onClicked: stackView.push(addDevicePage)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
@ -2,6 +2,8 @@ import QtQuick 2.0
|
|||||||
import QtQuick.Controls 1.0
|
import QtQuick.Controls 1.0
|
||||||
import QtQuick.Layouts 1.0
|
import QtQuick.Layouts 1.0
|
||||||
|
|
||||||
|
import hive 1.0
|
||||||
|
|
||||||
ApplicationWindow{
|
ApplicationWindow{
|
||||||
id: mainWindow
|
id: mainWindow
|
||||||
menuBar: MenuBar{
|
menuBar: MenuBar{
|
||||||
@ -13,6 +15,11 @@ ApplicationWindow{
|
|||||||
shortcut: "Ctrl+Q"
|
shortcut: "Ctrl+Q"
|
||||||
onTriggered: mainWindow.close()
|
onTriggered: mainWindow.close()
|
||||||
}
|
}
|
||||||
|
MenuItem {
|
||||||
|
text: "Disconnect"
|
||||||
|
shortcut: "Ctrl+D"
|
||||||
|
onTriggered: client.disconnectFromHost()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
statusBar: StatusBar {
|
statusBar: StatusBar {
|
||||||
@ -25,79 +32,41 @@ ApplicationWindow{
|
|||||||
width: 600
|
width: 600
|
||||||
height: 500
|
height: 500
|
||||||
|
|
||||||
|
StackView {
|
||||||
|
id: stackView
|
||||||
|
anchors.fill: parent
|
||||||
|
initialItem: connectionPage
|
||||||
|
}
|
||||||
|
|
||||||
GroupBox {
|
Connections{
|
||||||
id: connectionGroupBox
|
target: client
|
||||||
anchors.right: parent.right
|
onConnectionChanged:{
|
||||||
anchors.left: parent.left
|
print("connection changed",client.isConnected)
|
||||||
anchors.margins: 20
|
if(client.isConnected){
|
||||||
title: "Connection"
|
stackView.push(mainPage)
|
||||||
|
}else{
|
||||||
RowLayout{
|
stackView.clear()
|
||||||
anchors.fill: parent
|
stackView.push(connectionPage)
|
||||||
Button{
|
|
||||||
id: connectButton
|
|
||||||
text: "Connect"
|
|
||||||
onClicked: {
|
|
||||||
settings.setIPaddress(ipTextInput.text)
|
|
||||||
settings.setPort(portTextInput.text)
|
|
||||||
client.connectToHost(ipTextInput.text,portTextInput.text)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Text {
|
|
||||||
id: ipLable
|
|
||||||
text: "IP:"
|
|
||||||
horizontalAlignment: Text.AlignHCenter
|
|
||||||
}
|
|
||||||
TextField {
|
|
||||||
id: ipTextInput
|
|
||||||
text: "10.10.10.40"
|
|
||||||
horizontalAlignment: TextInput.AlignHCenter
|
|
||||||
font.pointSize: 9
|
|
||||||
}
|
|
||||||
Text {
|
|
||||||
id: portLable
|
|
||||||
text: "Port:"
|
|
||||||
wrapMode: Text.NoWrap
|
|
||||||
verticalAlignment: Text.AlignTop
|
|
||||||
horizontalAlignment: Text.AlignHCenter
|
|
||||||
}
|
|
||||||
TextField {
|
|
||||||
id: portTextInput
|
|
||||||
text: "1234"
|
|
||||||
horizontalAlignment: TextInput.AlignHCenter
|
|
||||||
font.pointSize: 9
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
TabView{
|
Settings{
|
||||||
id: tabView
|
id: settings
|
||||||
anchors.right: parent.right
|
|
||||||
anchors.rightMargin: 20
|
|
||||||
anchors.left: parent.left
|
|
||||||
anchors.leftMargin: 20
|
|
||||||
anchors.top: connectionGroupBox.bottom
|
|
||||||
anchors.bottom: statusBar.top
|
|
||||||
|
|
||||||
Tab{
|
|
||||||
id: actorTab
|
|
||||||
title: "Actor"
|
|
||||||
|
|
||||||
}
|
|
||||||
Tab{
|
|
||||||
id: sensorTab
|
|
||||||
title: "Sensor"
|
|
||||||
}
|
|
||||||
Tab{
|
|
||||||
id: ruleTab
|
|
||||||
title: "Rules"
|
|
||||||
}
|
|
||||||
Tab{
|
|
||||||
id: settingsTab
|
|
||||||
title: "Settings"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ConnectionPage{
|
||||||
|
id: connectionPage
|
||||||
|
}
|
||||||
|
|
||||||
|
MainPage{
|
||||||
|
id: mainPage
|
||||||
|
}
|
||||||
|
|
||||||
|
AddDevicePage{
|
||||||
|
id: addDevicePage
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -4,28 +4,31 @@
|
|||||||
Settings::Settings(QObject *parent) :
|
Settings::Settings(QObject *parent) :
|
||||||
QObject(parent)
|
QObject(parent)
|
||||||
{
|
{
|
||||||
m_settings = new QSettings(QString(),"hiveClient",this);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QString Settings::ipaddress()
|
QString Settings::ipaddress() const
|
||||||
{
|
{
|
||||||
return m_settings->value("server","10.10.10.40").toString();
|
QSettings settings("hive");
|
||||||
|
return settings.value("server","10.10.10.40").toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Settings::setIPaddress(QString ipaddress)
|
void Settings::setIPaddress(QString ipaddress)
|
||||||
{
|
{
|
||||||
m_settings->setValue("server",ipaddress);
|
QSettings settings("hive");
|
||||||
|
settings.setValue("server",ipaddress);
|
||||||
emit ipaddressChanged();
|
emit ipaddressChanged();
|
||||||
}
|
}
|
||||||
|
|
||||||
QString Settings::port()
|
int Settings::port() const
|
||||||
{
|
{
|
||||||
return m_settings->value("port","1234").toString();
|
QSettings settings("hive");
|
||||||
|
return settings.value("port","1234").toInt();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Settings::setPort(QString port)
|
void Settings::setPort(int port)
|
||||||
{
|
{
|
||||||
m_settings->setValue("port",port);
|
QSettings settings("hive");
|
||||||
|
settings.setValue("port",port);
|
||||||
emit ipaddressChanged();
|
emit ipaddressChanged();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -7,25 +7,26 @@
|
|||||||
class Settings : public QObject
|
class Settings : public QObject
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
Q_PROPERTY(QString ipaddress READ ipaddress WRITE setIPaddress NOTIFY ipaddressChanged)
|
||||||
|
Q_PROPERTY(int port READ port WRITE setPort NOTIFY portChanged)
|
||||||
|
|
||||||
public:
|
public:
|
||||||
explicit Settings(QObject *parent = 0);
|
explicit Settings(QObject *parent = 0);
|
||||||
|
|
||||||
|
QString ipaddress() const;
|
||||||
|
void setIPaddress(QString ipaddress);
|
||||||
|
|
||||||
|
int port() const;
|
||||||
|
void setPort(int port);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
QSettings* m_settings;
|
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void ipaddressChanged();
|
void ipaddressChanged();
|
||||||
void portChanged();
|
void portChanged();
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
QString ipaddress();
|
|
||||||
QString port();
|
|
||||||
|
|
||||||
void setIPaddress(QString ipaddress);
|
|
||||||
void setPort(QString port);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@ -6,10 +6,15 @@ Client::Client(QObject *parent) :
|
|||||||
QObject(parent)
|
QObject(parent)
|
||||||
{
|
{
|
||||||
m_tcpSocket = new QTcpSocket(this);
|
m_tcpSocket = new QTcpSocket(this);
|
||||||
|
m_connectionStatus = false;
|
||||||
connect(m_tcpSocket, SIGNAL(error(QAbstractSocket::SocketError)), this, SLOT(connectionError(QAbstractSocket::SocketError)));
|
connect(m_tcpSocket, SIGNAL(error(QAbstractSocket::SocketError)), this, SLOT(connectionError(QAbstractSocket::SocketError)));
|
||||||
connect(m_tcpSocket, SIGNAL(connected()),this, SLOT(connectedToHost()));
|
connect(m_tcpSocket, SIGNAL(connected()),this, SLOT(connected()));
|
||||||
|
connect(m_tcpSocket, SIGNAL(disconnected()),this, SLOT(disconneted()));
|
||||||
|
}
|
||||||
|
|
||||||
|
bool Client::isConnected()
|
||||||
|
{
|
||||||
|
return m_connectionStatus;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Client::connectionError(QAbstractSocket::SocketError error)
|
void Client::connectionError(QAbstractSocket::SocketError error)
|
||||||
@ -30,10 +35,18 @@ void Client::readData()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Client::connectedToHost()
|
void Client::connected()
|
||||||
{
|
{
|
||||||
qDebug() << "connected to hive server";
|
qDebug() << "connected to hive server";
|
||||||
emit connected();
|
m_connectionStatus = true;
|
||||||
|
emit connectionChanged();
|
||||||
|
}
|
||||||
|
|
||||||
|
void Client::disconneted()
|
||||||
|
{
|
||||||
|
qDebug() << "disconnect from hive server";
|
||||||
|
m_connectionStatus = false;
|
||||||
|
emit connectionChanged();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Client::connectToHost(QString ipAddress, QString port)
|
void Client::connectToHost(QString ipAddress, QString port)
|
||||||
|
|||||||
@ -8,26 +8,32 @@
|
|||||||
class Client : public QObject
|
class Client : public QObject
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
Q_PROPERTY(bool isConnected READ isConnected NOTIFY connectionChanged)
|
||||||
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
explicit Client(QObject *parent = 0);
|
explicit Client(QObject *parent = 0);
|
||||||
|
bool isConnected();
|
||||||
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
QTcpSocket *m_tcpSocket;
|
QTcpSocket *m_tcpSocket;
|
||||||
QString m_tcpBuffer;
|
QString m_tcpBuffer;
|
||||||
|
|
||||||
|
bool m_connectionStatus;
|
||||||
|
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void connected();
|
|
||||||
void jsonDataAvailable(const QByteArray &data);
|
void jsonDataAvailable(const QByteArray &data);
|
||||||
|
void connectionChanged();
|
||||||
|
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void connectionError(QAbstractSocket::SocketError error);
|
void connectionError(QAbstractSocket::SocketError error);
|
||||||
void readData();
|
void readData();
|
||||||
void connectedToHost();
|
void connected();
|
||||||
|
void disconneted();
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
void connectToHost(QString ipAddress, QString port);
|
void connectToHost(QString ipAddress, QString port);
|
||||||
void disconnectFromHost();
|
void disconnectFromHost();
|
||||||
|
|||||||
@ -20,8 +20,6 @@ public:
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
|
|||||||
@ -8,8 +8,7 @@ HiveCore::HiveCore(QObject *parent) :
|
|||||||
m_server = new Server(this);
|
m_server = new Server(this);
|
||||||
m_server->startServer();
|
m_server->startServer();
|
||||||
|
|
||||||
m_deviceManager = new DeviceManager(this);
|
//m_deviceManager = new DeviceManager(this);
|
||||||
m_deviceManager->getDevices();
|
|
||||||
|
|
||||||
m_jsonHandler = new JsonHandler(this);
|
m_jsonHandler = new JsonHandler(this);
|
||||||
|
|
||||||
|
|||||||
@ -18,7 +18,7 @@ private:
|
|||||||
Server *m_server;
|
Server *m_server;
|
||||||
//RadioReciver *m_reciver;
|
//RadioReciver *m_reciver;
|
||||||
//RadioSender *m_sender;
|
//RadioSender *m_sender;
|
||||||
//DeviceManager *m_deviceManager;
|
DeviceManager *m_deviceManager;
|
||||||
JsonHandler *m_jsonHandler;
|
JsonHandler *m_jsonHandler;
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
|
|||||||
Reference in New Issue
Block a user