aboutsummaryrefslogtreecommitdiff
path: root/ble/Bluetooth.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'ble/Bluetooth.cpp')
-rw-r--r--ble/Bluetooth.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/ble/Bluetooth.cpp b/ble/Bluetooth.cpp
index 66f97b7..b672dba 100644
--- a/ble/Bluetooth.cpp
+++ b/ble/Bluetooth.cpp
@@ -97,7 +97,7 @@ void AttPdu::makeWrite(ByteBuffer &req, uint16_t handle, const ByteBuffer &bytes
}
vector<AttributeData> AttPdu::parse(ByteBuffer &bytes, AttPduType type) {
- DF << "bytes: " << bytes.toString();
+ // cout << "bytes: " << bytes.toString();
AttPduType t = (AttPduType) bytes.read8();
@@ -114,15 +114,15 @@ vector<AttributeData> AttPdu::parse(ByteBuffer &bytes, AttPduType type) {
}
uint8_t length = bytes.read8();
- D << "length=" << (int) length;
+ // cout << "length=" << (int) length;
size_t count = (bytes.getSize() - 2) / length;
- D << "count=" << count;
+ // cout << "count=" << count;
vector<AttributeData> values;
for (int i = 0; i < count; i++) {
auto data = bytes.view(length);
- D << "data, size=" << data.getSize() << ", bytes=" << data.toString();
+ // cout << "data, size=" << data.getSize() << ", bytes=" << data.toString();
bytes.skip(length);
values.push_back(AttributeData::fromByteBuffer(data));
}
@@ -233,10 +233,10 @@ void shutdown() {
}
uuid_t makeUuid(const uuid_t base, uint8_t a, uint8_t b) {
- uuid_t copy = base;
- copy.data[2] = a;
- copy.data[3] = b;
- return copy;
+ uuid_t c = base;
+ c.data[2] = a;
+ c.data[3] = b;
+ return c;
}
}