Skip to content

Most visited

Recently visited

navigation

LowpanBeaconInfo

LowpanBeaconInfo

public class LowpanBeaconInfo
extends Object

java.lang.Object
   ↳ com.google.android.things.lowpan.LowpanBeaconInfo


Describes a LoWPAN Beacon.

LowpanBeaconInfo objects are emitted by the LowpanScanner class when performing a network scan. They contain a LowpanIdentity object along with the originating hardware address, RSSI, and (if available) LQI of the received network beacon.

See also:

Summary

Constants

int FLAG_CAN_ASSIST

Indicates if the device which sent this beacon can assist with commissioning a device onto the LoWPAN.

Public methods

boolean equals(Object rhs)
byte[] getBeaconAddress()

Returns a copy of the beacon address associated with this beacon.

Collection<Integer> getFlags()

Returns a collection of integers representing any flags associated with this beacon.

LowpanIdentity getLowpanIdentity()

Returns the LowpanIdentity object associated with this beacon.

int getLqi()

Returns the Link Quality Index (LQI) of the beacon.

int getRssi()

Returns the RSSI of the beacon, measured in dBm.

int hashCode()
boolean isFlagSet(int flag)

Test for determining if a specific flag is set on this beacon.

String toString()

Inherited methods

From class java.lang.Object

Constants

FLAG_CAN_ASSIST

int FLAG_CAN_ASSIST

Indicates if the device which sent this beacon can assist with commissioning a device onto the LoWPAN.

Constant Value: 1 (0x00000001)

Public methods

equals

boolean equals (Object rhs)

Parameters
rhs Object
Returns
boolean

getBeaconAddress

byte[] getBeaconAddress ()

Returns a copy of the beacon address associated with this beacon.

Returns
byte[]

getFlags

Collection<Integer> getFlags ()

Returns a collection of integers representing any flags associated with this beacon.

Returns
Collection<Integer>

getLowpanIdentity

LowpanIdentity getLowpanIdentity ()

Returns the LowpanIdentity object associated with this beacon.

Returns
LowpanIdentity

getLqi

int getLqi ()

Returns the Link Quality Index (LQI) of the beacon.

The returned value ranges between 0 and 255:

  • A value of 0 indicates that the LQI was not set.
  • A value of 1 indicates the worst possible quality where the decoded beacon is still valid.
  • A value of 255 indicates the best possible quality that can be recognized by the radio hardware.
  • Values 2-254 are intended to represent relative quality levels evenly distributed between the worst and best, with lower values always indicating a worse quality than higher values.

Returns
int

getRssi

int getRssi ()

Returns the RSSI of the beacon, measured in dBm.

Returns
int

hashCode

int hashCode ()

Returns
int

isFlagSet

boolean isFlagSet (int flag)

Test for determining if a specific flag is set on this beacon.

Parameters
flag int
Returns
boolean

toString

String toString ()

Returns
String
This site uses cookies to store your preferences for site-specific language and display options.

Get the latest Android developer news and tips that will help you find success on Google Play.

* Required Fields

Hooray!

Follow Google Developers on WeChat

Browse this site in ?

You requested a page in , but your language preference for this site is .

Would you like to change your language preference and browse this site in ? If you want to change your language preference later, use the language menu at the bottom of each page.

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.

Take a short survey?
Help us improve the Android developer experience. (April 2018 — Developer Survey)