Shirt Pocket Discussions

Shirt Pocket Discussions (https://www.shirt-pocket.com/forums/index.php)
-   General (https://www.shirt-pocket.com/forums/forumdisplay.php?f=9)
-   -   Hotkey Control of Remote machine? (https://www.shirt-pocket.com/forums/showthread.php?t=1273)

thom 05-08-2006 01:44 AM

Hotkey Control of Remote machine?
 
Hello,

I checked out netTunes and it seems like a good enough solution to the iTunes remote control problem. I'm not sure if I agree that the answer should be 100% dependant on screen-scraping -- part of me wonders if there couldn't be some inter-application messaging between the server app and the iTunes, possibly using Apple Events / applescript? Does it do any of that right now? Just a thought. (And besides, right now I'm using Apple Remote Desktop to control it on the remote machine, which is a pain, to put it mildly.)

At the present time I'm using Sizzling Keys from Yellowmug.com to control iTunes on my local computer.

I like SizzlingKeys because it allows me to use FKeys on my powerbook to play/pause (F3), Rewind (F4), Forward (F5), Toggle Shuffle (F6) and briefly display display a 'What's playing' window with album art (F7), not to mention Volume Up/Down (Cmd-Opt-Up/Dn arrow). I should mention that the product is free, though I paid the $5 for the 'Pro' version to access features like 'toggle shuffle.' :) And no, I'm not a paid shill, I just like the product. ;)

However, I have my Intel Mac mini hooked up as a home theater PC, and just moved my (external) music library to that machine so I could play it through my stereo.

Ideally, I'd love a way to easily toggle between 'local' and 'remote' control, like from a small icon in my menu bar, using the same FKeys. But, I expect that that might be pretty difficult to achieve.

As a compromise, would it be possible to add a menu to netTunes, possibly called, 'Control' that included many of these features? I think that if the commands were selectable as menu items, then the keyboard and mouse preference pane, Keyboard Shortcuts tab, could be used to assign hotkeys to those menu items. (Right?)

Patiently waiting for the Universal version -- obviously that's the priority for me, or all else is a moot point! But once that's taken care of, does this seem like a pretty reasonable request? Does it seem like it would work?

thom 05-08-2006 02:41 AM

Oh yeah, and while I'm asking for the moon...
 
...I realized that instead of / addition to asking for a 'Control' menu...

I should just ask for appleScript support.

And then I looked with Script Editor, and lo and behold... there already is an AppleScript Dictionary! Hooray! Thanks, Dave Nanian!

Now I just need to convince YellowMug to allow hotkeys to trigger applescripts, instead of directly controlling iTunes... :D

So instead, I'll ask about these things that SizzlingKeys has and netTunes doesn't, yet:
  • Toggle Shuffle
It would be nice to be able to toggle the shuffle mode on the remote iTunes instance. Normally I leave things in Shuffle, but when something comes on that I like, it's great to be able to hit a key and disable shuffle to stay within that album.
  • Remote Volume Up / Down
The volume thing I can handle, but it'd be nice if there were commands that would increment or decrement the remote iTunes' volume level by some fixed amount, like 5 or 10. (or, user settable... )
  • Remote Album Art
Finally, and this is total minutiae, but, it'd be great if there was a way for an applescript to request the graphic object of the remote iTunes' album art. But that's totally icing on the cake. And then I'd have to convince YellowMug to ALSO allow display of SizzlingKeys' floater window with data from an AppleScript... So I'll shut up now.

Thanks!

dnanian 05-08-2006 08:17 AM

Glad you found the script support: we do, indeed, do a lot more than just screen scraping!

Haven't been asked for "toggle shuffle" before, but I'll take a look a it for the future. Volume control is already there in the dictionary, as I recall, so I'm not sure anything needs to be done there.

Album art is something that appeared recently, and isn't part of all of the versions of iTunes we support... it'd also likely be much slower... but I'll consider it.

Thanks for the suggestions!

thom 05-08-2006 01:35 PM

Toggle Shuffle
 
I learned a pretty easy way to toggle shuffle from this thread on the MacScripter BBS. I also posted my results at the bottom of the page about using Growl for Quartz-style notification.

In short, the command would be something like

Code:

tell application "iTunes"
    activate
    tell first library playlist to set shuffle to not shuffle
end tell

Hope this is helpful. It would be nice to get back some kind of state on the client side, not just have the toggle work - and/or be able to request the shuffle state of the remote machine.

Thanks for the prompt reply and for considering Album art! I think that combined with Growl notification, it could make for a REALLY powerful extension to this app.

But I digress. Universal first! :D

dnanian 05-08-2006 01:46 PM

I'm definitely aware of the method used to set shuffle, etc -- it's just a matter of extending the scripting definitions, dictionary and implementations (local and remote) to support it... late for this release but, as I indicated, potentially doable for the future.

Note that netTunes already broadcasts the standard iTunes notifications for track name, artist and current play state. Those could be used by a Growl client to support *both* iTunes *and* netTunes transparently: iChat already does this...

thom 05-08-2006 02:16 PM

Quote:

Originally Posted by dnanian
Note that SD! already broadcasts the standard iTunes notifications for ...

Dude, you have SD! on the brain. :p

Guess it's understandable given what a favorable response there has been to SD!, but... (sniff sniff) WHAT PRICE GLORY, Dave Nanian!!?

dnanian 05-08-2006 02:56 PM

Ack! Fixed.

Sorry -- netTunes, while quite popular, doesn't have nearly the support load of SuperDuper. I type SuperDuper so many times a day, I can't even tell you. Ow. :)

thom 03-03-2007 02:49 AM

Has there been progress on remote shuffle?
 
Quote:

Originally Posted by dnanian (Post 6666)
Haven't been asked for "toggle shuffle" before, but I'll take a look a it for the future.

Thanks for the suggestions!

Dave,

I finally decided it could be done and I got around to doing it -- so I bought netTunes! Woohoo!

I am using QuickSilver to bind the key triggers to run different applescripts.

If netTunes is running, send the command there. If not, send it to iTunes:

Code:

tell application "Finder" to name of processes
if the result contains "netTunes" then
        tell application "netTunes"
                tell the connected server to next track
        end tell
else
        tell application "iTunes" to next track
end if

Soooooo... in celebration of my long-awaited purchase of netTunes... and of the fact that I finally got this thing working the way I wanted it to for the past two years (sheesh!) ... any possibility of toggling remote shuffle, and being able to ask what the current shuffle state is?

Thanks! -- TB

dnanian 03-03-2007 10:50 AM

It's something I'm considering for a future update, Thom -- glad you got things working the way you want! :)


All times are GMT -4. The time now is 09:15 AM.

Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2024, vBulletin Solutions, Inc.