Re: n00b question about Pandora

371 views
Skip to first unread message

Eric

unread,
Sep 23, 2013, 1:26:19 PM9/23/13
to tas...@googlegroups.com

I am still a n00b but I did find one way for this to work and I thought I would post it here.  

  1. I have a scene that is launched when I plug in my headphones. 
  2. I have a couple buttons on the scene with the name of the Pandora station. 
  3. When I tap one of the buttons, my phone launches the Opera Browser with the load app function. In the data field I put the URL for the desired station that I copied from the address bar on my laptop. (I normally use Chrome, but here I use opera because each time I click the scene a new tab is made and if I open Opera randomly it will reload Pandora because the open tab is a link to the Pandora app. So I don’t want to be opening the Pandora app each time I want to go on the web.)
  4. Opera is launched and the link in the data field automatically starts the Pandora app on the desired station. 

I am sure there is a better way to do this but for my skill level this way works for me.

I would love to hear more efficient solutions if anyone has better ideas. 


On Wednesday, May 1, 2013 8:43:28 PM UTC-4, Eric wrote:
My idea in short is, I want to make a task that launches a specific Pandora station as apposed to the last one that was played. Is this possible?

As far as I could find on my own this has something to do with sending intents, but I don't know how to do that. And I have read Pandora either doesn't have or cant receive intents. So I'm posting here to see if anyone has another idea of how this could be done. I have tried using the D-pad movements and clicks but this doesn't work because it depends on what the last station that was listened to.

Thanks for any new ideas. 

Matt R

unread,
Sep 23, 2013, 2:47:23 PM9/23/13
to tas...@googlegroups.com
What if you instead of loading opera you use the Browse URL action?

Matt

Eric

unread,
Sep 23, 2013, 3:06:47 PM9/23/13
to tas...@googlegroups.com
I didn't do that because that opens a new tab in my default browser, Chrome. Then the next time I open Chrome it reloads the new tab and launches Pandora again. So I used Opera to keep all those new tabs from reloading and and not launching Pandora when I don't want it to.

Eric

unread,
Apr 30, 2014, 11:20:53 PM4/30/14
to tas...@googlegroups.com
So I know I'm the only one posting about this but I finally figured out how to launch a specific Pandora station. So for other beginners like me here is what I did.

1 when I plug in headphones I have a scene that shows up, then based on the selection I make I set the %PANDstation variable to the desired station.

2 the following profile runs

Profile: Pandora Change Station (122)
Event: Variable Set [ Variable:%PANDstation Value:* ]
Enter: Pandora Change Station Intent (113)
A1: Perform Task [ Name:Volume Gradual Stop:Off Priority:9 Parameter 1 (%par1): Parameter 2 (%par2): Return Value Variable: ] If [ %PACTIVE ~ *music vg* ]
A2: Variable Set [ Name:%DATASTAY To:%TIMES+(60*60*2) Do Maths:On Append:Off ]
A3: Wait Until [ MS:0 Seconds:3 Minutes:0 Hours:0 Days:0 ] If [ %CELLSIG > 1 ]
A4: Send Intent [ Action:android.intent.action.VIEW Cat:Default Mime Type: Data:pandorav2:/createStation?stationId=%PANDstation Extra: Extra: Package:com.pandora.android Class:com.pandora.android.Main Target:Activity ]
A5: Perform Task [ Name:Kill Play Music Stop:Off Priority:4 Parameter 1 (%par1): Parameter 2 (%par2): Return Value Variable: ]

So I make a selection on the scene, it sets a variable and then the desired Pandora station launches.

%PANDstation should be set to the sequence of numbers shown at the the end of the address bar of your computer when listening to a station.

If you're interested and have more questions I'll be happy to help.

Bolu

unread,
Jun 10, 2015, 10:49:46 PM6/10/15
to tas...@googlegroups.com
Eric,

Does the command below still work for you? I am having trouble with it - it just opens up and pays the current pandora station. My basic setup is that I have two files that tasker read (stationNames.txt and stationIDs.txt). The user says a station name/nickname through Autovoice/GoogleNow, and then tasker searches the stationName array for the voice input, and returns the corresponding stationID. I then set that PANDstation to the returned stationID and run the intent exactly as below. I have flash alerts so i know the correct stationID is being selected, but nevertheless, the intent below just opens pandora with the last played station. I am on lollipop 5.1 (CM 12.1 actually) running pandora 6.0

Any help you can give would be greatly appreciated.

Eric

unread,
Jun 10, 2015, 11:27:59 PM6/10/15
to tas...@googlegroups.com
My task has gotten a little more personalized since the original post but I exported the description of the intent part and put it below. The only difference I see at the moment is that %PANDstation is now %par1. But it is still the same idea of using the station id number.

One time someone tried to use it and there was a space after their id number that they couldn't see in the flash alerts that caused it not to work so that's a possibility. I use SwiftKey and it is always adding spaces to my variables in Tasker.

It is still working for me every time. I've got a Droid Turbo 4.4.4 stock and Pandora version 6.0. I don't feel like that helped much but I can tell you it does still work. Let me know if you figure it out. If not I'll post one with a static id or something.


Pandora Change Station (113)
A10: Send Intent [ Action:android.intent.action.VIEW Cat:Default Mime Type: Data:pandorav2:/createStation?stationId=%par1 Extra: Extra: Extra: Package:com.pandora.android Class:com.pandora.android.Main Target:Activity ]

Stephen Schrauger

unread,
May 12, 2016, 3:04:52 PM5/12/16
to Tasker
This is exactly what I needed. Thanks for figuring out the exact Intent to call! Launching a browser url was getting old. Much appreciated! Now I can automatically listen to a specific station on my way to work, and a different one on my way home using time based profiles and bluetooth connection states.

Eric Sheep

unread,
May 12, 2016, 3:44:35 PM5/12/16
to tas...@googlegroups.com

Great I'm glad it helped someone else! It took me a lot of trial and error, I'm no developer.

Eric.

--
You received this message because you are subscribed to a topic in the Google Groups "Tasker" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tasker/p2i_cesy8Bk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tasker+un...@googlegroups.com.
Visit this group at https://groups.google.com/group/tasker.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages