I do not believe that there is a way that you can call to find out about it. However, what I usually saw was to keep a boolean in an activity that keeps track of whether the service is connected. You would set it to true in your callback ServiceConnection.onServiceConnected()and set it to false in ServiceConnection.onServiceDisconnected().
source
share