added debugging

Fork of BLE_nRF8001 by RedBearLab

Committer:
jn80842
Date:
Mon Nov 10 01:24:23 2014 +0000
Revision:
2:7805a5595aab
Parent:
0:075ea2812998
just added debugging

Who changed what in which revision?

UserRevisionLine numberNew contents of line
RedBearLab 0:075ea2812998 1 #ifndef _BLE_ATTRIBUTE_H_
RedBearLab 0:075ea2812998 2 #define _BLE_ATTRIBUTE_H_
RedBearLab 0:075ea2812998 3
RedBearLab 0:075ea2812998 4 enum BLEAttributeType {
RedBearLab 0:075ea2812998 5 BLETypeService = 0x2800,
RedBearLab 0:075ea2812998 6 BLETypeCharacteristic = 0x2803,
RedBearLab 0:075ea2812998 7 BLETypeDescriptor = 0x2900
RedBearLab 0:075ea2812998 8 };
RedBearLab 0:075ea2812998 9
RedBearLab 0:075ea2812998 10 #define BLE_ATTRIBUTE_MAX_VALUE_LENGTH 19
RedBearLab 0:075ea2812998 11
RedBearLab 0:075ea2812998 12 class BLEAttribute
RedBearLab 0:075ea2812998 13 {
RedBearLab 0:075ea2812998 14 public:
RedBearLab 0:075ea2812998 15 BLEAttribute(const char* uuid, enum BLEAttributeType type);
RedBearLab 0:075ea2812998 16 const char* uuid() const;
RedBearLab 0:075ea2812998 17
RedBearLab 0:075ea2812998 18 enum BLEAttributeType type() const;
RedBearLab 0:075ea2812998 19
RedBearLab 0:075ea2812998 20 protected:
RedBearLab 0:075ea2812998 21 static unsigned char numAttributes();
RedBearLab 0:075ea2812998 22
RedBearLab 0:075ea2812998 23 private:
RedBearLab 0:075ea2812998 24 static unsigned char _numAttributes;
RedBearLab 0:075ea2812998 25
RedBearLab 0:075ea2812998 26 const char* _uuid;
RedBearLab 0:075ea2812998 27 enum BLEAttributeType _type;
RedBearLab 0:075ea2812998 28 };
RedBearLab 0:075ea2812998 29
RedBearLab 0:075ea2812998 30 #endif