18#ifndef NIMBLE_CPP_BEACON_H_
19#define NIMBLE_CPP_BEACON_H_
22#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_BT_NIMBLE_ROLE_BROADCASTER)
36 uint16_t manufacturerId{0x4c00};
37 uint8_t subType{0x02};
38 uint8_t subTypeLength{0x15};
39 uint8_t proximityUUID[16]{};
43 } __attribute__((packed));
51 void setData(
const uint8_t* data, uint8_t length);
52 void setData(
const BeaconData& data);
60 BeaconData m_beaconData;
Representation of a beacon. See:
Definition NimBLEBeacon.h:33
void setManufacturerId(uint16_t manufacturerId)
Set the manufacturer ID.
Definition NimBLEBeacon.cpp:110
void setMinor(uint16_t minor)
Set the minor value.
Definition NimBLEBeacon.cpp:118
uint16_t getMinor()
Get the minor value being advertised.
Definition NimBLEBeacon.cpp:57
int8_t getSignalPower()
Get the signal power being advertised.
Definition NimBLEBeacon.cpp:73
void setProximityUUID(const NimBLEUUID &uuid)
Set the proximity UUID.
Definition NimBLEBeacon.cpp:126
uint16_t getManufacturerId()
Get the manufacturer ID being advertised.
Definition NimBLEBeacon.cpp:49
const BeaconData & getData()
Retrieve the data that is being advertised.
Definition NimBLEBeacon.cpp:33
NimBLEUUID getProximityUUID()
Get the proximity UUID being advertised.
Definition NimBLEBeacon.cpp:65
uint16_t getMajor()
Get the major value being advertised.
Definition NimBLEBeacon.cpp:41
void setData(const uint8_t *data, uint8_t length)
Set the beacon data.
Definition NimBLEBeacon.cpp:82
void setMajor(uint16_t major)
Set the major value.
Definition NimBLEBeacon.cpp:102
void setSignalPower(int8_t signalPower)
Set the signal power.
Definition NimBLEBeacon.cpp:137
A model of a BLE UUID.
Definition NimBLEUUID.h:41