hw

Files at this revision

API Documentation at this revision

Comitter:
b05901043
Date:
Thu Apr 30 15:08:01 2020 +0000
Parent:
1:b07c6505284b
Commit message:
debug devise info

Changed in this revision

source/main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/source/main.cpp	Thu Apr 23 08:43:44 2020 +0000
+++ b/source/main.cpp	Thu Apr 30 15:08:01 2020 +0000
@@ -37,9 +37,9 @@
         _hr_counter(100),
         _bt_service(ble, 25),
         _hr_service(ble, _hr_counter, HeartRateService::LOCATION_FINGER),
-        _deviceInfo(ble, "ST", "Nucleo", "SN1" ),
+        _deviceInfo(ble, "ST", "Nucleo", "SN1", "", "", ""),
         _adv_data_builder(_adv_buffer) { 
-            _uuid_list = new UUID(3);
+            _uuid_list = new UUID[3];
             _uuid_list[0] = GattService::UUID_HEART_RATE_SERVICE;
             _uuid_list[1] = GattService::UUID_BATTERY_SERVICE;
             _uuid_list[2] = GattService::UUID_DEVICE_INFORMATION_SERVICE;
@@ -84,6 +84,8 @@
         _adv_data_builder.setAppearance(ble::adv_data_appearance_t::GENERIC_HEART_RATE_SENSOR);
         _adv_data_builder.setLocalServiceList(mbed::make_Span(_uuid_list, 3));
         _adv_data_builder.setName(DEVICE_NAME);
+        
+        //_ble.gap().accumulateAdvertisingPayload(GapAdvertisingData::COMPLETE_LOCAL_NAME, (uint8_t *)DEVICE_NAME, sizeof(DEVICE_NAME));
 
         /* Setup advertising */