Button initiated config service
Dependencies: BLE_API_EddystoneConfigService_2 mbed nRF51822
Fork of BLE_EddystoneBeaconConfigService_3 by
Diff: main.cpp
- Revision:
- 18:91c36071aafb
- Parent:
- 16:a7d07ea94b31
- Child:
- 19:f7c33fa88ca5
diff -r 0458759c40e4 -r 91c36071aafb main.cpp --- a/main.cpp Wed Jul 22 21:28:09 2015 +0000 +++ b/main.cpp Thu Jul 23 06:02:45 2015 +0000 @@ -23,6 +23,7 @@ BLE ble; ZipBeaconConfigService *zipBeaconConfig; +Ticker test; //InterruptIn button(p17); /** @@ -40,9 +41,9 @@ // // Have to use this to add a interrupt, because C++ is stupid. // -//void stupidWrapperFn(){ -// zipBeaconConfig->radioNotificationCallback(); -// } +void stupidWrapperFn(){ + zipBeaconConfig->radioNotificationCallback(false); + } /** * Stop advertising the UriBeaconConfig Service after a delay; and switch to normal URIBeacon. @@ -57,6 +58,7 @@ configAdvertisementTimeoutTicker.detach(); /* disable the callback from the timeout Ticker. */ printf("removing config service\r\n"); + test.attach(stupidWrapperFn,1); } }