I love Pandora and use it frequently and with multiple sound devices. But I want it to start and play it automatically when I connect it to my headphones or car and then I want it to stop automatically when I disconnect it. I love Tasker too and thought it would allow me to do those tasks easily. Well, it can do those things, just not very easily. Here’s how I got it done. Sorry it’s not very elegant, but easy just wasn’t in the cards for this chore. I have a DROID X.
First: the issues. The Media Actions in Tasker don’t work for Pandora. So forget about Media Control (Next, Pause, Previous, Toggle Pause and Stop), Music Play and Music Stop. Also, the Kill App Action in the App Actions group doesn’t work (supposedly some Android OS limitation). Soooo what to do?
What does work? Pandora will start to play automatically when it is started from an Off state (not Paused, but Off, as in after Quitting Pandora). So that means we need to always start from a Pandora Off State. So we will always Quit or Kill Pandora whenever we stop listening to it. The Tasker Load App Action does work for Pandora. So when the Task Load App/Pandora is executed with Pandora in the Off State, the command will Load Pandora and Pandora will start Playing.
OK. So how do we get Tasker to put Pandora in the Off state when we are done listening? This is the tricky part. First we need to get Pandora in the Pause State and then we can kill it. For Wired Audio Connections this is not a problem. When the Audio Wire is pulled from the Headphone Jack, Pandora will automatically go into the Pause State. But when Bluetooth connections are terminated, Pandora will keep playing and turn on the Phone Speaker. So here is how we put it in Pause State. Pandora will Pause if another music App starts playing. I use doubleTwist for my music player on the phone and have it set as the Default Music Player (which must be done for this to work), but this should also work for the default Music player. I have Tasker Load the App doubleTwist and then execute Media Control/Toggle Pause. Next Action is Media Control/Pause. Now both Pandora and doubleTwist are in a Pause State.
Now I need to kill Pandora. For this I use the App Fast Reboot Pro by Great Bytes Software. This App does not require root and does not actually reboot your phone. It closes and restarts all core and user processes. But it will not kill an App like Pandora if it is Playing at the time. So that is why we put Pandora in Pause State. The free version of Fast Reboot closes and restarts everything, but does not allow you to selectively exclude Apps. I didn’t like that limitation and also think it adversely affected Tasker’s performance so I ponied up for the Pro version for about $1.40 (€0.99). Fast Reboot Pro is an App and a Widget. Tasker can Load an App, but can’t Load a Widget. So you need to set up the App first and then you can Load it with Tasker. To set it up, you first open the App and select the processes you want to exclude. I excluded almost every (especially exclude Tasker) except Pandora. We need to set it to the One Button Option so that Tasker can Load it (otherwise it loads up with the options screen and you would need to press some buttons), but once you set it to that option you can’t edit your exclusions without uninstalling and reinstalling the App (and then it loses your setting and you need start all over again, not a good thing). So test it first. When satisfied it works the way you want, Set the One Button Option to Yes. Now Opening or Loading the Fast Reboot Pro App will execute the close/restart processes that the Widget does. So that’s the way we Kill Pandora. First, we Pause Pandora by Playing doubleTwist. Then, we Pause doubleTwist. And finally we Kill them both. We now have everything in the Off State ready for our next listening connection.
I use Pandora five ways:
- Bluetooth Stereo Headphones – State/Bluetooth Connected/Bluetooth Stereo Headphones
- Wired Stereo Headphones – State/Headphones Plugged In and State/Not Bluetooth Connected/Car Bluetooth (CLS)
- Bluetooth Car Audio (Acura MDX) – State/Bluetooth Connected/Car Bluetooth (MDX)
- Wired Car Audio to AUX Input (Mercedes CLS550) – State/Headhones Plugged In and State/Bluetooth Connected/Car Bluetooth (CLS)
- Play through the phone speaker – Hardly ever use this, but if you do…be sure to Quit (not Pause) Pandora when you’re finished to insure the Tasker will work properly when used
In addition to having Tasker Load Pandora I have it adjust the Phone’s Media Volume because the Bluetooth connections all require Media Volume to be set at maximum because the Bluetooth device controls the volume. But with wired headphones you need the phone to control the volume. So for the wired headphones I have Tasker set the volume to level 5. So here are my tasks to get ‘r done.
- Display/Turn On
- Media/Media Volume/Level 15
- Apps/Load App/Pandora (for some connections I use Tasker/Perform Task/Music App Menu from the Tasker Wiki)
- Media/Media Volume/Level 0 (Not needed for Wired Connections, but for Bluetooth Connections you get a blip of music until the other commands are executed)
- Apps/Load App/App doubleTwist (not required for Wired Headphone Connection)
- Media/Media Control/Cmd Toggle Pause (not required for Wired Headphone Connection)
- Media/Media Control/Cmd Pause (note Stop does not work) (not required for Wired Headphone Connection)
- Tasker/Wait/10 Seconds
- Apps/Load App/Fast Reboot Pro
- Tasker/Wait/5 Seconds
- Media/Media Volume/Level 5
This works for all my Pandora sound devices, with some minor adjustments for each device. I hope this helps you and you find this works for you. If anyone knows of an easier way to do this, I’d love to hear about it.
I've been using this for a few weeks now and it works as presented, but I think that killing Pandora with the Fast Reboot Pro App is messing up Pandora. I seem to be getting an awful lot of songs that I just heard the prior time I used Pandora. I think that Pandora keeps track of what songs in your playlist you've listened to and picks up from the proper place if you just leave Pandora running or quit the App from its own Quit command. So for now I've removed the Load App/Fast Reboot Pro Action. So that means when I connect my device to the phone Pandora will become active and then it may start on its own or I may have to hit the Play button, depending on what state Pandora is in. There must be some way to stop and start Playing on Pandora. The Navigation App and Phone calls start and stop it.