Paparazzi UAS
v5.8.2_stable-0-g6260b7c
Paparazzi is a free software Unmanned Aircraft System.
|
#include "led.h"
#include "generated/airframe.h"
#include "paparazzi.h"
#include <RADIO_CONTROL_TYPE_H>
Go to the source code of this file.
Data Structures | |
struct | RadioControl |
Macros | |
#define | RC_AVG_PERIOD 8 /* TODO remove if IIR filter is used */ |
#define | RC_LOST_TIME 30 /* 500ms with a 60Hz timer */ |
#define | RC_REALLY_LOST_TIME 60 /* ~1s */ |
#define | RC_OK_CPT 15 |
#define | RC_OK 0 |
#define | RC_LOST 1 |
#define | RC_REALLY_LOST 2 |
Functions | |
void | radio_control_impl_init (void) |
Initialization. More... | |
void | radio_control_init (void) |
void | radio_control_periodic_task (void) |
Variables | |
struct RadioControl | radio_control |
struct RadioControl |
Definition at line 52 of file radio_control.h.
Data Fields | ||
---|---|---|
uint8_t | frame_cpt | |
uint8_t | frame_rate | |
uint8_t | radio_ok_cpt | |
uint8_t | status | |
uint8_t | time_since_last_frame | |
pprz_t | values[RADIO_CONTROL_NB_CHANNEL] |
#define RC_AVG_PERIOD 8 /* TODO remove if IIR filter is used */ |
Definition at line 42 of file radio_control.h.
#define RC_LOST 1 |
Definition at line 49 of file radio_control.h.
Referenced by radio_control_periodic_task().
#define RC_LOST_TIME 30 /* 500ms with a 60Hz timer */ |
Definition at line 43 of file radio_control.h.
Referenced by radio_control_periodic_task().
#define RC_OK 0 |
Definition at line 48 of file radio_control.h.
Referenced by failsafe_check(), guidance_h_read_rc(), guidance_v_run(), intermcu_parse_msg(), radio_control_impl_event(), radio_control_periodic_task(), and RadioControlEventImp().
#define RC_OK_CPT 15 |
Definition at line 46 of file radio_control.h.
Referenced by radio_control_periodic_task().
#define RC_REALLY_LOST 2 |
Definition at line 50 of file radio_control.h.
Referenced by failsafe_check(), main_periodic(), periodic_task_fbw(), radio_control_init(), and radio_control_periodic_task().
#define RC_REALLY_LOST_TIME 60 /* ~1s */ |
Definition at line 44 of file radio_control.h.
Referenced by radio_control_init(), and radio_control_periodic_task().
void radio_control_impl_init | ( | void | ) |
Initialization.
Definition at line 30 of file spektrum_arch.c.
References DefaultPeriodic, FALSE, gpio_setup_output(), ppm_arch_init(), ppm_cur_pulse, ppm_data_valid, ppm_frame_available, ppm_last_pulse_time, rc_dl_frame_available, RC_POLARITY_GPIO_PIN, RC_POLARITY_GPIO_PORT, RC_SET_POLARITY, rc_spk_parser_idx, rc_spk_parser_status, RC_SPK_STA_UNINIT, register_periodic_telemetry(), SpektrumStateStruct::ReSync, sbus, sbus2, sbus_common_init(), send_ppm(), spektrum_available, SpektrumTimerInit(), SpektrumUartInit(), and superbitrf_init().
Referenced by radio_control_init().
void radio_control_init | ( | void | ) |
Definition at line 32 of file radio_control.c.
References RadioControl::frame_cpt, RadioControl::frame_rate, radio_control, radio_control_impl_init(), RADIO_CONTROL_NB_CHANNEL, RadioControl::radio_ok_cpt, RC_REALLY_LOST, RC_REALLY_LOST_TIME, RadioControl::status, RadioControl::time_since_last_frame, and RadioControl::values.
Referenced by init_fbw(), and main_init().
void radio_control_periodic_task | ( | void | ) |
Definition at line 46 of file radio_control.c.
References RadioControl::frame_cpt, RadioControl::frame_rate, LED_OFF, LED_ON, radio_control, RadioControl::radio_ok_cpt, RC_LOST, RC_LOST_TIME, RC_OK, RC_OK_CPT, RC_REALLY_LOST, RC_REALLY_LOST_TIME, RadioControl::status, and RadioControl::time_since_last_frame.
Referenced by handle_periodic_tasks(), and periodic_task_fbw().
struct RadioControl radio_control |
Definition at line 30 of file radio_control.c.
Referenced by ap_mode_of_3way_switch(), autopilot_on_rc_frame(), failsafe_check(), get_rc_pitch(), get_rc_pitch_f(), get_rc_roll(), get_rc_roll_f(), get_rc_yaw(), get_rc_yaw_f(), guidance_h_module_read_rc(), guidance_h_read_rc(), guidance_v_read_rc(), guidance_v_run(), handle_rc_frame(), intermcu_on_rc_frame(), intermcu_parse_msg(), main_periodic(), percent_from_rc(), periodic_task_fbw(), radio_control_impl_event(), radio_control_init(), radio_control_periodic_task(), RadioControlEventImp(), read_rc_setpoint_speed_i(), sdlogger_spi_direct_periodic(), send_rc(), send_rotorcraft_rc(), send_status(), stabilization_none_read_rc(), stabilization_rate_read_rc(), stabilization_rate_read_rc_switched_sticks(), and update_rc_channel().