Integrate Android SDK
ubudu SDK for Android is a simple package for all ubudu's core
services, including Contextual Interactions Rules, Indoor Location,
The Mesh part of the SDK allows mobile devices to establish a connection to a mesh network and to send messages through it.
Full SDK and developer documentation is on ubudu's Github repository.
Once you have installed the ubudu SDK for Android, you need to follow this :
The UbuduSDK instance provides method to obtain the mesh
UbuduMeshManager meshManager = sdk.getMeshManager().
Note that mesh manager class doesn't inheritate from
com.ubudu.sdk.UbuduAreaManager like Beacon or Geofence manager.
To start using mesh
UbuduMeshManager must be
started. It may be done by calling:
start() method starts searching for connectable,
mesh enabled beacons.
To stop mesh manager and prevent searching for mesh beacons call
Mesh is super easy to use. Just call:
public void sendMeshMessage(String meshMessage, Integer
meshId, String networkUUID);
MeshMessage is a string with mesh message to be send. It should be no longer than 16 bytes.
meshId is the device address in dec format. Should be between 1-32767.
networkUUID String with UUID of the mesh network UUID.
meshIdshould be part of the network.
UbuduMeshDelegate interface must be implemented to
get feedback from mesh manager. At the moment receiving status is
possible by method:
public void onSendMeshMessage(int
status);. This method is called by mesh manager after
sending a message. status values can be:
MESH_MESSAGE_STATUS_OK = 0; // Message sent with success MESH_MESSAGE_STATUS_FAIL = 1; // Sending message failed - other reason MESH_MESSAGE_STATUS_FAIL_TIMEOUT = 2; // Sending message failed because of timeout MESH_MESSAGE_STATUS_FAIL_NO_MESH = 3; // Sending message failed because of missing Mesh service MESH_MESSAGE_STATUS_NO_MESH_NODE = 4; // Sending message failed because of no nearby mesh connectable node MESH_MESSAGE_STATUS_TOO_LONG = 5; // Sending message failed because of too long message
UbuduMeshDelegate allows you to be notified about
number of nearby availble mesh connectable nodes by
To learn everything about your project configuration, follow this link to the ubudu Android SDK on Github.