title: A.R Drone 2.0 Video Streaming Latency
body: <p>I am working on video streaming with the AR Drone 2.0 using different codes I have found on the internet. 
  I've attempted <code>ffplay tcp://192.168.1.1:5555</code> to video stream from the AR Drone 2.0;  however, the delay is way too high. </p>
  
  <p>My second attempt was with the following:</p>
  
  <pre><code>var arDrone = require('ar-drone');
  var http    = require('http');
  
  console.log('Connecting png stream ...');
  
  var pngStream = arDrone.createClient().getPngStream();
  
  var lastPng;
  pngStream
    .on('error', console.log)
    .on('data', function(pngBuffer) {
      lastPng = pngBuffer;
    });
  
  var server = http.createServer(function(req, res) {
    if (!lastPng) {
      res.writeHead(503);
      res.end('Did not receive any png data yet.');
      return;
    }
  
    res.writeHead(200, {'Content-Type': 'image/png'});
    res.end(lastPng);
  });
  
  server.listen(8080, function() {
    console.log('Serving latest png on port 8080 ...');
  });
  </code></pre>
  
  <p>This only streamed images. I had to refresh browser every second.</p>
  
  <p>My third option was using this option:</p>
  
  <pre><code>var arDrone=require('ar-drone')
  var client= arDrone.createclient();
  require('ar-drone-png-stream')(client,{port:8000})
  </code></pre>
  
  <p>It streamed a lot of images in a short amount of time. The delay is still significant and I'm looking for a video.</p>
  
  <p>Are there other approaches that will significantly lower the delay of the video stream?</p>