Commander helper functions implementations.
More...
#include <px4_defines.h>
#include <px4_posix.h>
#include <stdio.h>
#include <unistd.h>
#include <stdint.h>
#include <stdbool.h>
#include <fcntl.h>
#include <math.h>
#include <string.h>
#include <uORB/uORB.h>
#include <uORB/topics/vehicle_status.h>
#include <uORB/topics/actuator_controls.h>
#include <uORB/topics/vehicle_control_mode.h>
#include <uORB/topics/led_control.h>
#include <uORB/topics/tune_control.h>
#include <systemlib/err.h>
#include <parameters/param.h>
#include <drivers/drv_hrt.h>
#include <drivers/drv_tone_alarm.h>
#include "commander_helper.h"
#include "DevMgr.hpp"
|
#define | VEHICLE_TYPE_QUADROTOR 2 |
|
#define | VEHICLE_TYPE_COAXIAL 3 |
|
#define | VEHICLE_TYPE_HELICOPTER 4 |
|
#define | VEHICLE_TYPE_HEXAROTOR 13 |
|
#define | VEHICLE_TYPE_OCTOROTOR 14 |
|
#define | VEHICLE_TYPE_TRICOPTER 15 |
|
#define | VEHICLE_TYPE_VTOL_DUOROTOR 19 |
|
#define | VEHICLE_TYPE_VTOL_QUADROTOR 20 |
|
#define | VEHICLE_TYPE_VTOL_TILTROTOR 21 |
|
#define | VEHICLE_TYPE_VTOL_RESERVED2 22 |
|
#define | VEHICLE_TYPE_VTOL_RESERVED3 23 |
|
#define | VEHICLE_TYPE_VTOL_RESERVED4 24 |
|
#define | VEHICLE_TYPE_VTOL_RESERVED5 25 |
|
#define | BLINK_MSG_TIME 700000 |
|
|
bool | is_multirotor (const struct vehicle_status_s *current_status) |
|
bool | is_rotary_wing (const struct vehicle_status_s *current_status) |
|
bool | is_vtol (const struct vehicle_status_s *current_status) |
|
int | buzzer_init () |
|
void | buzzer_deinit () |
|
void | set_tune_override (int tune) |
|
void | set_tune (int tune) |
|
void | tune_home_set (bool use_buzzer) |
|
void | tune_mission_ok (bool use_buzzer) |
|
void | tune_mission_fail (bool use_buzzer) |
|
void | tune_positive (bool use_buzzer) |
| Blink green LED and play positive tune (if use_buzzer == true).
|
|
void | tune_neutral (bool use_buzzer) |
| Blink white LED and play neutral tune (if use_buzzer == true).
|
|
void | tune_negative (bool use_buzzer) |
| Blink red LED and play negative tune (if use_buzzer == true).
|
|
void | tune_failsafe (bool use_buzzer) |
|
int | blink_msg_state () |
|
int | led_init () |
| Ideally we'd be able to get these from up_internal.h, but since we want to be able to disable the NuttX use of leds for system indication at will and there is no separate switch, we need to build independent of the CONFIG_ARCH_LEDS configuration switch.
|
|
void | led_deinit () |
|
int | led_toggle (int led) |
|
int | led_on (int led) |
|
int | led_off (int led) |
|
void | rgbled_set_color_and_mode (uint8_t color, uint8_t mode, uint8_t blinks, uint8_t prio) |
|
void | rgbled_set_color_and_mode (uint8_t color, uint8_t mode) |
| set the LED color & mode More...
|
|
§ rgbled_set_color_and_mode()
void rgbled_set_color_and_mode |
( |
uint8_t |
color, |
|
|
uint8_t |
mode |
|
) |
| |
set the LED color & mode
- Parameters
-
- See also
- led_control_s::COLOR_*
- Parameters
-
- See also
- led_control_s::MODE_*