From 8f7bb40c889ac1f74cc0e11660011cf1ee2d7b15 Mon Sep 17 00:00:00 2001 From: Titta Heikkala Date: Thu, 2 Mar 2017 09:10:49 +0200 Subject: iot-sensortag: Reduce waiting time for service scan Unnecessary 1s delay to start service scan removed. If all service details have been discovered there's no need to start the 5s service details timer. Change-Id: I6c8c89455fb3cfdbc1a28198234e95a4ed0b7e8b Reviewed-by: Maurice Kalinowski --- tradeshow/iot-sensortag/bluetoothdataprovider.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'tradeshow/iot-sensortag/bluetoothdataprovider.cpp') diff --git a/tradeshow/iot-sensortag/bluetoothdataprovider.cpp b/tradeshow/iot-sensortag/bluetoothdataprovider.cpp index 0987d0d..06e9fd5 100644 --- a/tradeshow/iot-sensortag/bluetoothdataprovider.cpp +++ b/tradeshow/iot-sensortag/bluetoothdataprovider.cpp @@ -93,10 +93,7 @@ bool BluetoothDataProvider::startDataFetching() this, &BluetoothDataProvider::lightIntensityReceived); connect(m_btDevice, &BluetoothDevice::motionChanged, this, &BluetoothDataProvider::motionReceived); - timer.setInterval(1000); - timer.setSingleShot(true); - connect(&timer, &QTimer::timeout, this, &BluetoothDataProvider::startServiceScan); - timer.start(); + startServiceScan(); } return true; } -- cgit v1.2.3