[MTCD Android Head Units General] jtrosky:
So I modified my Tasker setup to make it easier to add new apps to the setup... Here is have I have things setup now (may give others ideas or others may give me ideas to make it work better):

[b]Profile: GoIntoSleep (5)[/b]
Event: Intent Received [ Action:com.microntek.bootcheck Cat:None Cat:None Scheme:* Mime Type:* ]
Enter: PauseMedia (2)

[b]Profile: PlayOnlineAfterSleep (20)[/b]
State: Wifi Connected [ SSID:* MAC:* IP:* Active:Yes ]
State: Variable Value [ %CPPLAYER ~ Online ]
Enter: PlayMedia (21)

[b]Profile: PlaySDAfterSleep (3)[/b]
Event: Card Mounted [ Card Title:Music Frequency:* ]
State: Variable Value [ %CPPLAYER ~ Local ]
Enter: PlayMedia (21)

[b]Profile: PandoraRunning (14)[/b]
State: AutoNotification Intercept [ Configuration:Persistency Type: Persistent Only Notification Apps: Pandora ]
Enter: Pandora (15)

[b]Profile: PowerAmpRunning (17)[/b]
State: AutoNotification Intercept [ Configuration:Persistency Type: Persistent Only Notification Apps: Poweramp ]
Enter: PowerAmp (22)

[b]Profile: SpotifyRunning (18)[/b]
State: AutoNotification Intercept [ Configuration:Persistency Type: Persistent Only Notification Apps: Spotify ]
Enter: Spotify (19)

[b]Task: PlayMedia (21)[/b]
A1: Run Shell [ Command:input keyevent KEYCODE_MEDIA_PLAY Timeout (Seconds):0 Use Root:eek:n Store Output In: Store Errors In: Store Result In: ]

[b]Task: PauseMedia (2)[/b]
A1: Run Shell [ Command:input keyevent KEYCODE_MEDIA_PAUSE Timeout (Seconds):0 Use Root:eek:n Store Output In: Store Errors In: Store Result In: ] If [ %class ~ poweroff ]

[b]Task: SetLocalPlayer (10)[/b]
A1: Variable Set [ Name:%CPPLAYER To:Local Recurse Variables:eek:ff Do Maths:eek:ff Append:eek:ff ]

[b]Task: SetOnlinePlayer (12)[/b]
A1: Variable Set [ Name:%CPPLAYER To:eek:nline Recurse Variables:eek:ff Do Maths:eek:ff Append:eek:ff ]

[b]Task: Pandora (15)[/b]
A1: Variable Set [ Name:%CPPLAYER To:eek:eek:nline Recurse Variables:eek:ff Do Maths:eek:ff Append:eek:ff ]
A2: Variable Set [ Name:%PLAYER To:Pandora Recurse Variables:eek:ff Do Maths:eek:ff Append:eek:ff ]
A3: Perform Task [ Name:KillOtherApps Priority:%priority Parameter 1 (%par1): Parameter 2 (%par2): Return Value Variable: Stop:eek:ff ]

[b]Task: Spotify (19)[/b]
A1: Variable Set [ Name:%CPPLAYER To:eek:eek:nline Recurse Variables:eek:ff Do Maths:eek:ff Append:eek:ff ]
A2: Variable Set [ Name:%PLAYER To:Spotify Recurse Variables:eek:ff Do Maths:eek:ff Append:eek:ff ]
A3: Perform Task [ Name:KillOtherApps Priority:%priority Parameter 1 (%par1): Parameter 2 (%par2): Return Value Variable: Stop:eek:ff ]

[b]Task: PowerAmp (22)[/b]
A1: Variable Set [ Name:%CPPLAYER To:Local Recurse Variables:eek:ff Do Maths:eek:ff Append:eek:ff ]
A2: Variable Set [ Name:%PLAYER To:PowerAmp Recurse Variables:eek:ff Do Maths:eek:ff Append:eek:ff ]
A3: Perform Task [ Name:KillOtherApps Priority:%priority Parameter 1 (%par1): Parameter 2 (%par2): Return Value Variable: Stop:eek:ff ]

[b]Task: KillOtherApps (16)[/b]
A1: If [ %PLAYER ~ PowerAmp ]
A2: Kill App [ App:Pandora Use Root:eek:n ]
A3: Kill App [ App:Spotify Use Root:eek:n ]
A4: Else If [ %PLAYER ~ Pandora ]
A5: Kill App [ App:Poweramp Use Root:eek:n ]
A6: Kill App [ App:Spotify Use Root:eek:n ]
A7: Else If [ %PLAYER ~ Spotify ]
A8: Kill App [ App:Poweramp Use Root:eek:n ]
A9: Kill App [ App:Pandora Use Root:eek:n ]
A10: End If

Hope this makes sense. Don't hesitate to ask if anyone has any questions - or any tips to make this simpler...

So basically, if it's a "local" music player, I set %CPPLAYER to "Local" and if it's an "online" music player, I set %CPPLAYER to "Online". This is used later to determine if I need to wait for the SD card to become ready or wait for the Wifi to become ready before "un-pausing" the player after the unit comes out of sleep.

The %PLAYER varible is used so I know which exact player is currently active - so that I know what other players to kill (since i have them all whitelisted). For some reason, the Hal9k "apps that cannot run simultanously" doesn't work for me, which is why I have to do this. I don't want a bunch of apps running when the unit sleeps (still not sure if the unit uses more battery power in sleep if more apps are running?).