PX4 Firmware
PX4 Autopilot Software http://px4.io
rc_receiver Namespace Reference

Functions

static void usage ()
 Print out the usage information. More...
 
static void start ()
 mpu9x50 start measurement More...
 
static void stop ()
 mpu9x50 stop measurement More...
 
static void task_main_trampoline (int argc, char *argv[])
 task main trampoline function More...
 
static void task_main (int argc, char *argv[])
 mpu9x50 measurement thread primary entry point More...
 
static void parameters_update ()
 update all parameters More...
 
static void parameter_update_poll ()
 poll parameter update More...
 
void parameters_init ()
 

Variables

static char _device [MAX_LEN_DEV_PATH]
 serial device path that rc receiver is connected to More...
 
static bool _is_running = false
 flag indicating if rc_receiver module is running More...
 
static bool _task_should_exit = false
 flag indicating if task thread should exit More...
 
static px4_task_t _task_handle = -1
 handle to the task main thread More...
 
static enum RC_RECEIVER_TYPES _rc_receiver_type
 RC receiver type. More...
 
static uint16_t rc_inputs [input_rc_s::RC_INPUT_MAX_CHANNELS]
 RC input channel value array accomondating up to RC_INPUT_MAX_CHANNELS. More...
 
static orb_advert_t _input_rc_pub = nullptr
 rc_input uorb topic publication handle More...
 
static struct input_rc_s _rc_in
 rc_input uorb topic data More...
 
static int _params_sub
 
struct {
   param_t   rc_receiver::rc_receiver_type
 
_params_handles
 parameter handles More...
 

Function Documentation

◆ parameter_update_poll()

void rc_receiver::parameter_update_poll ( )
static

poll parameter update

Definition at line 134 of file rc_receiver_main.cpp.

References orb_check(), orb_copy(), ORB_ID, and parameters_update().

Referenced by task_main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ parameters_init()

void rc_receiver::parameters_init ( )

Definition at line 127 of file rc_receiver_main.cpp.

References _params_handles, param_find(), and parameters_update().

Here is the call graph for this function:

◆ parameters_update()

void rc_receiver::parameters_update ( )
static

update all parameters

Definition at line 115 of file rc_receiver_main.cpp.

References _params_handles, and param_get().

Referenced by parameter_update_poll(), and parameters_init().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ start()

void rc_receiver::start ( )
static

mpu9x50 start measurement

Definition at line 148 of file rc_receiver_main.cpp.

References task_main_trampoline(), and warn.

Referenced by rc_receiver_main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ stop()

void rc_receiver::stop ( )
static

mpu9x50 stop measurement

Definition at line 168 of file rc_receiver_main.cpp.

Referenced by rc_receiver_main().

Here is the caller graph for this function:

◆ task_main()

void rc_receiver::task_main ( int  argc,
char *  argv[] 
)
static

mpu9x50 measurement thread primary entry point

Definition at line 182 of file rc_receiver_main.cpp.

References _rc_in, input_rc_s::channel_count, counter, fd, hrt_absolute_time(), input_rc_s::input_source, orb_advertise(), ORB_ID, orb_publish(), orb_subscribe(), parameter_update_poll(), input_rc_s::rc_failsafe, RC_INPUT_RSSI_MAX, input_rc_s::rc_lost, input_rc_s::rc_lost_frame_count, input_rc_s::rc_total_frame_count, input_rc_s::rssi, SIGNAL_LOST_THRESHOLD_MS, input_rc_s::timestamp, input_rc_s::timestamp_last_signal, and input_rc_s::values.

Referenced by task_main_trampoline().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ task_main_trampoline()

void rc_receiver::task_main_trampoline ( int  argc,
char *  argv[] 
)
static

task main trampoline function

Definition at line 176 of file rc_receiver_main.cpp.

References task_main().

Referenced by start().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ usage()

void rc_receiver::usage ( void  )
static

Print out the usage information.

Definition at line 278 of file rc_receiver_main.cpp.

Referenced by rc_receiver_main().

Here is the caller graph for this function:

Variable Documentation

◆ _device

char rc_receiver::_device[MAX_LEN_DEV_PATH]
static

serial device path that rc receiver is connected to

Definition at line 64 of file rc_receiver_main.cpp.

Referenced by rc_receiver_main().

◆ _input_rc_pub

orb_advert_t rc_receiver::_input_rc_pub = nullptr
static

rc_input uorb topic publication handle

Definition at line 82 of file rc_receiver_main.cpp.

◆ _is_running

bool rc_receiver::_is_running = false
static

flag indicating if rc_receiver module is running

Definition at line 67 of file rc_receiver_main.cpp.

Referenced by rc_receiver_main().

◆ _params_handles

struct { ... } rc_receiver::_params_handles

parameter handles

Referenced by parameters_init(), and parameters_update().

◆ _params_sub

int rc_receiver::_params_sub
static

Definition at line 88 of file rc_receiver_main.cpp.

◆ _rc_in

struct input_rc_s rc_receiver::_rc_in
static

rc_input uorb topic data

parameter update subscription

Definition at line 85 of file rc_receiver_main.cpp.

Referenced by task_main().

◆ _rc_receiver_type

enum RC_RECEIVER_TYPES rc_receiver::_rc_receiver_type
static

RC receiver type.

Definition at line 76 of file rc_receiver_main.cpp.

◆ _task_handle

px4_task_t rc_receiver::_task_handle = -1
static

handle to the task main thread

Definition at line 73 of file rc_receiver_main.cpp.

◆ _task_should_exit

bool rc_receiver::_task_should_exit = false
static

flag indicating if task thread should exit

Definition at line 70 of file rc_receiver_main.cpp.

◆ rc_inputs

uint16_t rc_receiver::rc_inputs[input_rc_s::RC_INPUT_MAX_CHANNELS]
static

RC input channel value array accomondating up to RC_INPUT_MAX_CHANNELS.

Definition at line 79 of file rc_receiver_main.cpp.

◆ rc_receiver_type

param_t rc_receiver::rc_receiver_type

Definition at line 91 of file rc_receiver_main.cpp.