Tasker + Media Utilities + Spotify

1,342 views
Skip to first unread message

Phil

unread,
Apr 1, 2014, 1:29:27 PM4/1/14
to tas...@googlegroups.com
I have a Car profile that when bluetooth/power connected launches Spotify and plays the current playlist.  That works quite well.  

What I now want to do is add the displaying of track info when the next track starts.  I know Spotify already does it but it shows in the menu bar which is displayed too small and too quickly to be seen by me while driving, so I'd like Tasker to display it larger and for a greater duration.  

I am able to detect the next track using the respective Media Utilities plugin event and then display an HTML popup that includes %MU_TRACK and %MU_ARTIST, among other variables... however none of the variables populate, I just see the literal "%MU_TRACK" text.  So it appears that Media Utilities variables aren't available even when tracks are playing.  I've also tried using Google Music with the same result, so it's not specific to Spotify.

Any ideas on why I can't access the MU_* variables from my tasks?  

However, I do see that there are some local variables available that seem to work %track, %artist, %appname, %isplaying and %coverart_uri but I wonder why the latter documented variables don't work.

Matt R

unread,
Apr 2, 2014, 12:17:23 AM4/2/14
to tas...@googlegroups.com
Those are for the widget creation apps, not Tasker.

Matt

Richard Wallace

unread,
Apr 2, 2014, 6:38:54 AM4/2/14
to tas...@googlegroups.com
You can creat global variables from the Media utilites locals:

Profile: Media Utilities New Meta

State: Media Utilities State [ Configuration:New Metadata ]

Enter: Anon

A1: Variable Set [ Name:%ARTIST To:%artist Do Maths:Off Append:Off ]

A2: Variable Set [ Name:%TRACK To:%track Do Maths:Off Append:Off ]

A3: Variable Set [ Name:%ALBUM To:%album Do Maths:Off Append:Off ]

A4: Variable Set [ Name:%ALBUMCOVER To:%coverart_uri Do Maths:Off Append:Off ]

 

Now you can place the fully capitilised variables in your HTML popup.

I use this method to populate text fields in a scene and it does work!

Phil

unread,
Apr 3, 2014, 2:18:29 AM4/3/14
to tas...@googlegroups.com
Thanks.  I don't really have the need for global variables, I just expected that the MU_* variables were available based on the Google Play page for Media Utilities.  

As of now, I have the HTML popup working and displaying the artist/track/album details.  It works pretty well, however, if I SKIP track too fast, consecutive popups cause Waze (my usual car GPS app that also launches in "car mode") to black screen indefinitely (if I press the BACK button on my phone it fixes it) but also when the initial popup flashes and then disappears it causes Waze to fully re-draw the map which isn't a huge deal but it would be nice if that could be avoided somehow.  I disabled the "show over keyguard" thinking that would fix that issue but no luck. I wonder if Minimalist Text or Zoom could fix either or both of these issues but I haven't yet installed either app since I'm unsure if that will fix anything.

Screech

unread,
Dec 4, 2014, 10:20:16 AM12/4/14
to tas...@googlegroups.com
Sounds similar to my setup. I have multiple variables/profiles for mine though. First is "In car" profile that detects "no mic headset and radio's Bluetooth address being near" and runs task to set InCar variable to Yes, disable keyguard (no lock screen), disables WiFi, disable the in car profile and enable out of car profile. Out of car profile triggers on InCar = Yes and no headset connected and all it does is set InCar to No, enables keyguard, enables WiFi, enables In Car profile and disables Out of Car profile. I have another profile (IgnOn) that triggers on InCar = Yes and any power connected and has enter and exit task. The enter task enables BT, wakes screen, sets the screen timeout to some really long time resumes music if it was playing and starts Waze. The exit task closes waze, pauses the music, sets screen timeout to shortest possible and disabled BT. There is a little more to the ignition toggling task to prevent them running on top of each other in the case of starting the car where the power is off while the key is in the start position. But for me that works since drive deliveries and leave the phone in the car while working. 

Like Richard I have a task that stores the %artist - %track variables to global ones. This task is called by New Track Detected profile that is triggered when Media Utilities State New Track is true.I have scenes for overlaying various apps with the track info from the global variables and music control buttons. It works most of the time. None of the scenes show if IgnOn = No. If IgnOn = Yes and one of the current app has a defined scene layout it is shown. On of the buttons also disables all the other overlays in case they are in the way of an action I'm attempting to do.




Nick Cassab

unread,
Nov 22, 2016, 3:52:13 PM11/22/16
to Tasker
Hey guys, trying to set up a simple taskr profile on my new pixel running nougat and whenever I use Media Utilities to send the play action it starts playing google play music.
nothing happens.  any thoughts?

technogeezer

unread,
Nov 23, 2016, 8:45:18 AM11/23/16
to Tasker
I believe Media Utilities is connected to your default music player.  You might be able to change this from Google Play Music to whatever you're using in the apps settings.

The problem with the profile in that link is that Bluetooth does not work the same in every car.  My Toyota, for example, must be in Bluetooth player mode.  When Bluetooth mode starts up it sends a play command to the my phone.  If I try to play before this command arrives, nothing is heard.

I have spent many hours trying to get a profile like this to work.  I've come close many times only to be thwarted by either a Tasker update or an update of my Toyota's OS.  At the moment, my profiles don't work at all even though they once worked perfectly.

HTH

Reply all
Reply to author
Forward
0 new messages