Q:

Can the Android emulator receive ACTION_POWER_CONNECTED intents? 

in my application, I'm trying to listen for the ACTION_POWER_CONNECTED intent like so:
    <service android:name=".myService">
        <intent-filter>
            <action android:name="android.intent.action. ACTION_POWER_CONNECTED" />
        </intent-filter>
    </service>

I assumed I would be able to test this by sending the emulator the "power ac on" command over telnet, however, my service doesn't seem to be receiving the intent.  I'm able to receive the BATTERY_LOW intent using this method just fine. 
I notice this message: http://groups.google.com/group/android-developers/msg/84e968734c51d50e suggests that you can't test this with the emulator, but its a few months old and the link in it seems to be out-of-date, and I don't have a device handy to test.  
Can anyone confirm?  Are you able to receive this intent using a command from telnet?  Thanks. 

A:

I was able to confirm this.  You can get the Power Connected event with a broadcast receiver. 
    <receiver android:name=". MyReceiver" android:label="@string/app_name">
            <intent-filter>
                <action android:name="android.intent.action. ACTION_POWER_CONNECTED" />
                <action android:name="android.intent.action. BOOT_COMPLETED" />
        </intent-filter>
    </receiver>

The command from telnet would be:
    power ac on

