Object managing one RC channel. More...
#include <AP_RcChannel.h>
Public Member Functions | |
AP_RcChannel (const char *name, const APM_RC_Class &rc, const uint8_t &ch, const float &scale=45.0, const float ¢er=0.0, const uint16_t &pwmMin=1200, const uint16_t &pwmNeutral=1500, const uint16_t &pwmMax=1800, const uint16_t &pwmDeadZone=10, const bool &filter=false, const bool &reverse=false) | |
Constructor. | |
void | readRadio () |
void | setPwm (uint16_t pwm) |
void | setPosition (float position) |
void | setNormalized (float normPosition) |
void | mixRadio (uint16_t infStart) |
void | setCh (const uint8_t &ch) |
void | setScale (const float &scale) |
void | setCenter (const float ¢er) |
void | setPwmMin (const uint16_t &pwmMin) |
void | setPwmNeutral (const uint16_t &pwmNeutral) |
void | setPwmMax (const uint16_t &pwmMax) |
void | setPwmDeadZone (const uint16_t &pwmDeadZone) |
void | setFilter (const bool &filter) |
uint16_t | getPwm () |
float | getPosition () |
float | getNormalized () |
const char * | getName () |
const uint8_t & | getCh () |
const float & | getScale () |
const float & | getCenter () |
const uint16_t & | getPwmMin () |
const uint16_t & | getPwmNeutral () |
const uint16_t & | getPwmMax () |
const uint16_t & | getPwmDeadZone () |
const bool & | getFilter () |
const bool & | getReverse () |
bool | failSafe () |
Object managing one RC channel.
Definition at line 18 of file AP_RcChannel.h.
AP_RcChannel::AP_RcChannel | ( | const char * | name, | |
const APM_RC_Class & | rc, | |||
const uint8_t & | ch, | |||
const float & | scale = 45.0 , |
|||
const float & | center = 0.0 , |
|||
const uint16_t & | pwmMin = 1200 , |
|||
const uint16_t & | pwmNeutral = 1500 , |
|||
const uint16_t & | pwmMax = 1800 , |
|||
const uint16_t & | pwmDeadZone = 10 , |
|||
const bool & | filter = false , |
|||
const bool & | reverse = false | |||
) |
Constructor.
Definition at line 17 of file AP_RcChannel.cpp.
bool AP_RcChannel::failSafe | ( | ) | [inline] |
Definition at line 61 of file AP_RcChannel.h.
const float& AP_RcChannel::getCenter | ( | ) | [inline] |
Definition at line 52 of file AP_RcChannel.h.
const uint8_t& AP_RcChannel::getCh | ( | ) | [inline] |
Definition at line 50 of file AP_RcChannel.h.
const bool& AP_RcChannel::getFilter | ( | ) | [inline] |
Definition at line 57 of file AP_RcChannel.h.
const char* AP_RcChannel::getName | ( | ) | [inline] |
Definition at line 49 of file AP_RcChannel.h.
float AP_RcChannel::getNormalized | ( | ) | [inline] |
Definition at line 48 of file AP_RcChannel.h.
float AP_RcChannel::getPosition | ( | ) | [inline] |
Definition at line 47 of file AP_RcChannel.h.
uint16_t AP_RcChannel::getPwm | ( | ) | [inline] |
Definition at line 46 of file AP_RcChannel.h.
const uint16_t& AP_RcChannel::getPwmDeadZone | ( | ) | [inline] |
Definition at line 56 of file AP_RcChannel.h.
const uint16_t& AP_RcChannel::getPwmMax | ( | ) | [inline] |
Definition at line 55 of file AP_RcChannel.h.
const uint16_t& AP_RcChannel::getPwmMin | ( | ) | [inline] |
Definition at line 53 of file AP_RcChannel.h.
const uint16_t& AP_RcChannel::getPwmNeutral | ( | ) | [inline] |
Definition at line 54 of file AP_RcChannel.h.
const bool& AP_RcChannel::getReverse | ( | ) | [inline] |
Definition at line 58 of file AP_RcChannel.h.
const float& AP_RcChannel::getScale | ( | ) | [inline] |
Definition at line 51 of file AP_RcChannel.h.
void AP_RcChannel::mixRadio | ( | uint16_t | infStart | ) |
Definition at line 82 of file AP_RcChannel.cpp.
void AP_RcChannel::readRadio | ( | ) |
Definition at line 39 of file AP_RcChannel.cpp.
void AP_RcChannel::setCenter | ( | const float & | center | ) | [inline] |
Definition at line 38 of file AP_RcChannel.h.
void AP_RcChannel::setCh | ( | const uint8_t & | ch | ) | [inline] |
Definition at line 36 of file AP_RcChannel.h.
void AP_RcChannel::setFilter | ( | const bool & | filter | ) | [inline] |
Definition at line 43 of file AP_RcChannel.h.
void AP_RcChannel::setNormalized | ( | float | normPosition | ) | [inline] |
Definition at line 34 of file AP_RcChannel.h.
void AP_RcChannel::setPosition | ( | float | position | ) |
Definition at line 76 of file AP_RcChannel.cpp.
void AP_RcChannel::setPwm | ( | uint16_t | pwm | ) |
Definition at line 46 of file AP_RcChannel.cpp.
void AP_RcChannel::setPwmDeadZone | ( | const uint16_t & | pwmDeadZone | ) | [inline] |
Definition at line 42 of file AP_RcChannel.h.
void AP_RcChannel::setPwmMax | ( | const uint16_t & | pwmMax | ) | [inline] |
Definition at line 41 of file AP_RcChannel.h.
void AP_RcChannel::setPwmMin | ( | const uint16_t & | pwmMin | ) | [inline] |
Definition at line 39 of file AP_RcChannel.h.
void AP_RcChannel::setPwmNeutral | ( | const uint16_t & | pwmNeutral | ) | [inline] |
Definition at line 40 of file AP_RcChannel.h.
void AP_RcChannel::setScale | ( | const float & | scale | ) | [inline] |
Definition at line 37 of file AP_RcChannel.h.