aboutsummaryrefslogtreecommitdiff
path: root/Bluetooth.h
diff options
context:
space:
mode:
Diffstat (limited to 'Bluetooth.h')
-rw-r--r--Bluetooth.h21
1 files changed, 6 insertions, 15 deletions
diff --git a/Bluetooth.h b/Bluetooth.h
index 15ef171..7bc5bc3 100644
--- a/Bluetooth.h
+++ b/Bluetooth.h
@@ -5,20 +5,9 @@
#include <stdexcept>
// For now
-#include <boost/log/core.hpp>
-#include <boost/log/trivial.hpp>
-#include "ByteBuffer.h"
-
-#define D BOOST_LOG_TRIVIAL(debug)
-#define I BOOST_LOG_TRIVIAL(info)
-#define W BOOST_LOG_TRIVIAL(warning)
+#include "log.h"
-#define DF BOOST_LOG_TRIVIAL(debug) << __FUNCTION__ << ": "
-#define IF BOOST_LOG_TRIVIAL(info) << __FUNCTION__ << ": "
-#define WF BOOST_LOG_TRIVIAL(warning) << __FUNCTION__ << ": "
-
-#define UUID_PRIMARY_SERVICE 0x2800
-#define UUID_SECONDARY_SERVICE 0x2801
+#include "ByteBuffer.h"
namespace trygvis {
using namespace std;
@@ -91,9 +80,11 @@ namespace trygvis {
virtual ~BluetoothAdapter();
+ virtual void runScan(void (callback)(BluetoothDevice &device)) = 0;
+
virtual void stopScan() = 0;
- virtual void runScan(void (callback)(BluetoothDevice &device)) = 0;
+ virtual void startScan() = 0;
virtual BluetoothDevice &getDevice(Mac& mac) = 0;
};
@@ -128,7 +119,7 @@ namespace trygvis {
public:
~AttributeData();
- static AttributeData fromByteBuffer(ByteBuffer &value, uint8_t length);
+ static AttributeData fromByteBuffer(ByteBuffer &value);
const uint16_t handle;
const uint16_t groupEndHandle;