Table of Contents

Class BluetoothLEAdvertisement

Namespace
nanoFramework.Device.Bluetooth.Advertisement
Assembly
nanoFramework.Device.Bluetooth.dll

A representation of a Bluetooth LE advertisement payload.

public class BluetoothLEAdvertisement
Inheritance
BluetoothLEAdvertisement
Inherited Members
Extension Methods

Constructors

BluetoothLEAdvertisement()

Creates a new BluetoothLEAdvertisement object.

public BluetoothLEAdvertisement()

Properties

DataSections

Gets the arrayList of raw _advertData sections.

public ArrayList DataSections { get; }

Property Value

ArrayList

Flags

Bluetooth LE advertisement flags. Defaults to ClassicNotSupported and GeneralDiscoverableMode.

public BluetoothLEAdvertisementFlags Flags { get; set; }

Property Value

BluetoothLEAdvertisementFlags

LocalName

The local name contained within the advertisement. This property can be either the shortened or complete local name defined by the Bluetooth LE specifications.

public string LocalName { get; set; }

Property Value

string

ManufacturerData

Gets the list of manufacturer-specific sections in a BluetoothLEAdvertisement.

public ArrayList ManufacturerData { get; }

Property Value

ArrayList

ServiceUuids

The array of service UUIDs in 128-bit GUID format. This property aggregates all the 16-bit, 32-bit and 128-bit service UUIDs into a single array.

public Guid[] ServiceUuids { get; }

Property Value

Guid[]

Methods

GetManufacturerDataByCompanyId(ushort)

Return a list of all manufacturer Data sections in the BluetoothLEAdvertisement payload matching the specified company id.

public ArrayList GetManufacturerDataByCompanyId(ushort companyId)

Parameters

companyId ushort

The company identifier code defined by the Bluetooth Special Interest Group (SIG).

Returns

ArrayList

A list of BluetoothLEManufacturerData by companyId.

GetSectionsByType(byte)

Returns a list of all the BluetoothLEAdvertisementDataSection matching the given advertisement type. This method returns an empty list if no such sections are found in the payload.

public ArrayList GetSectionsByType(byte type)

Parameters

type byte

The advertisement section type

Returns

ArrayList

BluetoothLEAdvertisementDataSection list of matching advertisement types. This method returns an empty list if no such sections are found in the payload.