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: 
EnTerr
Roku Guru

ECP "sensor input"?

ECP doc (External Control Guide) has this weird section 3.1 External Control Input Command Conventions

It first talks about Sensor Input ("There are four sensor values to report, accelerometer, orientation, gyroscope (rotation), and magnetometer (magnetic)") and then about "Touch and Multi-touch".

I said "weird" because to the best of my knowledge it describes something that does not exists. From what i can tell it is a section that that describes "good practices" for injecting input via ECP. Say if wrote a smartphone app "A" and Roku channel "B" and wanted to send some sensor readings A -> B.

I think it was asked before if 3.1 is actionable info and someone (RokuPatrick? RokuMarkn?) answered said part is not implemented. Or something like that, alas i cannot find it as a post. And I have tried injecting such input to no avail.

My question is: Do i remember right - or is there something implemented in Roku per 3.1?

PS. To clarify my interest, how does this relate to the physical game-enhanced remote?
(aka the motion remotes. the ones with A/B buttons on it, as exemplified by remote models GR-14 and RC03)
0 Kudos
4 REPLIES 4
belltown
Roku Guru

Re: ECP "sensor input"?

I think the sensor makers can post whatever inputs they want from their sensors:

Sub Main ()
ui = CreateObject ("roInput")
port = CreateObject ("roMessagePort")
ui.SetMessagePort(port)
While True
msg = Wait (0, port)
If Type (msg) = "roInputEvent"
Print msg.GetInfo ()
End If
End While
End Sub


curl -X POST "http://192.168.0.6:8060/input?phaser=stun&dispersalPattern=focused&power=42000&units=exoJoules"


------ Running dev 'ncc 1701' main ------
phaser: stun
dispersalPattern: focused
power: 42000
units: exoJoules
0 Kudos
EnTerr
Roku Guru

Re: ECP "sensor input"?

"belltown" wrote:
I think the sensor makers can post whatever inputs they want from their sensors:

Why sure - one can post and receive whatever they please, there was never a doubt about it.
It's not what i was asking though. My apologies for wording it badly, should have been more clear. I added a P.S.

I was pointed specifically at Section 3.1 by a Roku person in relation to the Roku motion remote, so i am trying to clarify who/what is confused
0 Kudos
RokuJoel
Binge Watcher

Re: ECP "sensor input"?

roInput allows you to http post data from, say, a smartphone to a running channel and the channel gets the data via an roInputEvent.

It is documented to some degree in that section with some example URLs.

- Joel
0 Kudos
EnTerr
Roku Guru

Re: ECP "sensor input"?

"RokuJoel" wrote:
roInput allows you to http post data from, say, a smartphone to a running channel and the channel gets the data via an roInputEvent. It is documented to some degree in that section with some example URLs.

Sure, sure - but how does this relate to the physical game-enhanced remote??
@RokuKevin sends link to that section when asked about docs on the game-enhanced remote - and i have a good deal of respect for him to think he doesn't know what he's linking about. So i am trying every angle, turning every stone...
0 Kudos
Need Assistance?
Welcome to the Roku Community! Feel free to search our Community for answers or post your question to get help.

Become a Roku Streaming Expert!

Share your expertise, help fellow streamers, and unlock exclusive rewards as part of the Roku Community. Learn more.