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: 1 Guest(s)
Post Reply 
MediatankController 1.2 for iPhone - browse and control your NMT from your phone
04-01-2009, 08:34 PM (This post was last modified: 07-26-2010 02:58 PM by Niels Leenheer.)
Post: #1
MediatankController 1.2 for iPhone - browse and control your NMT from your phone
Ever wanted to control your NMT from your iPhone. I decided to play around a bit and created my own iPhone webapp. It's not a native iPhone app, but a small piece of PHP code that you need to install on the NMT.

Just download CSI from nmtinstaller.com and follow the instructions. The package is called MediatankController. After installing follow the instructions for installing it on your iPhone home screen.

Use Safari on your iPhone to open the webapp. The location should be something like this: http://[IP address]:9999/MediatankController_web/. Important: you must use the IP address of your own NMT. Finally, click on the + button and use "Add to Home Screen" to create a button on the home screen of your iPhone.

[Image: IMG_0209.PNG]
[Image: IMG_0210.PNG]
[Image: IMG_0211.PNG]


Changelog

Version 0.5
  • Media files are started in a different way, which should be more stable.
  • After playing a media file, the mediatank will show a page which allows you to go back to your previous location in the mediatank browser. Previous versions would simply restart the browser in the default location.
  • Data is now transmitted in JSON form between the iPhone and the mediatank, which should be a bit faster (less data to transmit).
  • Directories are cached on the iPhone itself, using a HTML5 storage database. This means faster browsing if you have visited a directory before. The cache is persistant even between sessions. You can refresh a directory by clicking on the title. Click on the title of the Home page to empty the cache completely.
  • The current directory location is remembered between sessions. You can browse to a location, start a media file, read your e-mail, surf the web and return to the directory where you originally were without having to manually browse back to that directory.
  • Added Fast forward and Rewind buttons to the Controls page.
  • The Controls page can now be scrolled with just one finger.
  • Added a keyboard button on the Controls page for easier text input
  • Added webservices


Version 0.4
  • First release of MediatankController on CSI
  • Added support for the lighttpd package which should increase the loading speed of this webapp.


Version 0.3
  • Custom icon for your home screen
  • When started from your home screen it now works full screen
  • Network shares are listed on the same page as the rest of the disks
  • Disks, usb drives, network shares, folders, playlists, video files and audio files now have their own icon
  • Smaller font for more readable filenames
  • Natural sorting of files
  • Support for playlists
  • Completely redid the controls page. Scroll with two fingers to show all buttons (sorry still working on one finger swiping for this one)
  • Updated iUI for smoother animations
  • Patched iUI to prevent reloading pages after they have been loaded the first time
  • Removed base64 encoding from URLs, replacing it with URL encoding
  • Proper support for ISO files
  • Moved to the Apps directory for better NMT Community Software Installer support
  • JukeboxConnector support
  • Experimental support for streaming playback of files on the iPhone itself (enable in the index.php file)


Version 0.2
  • It is now possible to browse to USB drives
  • It is now possible to browse to network shares (as long as they are added on the configuration screen of the NMT)
  • Files larger than 2Gb are now also shown (also caused problems for ISO's)


Version 0.1
  • Initial release


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
[+] 31 users say Thank You to Niels Leenheer for this post
04-01-2009, 09:56 PM
Post: #2
RE: MediatankController for iPhone - Experimental!
Works fine on Android as well so I guess any decent handset with a browser will do...

Great work BTW!

PCH-A100 (beta fw) + PCH-C200
Streaming from ReadyNas (llink and nfs)
Sony 40-x3500 TV
Visit this user's website Find all posts by this user
Add Thank You Quote this message in a reply
04-01-2009, 10:01 PM (This post was last modified: 04-01-2009 10:44 PM by dc11ab.)
Post: #3
RE: MediatankController for iPhone - Experimental!
Holy rusty island, Batman! It works!


Yes, great work Niels. I have made a simple Jukebox skin for llink but lacked the controls, but now I can finally use them for real! (ehum, with some slight modifications)

[Image: iphonejukeboxhorizontalwj2.th.jpg]
[Image: iphonejukeboxhorizontalhz8.th.jpg]


I love the possibility to browse media while listening/seeing on something else in play.

The Controls page is slightly weird; is it a "full screen popup"? If I scroll below the buttons (which works fine) the underlying directory list is visible. Hmm, I should browse the code and see for myself.

I would add the 'Standby'/Power On and 'Source' button to the controls. Well, all buttons eventually, but they would clutter the display so I guess one has to be a little smarter about it.
Ah, and browsing any mounted directory shares too.

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
[+] 1 user says Thank You to dc11ab for this post
04-02-2009, 03:24 AM (This post was last modified: 04-02-2009 03:42 AM by wikkid.)
Post: #4
RE: MediatankController for iPhone - Experimental!
I can connect and everything seems to work, but I get no file listings on the phone. The controls work, just no file listing.

I've tried both mkv and jpg files (from the jukebox on the nmt).. No listing in any folder.

Could I be missing something?

Did some more testing. Tried putting the file in a folder by itself in case there was too many files. Tried renaming the file to test.mkv in case something in the names was messing it up, neither worked.

Your AIR based controller works great, lists files and everything. I"ll keep digging.
Find all posts by this user
Add Thank You Quote this message in a reply
04-02-2009, 09:14 AM (This post was last modified: 04-02-2009 09:15 AM by dc11ab.)
Post: #5
RE: MediatankController for iPhone - Experimental!
Wierd, works for me - although not complete:
I can see directories and list/launch music and video files.
However this app did not "see" any jpg photo, the Photo dir was shown as empty.

But from telnet:
/opt/sybhttpd/localhost.drives/HARD_DISK # ls -l Photo/
-rwxr--r-- 1 nmt nmt 1594267 Jan 26 2008 IMG_0236.JPG
-rwxr--r-- 1 nmt nmt 54008 Apr 13 2008 IMG_1398.JPG
-rwxr--r-- 1 nmt nmt 65234 Apr 13 2008 IMG_1599.jpg
drwxr-xr-x 5 nmt nmt 4096 Mar 23 22:47 _theme_
-rwxr--r-- 1 nmt nmt 35947 Apr 18 2008 monitor_calibration.gif

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
04-02-2009, 11:30 AM (This post was last modified: 04-02-2009 11:40 AM by Niels Leenheer.)
Post: #6
RE: MediatankController for iPhone - Experimental!
(04-02-2009 09:14 AM)dc11ab Wrote:  Wierd, works for me - although not complete:
I can see directories and list/launch music and video files.
However this app did not "see" any jpg photo, the Photo dir was shown as empty.

I have only implemented music and video files at this time (same as the Adobe AIR app).

(04-01-2009 10:01 PM)dc11ab Wrote:  The Controls page is slightly weird; is it a "full screen popup"? If I scroll below the buttons (which works fine) the underlying directory list is visible. Hmm, I should browse the code and see for myself.

I am using the iUI javascript library for the iPhone like UI.
It is probably a bug in that library. I'll try to look into it using a proper iPhone emulator (like the one in the Apple dev kit) or on a real iPhone.

(04-01-2009 10:01 PM)dc11ab Wrote:  Ah, and browsing any mounted directory shares too.

I already have a solution for this problem in the Adobe AIR app and will port it later this week.

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
04-02-2009, 11:49 AM
Post: #7
RE: MediatankController for iPhone - Experimental!
Well, that explains the lot. Excellent stuff, Niels. A big thank you for the efforts, despite not having an iPhone of your own.

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
04-02-2009, 12:50 PM (This post was last modified: 04-02-2009 01:05 PM by wikkid.)
Post: #8
RE: MediatankController for iPhone - Experimental!
I'm pretty sure you could add any file extension you'd like to mediatypes.php and it would list 'em for ya.

I just can't figure out why it won't list anything for me. Especially if the air app (which works flawlessly) is using similar methods. Smile

Any suggestions/help would be greatly appreciated. Smile

I've continued my efforts and discovered that Fileman 1.03 doesn't list files either. Shows the full folder tree, but no contents.

Do these apps use something similar to list the files? :/
Find all posts by this user
Add Thank You Quote this message in a reply
04-02-2009, 01:18 PM
Post: #9
RE: MediatankController for iPhone - Experimental!
Perhaps permissions are skewed;
is nmt the owner of files and dirs?

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
04-02-2009, 01:20 PM (This post was last modified: 04-02-2009 01:20 PM by wikkid.)
Post: #10
RE: MediatankController for iPhone - Experimental!
Everything has been setup as default. (I've done next to no tinkering).

All files were uploaded via ftp, so I'd assume ftpuser owns everything?

My linux knowledge is limited at best. :/
Find all posts by this user
Add Thank You Quote this message in a reply
04-02-2009, 01:22 PM
Post: #11
RE: MediatankController for iPhone - Experimental!
You could try chowning a file to user nmt, group nmt, and chmodding it to 775 and see if it get's listed.

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
04-02-2009, 01:54 PM
Post: #12
RE: MediatankController for iPhone - Experimental!
(04-02-2009 03:24 AM)wikkid Wrote:  I can connect and everything seems to work, but I get no file listings on the phone. The controls work, just no file listing.

[...]

Your AIR based controller works great, lists files and everything. I"ll keep digging.

Retrieving the list of files in this app is completely different from the way the AIR app does it.

Permissions of the files are probably not the issue here. I specifically use a method that retrieves the file listings as root. It's a little technical, but there are two webserver running on the NMT. One runs as a normal user and is publicly accessible. The second is running as root and is only accessible from within the NMT. The PHP script on the public webserver basically calls the PHP script again on the internal webserver. The result is then handed back to the first script.

Perhaps that mechanism isn't working on your system. Could you check the permissions of the index.cgi script of this app. It should have execute rights. For example using telnet: chmod 755 index.cgi.

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
[+] 1 user says Thank You to Niels Leenheer for this post
04-02-2009, 04:27 PM
Post: #13
RE: MediatankController for iPhone - Experimental!
Dang. Thought that was it when I seen it wasn't the correct permissions.

Changed index.cgi to 755 and still no go. Sad
Find all posts by this user
Add Thank You Quote this message in a reply
04-02-2009, 04:48 PM
Post: #14
RE: MediatankController for iPhone - Experimental!
(04-02-2009 04:27 PM)wikkid Wrote:  Dang. Thought that was it when I seen it wasn't the correct permissions.

Changed index.cgi to 755 and still no go. Sad

I'll create a new version which contains a diagnostics mode. It should help track down this problem. I don't have time today, but I'll post a message when it is ready. Probably tomorrow.

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
04-02-2009, 05:28 PM
Post: #15
RE: MediatankController for iPhone - Experimental!
Wow, that's very kind of you.

It's sad how many times I've searched the app store for "NMT, and Popcorn" in hopes of finding an app that did this. So it's greatly appreciated. Smile
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,042 10-08-2013 03:24 PM
Last Post: alkr
  NMT remote iPhone native app. racermonoid 391 177,689 07-06-2013 12:08 PM
Last Post: jojo88
  MediatankController 1.2 with Android Hann1BaL 9 7,025 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 210,704 05-13-2012 10:48 PM
Last Post: robertazimmerman
  is there an android remote control for the A110? jadeddog 2 3,624 06-04-2011 11:27 PM
Last Post: dw_bobby
  Can I browse MediaBox by Bonjour via my Android/Iphone App? stanly007 0 1,852 05-23-2011 11:02 AM
Last Post: stanly007
  music player daemon MPD & PCH Remote control beatnut88 19 11,974 12-22-2010 12:31 AM
Last Post: dooly
  a110 - iphone - torrent wasssu 0 1,818 11-17-2010 05:53 PM
Last Post: wasssu
  Psiloc IRremote Control PCH with Nokia Smartphone Insel_Affe_30 0 2,616 05-26-2010 11:28 AM
Last Post: Insel_Affe_30
  Download Links for TouchEverything - Remote Control NMT with PC, Web Youcontrol 4 4,292 04-07-2010 09:46 PM
Last Post: gfb107

Forum Jump: