Roku Developer Program

Join our online forum to talk to Roku developers and fellow channel creators. Ask questions, share tips with the community, and find helpful resources.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
merthin
Visitor

roScreen, Idle Time and Wait

Hi All. I have been playing with an interesting issue as of lately:

I'm working with roScreens and it seems that after 10 minutes of inactivity the usage of wait(timeout, port) takes
longer than what stated in timeout. Rendering the app unresponsive. This port is attached to a roUrlTransfer object.

I wonder if this is an issue some others have found, and if someone from the staff could elaborate in what happens
under the hood (GC, etc) when the blank screen (the screensaver mode for roScreen based apps) appears.

Also, does "wait(0, port)" is the same as doing port.GetMessage()?

thank you all in advance.
0 Kudos
3 REPLIES 3
NewManLiving
Visitor

Re: roScreen, Idle Time and Wait

I find It's better to use getmessage
Your transfer calls should generally be asynchronous
On their own port. And if absolutely necessary write your
Own screensaver
My Channels: 2D API Framework Presentation: https://owner.roku.com/add/2M9LCVC
Updated: 11-11-2015 - Completed Keyboard interface
The Joel Channel ( Final Beta )
0 Kudos
TheEndless
Channel Surfer

Re: roScreen, Idle Time and Wait

You didn't mention what model you're testing on. There's a known issue with sleeps/waits under 10 ms on the previous gen Roku 2 XD and XS, that probably carried over to the streaming stick as well.
"merthin" wrote:
Also, does "wait(0, port)" is the same as doing port.GetMessage()?

No. Wait(0, port) will block until it receives a message.
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)
0 Kudos
merthin
Visitor

Re: roScreen, Idle Time and Wait

Thanks all for the responses. I get around it by making all the call asyncronous.

@TheEndless I was testing in several Rokus, including the 3.
0 Kudos