From 3eda3f6fc32a45744d0e4216a83908ba203b9f69 Mon Sep 17 00:00:00 2001 From: Rohit Grover Date: Mon, 10 Nov 2014 14:46:52 +0000 Subject: [PATCH] GAP_ADV_PARAMS_INTERVAL_MAX and other such constants have moved into GapAdvertisingParams --- nRF51Gap.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/nRF51Gap.cpp b/nRF51Gap.cpp index 91c1aef..f4e68d0 100644 --- a/nRF51Gap.cpp +++ b/nRF51Gap.cpp @@ -134,13 +134,13 @@ ble_error_t nRF51Gap::startAdvertising(const GapAdvertisingParams ¶ms) /* Check interval range */ if (params.getAdvertisingType() == GapAdvertisingParams::ADV_NON_CONNECTABLE_UNDIRECTED) { /* Min delay is slightly longer for unconnectable devices */ - if ((params.getInterval() < GAP_ADV_PARAMS_INTERVAL_MIN_NONCON) || - (params.getInterval() > GAP_ADV_PARAMS_INTERVAL_MAX)) { + if ((params.getInterval() < GapAdvertisingParams::GAP_ADV_PARAMS_INTERVAL_MIN_NONCON) || + (params.getInterval() > GapAdvertisingParams::GAP_ADV_PARAMS_INTERVAL_MAX)) { return BLE_ERROR_PARAM_OUT_OF_RANGE; } } else { - if ((params.getInterval() < GAP_ADV_PARAMS_INTERVAL_MIN) || - (params.getInterval() > GAP_ADV_PARAMS_INTERVAL_MAX)) { + if ((params.getInterval() < GapAdvertisingParams::GAP_ADV_PARAMS_INTERVAL_MIN) || + (params.getInterval() > GapAdvertisingParams::GAP_ADV_PARAMS_INTERVAL_MAX)) { return BLE_ERROR_PARAM_OUT_OF_RANGE; } } @@ -154,7 +154,7 @@ ble_error_t nRF51Gap::startAdvertising(const GapAdvertisingParams ¶ms) /* Check timeout for other advertising types */ if ((params.getAdvertisingType() != GapAdvertisingParams::ADV_CONNECTABLE_DIRECTED) && - (params.getTimeout() > GAP_ADV_PARAMS_TIMEOUT_MAX)) { + (params.getTimeout() > GapAdvertisingParams::GAP_ADV_PARAMS_TIMEOUT_MAX)) { return BLE_ERROR_PARAM_OUT_OF_RANGE; }