Commit 1c303eb5 authored by Pierre TILAK's avatar Pierre TILAK

Add Bluetooth and Serial to outcoming logs

parent e51aeaef
...@@ -78,6 +78,7 @@ void BluetoothLink::_writeBytes(const QByteArray bytes) ...@@ -78,6 +78,7 @@ void BluetoothLink::_writeBytes(const QByteArray bytes)
{ {
if (_targetSocket) { if (_targetSocket) {
if(_targetSocket->write(bytes) > 0) { if(_targetSocket->write(bytes) > 0) {
emit bytesSent(this, data);
_logOutputDataRate(bytes.size(), QDateTime::currentMSecsSinceEpoch()); _logOutputDataRate(bytes.size(), QDateTime::currentMSecsSinceEpoch());
} else { } else {
qWarning() << "Bluetooth write error"; qWarning() << "Bluetooth write error";
......
...@@ -84,6 +84,7 @@ bool SerialLink::_isBootloader() ...@@ -84,6 +84,7 @@ bool SerialLink::_isBootloader()
void SerialLink::_writeBytes(const QByteArray data) void SerialLink::_writeBytes(const QByteArray data)
{ {
if(_port && _port->isOpen()) { if(_port && _port->isOpen()) {
emit bytesSent(this, data);
_logOutputDataRate(data.size(), QDateTime::currentMSecsSinceEpoch()); _logOutputDataRate(data.size(), QDateTime::currentMSecsSinceEpoch());
_port->write(data); _port->write(data);
} else { } else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment