replace Gap::addr_type_t with Gap::AddressType_t
This commit is contained in:
parent
192a19dc40
commit
a440201b9c
3 changed files with 7 additions and 7 deletions
|
@ -113,8 +113,8 @@ static void btle_handler(ble_evt_t *p_ble_evt)
|
|||
const ble_gap_addr_t *peer = &p_ble_evt->evt.gap_evt.params.connected.peer_addr;
|
||||
const ble_gap_addr_t *own = &p_ble_evt->evt.gap_evt.params.connected.own_addr;
|
||||
nRF51Gap::getInstance().processConnectionEvent(handle,
|
||||
static_cast<Gap::addr_type_t>(peer->addr_type), peer->addr,
|
||||
static_cast<Gap::addr_type_t>(own->addr_type), own->addr,
|
||||
static_cast<Gap::AddressType_t>(peer->addr_type), peer->addr,
|
||||
static_cast<Gap::AddressType_t>(own->addr_type), own->addr,
|
||||
params);
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -304,7 +304,7 @@ uint16_t nRF51Gap::getConnectionHandle(void)
|
|||
@endcode
|
||||
*/
|
||||
/**************************************************************************/
|
||||
ble_error_t nRF51Gap::setAddress(addr_type_t type, const address_t address)
|
||||
ble_error_t nRF51Gap::setAddress(AddressType_t type, const address_t address)
|
||||
{
|
||||
if (type > ADDR_TYPE_RANDOM_PRIVATE_NON_RESOLVABLE) {
|
||||
return BLE_ERROR_PARAM_OUT_OF_RANGE;
|
||||
|
@ -319,7 +319,7 @@ ble_error_t nRF51Gap::setAddress(addr_type_t type, const address_t address)
|
|||
return BLE_ERROR_NONE;
|
||||
}
|
||||
|
||||
ble_error_t nRF51Gap::getAddress(addr_type_t *typeP, address_t address)
|
||||
ble_error_t nRF51Gap::getAddress(AddressType_t *typeP, address_t address)
|
||||
{
|
||||
ble_gap_addr_t dev_addr;
|
||||
if (sd_ble_gap_address_get(&dev_addr) != NRF_SUCCESS) {
|
||||
|
@ -327,7 +327,7 @@ ble_error_t nRF51Gap::getAddress(addr_type_t *typeP, address_t address)
|
|||
}
|
||||
|
||||
if (typeP != NULL) {
|
||||
*typeP = static_cast<addr_type_t>(dev_addr.addr_type);
|
||||
*typeP = static_cast<AddressType_t>(dev_addr.addr_type);
|
||||
}
|
||||
if (address != NULL) {
|
||||
memcpy(address, dev_addr.addr, ADDR_LEN);
|
||||
|
|
|
@ -44,8 +44,8 @@ public:
|
|||
}
|
||||
|
||||
/* Functions that must be implemented from Gap */
|
||||
virtual ble_error_t setAddress(addr_type_t type, const address_t address);
|
||||
virtual ble_error_t getAddress(addr_type_t *typeP, address_t address);
|
||||
virtual ble_error_t setAddress(AddressType_t type, const address_t address);
|
||||
virtual ble_error_t getAddress(AddressType_t *typeP, address_t address);
|
||||
virtual ble_error_t setAdvertisingData(const GapAdvertisingData &, const GapAdvertisingData &);
|
||||
|
||||
virtual uint16_t getMinAdvertisingInterval(void) const {return ADVERTISEMENT_DURATION_UNITS_TO_MS(BLE_GAP_ADV_INTERVAL_MIN);}
|
||||
|
|
Loading…
Reference in a new issue