APM:Libraries
|
#include <AP_HAL/AP_HAL.h>
#include "RCOutput_Bebop.h"
#include <errno.h>
#include <poll.h>
#include <pthread.h>
#include <stdio.h>
#include <stdlib.h>
#include <sys/mman.h>
#include <sys/time.h>
#include <unistd.h>
#include <utility>
#include <AP_HAL/utility/sparse-endian.h>
#include <AP_Math/AP_Math.h>
#include "Util.h"
Go to the source code of this file.
Classes | |
struct | bldc_info |
Macros | |
#define | BEBOP_BLDC_I2C_ADDR 0x08 |
#define | BEBOP_BLDC_STARTPROP 0x40 |
#define | BEBOP_BLDC_SETREFSPEED 0x02 |
#define | BEBOP_BLDC_GETOBSDATA 0x20 |
#define | BEBOP_BLDC_TOGGLE_GPIO 0x4d |
#define | BEBOP_BLDC_GPIO_0 (1 << 0) |
#define | BEBOP_BLDC_GPIO_1 (1 << 1) |
#define | BEBOP_BLDC_GPIO_2 (1 << 2) |
#define | BEBOP_BLDC_GPIO_3 (1 << 3) |
#define | BEBOP_BLDC_GPIO_POWER (1 << 4) |
#define | BEBOP_BLDC_STOP_PROP 0x60 |
#define | BEBOP_BLDC_CLEAR_ERROR 0x80 |
#define | BEBOP_BLDC_PLAY_SOUND 0x82 |
#define | BEBOP_BLDC_GET_INFO 0xA0 |
#define | BEBOP_BLDC_MIN_PERIOD_US 1100 |
#define | BEBOP_BLDC_MAX_PERIOD_US 1900 |
#define | BEBOP_BLDC_MIN_RPM 1000 |
#define | BEBOP_BLDC_MAX_RPM_1 11000 |
#define | BEBOP_BLDC_MAX_RPM_2 12200 |
#define | BEBOP_BLDC_MAX_RPM_DISCO 12500 |
#define | RCOUT_BEBOP_RTPRIO 14 |
#define | BEBOP_BLDC_TIMEOUT_NS 500000000 |
Enumerations | |
enum | { BEBOP_BLDC_STARTED, BEBOP_BLDC_STOPPED } |
enum | BLDC_STATUS { BEBOP_BLDC_STATUS_STOPPED =1, BEBOP_BLDC_STATUS_RAMPUP =2, BEBOP_BLDC_STATUS_RUNNING =4, BEBOP_BLDC_STATUS_RAMPDOWN =5 } |
Variables | |
static const AP_HAL::HAL & | hal = AP_HAL::get_HAL() |
#define BEBOP_BLDC_CLEAR_ERROR 0x80 |
Definition at line 48 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_clear_error().
#define BEBOP_BLDC_GET_INFO 0xA0 |
Definition at line 52 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_get_info().
#define BEBOP_BLDC_GETOBSDATA 0x20 |
Definition at line 26 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::read_obs_data().
#define BEBOP_BLDC_GPIO_0 (1 << 0) |
Definition at line 40 of file RCOutput_Bebop.cpp.
#define BEBOP_BLDC_GPIO_1 (1 << 1) |
Definition at line 41 of file RCOutput_Bebop.cpp.
#define BEBOP_BLDC_GPIO_2 (1 << 2) |
Definition at line 42 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::init().
#define BEBOP_BLDC_GPIO_3 (1 << 3) |
Definition at line 43 of file RCOutput_Bebop.cpp.
#define BEBOP_BLDC_GPIO_POWER (1 << 4) |
Definition at line 44 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::init().
#define BEBOP_BLDC_I2C_ADDR 0x08 |
Definition at line 22 of file RCOutput_Bebop.cpp.
#define BEBOP_BLDC_MAX_PERIOD_US 1900 |
Definition at line 55 of file RCOutput_Bebop.cpp.
#define BEBOP_BLDC_MAX_RPM_1 11000 |
Definition at line 58 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_run_rcout().
#define BEBOP_BLDC_MAX_RPM_2 12200 |
Definition at line 59 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_run_rcout().
#define BEBOP_BLDC_MAX_RPM_DISCO 12500 |
Definition at line 60 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_run_rcout().
#define BEBOP_BLDC_MIN_PERIOD_US 1100 |
Definition at line 54 of file RCOutput_Bebop.cpp.
#define BEBOP_BLDC_MIN_RPM 1000 |
Definition at line 56 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_period_us_to_rpm().
#define BEBOP_BLDC_PLAY_SOUND 0x82 |
Definition at line 50 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_play_sound(), and Linux::RCOutput_Bebop::play_note().
#define BEBOP_BLDC_SETREFSPEED 0x02 |
Definition at line 24 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_set_ref_speed().
#define BEBOP_BLDC_STARTPROP 0x40 |
Definition at line 23 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_start_prop().
#define BEBOP_BLDC_STOP_PROP 0x60 |
Definition at line 46 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_stop_prop().
#define BEBOP_BLDC_TIMEOUT_NS 500000000 |
Definition at line 67 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_run_rcout().
#define BEBOP_BLDC_TOGGLE_GPIO 0x4d |
Definition at line 39 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::_toggle_gpio().
#define RCOUT_BEBOP_RTPRIO 14 |
Definition at line 65 of file RCOutput_Bebop.cpp.
Referenced by Linux::RCOutput_Bebop::init().
anonymous enum |
Enumerator | |
---|---|
BEBOP_BLDC_STARTED | |
BEBOP_BLDC_STOPPED |
Definition at line 69 of file RCOutput_Bebop.cpp.
enum BLDC_STATUS |
Enumerator | |
---|---|
BEBOP_BLDC_STATUS_STOPPED | |
BEBOP_BLDC_STATUS_RAMPUP | |
BEBOP_BLDC_STATUS_RUNNING | |
BEBOP_BLDC_STATUS_RAMPDOWN |
Definition at line 75 of file RCOutput_Bebop.cpp.
|
static |
Definition at line 84 of file RCOutput_Bebop.cpp.