Skip to content

Commit d66403e

Browse files
committed
Complete proximity search
1 parent 78e705d commit d66403e

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

src/ANT_private_defines.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
#define LOW_PRIORITY_SEARCH_TIMEOUT_LENGTH 0x02
4242
#define OPEN_CHANNEL_LENGTH 0x01
4343
#define OPEN_RX_SCAN_MODE_LENGTH 0x01
44+
#define PROXIMITY_SEARCH_LENGTH 0x02
4445
#define REQUEST_MESSAGE_LENGTH 0x02
4546
#define RESET_SYSTEM_LENGTH 0x01
4647
#define SEARCH_TIMEOUT_LENGTH 0x02

src/TX/Config/ANT_ProximitySearch.cpp

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,15 @@ uint8_t ProximitySearch::getSearchThreshold() {
3232
}
3333

3434
uint8_t ProximitySearch::getData(uint8_t pos) {
35-
// TODO
36-
return 0;
35+
if (pos == 0) {
36+
return _channel;
37+
} else {
38+
return _searchThreshold;
39+
}
3740
}
3841

3942
uint8_t ProximitySearch::getDataLength() {
40-
// TODO
41-
return 0;
43+
return PROXIMITY_SEARCH_LENGTH;
4244
}
4345

4446
#ifdef NATIVE_API_AVAILABLE

0 commit comments

Comments
 (0)