From 44a5d88dc9daf70cc285695f5031f3bad6dd32b0 Mon Sep 17 00:00:00 2001 From: Abhay Agarwal Date: Tue, 12 Jan 2021 11:25:26 +0530 Subject: [PATCH] Add API to set detection window Change-Id: I5eccfb05c4d72bc0d25456cb71b954ed6207153e Signed-off-by: Abhay Agarwal --- src/wifi-location-plugin.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/wifi-location-plugin.c b/src/wifi-location-plugin.c index 5e9193a..15823c4 100755 --- a/src/wifi-location-plugin.c +++ b/src/wifi-location-plugin.c @@ -249,6 +249,18 @@ done: return ret; } +static int set_detection_window(unsigned int detection_window) +{ + FUNC_ENTER; + + retv_if(NULL == uas_cbs, UAS_STATUS_NOT_READY); + + wifi_location_detection_window = detection_window; + + FUNC_EXIT; + return UAS_STATUS_SUCCESS; +} + static uas_api_t wifi_location_api = { .init = init, .deinit = deinit, @@ -260,7 +272,7 @@ static uas_api_t wifi_location_api = { .start_detection = start_detection, .stop_detection = stop_detection, .set_low_power_mode = NULL, - .set_detection_window = NULL, + .set_detection_window = set_detection_window, .set_detection_threshold = NULL, .scan_active_devices = NULL, .cancel_active_device_scan = NULL, -- 2.7.4