Archive for the ‘mobile’ Category

Control Your Music Playback from an iDevice without using iTunes? Yes!

Sunday, October 26th, 2014

For a variety of reasons, I prefer not to run iTunes on the old Windows XP computer that I have connected to the TV and amplifier at home.

Kids these days might call it a HTPC (home theatre PC), but in my case, it really is just a generic used computer – in fact, it doubles as the box I infrequently use for tasks like testing a hard drive, trying to image or salvage data from a disk, or testing other desktop computer components.

By number of hours of use, the machines #1 job is to be a physically enormously MP3 player. For the last couple years, I have used the trusty old WinAmp and either the wired keyboard, or the wireless keyboard, or remotely connected via VNC to add and remove tracks. It wasn’t ideal, but it generally worked fine. I really wanted a way to add items from the library to the playlist from my phone, though. Either an App or a functional mobile web page would be great.

It had been a couple years since I had thought about this, so I did some research and tried a few things. I tested both MusicBee (totally free), and the free edition of MediaMonkey. Both are highly rated, and quite good, media players. However, neither had built-in web sites for web controls or iPhone controls. There were plugins or extensions that offered these features, but, either they didn’t have an interface that worked for my needs, or they just didn’t work on my setup. This box runs XP, and the media playing runs under a Limited User account in Windows, these were at least part of the the problems. Admittedly, I didn’t want to spend too much time on this project, so I didn’t spend too much time trying to get these working.

Thanks to browsing the plugin library of MediaMonkey, I did learn the term DACP, this is the proprietary standard that Apple created to control iTunes (and other media devices) from iOS, i.e. the free Apple Remote app.

With the term DACP in hand, I was able to find out that there was a plugin for Foobar2000 that provided DACP support. I am somewhat familiar with Foobar2000, so, giving this DACP plugin, foo_touchremote, from http://wintense.com/plugins/foo_touchremote – was a no-brainer.

It worked. Surprisingly easily (given my troubles with the other packages that I had tried yesterday).

And, even better, the Apple Remote user interface on my iPhone is fantastically better than anything I could hope for from a web based interface. There are, apparently, Android DACP apps too.

So, the moral of this blog post? I would think that remote control of music (even just volume controls and pause/play) would be a high priority feature of media players by now – I don’t really understand why these highly rated media players don’t have built-in, well-tested, support for either a mobile web controls or a app controls.

Anyway, I’m happy for now with Foobar2000 + foo_touchremote plugin.

 

Using the PHP PEAR Services_Twitter Package with HTTPS

Saturday, January 25th, 2014

I have a PHP script that runs every few minutes via a cron job that has been running for a few years to send me direct messages on Twitter from a single-purpose Twitter account. The net result is that I can have system alerts sent to me by text message (by having direct messages from this special account subscribed for mobile alerts).

This script stopped working a week or two ago, and I finally got around to figuring out why. On Jan. 14, 2014, Twitter made SSL/TLS mandatory for connections to api.twitter.com. The announcement / blog post about that is here: https://dev.twitter.com/discussions/24239

Apparently, and not surprisingly, the PEAR module, Services_Twitter (available here: http://pear.php.net/package/Services_Twitter/),  works with api.twitter.com, and thus stopped working.

The fix was simple, once I was able to decipher the automated docs…

After this line: $twitter = new Services_Twitter();

I added this line: $twitter->setOption(‘use_ssl’,true);

The placement is probably flexible. But this one line worked. And my phone is now getting all those text message alerts that I dread. Yipee (?)

I wonder if I’m the only person using this library, considering that my Google searches came up surprisingly sparse on this topic…