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.

218 questions
2
votes
2 answers

Binder transaction failing in android

Possible Duplicate: Failed Binder Transaction when returning camera image What are the chances of binder transaction failing in android stack? I have an application which switches thru different activities, but the size of data being exchanged…
aTJ
  • 3,543
  • 3
  • 18
  • 25
2
votes
2 answers

Instant App crash using WiFi

My instant app crash when i run script “WifiManager.isWifiEnable” Caused by: java.lang.SecurityException: Method class android.net.wifi.IWifiManager$Stub$Proxy.getWifiEnabledState[] not available to instant apps …
2
votes
0 answers

java.lang.IllegalArgumentException: Invalid int: "today" at android.os.Parcel.readException(Parcel.java:1550)

when i use AIDL,it occured。 this is the exception: java.lang.IllegalArgumentException: Invalid int: "明天天气怎么样" at android.os.Parcel.readException(Parcel.java:1550) …
leooooooo
  • 117
  • 7
2
votes
0 answers

Android programming - How to leave binder

Sorry if this is a dumb question. I'm very new to Android. I have written a library that uses a library that uses a binder service. That is, my library has a class that derives from a library class which uses binder. My library is intended to…
2
votes
1 answer

Android binder in native code

I have created the class which implements the Binder interface(Service). I am able to send the data to it from client. If I want to send the asynchronous response back to client, do I need to implement Binder interface at client as well?
Vinay
  • 4,675
  • 7
  • 31
  • 42
2
votes
0 answers

How can I call an IBinder android service from JNI

How can I call an IBinder service (lets say IPackageManager) from JNI and parse the Parcel returned by the method? For example I want to call what should be the same from adb to: adb shell service call package 62 s16 "application.package.id" Where…
2
votes
0 answers

Android bypass normal system api to communicate with system service

I will use one specific api, TelephonyManager.getDeviceId, as an example.What I want to implement is bypass TelephonyManager.getDeviceId but still get device's imei. I am new to Java and Android. Java reflection with Android binder is really…
gen
  • 21
  • 1
  • 2
2
votes
0 answers

Is there any c interface to use Android binders

Basically I need to use shared memory. From this example, I understood that i need to use binders to pass the fd between 2 processes to be able to use shared memory. But my application is in C. So, is there a C interface for using android binders?
mk..
  • 15,357
  • 13
  • 60
  • 96
2
votes
0 answers

Catch Binder TransactionTooLargeException from native code

I'm sending intents from native layer to Java layer at a very high rate ( more than 100 intents / sec ). If the CPU load is high, a TransactionTooLargeException is thrown in logcat, but i cannot catch it back in the native sender. My intents have…
Cumatru
  • 635
  • 2
  • 11
  • 31
2
votes
1 answer

How to understand Android Binder recursion

I read the docs on Android Developer about IBinder/Binder. It says The Binder system also supports recursion across processes. For example if process A performs a transaction to process B, and process B while handling that transaction calls…
刘奔康
  • 155
  • 2
  • 7
2
votes
2 answers

Android Binder Tracing

In Android OS source code (Path: /drivers/staging/android/binder_trace.h), we have a file named binder_trace.h and also in /drivers/staging/android/binder.c binder_trace is included. As we can see in binder_trace.h file, the binder transactions are…
Cert
  • 79
  • 2
  • 9
2
votes
0 answers

Android binder - string truncated while calling JAVA api via native binder interface

I am writing a test code to study binder APIs, referring to (the reference sample also has similar problem) https://github.com/qianjigui/android_system_service_example I wrote a Java service and a native client. It seems everything is fine except…
Robin
  • 9,232
  • 5
  • 26
  • 45
2
votes
2 answers

Android: secure IPC alternative to AIDL?

What I'm trying to do: implement lightweight, secure IPC protocol between two applications installed on the device. Client app should be able to send commands and queries to Service running in a service app, and receive back results of…
Vasiliy
  • 14,686
  • 5
  • 56
  • 105
2
votes
1 answer

What is the correct way to share Active Objects between processes?

I am looking into sharing active objects between two processes, however the documentation regarding it is often lackluster and sometimes even incorrect. Specifically I was looking into sharing a Binder objects via parcels. The documentation…
Beryllium
  • 546
  • 7
  • 19
2
votes
1 answer

How do user-space applications control hardware (Location/Network/Wifi) in Android?

I have been reading all I can find trying to figure out the software architecture behind Android's BINDER IPC mechanism. From what I understand, BINDER sits in Kernel-space and temporarily gives user-space applications an allocation of shared memory…
sherrellbc
  • 4,222
  • 7
  • 37
  • 71