Android :: How To Broadcast Intent From Native Code

Nov 2, 2010

Is it possible to broadcast an Intent from native code? If so, is there documentation and/or sample code pertaining to the relevant APIs?

Android :: How to broadcast intent from native code


Android :: Broadcast Intent For USB Power?

Feb 20, 2010

Is there a Broadcast Intent that gets sent out when the device is plugged in for power? I want to create a BroadcastReceiver to detect the device's plugged in state.

I've looked everywhere in the Developer's resources and reference, but I can't find anything that resembles what I'm trying to do.

View 4 Replies View Related

Android :: Way To Broadcast Any Intent As New Email Received?

Jul 28, 2010

Do any one know how to broadcast any intent if new email is received?

View 8 Replies View Related

Android :: Start Another Activity With Broadcast Intent

Nov 29, 2009

I'm trying to start an activity out of a widget so I can't use the startActivity() function. So I'm trying to create the correct intent but I don't find what I'm missing.

View 2 Replies View Related

Android :: Create A New Intent For Another App's Broadcast Receiver?

Jul 23, 2010

In the examples, they create Intent as:

Intent intent = new Intent(this, AlarmReceiver.class);

But suppose my AlarmReceiver class is in another app, how do I create this intent?

I've tried with

new Intent("com.app.AlarmReceiver")

but nothing happens.. It was not called..

--Broadcast definition added using the manifest editor on Eclipse:

CODE:.................

View 1 Replies View Related

Android :: Way To Determine Sender Of Broadcast Intent

Sep 20, 2010

I have an application that is at the same time a broadcast sender and receiver of standard action android.intent.action.SET_WALLPAPER. I want to do some stuff only in a case when another application broadcasted this intent.

Is there any way to determine who initiated a broadcast in onReceive method of a BroadcastReceiver?

View 1 Replies View Related

Android :: Sending Broadcast Intent From Runnable

Jul 10, 2010

I want to send a broadcast from a new thread is start.

This is what i tried:

CODE:............

But ofcourse i need context..this won't work. How can i handle this.

View 1 Replies View Related

Android :: Sending / Receiving Custom Broadcast Intent

Jul 25, 2009

I'm building a service that sends a broadcast intent when some value changes. The service sends the broadcast like this:

Intent broadcastIntent = new Intent(); broadcastIntent.setAction("nl.vu.contextframework.NEWREADING"); broadcastIntent.setData(Uri.parse("context://"+cer.getKey())); broadcastIntent.putExtra("reading",cer); broadcastIntent.addCategory("nl.vu.contextframework.CONTEXT"); sendBroadcast(broadcastIntent);

In some Activity (in a different process), I'm tryint to receive this broadcast as follows:

IntentFilter intentFilter = new IntentFilter();
intentFilter.addDataScheme("context");
intentFilter.addCategory(CATEGORY_CONTEXT);
registerReceiver(new BroadcastReceiver() {
public void onReceive(Context context, Intent intent) {
Log.d(TAG,"Received intent "+intent); }
}, intentFilter);

View 6 Replies View Related

Android :: How Broadcast Receiver And Intent Filter Behaves?

Jul 6, 2010

I am new to android platform.please help me out how the Broadcast Receiver and Intent Filter behaves in android.please explain in simple line or with example.

View 1 Replies View Related

Android :: Run Multiple Broadcast Receivers For Same Intent In Same Application?

Oct 25, 2010

I'm working on a project where I need to run the BroadcastReceiver for a third party library for a specific Intent. I also want to run some of my own code when the Intent is broadcast. If I supply my own BroadcastReceiver for the same Intent, it seems that only, one or the other runs, but not both, depending on which appears first in the AndroidManifest.xml file. Is it possible to register multiple BroadcastReceivers for the same Intent in the same application and have them all run? AndroidManifest.xml snippet

View 4 Replies View Related

Android :: Broadcast Intent When Network State Has Changend

Apr 20, 2010

Does Android broadcast an intent when the network state has changend, i.e. from GSM to Wifi? And if so what permission do I need and what is the intent action called?

View 3 Replies View Related

Android :: How To Capture Key Events From Intent's / Broadcast Receivers?

Oct 29, 2010

Is there a way to capture a key event from the Menu button using an Intent or Broadcast Receiver? Basically I want my app's Service to be activated when the Menu key is pressed.

View 1 Replies View Related

Android :: Listen For Entries To Log / Broadcast Intent For When Log Entry Is Appended?

Aug 22, 2010

Is it possible to listen for entries to the log?
Ie is there a broadcast intent for when a log entry is appended?

View 1 Replies View Related

Android :: What Is Intent Action Name To Launch Native Map Appl?

Apr 20, 2009

what is intent action name(e.g. action name "android.media.action.IMAGE_CAPTURE" for launching camera appl) to launch the native map appl Is there intent available(documented or undocumented since above intent of capturing image is undocumented ) for launching maps appl?

I know one for launching maps for driving direction "this.startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("http://maps.google.com/maps? f=d&saddr=37.4,-121.9"+ "&daddr=Bellevue, WA&hl=en")));" but this goes to driving direction page of maps appl.

is there any way to launch maps appl which will open maps home page?

View 3 Replies View Related

Android :: How To Change Default Intent Action To Select Native - My App

Jun 26, 2009

I am customizing native phonebook application as a third party application which can be launched by the same intent as the native application. I have installed that application in my G1 phone. When I have clicked on Contacts icon in launcher menu it a menu pops out and asks me to select which app to lauch i.e., native contacts or my customized contact application. I have selected my application and I have also selected to use this selection as my default choice. After that system never put a pop-up and whenever I clicked on contacts it launches my customized application.

Now my problem is, I do not know how do I change this setting i.e., tell the phone to put the pop-up again so that I can select native app or my app?

Does anyone has any idea?

View 3 Replies View Related

Android :: Notification Code Inside Broadcast Receiver?

Mar 23, 2010

how to use notification code inside Broadcast Reciever.

View 2 Replies View Related

Android :: Using Sqlite In Native Code

Nov 22, 2010

I have a library written in C which implements some complicated algorithm over two databases and as a result produce new one. I am trying to import it in android using android-ndk. What is the correct wat to use sqlite in you native libraries, i was able to build the sqlite manually using the ndk but when i use it gives some strange errors when trying to fetch rows from db which is on phone storate - after i fetch some data i got SQL:database not opened. how can use sqlite in native code on android.

View 2 Replies View Related

Android :: Can Use TraceView In Native Code When Using NDK

Dec 10, 2009

We know that it's very convenient to use TraceView in Android java code to check the runtime of different chunks of code. Now I develop my app with NDK and I want to check the runtime of some native functions, but I found nothing in TraceView guide if it's possible to use this tool. Because I noticed that one of my native methods spent too much time and I want to dig out the more detailed root cause. Is there anybody know if we can use TraceView in native code?

View 2 Replies View Related

Android :: Using Surface In The Native Code

Feb 3, 2010

I am planning to write a video player application and I am planning to use the gstreamer on the native side. I am trying to use the SurfaceFlinger for the rendering part. For this I have written a test program to experiment on the rendering part. I am using the surface flinger wrapper from the project

http://gitorious.org/rowboat/external-gst-plugins-android

But the following ERROR occurs when we try to run the .apk.

CODE:.......

The I changed the permission for "android.permission.ACCESS_SURFACE_FLINGER" in frameworks/base/core/ res/AndroidManifest.xml to "dangerous" and recompiled. But got the same error.

Then I commented out the "checkCallingPermission" method in IServiceManager.cpp and recompiled. Then also i got the same error.

View 4 Replies View Related

Android :: Broadcast Event / Android Intent Action

Mar 25, 2010

I added broadcast listener "BATTERY_CHANGED" to Android Manifest file so that when the status changed I should get informed. I am adding to Android Manifest file as I want it active through my application life time. But the problem is that I am not getting the broad cast event from the system when battery status changes.

My code is here :-
<receiver android:name=".MyBroadcastReceiver" android:enabled="true"
android:permission="android.permission.BROADCAST_STICKY">
<intent-filter>
<action android:name="android.intent.action.BATTERY_CHANGED" />
</intent-filter> </receiver>
<uses-permission android:name="android.permission.BATTERY_STATS"/>
<uses-permission android:name="android.permission.BROADCAST_STICKY"/>

View 10 Replies View Related

Android :: Android - Difference Between Intent And Broadcast Receiver

Aug 30, 2010

I am new to android. I what to know the difference between Intent and Broadcast Receiver. I am more confused with Broadcast receiver then Intent. Simple codes will be helpful.

View 1 Replies View Related

Android :: Getting Sensor Information From Native Code - C Or C++

Oct 12, 2010

Is this possible to access a sensor data form native code without using Java at all? I need to access to the sensor as fast as possible, but it seems like the "DELAY_FASTEST" parameter when registering an event change is not fast enough.

View 3 Replies View Related

Android :: How To Debug Native Code In Eclipse

Jun 18, 2010

I created one android application it is using one native method. I created shared library using ndk tools.My jni function is having some problems i want to debug it. How to debug it in eclipse tool

View 2 Replies View Related

Android :: Using SKIA Canvas In Native Code

Oct 4, 2009

I set out to use SkCanvas and other native SKIA classes but I could not find any sample code. After a week's of search and diving deep into Android source, I got it working. Below in my blog, I have detailed, how to use SimpleJNI native sample, to get native canvas going. If you find it useful or I did something wrong let me know http://matthiyosi.blogspot.com/2009/10/using-skia-in-android-native-c...

View 6 Replies View Related

Android :: Debugging Native Code (C++) Using Gdb With Eclipse / Is It Possible?

May 24, 2010

I have some piece of code which uses JNI. I can debug code wrote in Java directly in Eclipse (using ADT). I even have a script, which help me debug native code with gdb. However this is not very comfortable way for doing this.Is it possible to configure Eclipse to use gdb (I guess gdbserver) for debbuging android native applications? Do you know where I could find any description of this?

View 1 Replies View Related

Android :: Can Native Only Code Run As Standalone Application

Nov 8, 2010

We want to migrate a huge complex native program to Android system ,running it as a background service accepting command sent from Java Program using JNI along with IPC. However, the Android NDK state following words:

Please note that the NDK does not enable you to develop native-only applications. Android's primary runtime remains the Dalvik virtual machine.

Does that mean we have no way to run an standalone native-only application on Android as a background service? The native code can only exist in the form of library that will be loaded to the virtual machine through JNI?

View 2 Replies View Related

Android :: Porting JMF / Native Source Code

Jan 22, 2009

I am creating an Android application which uses the JMF (SIP, RTP, JAIN). So i downloaded the JMF source code for some adhoc change to my application.The basic questions 1. How will it behave the "native files - C/C++/header" in JMF source files(downloaded)? because android is based on java right now. 2. Is there any complete different way to porting/doing the SIP, RTP working in android?Is there any link from sun.com(this) site for JMF source code?Any suggestion and comment about this?

View 3 Replies View Related

Android :: How To Add Includes In Native C Code That Will Be Compiled By Ndk

Aug 23, 2010

How I can add headers to my native c file.

So here's the details.

I was able to setup my android project to call a native function from a .so file. And actually I need to add box2d to my project, but I when I include the header files, it won't make. So basically my problem is how do I tell the make file to include a whole folder with header and cpp files.

I tried adding the path directly to the include statement just for the sake of testing it. The error goes away, but new errors come out.

View 2 Replies View Related

Android : How To Access A File (say .xml) From A Native Code?

Sep 16, 2010

I am trying out an example of OpenCV from http://github.com/billmccord/OpenCV-Android and am stuck at the point where it is mentioned "Before attempting to run the VideoEmulator application, you must first copy this XML file into the emulator in the following location: /data/data/org.siprop.opencv/files/haarcascade_frontalface_alt.xml " Where in my eclipse workspace do I need to place this haar xml file to be copied to the location /data/data/org.siprop.opencv/files/ of the emulator?

View 1 Replies View Related

Android :: Print Backtrace When Debug Native Code

Nov 23, 2010

When I debug android app, if I work with Java, I can use Log.d("TAG", "xxxx", new Throwable()) to print backtrace of Java code. This is really handy for me to find bugs. But when I work with native library (e.g. libwebcore.so), there seems no way to print backtrace in runtime. The only way to debug native code is use gdbserver.

I have a question: Is there any way to print backtrace in C/C++?

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved