Well, I have searched a lot. People say that I need to close the window of emulator to close it. However, I need to reboot the emulator to catch ACTION_BOOT_COMPLETE
D by my BroadcastReceiver
.
How can I do that?
Well, I have searched a lot. People say that I need to close the window of emulator to close it. However, I need to reboot the emulator to catch ACTION_BOOT_COMPLETE
D by my BroadcastReceiver
.
How can I do that?
emulators have on/off button - just click it
To emulate a broadcast action, you can connect via adb to the emulator/device and open a shell:
Then, you can broadcast the action you want to test:
Please note that, in the latest Android versions, broadcasting the *android.intent.action.BOOT_COMPLETED* action will actually reboot your emulator/device.
While using
tubemate
on android tab, I was not successful in downloading video with theerror:host interupped
etc. I used the following commands:and the application started downloading videos.
You can use the following command from adb:
for example:
Note that class name and package names need to be as defined in the Manifest.
This will generate the Intent you want , directed only to the component you want (otherwise you system will go crazy with BOOT_COMPLETED sent...)
Or another way (also from the command line):
First, make sure that USB Debugging is enabled from within the emulator:
click:
from a command-line:
EDIT:
This definitely doesn't work... very strange. I tested it and could not make the emulator reboot. It just hangs.