|
MAV'RIC
|

Classes | |
| union | button_t |
| The union structure for the bit mask of the joystick buttons. More... | |
| struct | channels_t |
| Joystick Channels. More... | |
| struct | conf_t |
| Configuration for joystick. More... | |
Public Types | |
| enum | button_pressed_t { BUTTON_UNPRESSED = 0, BUTTON_PRESSED = 1 } |
| button enumeration | |
| enum | throttle_mode_t { ZERO_CENTER = 0, ZERO_DOWN } |
Public Member Functions | |
| Joystick (conf_t conf=default_config()) | |
| Constructor. | |
| float | throttle () const |
| Returns the throttle value from the joystick. | |
| float | roll () const |
| Returns the roll value from the joystick. | |
| float | pitch () const |
| Returns the pitch value from the joystick. | |
| float | yaw () const |
| Returns the yaw value from the joystick. | |
| Mav_mode | get_mode (const Mav_mode current_mode) |
| Returns the current desired mode value from the joystick. | |
| void | button_update (uint16_t buttons) |
| Do operations when buttons are pressed. | |
Static Public Member Functions | |
| static conf_t | default_config () |
| Default config for joystick. | |
Public Attributes | |
| button_t | buttons_ |
| The bit mask of the button pressed. | |
| channels_t | channels_ |
| Channels of the joystick. | |
| Mav_mode | mav_mode_desired_ |
| The mav mode indicated by the remote. | |
| void Joystick::button_update | ( | uint16_t | buttons | ) |
Do operations when buttons are pressed.
| buttons | The bit mask of the buttons |

| Mav_mode Joystick::get_mode | ( | const Mav_mode | current_mode | ) |
Returns the current desired mode value from the joystick.


| float Joystick::pitch | ( | ) | const |
Returns the pitch value from the joystick.

| float Joystick::roll | ( | ) | const |
Returns the roll value from the joystick.

| float Joystick::throttle | ( | ) | const |
Returns the throttle value from the joystick.

| float Joystick::yaw | ( | ) | const |
Returns the yaw value from the joystick.

1.7.6.1