LowpanDriverCallback

public class LowpanDriverCallback
extends Object

java.lang.Object
   ↳ com.google.android.things.userdriver.lowpan.LowpanDriverCallback


Callback interface for LowpanDriver.

An instance of this class is passed to the LowpanDriver instance via start(LowpanDriverCallback). It is used by the driver and not subclassed.

Summary

Public methods

void onError(int error)

Called by @{link LowpanDriver} instance when an error has been detected.

void onReceiveFrame(byte[] frame)

Called by @{link LowpanDriver} instance whenever a Spinel frame is received from the NCP.

void onReset()

Called by @{link LowpanDriver} instance when the driver has detected a NCP reset.

void onStarted()

Called by @{link LowpanDriver} instance when the driver has opened and is ready to transport frames.

Inherited methods

From class java.lang.Object

Public methods

onError

void onError (int error)

Called by @{link LowpanDriver} instance when an error has been detected.

Parameters
error int

onReceiveFrame

void onReceiveFrame (byte[] frame)

Called by @{link LowpanDriver} instance whenever a Spinel frame is received from the NCP.

Parameters
frame byte: Frame received from NCP.

onReset

void onReset ()

Called by @{link LowpanDriver} instance when the driver has detected a NCP reset.

onStarted

void onStarted ()

Called by @{link LowpanDriver} instance when the driver has opened and is ready to transport frames.