karmacode
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-13-2012
10:12 AM
Running Brightscript remote code
Hello,
I am trying to figure out a way to execute remote Brightscript code through Roku. Is this possible?
I am trying to figure out a way to execute remote Brightscript code through Roku. Is this possible?
http://www.connectedtvforum.com
5 REPLIES 5
YungBlood
Streaming Star
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-13-2012
10:51 AM
Re: Running Brightscript remote code
Yes, it's possible. If you are trying to run a single .brs file, just download it using roUrlTransfer, and then run() it. If you are trying to run a program with multiple files, you will have to develop a way to organise them, and figure out which ones to put in an array to run().
Games 4 Roku is built on that concept. And I can run programs with lots of files.
Games 4 Roku is built on that concept. And I can run programs with lots of files.
YungBlood
Bringing more fun to Roku!
Bringing more fun to Roku!
gonzotek
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-13-2012
11:25 AM
Re: Running Brightscript remote code
"YungBlood" wrote:+1. See Section 6.5 of the BrightScriptReferenceManual.pdf. Also the next section, Eval(), if you only need a short code snippet.
Yes, it's possible. If you are trying to run a single .brs file, just download it using roUrlTransfer, and then run() it. If you are trying to run a program with multiple files, you will have to develop a way to organise them, and figure out which ones to put in an array to run().
Games 4 Roku is built on that concept. And I can run programs with lots of files.
Remoku.tv - A free web app for Roku Remote Control!
Want to control your Roku from nearly any phone, computer or tablet? Get started at http://help.remoku.tv
by Apps4TV - Applications for television and beyond: http://www.apps4tv.com
Want to control your Roku from nearly any phone, computer or tablet? Get started at http://help.remoku.tv
by Apps4TV - Applications for television and beyond: http://www.apps4tv.com
EnTerr
Roku Guru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-13-2012
01:36 PM
Re: Running Brightscript remote code
"YungBlood" wrote:
If you are trying to run a program with multiple files, you will have to develop a way to organise them, and figure out which ones to put in an array to run().
Speaking of which, is there any additional meaning (eg. scope) to separating source in different files, or is it just one big #include. Does the interpreter care if files are separated or "copy *.brs blob.brs"?
RokuJoel
Binge Watcher
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-13-2012
01:41 PM
Re: Running Brightscript remote code
Not really, it is just helpful for keeping track of what is where for sanity. Best not to go overboard with lots of small files as they frequently won't compress as well as a few medium sized .brs files. The interpreter does not care either way as far as I know, as long as you don't have the same function or sub name used twice within a project.
- Joel
- Joel
TheEndless
Channel Surfer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-13-2012
02:10 PM
Re: Running Brightscript remote code
"gonzotek" wrote:
Also the next section, Eval(), if you only need a short code snippet.
Be aware that any script you Eval() should be less than 32k (I think it was increased to ~48k in 3.x). Anything larger, and you're likely to hard crash the box. I created a "Reboot" channel awhile back that took advantage of this little gem.. 😛
"RokuJoel" wrote:
Not really, it is just helpful for keeping track of what is where for sanity. Best not to go overboard with lots of small files as they frequently won't compress as well as a few medium sized .brs files. The interpreter does not care either way as far as I know, as long as you don't have the same function or sub name used twice within a project.
- Joel
Furthermore, you can have multiple subfolders as well under the source folder. All *.brs files under the source folder get combined into one giant BrightScript, regardless of location in the tree.
My Channels: http://roku.permanence.com - Twitter: @TheEndlessDev
Instant Watch Browser (NetflixIWB), Aquarium Screensaver (AQUARIUM), Clever Clocks Screensaver (CLEVERCLOCKS), iTunes Podcasts (ITPC), My Channels (MYCHANNELS)
Instant Watch Browser (NetflixIWB), Aquarium Screensaver (AQUARIUM), Clever Clocks Screensaver (CLEVERCLOCKS), iTunes Podcasts (ITPC), My Channels (MYCHANNELS)