Firmware: A-410 [01 Apr. 2014] | A-400 [12 Mar. 2014] | C-300 [13 Feb. 2014] | A-300 [24 Feb. 2014] | C-200 [11 July 2013] | A-200/A-210 [11 July 2013] | Popbox V8 [3 Dec 2013]

Just got your NMT | WIKI has the answers | Search the forum | Forum Rules/Policy | Firmware & Official NMT News | Popcornhour manuals



User(s) browsing this thread: 2 Guest(s)
Post Reply 
MediatankController 1.2 for iPhone - browse and control your NMT from your phone
06-17-2009, 06:27 PM
Post: #91
RE: MediatankController for iPhone - Experimental!
Hi,

This really works brilliant!!!
I got it to work !!!
Find all posts by this user
Add Thank You Quote this message in a reply
06-22-2009, 02:03 AM
Post: #92
RE: MediatankController for iPhone - Experimental!
(04-23-2009 06:02 PM)humptybump Wrote:  I've been making a few of changes to the code base ...
  • added sorting (language sorting works so "program 1" comes before "program 10" with "PROGRAM 5" in between, etc.)
  • added most PCH remote control buttons (including power on/off)
  • added "hide directories starting with an underscore"


I want to coordinate with Neils so we don't continue with two code bases...

I've also made a simple change. I've added this to the main case statement. This way, I didn't have to add entries for each button on the remote in the script.
Code:
    case 'sendir':
        $command = $_GET['code'];
        exec("echo " . $command . " > /tmp/irkey");
        break;

I know ZERO php, and guessed the syntax from the rest of the script. It works, except you have to pass a decimal "code". Hex doesn't work. Anyway, you link to:

http://ipaddress:8088/stream/file=/opt/sybhttpd/localhost.drives/HARD_DISK/controller/index.php?action=sendir&code=168

for instance, to execute 0xA8, or "Cursor Up". No need to modify the script to add support for more buttons.

- Mike
Find all posts by this user
Add Thank You Quote this message in a reply
[+] 2 users say Thank You to mjr for this post
07-12-2009, 12:45 AM
Post: #93
RE: MediatankController for iPhone - Experimental!
(04-01-2009 08:34 PM)Niels Leenheer Wrote:  Hi everybody,

This afternoon I decided to play around a bit with an experimental iPhone webapp for controlling the NMT. It's not a native iPhone app, but a small piece of PHP code that you need to install on the NMT. Once installed you can use Safari on the iPhone to access the webapp. I believe you can even create a separate home screen button for this webapp.

The thing is... I don't have an iPhone... so it's completely untested and experimental. The only thing I did was load it in an iPhone emulator and it worked.

Feature wise it is still very limited. But still it is possible to browse your NMT, start playing files and bring up a very simple control interface for playing, pausing and navigation.

Download the controller.zip file, unzip it and place the controller directory in the root of the hard disk of your NMT.

Load the following url in Safari on your iPhone:
http://IP-OF-YOUR-NMT:8088/stream/file=/opt/sybhttpd/localhost.drives/HARD_DISK/controller/index.php

Great App! I can finally listen to music without turning on my TV!!
Find all posts by this user
Add Thank You Quote this message in a reply
07-14-2009, 04:16 PM
Post: #94
RE: MediatankController for iPhone - Experimental!
Hi Guys,
Its been a while since i've visited this thread or worked on this app. Fortunately I now have an iPhone for myself, so I can test it properly and make some much needed improvements.

Cheers,
Niels

mediatankcontroller.com: the home of MediatankController 1.0 for Adobe AIR and MediatankController 1.0 for iPhone and iPod Touch.
Visit this user's website Find all posts by this user
Add Thank You Quote this message in a reply
[+] 2 users say Thank You to Niels Leenheer for this post
07-14-2009, 04:50 PM
Post: #95
RE: MediatankController for iPhone - Experimental!
I'd love to see a native app made for the PCH. Make it look nice and purty and sell it on the app store Smile
Find all posts by this user
Add Thank You Quote this message in a reply
07-14-2009, 04:51 PM
Post: #96
RE: MediatankController for iPhone - Experimental!
I would love an app for the S60v50 and not just the Jesus phone.

Samsung PS51d8000, Onkyo 509, Tannoy EFX5.1, Xbox 360, Popcornhour C200, Sky+HD, Wii, Harmony one
Find all posts by this user
Add Thank You Quote this message in a reply
07-15-2009, 04:42 AM
Post: #97
RE: MediatankController for iPhone - Experimental!
(07-14-2009 04:16 PM)Niels Leenheer Wrote:  Hi Guys,
Its been a while since i've visited this thread or worked on this app. Fortunately I now have an iPhone for myself, so I can test it properly and make some much needed improvements.

Cheers,
Niels

In my best Mr. Burns voice... "Excellent"
Find all posts by this user
Add Thank You Quote this message in a reply
07-16-2009, 09:32 AM
Post: #98
RE: MediatankController for iPhone - Experimental!
awesome stuff, this! is it at all possible to have a power button on this? Since on the popcorn that only turns the video output on/off it should be possible, right? then we wouldn't need the original popcorn NMT remote at all really Smile Smile (and as it really sucks that would be a good thing)
Find all posts by this user
Add Thank You Quote this message in a reply
07-16-2009, 04:00 PM
Post: #99
RE: MediatankController for iPhone - Experimental!
(05-01-2009 07:50 AM)bond Wrote:  It works great. I have been really looking for something like this since I do not like to switch on the TV to play music and I had a iPhone handy. I even bought PlugPlayer for 4.99 to get the remote play functionality.

You would have saved me the money if you had started this earlier Smile

BTW, the biggest gripe I had with PlugPlayer (other than the fact that it often crashed) was I could only play one file at a time.

The controller script also has the same issue but I could hack it pretty easily.

I used NMT Playlist generator to auto-generate playlists for all my music directories and then patched the controller:

PHP Code:
                    case MediaTypes::isPlaylist(basename($file)):
                        
$file preg_replace("/([^\w:.,-\/])/x""\\\\\\1"$file);
                        
$command "rm -f /tmp/playlist.txt; sed -e '2,$!d' " $file " | sed -e '$d' > /tmp/playlist.txt; mono -playlist file:///tmp/playlist.txt -dram 1 > /dev/null 2>&1 < /tmp/irkey";
                        break; 

I think you can easily guess what changes I had to do to the mediatypes.php library file.

Now I can click on the jsp file and put the iPhone away!

P.S.: I have been lurking here for an year, but finally registered just to post regarding this. you can imagine my happiness at being able to hack it Big Grin

Can anyone help me guess what change is needed to the mediatypes.php file? I have to confess that I tried several things without success confused I desesperatly need to play all file in folder at once !!

Many thanks in advance, and thanks again Niels for this brillant application !!!
Find all posts by this user
Add Thank You Quote this message in a reply
07-17-2009, 03:00 PM (This post was last modified: 07-17-2009 03:03 PM by erdincyilmazel.)
Post: #100
RE: MediatankController for iPhone - Experimental!
I just installed this great looking application on my PCH-A110, it seams to be working fine (Without errors) but selecting a media doesn't make the device play it. The control buttons are working fine, I can jump from a menu to another using my iphone and see it on the TV. The only problem is media playback. I can't trigger a play action on the device. index.cgi/index.php and busybox26 files have 755 permission. What can be the problem? Are there any log files or anything on the server side that I can check? The adobe air MediatankController app is working without any problems.

Thanks
Find all posts by this user
Add Thank You Quote this message in a reply
07-17-2009, 03:27 PM
Post: #101
RE: MediatankController for iPhone - Experimental!
(07-16-2009 04:00 PM)Tonio08 Wrote:  Can anyone help me guess what change is needed to the mediatypes.php file? I have to confess that I tried several things without success confused I desesperatly need to play all file in folder at once !!

Many thanks in advance, and thanks again Niels for this brillant application !!!

Add the following code to the mediatypes.php file:
PHP Code:
function isPlaylist($file) {
        switch(
end(explode("."$file))) {
            case 
'jsp':
                return 
true;
        }
        
        return 
false;
    } 

Also you need to edit the isVisible function in the mediatypes.php file as follows:
PHP Code:
function isVisible($file) {
        return 
MediaTypes::isPlaylist($file) || MediaTypes::isVideo($file) || MediaTypes::isAudio($file);
    } 

Now you should be able to see the .jsp files in your browser.
Find all posts by this user
Add Thank You Quote this message in a reply
[+] 1 user says Thank You to jmjlewis for this post
07-19-2009, 08:44 PM (This post was last modified: 07-20-2009 12:36 AM by gfb107.)
Post: #102
RE: MediatankController for iPhone - Experimental!
(06-10-2009 06:37 PM)dc11ab Wrote:  This is quite easily done. Just take a copy of the skin files (line_movie.htm etc. from the default Aquarius skin, for instance) then grab some nice webkit template - and combine the two.

Either you go Jukebox-style or normal text inteface. The code below is just a mockup/experimental, not ready for primetime by any means. I have had no time to work with it, but I'm sure it would not take but some hour for an experienced php-hacker to whack it up properly.
I've been experimenting combining a YAMJ skin with this MediaTankController for iPhone. It's working out really nicely. I'll start a thread for it when I get a little further along.

However, there's one change I had to make to MediaTankController that nobody else has mentioned, and I would have expected it to be required for use with llink. I switched from Base64 encoding to URL encoding for file and directory paths.

The code changes are very minor. Just replace all instances of base64_decode with urldecode, and all instances of base64_encode with urlencode, respectively.

The modified files are:
  • index.php
  • themes/iphone/files.html
  • themes/iphone/index.html


Quote:Not sure why, but I found that putting the CSS stuff in the head.htm worked out best. Using a CSS file did some strange things.
I've seen that too. Something in the way llink serves up files prevents it from serving CSS files. I use llink (running on a DNS323 and a NSLU2) to stream my video files, but this issue prevents it from serving up my YAMJ Jukebox. So I just keep the Jukebox on the PCH internal drive.

iSkin(2) (Donate) | PlexNMTHelper (Donate)
Visit this user's website Find all posts by this user
Add Thank You Quote this message in a reply
[+] 1 user says Thank You to gfb107 for this post
07-19-2009, 09:00 PM
Post: #103
RE: MediatankController for iPhone - Experimental!
Yeah, I think I only got the CSS rendered from a file if in the llink media root, not when entering a subdir. I'm far from an expert so I couldn't really explain myself well for lundman or find something useful in the logs, perhaps you can give it a shot?

Oh, and thanks for mentioning the urlde/encode! Sorry, I totally overlooked that in my simplistic explanation.

Audio, video, disco - I hear, I see, I learn.
Wiki. Wiki? Wiki!
Find all posts by this user
Add Thank You Quote this message in a reply
07-30-2009, 05:26 PM (This post was last modified: 07-30-2009 06:28 PM by gfb107.)
Post: #104
RE: MediatankController for iPhone - Experimental!
Niels, any chance you'll update your distribution with the changes discussed here?
  • Adding the rest of the remote commands. Sure wish we knew the irkey codes for Standby and Resume from Standy.
  • Replacing base64_encode/decode with urlencode/decode
  • Playlist support

I have a YAMJ iphone skin I want to make available, and it'd be nice to just point potential users to your download.
Otherwise, I guess I can bundle an updated version with the skin, if that's OK with you.

iSkin(2) (Donate) | PlexNMTHelper (Donate)
Visit this user's website Find all posts by this user
Add Thank You Quote this message in a reply
07-30-2009, 05:43 PM (This post was last modified: 07-30-2009 05:44 PM by humptybump.)
Post: #105
RE: MediatankController for iPhone - Experimental!
Niels / gfb107,

I added UI and buttons for most remote comments we have Ir codes for. Feel free to copy my work and fold it into the main stream.

Here is a screenshot:
[Image: popcornhourcontrollerremoteportrate.jpg]


Here is a link to my zip:
iPod Touch app for PCH
Find all posts by this user
Add Thank You Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Pure Web Remote Control or Listening Audio with switched off TV pompon 170 86,150 10-08-2013 03:24 PM
Last Post: alkr
  NMT remote iPhone native app. racermonoid 391 178,224 07-06-2013 12:08 PM
Last Post: jojo88
  MediatankController 1.2 with Android Hann1BaL 9 7,030 05-16-2012 10:26 PM
Last Post: MacLeod
  MediatankController 1.0 for Adobe AIR - browse and control your NMT from your PC Niels Leenheer 232 211,270 05-13-2012 10:48 PM
Last Post: robertazimmerman
  is there an android remote control for the A110? jadeddog 2 3,640 06-04-2011 11:27 PM
Last Post: dw_bobby
  Can I browse MediaBox by Bonjour via my Android/Iphone App? stanly007 0 1,856 05-23-2011 11:02 AM
Last Post: stanly007
  music player daemon MPD & PCH Remote control beatnut88 19 11,998 12-22-2010 12:31 AM
Last Post: dooly
  a110 - iphone - torrent wasssu 0 1,821 11-17-2010 05:53 PM
Last Post: wasssu
  Psiloc IRremote Control PCH with Nokia Smartphone Insel_Affe_30 0 2,621 05-26-2010 11:28 AM
Last Post: Insel_Affe_30
  Download Links for TouchEverything - Remote Control NMT with PC, Web Youcontrol 4 4,297 04-07-2010 09:46 PM
Last Post: gfb107

Forum Jump: