title: How to use WebRTC on Android for Real Time Communication?
body: <p>I'm working on a simple project in which i need to control a Arduino Robot (2-servo motors) through an <code>Android</code> Phone's <code>Gyroscope Sensor</code>, via Internet. 
  As you can visualize, 3-axis Gyroscopic Coordinates change quite sensitively even with little change in Phone's orientation in 3D space, so i want to minimize the Lag to milliseconds. </p>
  
  <p>Now aside from hardware, my first milestone is to send Gyroscope coordinates from Android to a computer through internet as Fast and Continuously as possible (like a RealTime stream of Numeric data). I know traditional <code>HTTP based Client-Server</code> mechanism will be quite slow therefore i've looked into following: </p>
  
  <blockquote>
    <ol>
    <li>Google's Chanel API </li>
    <li>WebRTC</li>
    <li>WebSockets</li>
    </ol>
  </blockquote>
  
  <p>According to my research, Channel API shows latency that from 10ms to even in Seconds. Also GAE limits requests to 30 seconds. Here is a Channels API stress test:
  <a href="http://channelapistresstest.appspot.com" rel="nofollow">http://channelapistresstest.appspot.com/</a>
  Try clicking "send 5"-button a lot, and you will see latency numbers going up to several seconds.</p>
  
  <p>Now WebRTC sounds most promising and faster than WebSockets. I'll be really grateful if someone can guide me about practical implementation of WebRTC in Native JAVA and Native Android (<strong>Any good libraries?</strong> i want to send coords. from Android and Receive via a JAVA-SE client on Desktop). I'm not interested in Hybrid App solutions (like <code>Crosswalk</code>). I would also like to know about How should i setup a Signalling Server. Summing it up i have following questions: </p>
  
  <blockquote>
    <ol>
    <li>Which method should i use? (Channel API, WebSockets, WebRTC or something else) with native Java and android support?</li>
    <li>Incase of WebRTC, how should i setup a Signalling server? (just brief description) or a WebSocket Server for WebSockets?</li>
    <li>Can i make use of Google's Cloud platform or something similar to reduce complexity at my end?</li>
    <li>Any overall suggestion?</li>
    </ol>
  </blockquote>
  
  <p>Thanks in advance.</p>