Object managing one RC channel. More...
#include <RC_Channel.h>
Public Member Functions | |
RC_Channel () | |
RC_Channel (uint16_t address) | |
void | update_min_max () |
void | zero_min_max () |
void | load_eeprom (void) |
void | save_eeprom (void) |
void | save_trim (void) |
void | set_filter (bool filter) |
void | set_range (int low, int high) |
void | set_angle (int angle) |
void | set_reverse (bool reverse) |
void | set_pwm (int pwm) |
void | trim () |
bool | get_failsafe (void) |
int | control_mix (float value) |
void | calc_pwm (void) |
int16_t | pwm_to_angle () |
float | norm_input () |
float | norm_output () |
int16_t | angle_to_pwm () |
int16_t | pwm_to_range () |
int16_t | range_to_pwm () |
Public Attributes | |
int16_t | radio_in |
int16_t | control_in |
int16_t | dead_zone |
int16_t | servo_out |
int16_t | pwm_out |
int16_t | radio_out |
int16_t | radio_min |
int16_t | radio_trim |
int16_t | radio_max |
float | scale_output |
Object managing one RC channel.
Definition at line 13 of file RC_Channel.h.
RC_Channel::RC_Channel | ( | ) | [inline] |
Constructor
A RC_Channel constructed in this fashion does not support save/restore.
Definition at line 19 of file RC_Channel.h.
RC_Channel::RC_Channel | ( | uint16_t | address | ) | [inline] |
Constructor
address | EEPROM base address at which RC_Channel parameters are stored. Zero if the RC_Channel does not support save/restore. |
Definition at line 29 of file RC_Channel.h.
int16_t RC_Channel::angle_to_pwm | ( | ) |
Definition at line 180 of file RC_Channel.cpp.
void RC_Channel::calc_pwm | ( | void | ) |
Definition at line 103 of file RC_Channel.cpp.
int RC_Channel::control_mix | ( | float | value | ) |
Definition at line 89 of file RC_Channel.cpp.
bool RC_Channel::get_failsafe | ( | void | ) |
Definition at line 96 of file RC_Channel.cpp.
void RC_Channel::load_eeprom | ( | void | ) |
Definition at line 119 of file RC_Channel.cpp.
float RC_Channel::norm_input | ( | ) |
Definition at line 210 of file RC_Channel.cpp.
float RC_Channel::norm_output | ( | ) |
Definition at line 219 of file RC_Channel.cpp.
int16_t RC_Channel::pwm_to_angle | ( | ) |
Definition at line 167 of file RC_Channel.cpp.
int16_t RC_Channel::pwm_to_range | ( | ) |
Definition at line 194 of file RC_Channel.cpp.
int16_t RC_Channel::range_to_pwm | ( | ) |
Definition at line 201 of file RC_Channel.cpp.
void RC_Channel::save_eeprom | ( | void | ) |
Definition at line 130 of file RC_Channel.cpp.
void RC_Channel::save_trim | ( | void | ) |
Definition at line 143 of file RC_Channel.cpp.
void RC_Channel::set_angle | ( | int | angle | ) |
Definition at line 30 of file RC_Channel.cpp.
void RC_Channel::set_filter | ( | bool | filter | ) |
Definition at line 44 of file RC_Channel.cpp.
void RC_Channel::set_pwm | ( | int | pwm | ) |
Definition at line 58 of file RC_Channel.cpp.
void RC_Channel::set_range | ( | int | low, | |
int | high | |||
) |
Definition at line 22 of file RC_Channel.cpp.
void RC_Channel::set_reverse | ( | bool | reverse | ) |
Definition at line 37 of file RC_Channel.cpp.
void RC_Channel::trim | ( | ) |
Definition at line 51 of file RC_Channel.cpp.
void RC_Channel::update_min_max | ( | ) |
Definition at line 158 of file RC_Channel.cpp.
void RC_Channel::zero_min_max | ( | ) |
Definition at line 152 of file RC_Channel.cpp.
int16_t RC_Channel::control_in |
Definition at line 64 of file RC_Channel.h.
int16_t RC_Channel::dead_zone |
Definition at line 65 of file RC_Channel.h.
int16_t RC_Channel::pwm_out |
Definition at line 76 of file RC_Channel.h.
int16_t RC_Channel::radio_in |
Definition at line 55 of file RC_Channel.h.
int16_t RC_Channel::radio_max |
Definition at line 81 of file RC_Channel.h.
int16_t RC_Channel::radio_min |
Definition at line 79 of file RC_Channel.h.
int16_t RC_Channel::radio_out |
Definition at line 77 of file RC_Channel.h.
int16_t RC_Channel::radio_trim |
Definition at line 80 of file RC_Channel.h.
float RC_Channel::scale_output |
Definition at line 93 of file RC_Channel.h.
int16_t RC_Channel::servo_out |
Definition at line 70 of file RC_Channel.h.