Roku Developer Program

Developers and content creators—a complete solution for growing an audience directly.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Highlighted
Level 7

Can't get to first base

Ok, I've just begun to explore the development side of the Roku and I'm hitting a snag on my first attempt. I'm just trying to replace the video link in the simplevideoplayer with another link to an mp4 file hosted on the web. I'm not changing anything else in the appmain file. I'm just replacing the link and uploading the zip folder to the Roku, but the Play button does nothing. The UP button just brings up a "Retreving" message and seems to hang there. I've tried several link and none have worked yet.

One of the links I've tried is:
http://blip.tv/file/get/DailyFX-Technic ... 011715.mp4

Could you take a look and tell me where I'm going wrong? Thanks!
~Mark
0 Kudos
19 Replies
Highlighted
Level 10

Re: Can't get to first base

I don't think Roku will play a 15fps stream.
0 Kudos
Highlighted
Roku Employee
Roku Employee

Re: Can't get to first base

The video itself plays fine for me. The first place to look for clues as to what's going wrong is the debug console. Telnet to port 8085 of your Roku to access it.
0 Kudos
Highlighted
Level 10

Re: Can't get to first base

So
The developer guide should be updated to allow for other stream types.
Page 9
23.976 fps or 29.97 fps
0 Kudos
Highlighted
Level 7

Re: Can't get to first base

Ug, that doesn't sound good :? How do you discover the fps and other file attributes on a video file on the web? When I play it, I dont' see any way to view the file properties. Yes, my newbiness is showing Smiley LOL

So, I'm assuming that blip.tv must reformat these mp4 files in order to place them on their Roku channel. Seems odd but could be the case.

Thanks for the reply. Anyone else have any suggestions?
~Mark
0 Kudos
Highlighted
Roku Employee
Roku Employee

Re: Can't get to first base

"destruk" wrote:
So
The developer guide should be updated to allow for other stream types.
Page 9
23.976 fps or 29.97 fps


Not necessarily. Those are the recommended and officially supported encode settings. Other stuff may work, but is not recommended.
0 Kudos
Highlighted
Level 7

Re: Can't get to first base

Here's what I get when I telnet into it. Says there's an uninitialized variable at line 221. All I do is change the mp4 that simplevideoplayer points to. Why would that cause a variable error?


220: print "srt = ";srt
221: if srt <> invalid and srt <> "" then
222: videoclip.SubtitleUrl = srt
223: end if
224:
225: video.SetContent(videoclip)
226: video.show()
227:
228: lastSavedPos = 0
229: statusInterval = 10 'position must change by more than this number of s
econds before saving
230:
231: while true
232: msg = wait(0, video.GetMessagePort())
233: if type(msg) = "roVideoScreenEvent"
234: if msg.isScreenClosed() then 'ScreenClosed event
235: print "Closing video screen"
236: exit while
237: else if msg.isPlaybackPosition() then
238: nowpos = msg.GetIndex()
239: if nowpos > 10000
240:
241: end if
242: if nowpos > 0
243: if abs(nowpos - lastSavedPos) > statusInterval
244: lastSavedPos = nowpos
245: end if
246: end if
247: else if msg.isRequestFailed()
248: print "play failed: "; msg.GetMessage()
249: else
250: print "Unknown event: "; msg.GetType(); " msg: "; msg.GetMe
ssage()
251: endif
252: end if
253: end while
254: End Function
Use of uninitialized variable. (runtime error &he9) in ...bVmMC/pkg:/source/appM
ain.brs(221)

221: if srt <> invalid and srt <> "" then
Backtrace:
Function displayvideo(args As ) As
file/line: /tmp/plugin/ICAA...bVmMC/pkg:/source/appMain.brs(221)
Function showspringboardscreen(item As <uninitialized>) As Boolean
file/line: /tmp/plugin/ICAA...bVmMC/pkg:/source/appMain.brs(137)
Function main(args As ) As
file/line: /tmp/plugin/ICAA...bVmMC/pkg:/source/appMain.brs(66)

Local Variables:
args &h0100 String (VT_STR_CONST) val:
global &h0020 rotINTERFACE:ifGlobal
m &h0010 bsc:roAssociativeArray, refcnt=4
p &h0010 bsc:roMessagePort, refcnt=2
video &h0010 bsc:roVideoScreen, refcnt=1
bitrates &h0010 bsc:roArray, refcnt=2
urls &h0010 bsc:roArray, refcnt=2
qualities &h0010 bsc:roArray, refcnt=2
streamformat &h0100 String (VT_STR_CONST) val:mp4
title &h0100 String (VT_STR_CONST) val:test
srt &h0000 <uninitialized> val:Uninitialized
videoclip &h0010 bsc:roAssociativeArray, refcnt=1
lastsavedpos &h0000 <uninitialized> val:Uninitialized
statusinterval &h0000 <uninitialized> val:Uninitialized
msg &h0000 <uninitialized> val:Uninitialized
nowpos &h0000 <uninitialized> val:Uninitialized
BrightScript Debugger>
0 Kudos
Highlighted
Level 8

Re: Can't get to first base

it's erroring on a line referring to the subtitles (srt file), try taking the reference to a subtitle for the video out of the code of that particular stream i.e.

'Swap the commented values below to play different video clips...
urls = ["http://video.ted.com/talks/podcast/CraigVenter_2008_480.mp4"]
qualities = ["HD"]
StreamFormat = "mp4"
title = "Craig Venter Synthetic Life"
srt = "file://pkg:/source/craigventer.srt"


remove the "srt = "file://pkg:/source/craigventer.srt" and see if that works then
0 Kudos
Highlighted
Level 7

Re: Can't get to first base

Interesting. I have that srt line commented out. All I have uncommented is:


urls = ["http://blip.tv/file/get/DailyFX-TechnicalOutlookForMajorCurrenciesNovember102011715.mp4"]
qualities = ["HD"]
StreamFormat = "mp4"
title = "test title"

I'll look a bit closer at my code.
0 Kudos
Highlighted
Level 7

Re: Can't get to first base

I'm apparently not doing something correctly with my zipped folder that I'm uploading to Roku. I just realized that the changes I make to the appmain file aren't showing up in the file when I Telnet in. I've been opening the appmain, making changes and saving. Then I drop it into my zipped folder which contains the source/images/etc. It seems like that might be working for me.
0 Kudos