mirror of
https://github.com/h2zero/esp-nimble-cpp.git
synced 2024-11-24 14:10:55 +01:00
Add access to the adv type of remote device
Adds new method `uint8_t NimBLEAdvertisedDevice::getAdvType()` to get the advertisement type of the found device.
This commit is contained in:
parent
c5c9423893
commit
5667c97efe
3 changed files with 13 additions and 0 deletions
|
@ -62,6 +62,16 @@ NimBLEAddress NimBLEAdvertisedDevice::getAddress() {
|
||||||
} // getAddress
|
} // getAddress
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @brief Get the advertised type.
|
||||||
|
*
|
||||||
|
* @return The advertised type of the advertised device.
|
||||||
|
*/
|
||||||
|
uint8_t NimBLEAdvertisedDevice::getAdvType() {
|
||||||
|
return m_advType;
|
||||||
|
} // getAddress
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Get the appearance.
|
* @brief Get the appearance.
|
||||||
*
|
*
|
||||||
|
|
|
@ -42,6 +42,7 @@ public:
|
||||||
NimBLEAdvertisedDevice();
|
NimBLEAdvertisedDevice();
|
||||||
|
|
||||||
NimBLEAddress getAddress();
|
NimBLEAddress getAddress();
|
||||||
|
uint8_t getAdvType();
|
||||||
uint16_t getAppearance();
|
uint16_t getAppearance();
|
||||||
std::string getManufacturerData();
|
std::string getManufacturerData();
|
||||||
std::string getName();
|
std::string getName();
|
||||||
|
|
|
@ -115,7 +115,9 @@
|
||||||
#define CONFIG_BT_NIMBLE_L2CAP_COC_MAX_NUM 0
|
#define CONFIG_BT_NIMBLE_L2CAP_COC_MAX_NUM 0
|
||||||
|
|
||||||
/** Do not comment out */
|
/** Do not comment out */
|
||||||
|
#ifndef CONFIG_BT_ENABLED
|
||||||
#define CONFIG_BT_ENABLED
|
#define CONFIG_BT_ENABLED
|
||||||
|
#endif
|
||||||
#define CONFIG_BTDM_CONTROLLER_MODE_BLE_ONLY
|
#define CONFIG_BTDM_CONTROLLER_MODE_BLE_ONLY
|
||||||
#define CONFIG_BT_NIMBLE_MEM_ALLOC_MODE_INTERNAL
|
#define CONFIG_BT_NIMBLE_MEM_ALLOC_MODE_INTERNAL
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue