MouseScroll example from BLE_HID
Dependencies: BLE_API BLE_HID mbed nRF51822
This example is currently copied as-is from the github development repo.
Revision 4:8fb54802ba2b, committed 2016-04-03
- Comitter:
- Jean-Philippe Brucker
- Date:
- Sun Apr 03 22:06:47 2016 +0100
- Parent:
- 3:acfb913bff6b
- Commit message:
- v0.4 - small change to enable Win10 support
Changed in this revision
mouse_scroll.cpp | Show annotated file Show diff for this revision Revisions of this file |
version | Show annotated file Show diff for this revision Revisions of this file |
--- a/mouse_scroll.cpp Thu Nov 19 15:17:41 2015 +0000 +++ b/mouse_scroll.cpp Sun Apr 03 22:06:47 2016 +0100 @@ -108,9 +108,11 @@ HID_DEBUG("setting up gap\r\n"); ble.gap().accumulateAdvertisingPayload(GapAdvertisingData::MOUSE); ble.gap().accumulateAdvertisingPayload(GapAdvertisingData::COMPLETE_LOCAL_NAME, - (uint8_t *)DEVICE_NAME, sizeof(DEVICE_NAME)); + (const uint8_t *)DEVICE_NAME, sizeof(DEVICE_NAME)); ble.gap().accumulateAdvertisingPayload(GapAdvertisingData::SHORTENED_LOCAL_NAME, - (uint8_t *)SHORT_DEVICE_NAME, sizeof(SHORT_DEVICE_NAME)); + (const uint8_t *)SHORT_DEVICE_NAME, sizeof(SHORT_DEVICE_NAME)); + + ble.gap().setDeviceName((const uint8_t *)DEVICE_NAME); HID_DEBUG("advertising\r\n"); ble.gap().startAdvertising();
--- a/version Thu Nov 19 15:17:41 2015 +0000 +++ b/version Sun Apr 03 22:06:47 2016 +0100 @@ -1,1 +1,1 @@ -0.3 +0.4