Hi,
I have a particular situation:
a service started by a broadcast receiver starts an activity. I want to make it possible for this activity to communicate back to the service. I have chosen to use AIDL to make it possible. Everything seems works good except for bindService()
method called in onCreate()
of the activity. bindService(), in fact, throws a null pointer exception because onServiceConnected()
is never called while onBind()
method of the service is. Anyway bindService()
returns true.
The service is obviously active because it starts the activity.
I know that calling an activity from a service could sound strange, but unfortunately this is the only way to have speech recognition in a service.
Thanks in advance