BLE: refactor parameters order of Gap::startAdvertising

pull/8738/head
Vincent Coubard 2018-11-10 21:29:09 +00:00
parent d6d1ea5c2a
commit 06b3ccd322
3 changed files with 10 additions and 8 deletions

View File

@ -1736,9 +1736,10 @@ public:
virtual ble_error_t startAdvertising(
AdvHandle_t handle,
uint8_t maxEvents = 0,
uint32_t maxDuration = 0
) {
uint32_t maxDuration = 0,
uint8_t maxEvents = 0
)
{
(void) maxEvents;
(void) maxDuration;
/* Requesting action from porter(s): override this API if this capability is supported. */

View File

@ -106,8 +106,8 @@ public:
ble_error_t startAdvertising(
AdvHandle_t handle,
uint8_t maxEvents = 0,
uint32_t maxDuration = 0
uint32_t maxDuration,
uint8_t maxEvents
);
ble_error_t stopAdvertising(AdvHandle_t handle);

View File

@ -1816,9 +1816,10 @@ ble_error_t GenericGap::setAdvertisingData(
ble_error_t GenericGap::startAdvertising(
AdvHandle_t handle,
uint8_t maxEvents,
uint32_t maxDuration
) {
uint32_t maxDuration,
uint8_t maxEvents
)
{
if (!_existing_sets.get(handle)) {
return BLE_ERROR_INVALID_PARAM;
}