[19. April 2013] A-400 Advanced Network Setup now available | [11 Jan. 2013] Customize your A-400 Home Screen

Firmware: A-400 [13 May 2013] | C-300 [30 Nov. 2012] | A-300 [30 Nov. 2012] | C-200 [21 Jan. 2013] | A-200/A-210 [10 Aug. 2012]

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)
Thread Closed 
[200] MP3 + Sub-Folders + Shuffle = FolderShufflePlay (v1.2.0)
10-07-2009, 01:16 PM (This post was last modified: 01-16-2010 02:16 PM by gigel.vizionarul.)
Post: #1
MP3 + Sub-Folders + Shuffle = FolderShufflePlay (v1.2.0)
Here's a small application to help you play all MP3 files that can be found in a folder (and in its sub-folders). And best of all, it shuffles the songs.

Install using NMT CSI (http://www.nmtinstaller.com/). A new "FolderShufflePlay" option should appear in the "web services" menu.

For manual installation it can be downloaded by clicking here.

Current limitations:
- Works only with files available in the local filesystem (HDD).

Enjoy!

ChangeLog:

16-01-10
Sorry guys, I no longer support this script/app. My PCH is going to be replaced by a HTPC. This device has a lot of potential, but the current firmware is holding it way back. Anyone with a bit of PHP knowledge is free to continue improving FolderShufflePlay.

03-Dec-09 - v1.2.0
- Added ability to (recursively) search a folder for filenames containing certain text. The matching results will be shuffled and played. If your songs are properly named, you can use this to search for a particular artist. Click green button on the remote to access this feature easier.
- Changed background, increased font size, to fit (my new) 1080p tv better.
- M3U files are now listed as well, at the end of the folders list, so you can open them without quitting the app. I can now listed to my favorite online radio stations from the same app.
- Added configurable limitation (defaults to 500 songs), to avoid crashing, in case of a huge folder.
- You can also edit "config.php" to set the start folder (I set mine to "/Music")

25-Oct-09 - v1.1.0
- Added FLAC support (the FLAC support was added in the new beta C-200 firmware).
- Added ability to select particular folders to be shuffled and played. (The list is persistent so you don't have to select your favorite folders all the time. The songs are also shuffled every time you play it.)
- Folder names with special characters (Greek, German, etc.) should display fine now.

12-Oct-09 - v1.0.1
- Improved interface:
- Displays current path.
- Shows how many MP3's are in on folder when there are no more sub-folders.
- You can quickly play a folder by pressing its list number on the remote.
- Improved error handling.
- Workaround for missing file information - no more black screen while playing music.
Find all posts by this user
[+] 2 users say Thank You to gigel.vizionarul for this post
10-07-2009, 03:33 PM
Post: #2
RE: MP3 + Sub-Folders + Shuffle
hmmm are you sure that the index.htm file is correct??


Code:
<html><meta http-equiv="refresh" content="0;http://localhost.drives:9999/photos/">
</html>

-----------------------------------------------------------------------------------------------------
Syabas Technology Inc. DBA Popcornhour
Find all posts by this user
10-07-2009, 06:15 PM
Post: #3
RE: MP3 + Sub-Folders + Shuffle
(10-07-2009 03:33 PM)werner Wrote:  hmmm are you sure that the index.htm file is correct??
I've corrected that now. Thanks for pointing it out.
Find all posts by this user
10-07-2009, 07:07 PM
Post: #4
RE: MP3 + Sub-Folders + Shuffle
no doesnt work, i think you need to add that an user needs to install lighthttp??? or something else

-----------------------------------------------------------------------------------------------------
Syabas Technology Inc. DBA Popcornhour
Find all posts by this user
10-07-2009, 07:51 PM
Post: #5
RE: MP3 + Sub-Folders + Shuffle
Yes, seems it pointing to the port which is used by the CSI packaged lighttpd by journey4712.
Please describe the dependencies needed.

Audio, video, disco - I hear, I see, I learn.
Wiki. Wiki? Wiki!
Find all posts by this user
10-07-2009, 08:46 PM
Post: #6
RE: MP3 + Sub-Folders + Shuffle
I totally forgot about that. Yes, so it seems that I've used the installed lighttpd. I guess it should work with myiHome as well, I will make a new zip that should not require lighttpd.
Find all posts by this user
10-07-2009, 09:04 PM (This post was last modified: 10-07-2009 09:27 PM by Ger Teunis.)
Post: #7
RE: MP3 + Sub-Folders + Shuffle
You guys aren't right, per default AppInit uses a php5 enabled webserver on port 9999.
Journey and I just worked together to offer users a better and faster replacement of the default webserver of AppInit's webserver on 9999. It is in place so there isn't a dependency on a special webserver, lighttpd is just faster.

So installing the lighttpd webserver isn't required at all, just handy and fully optionally. Lighttpd isn't required for this app, just AppInit which comes with CSI. Users should not tinker in there, it could affect the ability for AppInit and thus CSI to correctly function.

Also; please do not store files directly in AppInit website; IT WILL GET DELETED whenever AppInit feels it needs to rebuild the meta information. It should only be used by AppInit!

Creating a real CSI package is really easy, just store the files in a new folder in Apps.
For instance create a folder called FolderShuffleplay, store all your php and html files there.
Then create one extra file called appinfo.json and add the following content in it:
Code:
{
    appinfo_format="1",
    name="FolderShuffleplay",
    version="1.0.0",
    enabled="1",
    webui_path="#PATH#"
}

If you use gayaui_path you even get an automatic link in "webservices" menu on the NMT for free!

One little step further: if you then tar the contents of that folder and zip that tar (not tar.gz, real tar and a real zip containing the tar) then users can install it using CSI via File -> Install from file which is somewhat user friendly (i hope)

Please read the compact and easy CSI packaging document here:
http://www.nmtinstaller.com/?p=createpackage

After these words: thanks for the contribution Smile
Please contact me if you need any support on the above. If you feel it is ready we can add it to CSI if you like.

Easy way of installing software on your NMT using just your mouse: NMT Community Software Installer
Visit this user's website Find all posts by this user
[+] 1 user says Thank You to Ger Teunis for this post
10-08-2009, 12:18 AM (This post was last modified: 10-08-2009 01:15 AM by gigel.vizionarul.)
Post: #8
RE: MP3 + Sub-Folders + Shuffle
(10-07-2009 09:04 PM)Ger Teunis Wrote:  Please read the compact and easy CSI packaging document here:
http://www.nmtinstaller.com/?p=createpackage
That's a useful hidden page Smile. It should be placed on the website's menu, or, somewhere.
Perhaps it was posted on the forum, but I'm new to all this. I wasn't even aware that "AppInit" was not a default folder on the device Tongue I guess I rushed into installing stuff before checking out the default features.

BTW, thanks for making lighttpd available on this device, it's way faster than the default server.
(10-07-2009 09:04 PM)Ger Teunis Wrote:  One little step further: if you then tar the contents of that folder and zip that tar (not tar.gz, real tar and a real zip containing the tar) then users can install it using CSI via File -> Install from file which is somewhat user friendly (i hope)

It works! That's really cool Smile
Here's the package file, if you want to try the script: http://www.quedo.com/tmp/FolderShufflePlay.zip
Find all posts by this user
[+] 1 user says Thank You to gigel.vizionarul for this post
10-08-2009, 06:55 AM
Post: #9
RE: MP3 + Sub-Folders + Shuffle
Great work Gigel!
New developers and apps are greatly appreciated.
Please contact me when you feel the app is stable enough to be put in the main repository of CSI!

Easy way of installing software on your NMT using just your mouse: NMT Community Software Installer
Visit this user's website Find all posts by this user
10-11-2009, 09:04 AM
Post: #10
RE: MP3 + Sub-Folders + Shuffle
Wooooowww.. yess....

I say gigel.vizionarul for President...Big GrinBig Grin

This is what I needed.. something that just plays all my mp3 random...

SmileSmileSmile

I do not see any artwork when playing a mp3.. is that correct..

A110, C200 + ASUS BR-04B2T with samsung HDD 2,5" 400gb, NAS Synology DS411J with 3 x Samsung 1500 GB
Marantz SR6006 + MM7025, Canton Vento 890.2 DC speakers + sub, Panasonic TX-P50UT50E
TP-Link TL-WR1043ND
Find all posts by this user
10-11-2009, 11:26 AM
Post: #11
RE: MP3 + Sub-Folders + Shuffle
(10-07-2009 09:04 PM)Ger Teunis Wrote:  You guys aren't right, per default AppInit uses a php5 enabled webserver on port 9999.
Journey and I just worked together to offer users a better and faster replacement of the default webserver of AppInit's webserver on 9999. It is in place so there isn't a dependency on a special webserver, lighttpd is just faster.

So installing the lighttpd webserver isn't required at all, just handy and fully optionally. Lighttpd isn't required for this app, just AppInit which comes with CSI. Users should not tinker in there, it could affect the ability for AppInit and thus CSI to correctly function.

Also; please do not store files directly in AppInit website; IT WILL GET DELETED whenever AppInit feels it needs to rebuild the meta information. It should only be used by AppInit!

Creating a real CSI package is really easy, just store the files in a new folder in Apps.
For instance create a folder called FolderShuffleplay, store all your php and html files there.
Then create one extra file called appinfo.json and add the following content in it:
Code:
{
    appinfo_format="1",
    name="FolderShuffleplay",
    version="1.0.0",
    enabled="1",
    webui_path="#PATH#"
}

If you use gayaui_path you even get an automatic link in "webservices" menu on the NMT for free!

One little step further: if you then tar the contents of that folder and zip that tar (not tar.gz, real tar and a real zip containing the tar) then users can install it using CSI via File -> Install from file which is somewhat user friendly (i hope)

Please read the compact and easy CSI packaging document here:
http://www.nmtinstaller.com/?p=createpackage

After these words: thanks for the contribution Smile
Please contact me if you need any support on the above. If you feel it is ready we can add it to CSI if you like.

I have the following in the appinfo file:

{
appinfo_format="1",
name="FolderShufflePlay",
version="1.0.0",
enabled="1",
gayaui_path="Z:/Apps/FolderShufflePlay/gayaui"
}

And this is in the folder FolderShufflePlay: appinfo.json, index.pfp and play.php
But what do i have to do next??
Find all posts by this user
10-11-2009, 11:32 AM (This post was last modified: 10-11-2009 11:34 AM by Ger Teunis.)
Post: #12
RE: MP3 + Sub-Folders + Shuffle
(10-11-2009 11:26 AM)patres14 Wrote:  I have the following in the appinfo file:

{
appinfo_format="1",
name="FolderShufflePlay",
version="1.0.0",
enabled="1",
gayaui_path="Z:/Apps/FolderShufflePlay/gayaui"
}

And this is in the folder FolderShufflePlay: appinfo.json, index.pfp and play.php
But what do i have to do next??


All is relative to the NMT, so you can not use a Z drive, the NMT doesn't know anything about a Z drive.

Please use
{
appinfo_format="1",
name="FolderShufflePlay",
version="1.0.0",
enabled="1",
gayaui_path="#path#/gayaui"
}

#path# will be replaced by AppInit to the correct path; just leave that in.
But only when you have a folder called gayaui in your app folder.
Otherwise it should be gayaui_path="#path#"
Just to make sure: please read http://nmtinstaller.com/?p=createpackage
Then click the "Creating packages using AppInit" link. All details should be there, even the next steps to take.

If you have any questions; please ask (but read the above document!)

ps> gigel also release a real CSI package in post:
http://www.networkedmediatank.com/showth...#pid265334

Easy way of installing software on your NMT using just your mouse: NMT Community Software Installer
Visit this user's website Find all posts by this user
10-11-2009, 11:46 AM
Post: #13
RE: MP3 + Sub-Folders + Shuffle
(10-11-2009 09:04 AM)zoef Wrote:  Wooooowww.. yess....
I say gigel.vizionarul for President...Big GrinBig Grin
Smile
(10-11-2009 09:04 AM)zoef Wrote:  I do not see any artwork when playing a mp3.. is that correct..
This script is dynamically creating a PLS play list file which gets recognized by PCH and played. I don't think it's possible to place an image (or anything) in the background. (I usually turn my TV off after hitting the play button anyway. - it would be cool if it were possible to display the links on the LCD display, so you don't have to open the TV at all)
Find all posts by this user
10-11-2009, 03:41 PM
Post: #14
RE: MP3 + Sub-Folders + Shuffle
Hmm, what if there is a jpg embedded in the mp3? I thought that showed?

Audio, video, disco - I hear, I see, I learn.
Wiki. Wiki? Wiki!
Find all posts by this user
10-11-2009, 03:48 PM
Post: #15
RE: MP3 + Sub-Folders + Shuffle
(10-11-2009 03:41 PM)dc11ab Wrote:  Hmm, what if there is a jpg embedded in the mp3? I thought that showed?

no. I think it show the on screen info which normally shows when playing a movie... I just get a black screen... when the info is off.

Perhaps another filter... or something.. I do not know..

A110, C200 + ASUS BR-04B2T with samsung HDD 2,5" 400gb, NAS Synology DS411J with 3 x Samsung 1500 GB
Marantz SR6006 + MM7025, Canton Vento 890.2 DC speakers + sub, Panasonic TX-P50UT50E
TP-Link TL-WR1043ND
Find all posts by this user
Thread Closed 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  [300] Slideshow view folders kaz47 0 701 04-02-2012 10:30 PM
Last Post: kaz47
  [200] mp3 http Radio on PCH A200 pabbllo 1 1,080 11-12-2011 04:24 PM
Last Post: monkeylove
Wink [200] Lyrics on mp3 files carlosfp 2 1,559 04-13-2011 05:17 PM
Last Post: black_dragon
  [200] Utility/script to move tv shows to correct folders Yoda83 3 1,953 11-23-2010 10:05 PM
Last Post: Yoda83
  [200] Deleted _theme_ & _index_ folders! Need Help! ahnernoch 2 1,138 02-18-2010 05:29 AM
Last Post: ahnernoch
  [200] How to use FolderShufflePlay ? bandolou 0 1,431 01-24-2010 08:50 AM
Last Post: bandolou

Forum Jump: