broadcast

UDP-Broadcast on all interfaces

时光怂恿深爱的人放手 提交于 2019-11-26 13:45:29
问题 On a Linux system with a wired and a wireless interface (e.g. 192.168.1.x and 192.168.2.x subnets) I want to send a UDP broadcast that goes out via ALL available interfaces (i.e. both through the wired and the wireless interface). Currently I sendto() to INADDR_BROADCAST, however it seems that the broadcast only is sent through one of the interfaces (not always the same and subsequent broadcasts may use the other interface). Is there a way that I can send a UDP broadcast that goes out through

Broadcast receiver not working in ICS if the app is not started atleast once

拟墨画扇 提交于 2019-11-26 11:29:47
问题 This question has been asked few times in stack overflow, but no solution, yet. I have a broadcast receiver for for receiving USB connected action.The broadcast receiver responsibility is , if I get the intent start my application.In the manifest file I have added the receiver . I have the same logic working in GingerBread, but I ICS its not working. Many questions like , broadcast-not-invoking 1: Android Boot-Up BroadCast Not invoking and broadcastreciever-not-working If I start my app

Where is the all Android broadcast Intent list

♀尐吖头ヾ 提交于 2019-11-26 10:09:22
问题 I want to receive the Android broadcast messages. Is there a list of all intents? 回答1: I have found the broadcast intent list. It can be located under the sdks(or android-sdks)/platforms/<android-sdk-version>/data/broadcast_actions.txt . 回答2: For API level 16 (ICS), this is the list: android.app.action.ACTION_PASSWORD_CHANGED android.app.action.ACTION_PASSWORD_EXPIRING android.app.action.ACTION_PASSWORD_FAILED android.app.action.ACTION_PASSWORD_SUCCEEDED android.app.action.DEVICE_ADMIN

Android - how to receive broadcast intents ACTION_SCREEN_ON/OFF?

不羁的心 提交于 2019-11-26 06:45:26
<application> <receiver android:name=".MyBroadcastReceiver" android:enabled="true"> <intent-filter> <action android:name="android.intent.action.ACTION_SCREEN_ON"></action> <action android:name="android.intent.action.ACTION_SCREEN_OFF"></action> </intent-filter> </receiver> ... </application> MyBroadcastReceiver is set just to spit foo to the logs. Does nothing. Any suggestions please? Do I need to assign any permissions to catch the intent? I believe that those actions can only be received by receivers registered in Java code (via registerReceiver() ) rather than through receivers registered

Is there a broadcast action for volume changes?

心已入冬 提交于 2019-11-26 06:41:55
I'm programming a small widget that needs to be updated whenever the user changes the ringer volume or the vibrate settings. Capturing android.media.VIBRATE_SETTING_CHANGED works just fine for the vibrate settings, but I haven't found any way of getting notified when the ringer volume changes and although I could try to capture when the user presses the volume up/volume down physical keys, there are many other options for changing the volume without using these keys. Do you know if there's any broadcast action defined for this or any way to create one or to solve the problem without it? Nathan

How can I update a broadcast variable in spark streaming?

梦想与她 提交于 2019-11-26 05:19:54
问题 I have, I believe, a relatively common use case for spark streaming: I have a stream of objects that I would like to filter based on some reference data Initially, I thought that this would be a very simple thing to achieve using a Broadcast Variable : public void startSparkEngine { Broadcast<ReferenceData> refdataBroadcast = sparkContext.broadcast(getRefData()); final JavaDStream<MyObject> filteredStream = objectStream.filter(obj -> { final ReferenceData refData = refdataBroadcast.getValue()

Is there a broadcast action for volume changes?

╄→гoц情女王★ 提交于 2019-11-26 01:57:33
问题 I\'m programming a small widget that needs to be updated whenever the user changes the ringer volume or the vibrate settings. Capturing android.media.VIBRATE_SETTING_CHANGED works just fine for the vibrate settings, but I haven\'t found any way of getting notified when the ringer volume changes and although I could try to capture when the user presses the volume up/volume down physical keys, there are many other options for changing the volume without using these keys. Do you know if there\'s