[JdeRobot] ICE Server in Android
s.rey
samuel.rey.escudero at gmail.com
Mon Sep 26 10:15:44 CEST 2016
Hello,
I am working on an Android app that get the GPS data and uses ICE for create
a server sow others applications can get the data. I do this in a separate
thread so it does not block the UI:
private void connectIce(){
Log.d("GPS", "CONNECTING ICE");
final Ice.Object object = new GpsI(mLocationManager, this);
Log.d("GPS", "OBJECT CREATED");
new Thread(new Runnable() {
@Override
public void run() {
try {
ic = Ice.Util.initialize();
Log.d("GPS", "IC INITIALIZED");
mAdapter = ic.createObjectAdapterWithEndpoints("GPS",
"default -h 0.0.0.0 -p 10001");
mAdapter = ic.createObjectAdapter("GPS");
Log.d("GPS", "ENDPOINT CONNECTED");
mAdapter.add(object, ic.stringToIdentity("GPS"));
Log.d("GPS", "ICE CONNECTED");
mAdapter.activate();
ic.waitForShutdown();
} catch (Exception e) {
Log.e("ERROR", "HEMOS TENIDO UN ERROR!!");
Log.e("ERROR", e.getMessage());
}
}
}).start();
}
This function is called in the onCreate method, but when I call:
ic.createObjectAdapterWithEndpoints("GPS", "default -h 0.0.0.0 -p 10001");
The program stop and I get this error:
E/GpsXtraDownloader: No XTRA servers were specified in the GPS configuration
Is there another way to set the ICE server listening? Or how could I solve
this?
Thanks!
--
View this message in context: http://jderobot-developer-list.2315034.n4.nabble.com/ICE-Server-in-Android-tp4643089.html
Sent from the Jderobot Developer List mailing list archive at Nabble.com.
More information about the Jde-developers
mailing list