UAV::Pilot::Control::ARDrone::Event
my $sender = UAV::Pilot::Driver::ARDrone->new( ... ); $sender->connect; my $dev = UAV::Pilot::Control::ARDrone::Event->new({ sender => $sender, }); my $cv = $uav->init_event_loop; $cv->pitch( -0.8 ); $cv->recv; # Will now pitch forward until you kill the process
AnyEvent-based version of UAV::Pilot::Control::ARDrone. With the normal module, you need to send movement commands yourself every 30ms to maintain smooth control. By using an event loop, this module handles the timing for you.
UAV::Pilot::Control::ARDrone
Sets up the event loop and returns the AnyEvent::CondVar. You will need to call recv() on that condvar to start the event loop running.
recv()
Stops all movement.
To install UAV::Pilot, copy and paste the appropriate command in to your terminal.
cpanm
cpanm UAV::Pilot
CPAN shell
perl -MCPAN -e shell install UAV::Pilot
For more information on module installation, please visit the detailed CPAN module installation guide.