fix debug outputs in denon
This commit is contained in:
parent
7f3a373e3c
commit
3b715960e9
@ -388,7 +388,7 @@ DeviceManager::DeviceError DevicePlugin::displayPin(const PairingTransactionId &
|
||||
Q_UNUSED(pairingTransactionId)
|
||||
Q_UNUSED(deviceDescriptor)
|
||||
|
||||
qWarning() << "Plugin does not implement the display pin setup method.";
|
||||
qCWarning(dcDeviceManager) << "Plugin does not implement the display pin setup method.";
|
||||
|
||||
return DeviceManager::DeviceErrorNoError;
|
||||
}
|
||||
|
||||
@ -60,13 +60,13 @@ DeviceManager::DeviceSetupStatus DevicePluginDenon::setupDevice(Device *device)
|
||||
|
||||
// Check if we already have a denon device
|
||||
if (!myDevices().isEmpty()) {
|
||||
qCWarning(dcDenon()) << "Could not add denon device. Only one denon device allowed.";
|
||||
qCWarning(dcDenon) << "Could not add denon device. Only one denon device allowed.";
|
||||
return DeviceManager::DeviceSetupStatusFailure;
|
||||
}
|
||||
|
||||
QHostAddress address(device->paramValue("ip").toString());
|
||||
if (address.isNull()) {
|
||||
qCWarning(dcDenon()) << "Could not parse ip address" << device->paramValue("ip").toString();
|
||||
qCWarning(dcDenon) << "Could not parse ip address" << device->paramValue("ip").toString();
|
||||
return DeviceManager::DeviceSetupStatusFailure;
|
||||
}
|
||||
|
||||
@ -182,7 +182,7 @@ void DevicePluginDenon::onConnectionChanged()
|
||||
|
||||
void DevicePluginDenon::onDataReceived(const QByteArray &data)
|
||||
{
|
||||
qDebug(dcDenon) << "Data received" << data;
|
||||
qCDebug(dcDenon) << "Data received" << data;
|
||||
|
||||
// if there is no device, return
|
||||
if (m_device.isNull())
|
||||
@ -192,7 +192,7 @@ void DevicePluginDenon::onDataReceived(const QByteArray &data)
|
||||
int index = data.indexOf("MV");
|
||||
int vol = data.mid(index+2, 2).toInt();
|
||||
|
||||
qDebug(dcDenon) << "Update volume:" << vol;
|
||||
qCDebug(dcDenon) << "Update volume:" << vol;
|
||||
m_device->setStateValue(volumeStateTypeId, vol);
|
||||
}
|
||||
|
||||
@ -240,15 +240,15 @@ void DevicePluginDenon::onDataReceived(const QByteArray &data)
|
||||
cmd = "FVP";
|
||||
}
|
||||
|
||||
qDebug(dcDenon) << "Update channel:" << cmd;
|
||||
qCDebug(dcDenon) << "Update channel:" << cmd;
|
||||
m_device->setStateValue(channelStateTypeId, cmd);
|
||||
}
|
||||
|
||||
if (data.contains("PWON")) {
|
||||
qDebug(dcDenon) << "Update power on";
|
||||
qCDebug(dcDenon) << "Update power on";
|
||||
m_device->setStateValue(powerStateTypeId, true);
|
||||
} else if (data.contains("PWSTANDBY")) {
|
||||
qDebug(dcDenon) << "Update power off";
|
||||
qCDebug(dcDenon) << "Update power off";
|
||||
m_device->setStateValue(powerStateTypeId, false);
|
||||
}
|
||||
}
|
||||
|
||||
@ -335,7 +335,7 @@ void DevicePluginMock::emitPushButtonDevicesDiscovered()
|
||||
|
||||
m_pushbuttonPressed = false;
|
||||
QTimer::singleShot(3000, this, SLOT(onPushButtonPressed()));
|
||||
qDebug() << "Start PushButton timer (will be pressed in 3 second)";
|
||||
qCDebug(dcMockDevice) << "Start PushButton timer (will be pressed in 3 second)";
|
||||
}
|
||||
|
||||
void DevicePluginMock::emitDisplayPinDevicesDiscovered()
|
||||
|
||||
@ -130,6 +130,7 @@
|
||||
|
||||
|
||||
#include "httpreply.h"
|
||||
#include "loggingcategories.h"
|
||||
|
||||
#include <QDateTime>
|
||||
#include <QPair>
|
||||
@ -416,7 +417,7 @@ void HttpReply::startWait()
|
||||
|
||||
void HttpReply::timeout()
|
||||
{
|
||||
qDebug() << "Http reply timeout";
|
||||
qCDebug(dcWebServer) << "Http reply timeout";
|
||||
m_timedOut = true;
|
||||
emit finished();
|
||||
}
|
||||
|
||||
@ -216,7 +216,7 @@ void HttpRequest::validate()
|
||||
|
||||
// check User-Agent
|
||||
if (!m_rawHeaderList.contains("User-Agent"))
|
||||
qWarning() << "User-Agent header is missing";
|
||||
qCWarning(dcWebServer) << "User-Agent header is missing";
|
||||
|
||||
|
||||
// verify content length with actual payload
|
||||
|
||||
Reference in New Issue
Block a user