Questions tagged [android-binder]

Android's lightweight remote procedure call mechanism designed for high performance when performing in-process and cross-process calls.

While the term "binder" is somewhat generic, its most popular namesake is the Android-specific interprocess communication mechanism and remote method invocation system. It forms the basis for many of Android's core services.

The official documentation is here, and there is a collection of in-depth information at this wiki.

244 questions
1
vote
0 answers

How to prevent TransactionTooLargeException, or recover from it

I am sending data via broadcasts like this: Intent outIntent = new Intent(Const.ACTION_FEED); outIntent.putExtra(Const.EXTRA_FEED, data); sendBroadcast(outIntent); The issue is that data can get quite large, resulting in a…
user149408
  • 5,385
  • 4
  • 33
  • 69
1
vote
0 answers

Binder [IPC] Interface for Java App service called from Native App Service

I am working on adding Native app service on Android platform and wondering if there is right way to complete the interprocess transactions between Java service and Native service. How much is the effort for making it successfully compiling native…
1
vote
1 answer

Another color is binding color in Cardview?

Hello I am trying set a red color in app:cardBackgroundColor on a CardView for do this I have the following code:
Tlaloc-ES
  • 4,825
  • 7
  • 38
  • 84
1
vote
0 answers

SElinux domain transition for non-init process/files ( Android Natvie )

I'm writing Android Native programs and setting their SEPolicy I want to know how to set the process context for non-init program, it seems that the domain transition doesn't work I wrote 2 programs and put the built executable in /vendor/bin One…
cshushu
  • 89
  • 1
  • 11
1
vote
1 answer

SEPolicy for Android Native binder client

I'm new to the Android world I want to know how to set SEPolicy for native binder client program (And what to set as well..) I'm using vendor binder (vndservicemanager) reference from Using Binde-IPC And I add some files for the required…
cshushu
  • 89
  • 1
  • 11
1
vote
0 answers

Binder thread IDs

I am just after a quick clarification from someone who has more of an idea than I. I am currently tracing binder transactions in the Android Kernel and comparing them to the binder logs as a sanity check. The logs show an entry such as …
Alex Hoffmann
  • 355
  • 4
  • 20
1
vote
1 answer

What's the handle of Service generated by AIDL?

It's known to us that android system service register to system manager when device is booting.For Example: AlarmManagerService alarm = new AlarmManagerService(context); ServiceManager.addService(Context.ALARM_SERVICE, alarm); The…
user13457
  • 23
  • 3
1
vote
0 answers

Cast IBinder from different process service to extended Binder

I struggle with the Binder from Android. I developed an App, which should load different "driver" modules for some devices as plguins. In my Main App, I build an extra module (driverinterface), which contains a "DriverBinder"-Class and an Interface…
Marco Rehmer
  • 1,033
  • 2
  • 12
  • 32
1
vote
1 answer

android binder driver implementation

I'm learning binder driver. It has a struct binder_thread for saving thread info. I find that it uses binder_thread.pid that is assigned with current->pid to distinguish each others. for example, in binder_get_thread method, that field is used to…
mmmmar
  • 41
  • 8
1
vote
0 answers

Interaction between Java app and native daemon - Parcel.readException

I'm working on a requirement where the Java app need to interact with native daemon. The Java app issues command such as Start, Stop, and many others. The native daemon handles these requests and sends the response back to the Java app. I'm using…
webgenius
  • 856
  • 3
  • 13
  • 30
1
vote
1 answer

Service Connection Leak in android app when back to a previous page

Hello i am developing a clock in and out attendance app which has a timer service that runs when the user clocks in. the issue i am having is when i start the service and then press the back button on the phone to return to the previous page i get a…
James Ferry
  • 127
  • 1
  • 3
  • 12
1
vote
0 answers

Analyzing the ANR I occurred in android 8.0

The ANR was from a Monkey test, the probability of this issue is about 10%. It seems that there was a deadlock happened in binder driver, but I can't get more information from this ANR log, anyone could give me some hints or suggestions on tackling…
alexunder
  • 2,793
  • 3
  • 15
  • 18
1
vote
0 answers

Android IPC Binder - onTransact() waiting for previous one to return

I have an application that is using IPC. My main application is receiving one-way callbacks from a remote service. Upon receiving those callbacks I'm doing some timely work (1-20s). If I understand correctly - this work is done on a binder Thread on…
1
vote
0 answers

Accessing Frame Buffer

I am trying to find energy consumption of AMOLED displays and therefore, want to detect changes in the frame buffer of an Android phone at runtime. I read that Android framework used SurfaceManager library to combine, construct, and project the…
Sugam
  • 11
  • 2
1
vote
2 answers

Why does Android Bound Services documentation suggest IBinder can't be used across processes?

From https://developer.android.com/guide/components/bound-services.html: If your service is private to your own application and runs in the same process as the client (which is common), you should create your interface by extending the Binder class…
Alexey Romanov
  • 167,066
  • 35
  • 309
  • 487