Broadcast Receiver / Service will only restart my activity once.

by AuxOne » Thu, 18 Mar 2010 04:30:39 GMT

Sponsored Links
 I have a single Activity application, within it I have a service which
creates an AlarmManager and sends a broadcast to a broadcast Receiver.
If the activity which starts the services dies, (ie. divide by zero),
the broadcast receiver stops the old service which created the

It works the first time. The second time, it does not.

I am seeing the following messages in the logCat:

ActivityManager: Process  has crashed too many times: killing!
ActivityManager: Unable to launch app for broadcast Intent: process is
                 finishReceiver called but not active

It seems like the AlarmManager is still active but the broadcast
receiver is no longer receiving. It works great once!

Anyone have any ideas? Thanks in advance.


Other Threads

1. Porting android on OMAP

Hi All,

I have flashed the image using SD card and booted my OMAP3530 EVM
(mistral  board).
I followed the document they have given me..

while booting .. from SD/MMC card... I am getting these msg..

X-loader 1.41(OMAP3EVM-1.1)  (Apr  8 2009 - 16:29:36)
Detected Samsung MuxOneNAND1G Flash
Starting X-loader on MMC
Reading boot sector

196968 Bytes Read from MMC
Starting OS Bootloader from MMC...
Starting OS Bootloader...
Unknown Boot chip!!!

U-Boot 1.1.6(OMAP3EVM-1.1) (Apr  8 2009 - 16:34:49)
Mistral OMAP3EVM Development Board
DRAM:  128 MB
OneNAND Manufacturer: Samsung (0xec)
Muxed OneNAND 128MB 1.8V 16-bit (0x30)
OneNAND version = 0x0221
Scanning device for bad blocks
num of blocks = 2048
onenand_wait: controller error = 0x2400
Bad factory block738 at 0x05c40000
Using default environment

In:    serial
Out:   serial
Err:   serial
Reseting CHIP... Done
LAN9x18 (0x01150002) detected.
Setting mac address: aa:bb:cc:dd:ee:ff
start Auto negotiation... (take ~2sec)
Auto negotiation failed
The board has OneNand flash.
Using OneNand based commands
Hit any key to stop autoboot:  0

1951744 bytes read
## Booting image at 80000000 ...
   Image Name:   Linux-2.6.28-OMAP3EVM-1.1-00026-
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    1951680 Bytes =  1.9 MB
   Load Address: 80008000
   Entry Point:  80008000
   Verifying Checksum ... OK

Starting kernel ...

Linux version 2.6.28-OMAP3EVM-1.1-00026-g461463c
(shar...@localhost.localdomain) (gcc version 4.2.1 (CodeSourcery
Sourcery G++ Lite 2007q3-51)) #1 Thu Apr 99
CPU: ARMv7 Processor [411fc082] revision 2 (ARMv7), cr=10c5387f
CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache
Machine: OMAP3 EVM
Memory policy: ECC disabled, Data cache writeback
OMAP3430 ES2.1
SRAM: Mapped pa 0x40200000 to va 0xd7000000 size: 0x100000
Built 1 zonelists in Zone order, mobility grouping on.  Total pages:
Kernel command line: mem=128M console=ttyS0,115200n8 root=/dev/
mmcblk0p2 rw rootdelay=2
Clocking rate (Crystal/DPLL/ARM core): 26.0/332/500 MHz
GPMC revision 5.0
IRQ: Found an INTC at 0xd8200000 (revision 4.0) with 96 interrupts
Total of 96 interrupts on 1 active controller
OMAP34xx GPIO hardware version 2.5
PID hash table entries: 512 (order: 9, 2048 bytes)
OMAP clockevent source: GPTIMER1 at 32768 Hz
Console: colour dummy device 80x30
Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
Memory: 128MB = 128MB total
Memory: 125084KB available (3556K code, 673K data, 440K init)
Calibrating delay loop... 499.92 BogoMIPS (lpj=1949696)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
net_namespace: 288 bytes
NET: Registered protocol family 16
OMAP DMA hardware revision 4.0
USB: No board-specific platform config found
i2c_omap i2c_omap.1: bus 1 rev3.12 at 2600 kHz
twl4030: PIH (irq 7) chaining IRQs 368..375
twl4030: power (irq 373) chaining IRQs 376..383
i2c_omap i2c_omap.2: bus 2 rev3.12 at 400 kHz
i2c_omap i2c_omap.3: bus 3 rev3.12 at 400 kHz
SCSI subsystem initialized
twl4030_usb twl4030_usb: Initialized TWL4030 USB module
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
musb_hdrc: version 6.0, musb-dma, otg (peripheral+host), debug=0
musb_hdrc: USB OTG mode controller at d80ab000 using DMA, IRQ 92
NET: Registered protocol family 2
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 4096 (order: 3, 32768 bytes)
TCP bind hash table entries: 4096 (order: 2, 16384 bytes)
TCP: Hash tables configured (established 4096 bind 4096)
TCP reno registered
NET: Registered protocol family 1
NetWinder Floating Point Emulator V0.97 (double precision)
ashmem: initialized
VFS: Disk quotas dquot_6.5.1
Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
JFFS2 version 2.2. (NAND) .. 2001-2006 Red Hat, Inc.
yaffs Apr  9 2009 11:03:21 Installing.
msgmni has been set to 244
alg: No test for stdrng (krng)
io scheduler noop registered
io scheduler anticipatory registered (default)
io scheduler deadline registered
io scheduler cfq registered
This is backlight driver
Allocating static major number 255 to omap3evm_bl driver
omapfb: configured for panel omap3evm
omapfb: DISPC version 3.0 initialized
Console: switching to colour frame buffer device 60x40
omapfb: Framebuffer initialized. Total vram 1228800 planes 1
omapfb: Pixclock 19636 kHz hfreq 37.9 kHz vfreq 57.5 Hz
Serial: 8250/16550 driver4 ports, IRQ sharing enabled
serial8250.0: ttyS0 at MMIO 0x4806a000 (irq = 72) is a ST16654
console [ttyS0] enabled
serial8250.0: ttyS1 at MMIO 0x4806c000 (irq = 73) is a ST16654
serial8250.0: ttyS2 at MMIO 0x49020000 (irq = 74) is a ST16654
brd: module loaded
loop: module loaded
eth0: LAN9115 (rev 2) at 0x2c000000 IRQ 336
eth0: Ethernet addr: aa:bb:cc:dd:ee:ff
i2c /dev entries driver
input: triton2-pwrbutton as /class/input/input0
triton2 power button driver initialized
Driver 'sd' needs updating - please use bus_type methods
omap2-nand driver initializing
OneNAND driver initializing
omap2-onenand omap2-onenand: initializing on CS0, phys base
0x20000000, virtual base c8880000
Muxed OneNAND 128MB 1.8V 16-bit (0x30)
OneNAND version = 0x0221
Scanning device for bad blocks
onenand_bbt_wait: ecc error = 0x2222, controller error 0x2400
Bad eraseblock 738 at 0x05c40000
Creating 9 MTD partitions on "omap2-onenand":
0x00000000-0x00020000 : "X-Loader(1)"
0x00020000-0x00040000 : "X-Loader(2)"
0x00040000-0x00060000 : "X-Loader(3)"
0x00060000-0x00080000 : "X-Loader(4)"
0x00080000-0x00100000 : "U-Boot"
0x00100000-0x00120000 : "U-Boot Environment"
0x00120000-0x00520000 : "Kernel(1)"
0x00520000-0x00920000 : "Kernel(2)"
0x00920000-0x08000000 : "File System"
android adb driver
musb_hdrc musb_hdrc: MUSB HDRC host driver
musb_hdrc musb_hdrc: new USB bus registered, assigned bus number 1
usb usb1: configuration #1 chosen from 1 choice
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 1 port detected
usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
usb usb1: Product: MUSB HDRC host driver
usb usb1: Manufacturer: Linux 2.6.28-OMAP3EVM-1.1-00026-g461463c musb-
usb usb1: SerialNumber: musb_hdrc
input: omap_twl4030keypad as /class/input/input1

[ads7846_probe]: pressure_min=0, pressure_max=255
ads7846 spi1.0: touchscreen, irq 335
input: ADS784x Touchscreen as /class/input/input2
twl4030_rtc twl4030_rtc: rtc core: registered twl4030_rtc as rtc0
twl4030_rtc twl4030_rtc: Power up reset detected.
twl4030_rtc twl4030_rtc: Enabling TWL4030-RTC.
mmci-omap-hs mmci-omap-hs.0: Failed to get debounce clock
usbcore: registered new interface driver usbhid
usbhid: v2.6:USB HID core driver
logger: created 64K log 'log_main'
logger: created 256K log 'log_events'
logger: created 64K log 'log_radio'
Advanced Linux Sound Architecture Driver Version 1.0.18rc3.
ASoC version 0.13.2
OMAP3EVM  SoC init
TWL4030 Audio Codec init
asoc: twl4030 <-> omap-mcbsp-dai-(link_id) mapping ok
ALSA device list:
  #0: OMAP3EVM (twl4030)
TCP cubic registered
NET: Registered protocol family 17
NET: Registered protocol family 15
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
ieee80211: 802.11 data/management/control stack, git-1.1.13
ieee80211: Copyright (C) 2004-2005 Intel Corporation
Power Management for TI OMAP3.
VFP support v0.3: implementor 41 architecture 3 part 30 variant c rev
twl4030_rtc twl4030_rtc: setting system clock to 2000-01-01 00:00:00
UTC (946684800)
Waiting 2sec before mounting root device...
mmc0: host does not support reading read-only switch. assuming write-
mmc0: new high speed SD card at address 0002
mmcblk0: mmc0:0002 00000 1.90 GiB
 mmcblk0: p1 p2
kjournald starting.  Commit interval 5 seconds
EXT3 FS on mmcblk0p2, internal journal
EXT3-fs: recovery complete.
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem).
Freeing init memory: 440K
init started: BusyBox v1.8.1 (2007-11-14 09:47:41 EST)
starting pid 435, tty '': '/startme'
 Disabling Power mgmt       : /startme: cannot create /sys/power/
cpuidle_deepest_state: directory nonexistent
 Turn off LCD after 1 hour  : /startme: cannot create /sys/power/
fb_timeout_value: directory nonexistent
Socket created.
Bind completed!

[Thread]: cmd_processor_name=COMMON_TASKS_SLOW

[deQueueCmdPkt]: COMMON_TASKS_SLOW waiting ...

[Thread]: cmd_processor_name=COMMON_TASKS_FAST

[deQueueCmdPkt]: COMMON_TASKS_FAST waiting ...

[Thread]: cmd_processor_name=AUDIO_CTRL_TASKS

[setMasterVolume]: cmd_buf=/usr/bin/amixer cset numid=2 70
sh: /usr/bin/amixer: not found

[Thread]: cmd_processor_name=AUDIO_PB_REC_TASKS

[deQueueCmdPkt]: AUDIO_PB_REC_TASKS waiting ...

[deQueueCmdPkt]: AUDIO_CTRL_TASKS waiting ...
Initializing Android...
This process may take atlease 2-3 minutes
to bring up the home page, please wait.......
init: cannot open '/initlogo.rle'
sh: can't access tty; job control turned off
# warning: `app_process' uses 32-bit capabilities (legacy support in
android_power: wakeup (0->0) at 32725341832 (2000-01-01
00:00:31.648620593 UTC)
eth0: link down
binder: release 831:831 transaction 503 out, still active
binder: 772:836 transaction failed 29189, size 4-0
binder: send failed reply for transaction 503, target dead

Job control is turned off.. :(
Can someone please guide me.. how to proceed...

Can you please suggest me.. how can i a test a test application ..
please suggest some tools and any links..
We are using Fedora core 6. Do I need to migrate to Ubuntu ?  I am new
to android...

Thanks in advance..



2. Huge quert and sorting update of content provider

I implement ProviderTestCase2 to test my content provider functions.
And when I insert huge number  (about 10000) of data,  the insert,
delete and update functions are fine. But the query function will have
SQLiteDiskIOOException: disk I/O error. And the data number limit of
causing the exception is about 5000. Is it bug of content provider?

And there is another problem. Each of my data has different priority.
When I sort my data by priority, its no problem. But when I change
priority of some data and then sorting again. Sometimes I will get
incorrect result  and I'm sure its not logical problem of test
program. Does anyone meet the same problem?

Any suggestion is appreciative.Thanks

3. How can I know who started(bind) service?

4. why my getCheckedRadioButtonId() always return a wrong value.

5. connecting internet through Android Emulator

6. Calendar only syncs one way

7. How often are download stats updated for apps in Android Market