hybridgroup.gobot/platforms/parrot/ardrone
deadprogram f225a66db9 docs: correct installation instructions to match latest versions
Signed-off-by: deadprogram <ron@hybridgroup.com>
2017-06-15 14:04:08 +02:00
..
LICENSE license: update license year to include 2017 2017-01-02 22:25:17 +01:00
README.md docs: correct installation instructions to match latest versions 2017-06-15 14:04:08 +02:00
ardrone_adaptor.go ardrone: use new improved default namer to avoid API conflicts 2017-02-02 16:34:21 +01:00
ardrone_adaptor_test.go ardrone: increase test coverage 2017-04-06 11:05:23 +02:00
ardrone_driver.go ardrone: use new improved default namer to avoid API conflicts 2017-02-02 16:34:21 +01:00
ardrone_driver_test.go ardrone: increase test coverage 2017-04-06 11:05:23 +02:00
doc.go docs: correct ARDrone README link 2016-12-21 10:54:30 +01:00
pitch.go ardrone: add ValidatePitch helper function for ARDrone 2.0 to package 2017-02-07 11:31:27 +01:00
pitch_test.go ardrone: add ValidatePitch helper function for ARDrone 2.0 to package 2017-02-07 11:31:27 +01:00
test_helper.go parrot: move both ARDrone and Bebop under Parrot package 2016-12-07 14:22:12 +01:00

README.md

Ardrone

The ARDrone from Parrot is an inexpensive quadcopter that is controlled using WiFi. It includes a built-in front-facing HD video camera, as well as a second lower resolution bottom facing video camera.

For more info about the ARDrone platform click here.

How to Install

go get -d -u gobot.io/x/gobot/...

How to Use

package main

import (
	"time"

	"gobot.io/x/gobot"
	"gobot.io/x/gobot/platforms/parrot/ardrone"
)

func main() {
	ardroneAdaptor := ardrone.NewAdaptor("Drone")
	drone := ardrone.NewDriver(ardroneAdaptor, "Drone")

	work := func() {
		drone.On(drone.Event("flying"), func(data interface{}) {
			gobot.After(3*time.Second, func() {
				drone.Land()
			})
		})
		drone.TakeOff()
	}

	robot := gobot.NewRobot("drone",
		[]gobot.Connection{ardroneAdaptor},
		[]gobot.Device{drone},
		work,
	)

	robot.Start()
}

How to Connect

The ARDrone is a WiFi device, so there is no additional work to establish a connection to a single drone. However, in order to connect to multiple drones, you need to perform some configuration steps on each drone via SSH.