Plugin to Plugin
Your ATAK plugin can send and receive data over Somewear via the Somewear ATAK Plugin.
Messages
Outbound
Intent intent = new Intent("com.somewearlabs.tak.message.SEND");
intent.putExtra("content", "Test outbound message");
intent.putExtra("parcelId", 123);
AtakBroadcast.getInstance().sendBroadcast(intent);Outbound Status
public static final String SOMEWEAR_MESSAGE_OUTBOUND = "com.somewearlabs.tak.message.OUTBOUND";
override fun onReceive(context: Context, intent: Intent) {
switch (action) {
case HelloWorldDropDownReceiver.SOMEWEAR_MESSAGE_OUTBOUND: {
String status = intent.getStringExtra("status");
int parcelId = intent.getIntExtra("parcelId", 0);
if (status.equals("Delivered")) {
Log.d(TAG, "onReceive: did send Somewear message; parcelId=" + parcelId);
} else if (status.equals("Error") {
Log.d(TAG, "onReceive: Somewear message did timeout; parcelId=" + parcelId);
}
break;
}
}
}Inbound
Data
Outbound
Inbound
Last updated