Your Digital Media Has Never Looked So Good

 
dgburns
Topic Author
Posts: 807
Joined: Mon Jun 27, 2005 9:37 am

Video Jukebox

Mon Aug 13, 2007 11:28 am

Endless/Marcello,
Now that my two Roku's are repaired and on their way back to me, I'd like to know if you guys would consider developing an extension of MPlay (or new app?) that allows one to point the app at a particular shared folder that contains video clips and it randomly chooses and plays them. It would dynamically update itself so that I could leave it running long term and add/remove clips (other than the one playing of course) by just deleting or adding video clips to the shared folder.

I've asked about this before and it seemed like there was some interest then. I find nothing on the market (either for Roku or another device) that does this sort of thing.

Hope you'll consider it. I'd gladly make a paypal donation.
HD-1500 RevB #1 (media room)
Mitsubishi WD-62528 62" LCD RPTV
Kenwood VR-407 receiver w/PSB Alpha's
PS/3 60GB (now 250GB) w/750GB Seagate ext
M1000 (upstairs)
HD-1000 RevB #2 (bedroom)
Visco 32" LCD
AR 2.1 audio system
PS/2
 
soiaf
Posts: 785
Joined: Fri Jan 14, 2005 5:19 am

Mon Aug 13, 2007 11:46 pm

Would something like this script do what you're looking for?

#!/bin/sh
mydir=/mnt/flash1/video
cd "$mydir"
start=0
currentfilename=nothing
while [ 1 -eq 1 ]
do
filename=$(find -type f | grep -v ".mplay" |
awk 'BEGIN{
                srand()
        }
        {
                names[NR]=$0
        }
        END{
                i=1+int(rand()*NR)
                print names[i]
        }
')

if [ $start -eq 1 ]
then
set -- `ecp MPlay status`
fi

if [ $2 == Stopped ]
then
ecp MPlay Open "$mydir/$filename"
fi

if [ $start -eq 0 ]
then
# Change the location of the MPlay.app here
/mnt/flash1/mplay/MPlay.app -nomenu -noresume "$mydir/$filename" &
start=1
sleep 5
fi

sleep 5;
done


You need to change the value of mydir (at the start of the script) to where your videos are and also change the location of the MPlay app (towards the end of the script).

This script looks in the specified directory, ignores any .mplay files, and picks a file at random. When MPlay says it is finished, it picks another one etc. It will always get a current list of files so you can add/delete as you want.
I put this together really quick, theres lots of improvements that could be made to it, but is this the type of thing you were actually looking for?
 
dgburns
Topic Author
Posts: 807
Joined: Mon Jun 27, 2005 9:37 am

Wed Aug 15, 2007 8:06 pm

soiaf wrote:
but is this the type of thing you were actually looking for?

Well dang, that was quick. I didn't even think of scripts and ecp commands to do this (not that I could have, but...).

I'll give it a whirl tomorrow!
HD-1500 RevB #1 (media room)

Mitsubishi WD-62528 62" LCD RPTV

Kenwood VR-407 receiver w/PSB Alpha's

PS/3 60GB (now 250GB) w/750GB Seagate ext

M1000 (upstairs)

HD-1000 RevB #2 (bedroom)

Visco 32" LCD

AR 2.1 audio system

PS/2

Who is online

Users browsing this forum: No registered users and 3 guests