`

android手机自启动-------捕获系统广播BOOT_COMPLETED

阅读更多
android手机自启动,注意事项

1 AndroidManifest.xml
<receiver android:name=".util.BootReceiver"  android:enabled="true" android:exported="true">
  <intent-filter>
	<action android:name="android.intent.action.BOOT_COMPLETED"></action>
  </intent-filter>
</receiver>


2 权限
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />


3 程序不能安装在sdcard上。
可以在AndroidManifest.xml设置
android:installLocation="internalOnly"


4 有些机型(htc)有“快速启动”,不会发送BOOT_COMPLETED广播,自然也接受不到。

参考:
http://stackoverflow.com/questions/8277207/how-to-catch-the-system-broadcast-boot-completed-my-program-just-doesnt-work
分享到:
评论

相关推荐

    实现开机自启动服务

    开机启动后,当系统发出android.intent.action.BOOT_COMPLETED广播时,接收该广播,并自动启动一个后台service。

    Android 开机自启动应用

    Android 开机自启动应用, BOOT_COMPLETED

    android开机自启动APP及使用adb命令测试方法

    在android系统运行时,会发出“android.intent.action.BOOT_COMPLETED”这个系统广播,因此我们监听它,并进行打开APP的操作即可。现在大多数的android手机系统都默认禁止第三方安装的APP开机自启动,只有系统APP...

    testBOOT_COMPLETED如何在开机时即启动程序

    testBOOT_COMPLETED如何在开机时即启动程序

    android 系统中的几乎所有广播接收者

    BOOT_COMPLETED_ACTION 在系统启动后,这个动作被广播一次(只有一次) "android.intent.action.BOOT_COMPLETED" CALL_FORWARDING_STATE_CHANGED_ACTION 语音电话的呼叫转移状态已经改变 "android.intent.action.CFF" ...

    BOOT_COMPLETED issue analysis report

    BOOT_COMPLETED_issue_analysis_report_201407111625.pdf

    Android 屏幕唤醒 + 屏幕解锁 + 开机服务监听(android.intent.action.BOOT-COMPLET)

    Android 屏幕唤醒 + 屏幕解锁 + 开机服务监听(android.intent.action.BOOT_COMPLET)添加权限:{//开机监听&lt;uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/&gt;&lt;uses-permission android...

    bpi_a64_android初步编译为LCD显示20170309_1442.7z

    /home/wwt/a64/bpi_a64_android/lichee/brandy/u-boot-2014.07/../gcc-linaro/bin/arm-linux-gnueabi-gcc -E -include /home/wwt/a64/bpi_a64_android/lichee/brandy/u-boot-2014.07/include/u-boot/u-boot.lds.h -...

    android应用程序开机启动

    Android应用程序可以实现开机时启动相关应用 如service等 Android系统在开机启动时会发出一个系统广播&quot;android intent action BOOT COMPLETED&quot; 在接收到这个广播就可以实现开机自启动功能 下面就是一个...

    开机时自动启动Android应用

    如果需要在Android开机时自动启动应用程序,可以通过响应android.intent.action.BOOT_COMPLETED广播消息来实现, Android系统启动结束时,会发出 android.intent.action.BOOT_COMPLETED 消息

    Service开机自动启动

    1.首先开机启动后系统会发出一个Standard Broadcast Action,名字叫android.intent.action.BOOT_COMPLETED,这个Action只会发出一次。 2.构造一个IntentReceiver类,重构其抽象方法onReceiveIntent(Context context...

    AM335x U-Boot User's Guide.pdf

    The booting is completed in two consecutive stages by U-Bootbinaries.The binary for the 1st U-Boot stage is referred to as the Secondary Program Loader (SPL) or the MLO. The binaryfor the 2nd U-Boot ...

    android 开机自动启动服务

    需要注意的是开机启动action Intent.ACTION_BOOT_COMPLETED 需要申请权限:&lt;uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" /&gt; action Intent.ACTION_TIME_TICK只能通过动态注册,不...

    delphi android 的app 自启动(随系统启动)

    APP 自动启动,随系统启动,马上启动的demo ,在 delphi xe 10.2 和10.3 中编译统统,可以运行,包含源码,注意修改项目2个地方,1 permission 里面的 receive boot completed 2. 修改AndroidManifest.template.xml...

    COMPLETED_PISCINE_C-master.rar

    COMPLETED_PISCINE_C-master.rar

    Android APP:开机自动启动app demo 源码 autorundemo.zip

    Android APP:开机自动启动...Android启动完成会发出一个系统广播 ACTION_BOOT_COMPLETED,字符串常量表示为 “android.intent.action.BOOT_COMPLETED”,我们要做的是用BroadcastReceiver接收这个消息然后启动该程序。

    mumu-osc-nicefish-spring-boot-master_salej2k_js项目演示_BackInServic

    Nicefish-springboot | is used to demonstrate the docking mode of front-end code and back-end ... The baseline version has been completed and the actual deployment has been made on the Tengxun cloud

    Android应用示例-开机启动

    安卓应用开机启动功能的演示示例,原理:当Android系统完成BOOT阶段之后,就会发送一条名为 ACTION_BOOT_COMPLETED 的广播,我们便可在一个BroadcastReceiver中捕获这条广播,然后启动我们的Activity或者Service!

    Android开机自启动服务的实现方法

    android实现开机自启动可能是移动操作系统中最简单的了,我们只需要监听一个开机启动的Broadcast(广播)即可。首先写一个Receiver(即广播监听器),继承BroadcastReceiver,如下所示:  view source  print? 代码...

Global site tag (gtag.js) - Google Analytics