[BLE] Simplify the publication of advertisement data (#1408)
With only one control that enables the publication of all the advertisement data, default: false Note that if the sensor is not recognized, we will no longer publish its advertisement data unless the control is true. This is for the sake of traffic reduction.
This commit is contained in:
1 parent
27b568e4f9
commit
a3603c6a78
5 files changed
+41
-85
No files matched your search
+3
-23
@@ -112,24 +112,8 @@ extern int btQueueLengthCount;
|
||||
|
||||
unsigned long scanCount = 0;
|
||||
|
||||
#ifndef pubKnownBLEServiceData
|
||||
# define pubKnownBLEServiceData false // define true if you want to publish service data belonging to recognised sensors
|
||||
#endif
|
||||
|
||||
#ifndef pubUnknownBLEServiceData
|
||||
# define pubUnknownBLEServiceData true // define false if you don't want to publish service data to unrecognised sensors (in case you are having too heavy service data) https://github.com/1technophile/OpenMQTTGateway/issues/318#issuecomment-446064707
|
||||
#endif
|
||||
|
||||
#ifndef pubBLEManufacturerData
|
||||
# define pubBLEManufacturerData false // define true if you want to publish the manufacturer's data (sometimes contains characters that aren't valid with receiving client)
|
||||
#endif
|
||||
|
||||
#ifndef pubUnknownBLEManufacturerData
|
||||
# define pubUnknownBLEManufacturerData true // define true if you want to publish the manufacturer's data (sometimes contains characters that aren't valid with receiving client)
|
||||
#endif
|
||||
|
||||
#ifndef pubBLEServiceUUID
|
||||
# define pubBLEServiceUUID false // define true if you want to publish the service UUID data
|
||||
#ifndef pubBLEAdvData
|
||||
# define pubBLEAdvData false // define true if you want to publish all advertisement data
|
||||
#endif
|
||||
|
||||
#ifndef useBeaconUuidForTopic
|
||||
@@ -157,11 +141,7 @@ struct BTConfig_s {
|
||||
bool extDecoderEnable; // Send undecoded device data to another gateway device for decoding
|
||||
String extDecoderTopic; // Topic to send undecoded device data on
|
||||
bool filterConnectable; // Sets whether to filter publishing of scanned devices that require a connection.
|
||||
bool pubKnownServiceData; // Publish service data belonging to recognised sensors
|
||||
bool pubUnknownServiceData; // Publish service data belonging to unrecognised sensors (in case you are having too heavy service data) https://github.com/1technophile/OpenMQTTGateway/issues/318#issuecomment-446064707
|
||||
bool pubKnownManufData; // Publish the manufacturer's data (sometimes contains characters that aren't valid with receiving client)
|
||||
bool pubUnknownManufData; // Publish the manufacturer's data (sometimes contains characters that aren't valid with receiving client)
|
||||
bool pubServiceDataUUID; // Publish the service UUID data
|
||||
bool pubAdvData; // Publish advertisement data
|
||||
bool pubBeaconUuidForTopic; // Use iBeacon UUID as topic, instead of sender (random) MAC address
|
||||
bool ignoreWBlist; // Disable Whitelist & Blacklist
|
||||
};
|
||||
|
||||
Reference in new issue
Block a user