amiro-os / include / amiro / bluetooth / bluetooth-descriptor.hpp @ 0f37fb41
History | View | Annotate | Download (752 Bytes)
1 |
#ifndef _BLUETOOTH_DESCRIPTOR_H_
|
---|---|
2 |
#define _BLUETOOTH_DESCRIPTOR_H_
|
3 |
|
4 |
#include <string.h> |
5 |
|
6 |
#define BLUETOOTH_DESCRIPTOR_BUFFER_SIZE 64 |
7 |
|
8 |
namespace amiro {
|
9 |
|
10 |
class BluetoothDescriptor { |
11 |
|
12 |
public:
|
13 |
BluetoothDescriptor(); |
14 |
|
15 |
void bluetoothDescriptorSetLinkId(uint8_t linkId);
|
16 |
void bluetoothDescriptorSetPayloadLength(size_t length);
|
17 |
|
18 |
uint8_t bluetoothDescriptorGetLinkId(); |
19 |
size_t bluetoothDescriptorGetBufferLength(); |
20 |
size_t bluetoothDescriptorGetPayloadLength(); |
21 |
|
22 |
uint8_t *bluetoothDescriptorGetBuffer(); |
23 |
uint8_t *bluetoothDescriptorGetPayload(); |
24 |
|
25 |
private:
|
26 |
// unsigned char flags;
|
27 |
uint8_t linkId; |
28 |
size_t length; |
29 |
uint8_t buffer[BLUETOOTH_DESCRIPTOR_BUFFER_SIZE]; |
30 |
|
31 |
}; |
32 |
} |
33 |
|
34 |
#endif /* _BLUETOOTH_DESCRIPTOR_H_ */ |