dreinhard
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2010
05:44 AM
matchfiles call
Hello,
Do any devs have a good example on how to use the matchfiles call when trying enum filenames from a URL that meet the *.mp4 criteria? I keep getting an "Invalid or missing PHY in path" error in the debugger. Thanks in advance.
Dave
Do any devs have a good example on how to use the matchfiles call when trying enum filenames from a URL that meet the *.mp4 criteria? I keep getting an "Invalid or missing PHY in path" error in the debugger. Thanks in advance.
Dave
7 REPLIES 7
nowhereman
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2010
08:24 AM
Re: matchfiles call
"dreinhard" wrote:
Hello,
Do any devs have a good example on how to use the matchfiles call when trying enum filenames from a URL that meet the *.mp4 criteria? I keep getting an "Invalid or missing PHY in path" error in the debugger. Thanks in advance.
Dave
I haven't tried it, but I don't think MatchFiles() will work with remote URLs. It's meant for use with the local file system.
twitter:nowhereman
http://www.thenowhereman.com/roku
http://www.thenowhereman.com/netflix
http://www.thenowhereman.com/roku
http://www.thenowhereman.com/netflix
dreinhard
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2010
09:59 AM
Re: matchfiles call
"nowhereman" wrote:"dreinhard" wrote:
Hello,
Do any devs have a good example on how to use the matchfiles call when trying enum filenames from a URL that meet the *.mp4 criteria? I keep getting an "Invalid or missing PHY in path" error in the debugger. Thanks in advance.
Dave
I haven't tried it, but I don't think MatchFiles() will work with remote URLs. It's meant for use with the local file system.
Thanks for the fast reply! Local file system meaning on the RVP? If that is the case, that is def. not what i need. Is there a call to enumerate files from a URL location? I have a few dirs. on my system with changing mp4 videos (filename changes with each new recording) and would like to enumerate these files so I can parse out part of the name.
Dave

RokuKevin
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2010
11:24 AM
Re: matchfiles call
There is no call to enumerate files from a URL.... You would have to code it yourself.
--Kevin
--Kevin
nowhereman
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2010
11:27 AM
Re: matchfiles call
"dreinhard" wrote:
Local file system meaning on the RVP?
Correct. I believe MatchFiles() is expecting the path argument to begin with something like pkg:/ or tmp:/. That's why you get the "Invalid or missing PHY" error when you give it a path that starts with http://
"dreinhard" wrote:
Is there a call to enumerate files from a URL location? I have a few dirs. on my system with changing mp4 videos (filename changes with each new recording) and would like to enumerate these files so I can parse out part of the name.
It sounds like the videos are hosted on a machine you control. If that's the case, your best bet is to build an XML file on the server side that contains the list of files and other pertinent data and serve that XML to the box where it can be parsed and acted on appropriately. I have been successful using such a mechanism to serve EyeTV recordings to my Roku. The videoplayer example takes this approach as well.
twitter:nowhereman
http://www.thenowhereman.com/roku
http://www.thenowhereman.com/netflix
http://www.thenowhereman.com/roku
http://www.thenowhereman.com/netflix
dreinhard
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2010
11:53 AM
Re: matchfiles call
"nowhereman" wrote:"dreinhard" wrote:
Local file system meaning on the RVP?
Correct. I believe MatchFiles() is expecting the path argument to begin with something like pkg:/ or tmp:/. That's why you get the "Invalid or missing PHY" error when you give it a path that starts with http://"dreinhard" wrote:
Is there a call to enumerate files from a URL location? I have a few dirs. on my system with changing mp4 videos (filename changes with each new recording) and would like to enumerate these files so I can parse out part of the name.
It sounds like the videos are hosted on a machine you control. If that's the case, your best bet is to build an XML file on the server side that contains the list of files and other pertinent data and serve that XML to the box where it can be parsed and acted on appropriately. I have been successful using such a mechanism to serve EyeTV recordings to my Roku. The videoplayer example takes this approach as well.
Thanks again for the fast reply. I do have an almost complete video center coded to my home server that is serving up tv shows, movies, etc... I just started evaluating Beyond TV and have it recording various shows to different directories on my web server. The way I have it setup is to only keep a weeks worth of content for each show I record. The problem is the file names change with each recording so in order for me to control the content to be played through the RVP, I have to figure out a way to fetch the mp4's from the specified URL's on my web server dynamically. It almost sounds like I am going to have to try a different approach.
Dave
dreinhard
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2010
06:36 AM
Re: matchfiles call
Does anyone have a code sample on how to find a .mp4 file at a url that does not completely match the actual filename? Here is the example on what I mean:
Monday the path for a .mp4 file in will be "http://192.168.1.112/videos/TheView/TheView(actorJoeBlow)Daily.mp4"
Tuesday the path for the .mp4 file will be "http://192.168.1.112/vidoes/TheView/TheView(actressMaryBlow)Daily.mp4"
etc...
etc...
etc...
There will only be 1 .mp4 file in TheView dir at a time. The problem is the (actor....) part of the filename changes daily. Does anyone have a code sample on how I can get brightscript to look for 'TheView*Daily.mp4' at that particular URL and play it? I believe that '*' wildcard is not recognized in brightscript for URL path's but thought there might be another way to code this. Any help would be much appreciated.
Dave
Monday the path for a .mp4 file in will be "http://192.168.1.112/videos/TheView/TheView(actorJoeBlow)Daily.mp4"
Tuesday the path for the .mp4 file will be "http://192.168.1.112/vidoes/TheView/TheView(actressMaryBlow)Daily.mp4"
etc...
etc...
etc...
There will only be 1 .mp4 file in TheView dir at a time. The problem is the (actor....) part of the filename changes daily. Does anyone have a code sample on how I can get brightscript to look for 'TheView*Daily.mp4' at that particular URL and play it? I believe that '*' wildcard is not recognized in brightscript for URL path's but thought there might be another way to code this. Any help would be much appreciated.
Dave
jjinux
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-14-2010
02:28 PM
Re: matchfiles call
Well, the Roku box can't possibly know what's on the server unless the server tells it. Your best bet is to create some way for the Roku box to ask some server what the right URL is.