I am looking for simple binder IPC example in C/C++. Recently I started reading about the Android Binder basic (http://bharathi.posterous.com/android-binder) and gone thru the code in Android source also. Most of the binder usage part is in C++. Can some one explain why C++ is used instead of C?
Check out http://github.com/mcr/Android-HelloWorldService (if you use later versions of android you may have to exchange some includes from #include <utils/something>
to #include <binder/something>
).
You can also download the android source code and look into frameworks/base/camera/tests/CameraServiceTest/CameraServiceTest.cpp
Cheers!