Example #1
0
function sendCommand(name, attributes, userdata) {
  var message = {
    seq: 0,
    type: 'request',
    command: name,
    arguments: attributes || {}
  };
  binding.sendCommand(JSON.stringify(message));
};
Example #2
0
 socket.on('control_update', function(controls) {
     controller.sendCommand(controls.throttle, controls.yaw, controls.lift);
 });