ADB connection problems

Former Member
Former Member
I am trying to connect the Connect IQ Device simulator with my phone app through ADB. I set up ConnectIQ as required, ran the required ADB command (adb forward tcp:7381 tcp:7381) and launched the app. The app crashes instantly, with the following stack trace:

java.lang.NullPointerException: Attempt to invoke virtual method 'void java.net.ServerSocket.close()' on a null object reference
at
com.garmin.android.connectiq.adb.AdbConnection$ServerThread.run(AdbConnection.java:90)
at java.lang.Thread.run(Thread.java:764)

ConnectIQ iq;
// ...
iq = ConnectIQ.getInstance(this, ConnectIQ.IQConnectType.TETHERED);

iq.initialize(getApplicationContext(), true, new ConnectIQ.ConnectIQListener() { @Override public void onSdkReady() { } @Override public void onInitializeError(ConnectIQ.IQSdkErrorStatus status) { } @Override public void onSdkShutDown() { } });