DataAdvertising by MANUFACTURER_SPECIFIC_DATA
Dependents: LinkNode_DataAdvertising LinkNode_DataAdvertising1
Fork of TMP_nrf51 by
Diff: Sensors.cpp
- Revision:
- 5:29171beb6b8c
- Parent:
- 4:ee98296289d0
--- a/Sensors.cpp Mon Feb 22 08:55:19 2016 +0000 +++ b/Sensors.cpp Wed Apr 06 08:57:47 2016 +0000 @@ -1,17 +1,17 @@ #include "Sensors.h" -Ticker ticker1; +InterruptIn btn(P0_28); uint64_t p_temp; -uint64_t data_1; +uint64_t data_1=0; void add_data(void) { - data_1 =0x123456789abcdef ; + data_1 = ~data_1; } Sensors::tmpSensorValue_t Sensors::get() { - ticker1.attach(add_data,1); + btn.rise(&add_data); p_temp = data_1; return p_temp; }