It is the Nordic nRF8001 BLE library for RedBearLab BLE Shield v2.1 or above. It is compatible with the platforms those soldered Arduino compatible form factor. The library is ported to mbed from Sandeep's arduino-BLEPeripheral library for Arduino: https://github.com/sandeepmistry/arduino-BLEPeripheral. We have tested it on KL05, KL25, MK20 and SeeedStudio Arch platforms and it works well.

Dependents:   nRF8001_SimpleChat nRF8001_SimpleControls mbed_BLE2 mbed_BLEtry2 ... more

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers BLEDescriptor.h Source File

BLEDescriptor.h

00001 #ifndef _BLE_DESCRIPTOR_H_
00002 #define _BLE_DESCRIPTOR_H_
00003 
00004 #include "BLEAttribute.h"
00005 
00006 class BLEDescriptor : public BLEAttribute
00007 {
00008   public:
00009     BLEDescriptor(const char* uuid, unsigned char valueSize);
00010     BLEDescriptor(const char* uuid, const char* value);
00011 
00012     virtual ~BLEDescriptor();
00013 
00014     unsigned char valueSize() const;
00015     const unsigned char* value() const;
00016     unsigned char valueLength() const;
00017 
00018     void setValue(const unsigned char value[], unsigned char length);
00019     void setValue(const char* value);
00020 
00021   private:
00022     const char*     _uuid;
00023     unsigned char   _valueSize;
00024     unsigned char*  _value;
00025     unsigned char   _valueLength;
00026 };
00027 
00028 #endif