Skip to content

Instantly share code, notes, and snippets.

@deadprogram
Created October 17, 2013 21:09
Show Gist options
  • Select an option

  • Save deadprogram/7032249 to your computer and use it in GitHub Desktop.

Select an option

Save deadprogram/7032249 to your computer and use it in GitHub Desktop.
require 'artoo'
connection :ardrone, :adaptor => :ardrone
device :drone, :driver => :ardrone, :connection => :ardrone
connection :navigation, :adaptor => :ardrone_navigation
device :nav, :driver => :ardrone_navigation, :connection => :navigation
work do
on drone, :ready => :fly
drone.start(nav)
end
def fly(*data)
drone.take_off
after(15.seconds) { drone.hover.land }
after(20.seconds) { drone.stop }
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment