PX4 Firmware
PX4 Autopilot Software http://px4.io
spektrum_rc.cpp File Reference

This is a driver for a Spektrum satellite receiver connected to a Snapdragon on the serial port. More...

#include <string.h>
#include <px4_platform_common/tasks.h>
#include <px4_platform_common/posix.h>
#include <px4_platform_common/getopt.h>
#include <lib/rc/dsm.h>
#include <drivers/drv_rc_input.h>
#include <drivers/drv_hrt.h>
#include <uORB/uORB.h>
#include <uORB/topics/input_rc.h>
Include dependency graph for spektrum_rc.cpp:

Go to the source code of this file.

Namespaces

 spektrum_rc
 

Macros

#define SPEKTRUM_UART_DEVICE_PATH   "/dev/tty-3"
 
#define UNUSED(x)   (void)(x)
 

Functions

__EXPORT int spektrum_rc_main (int argc, char *argv[])
 
int spektrum_rc::start ()
 Attempt to start driver on all available I2C busses. More...
 
int spektrum_rc::stop ()
 Stop the driver. More...
 
int spektrum_rc::info ()
 Print a little info about the driver. More...
 
void spektrum_rc::usage ()
 Prints info about the driver argument usage. More...
 
void spektrum_rc::task_main (int argc, char *argv[])
 
void spektrum_rc::fill_input_rc (uint16_t raw_rc_count, uint16_t raw_rc_values[input_rc_s::RC_INPUT_MAX_CHANNELS], hrt_abstime now, bool frame_drop, bool failsafe, unsigned frame_drops, int rssi, input_rc_s &input_rc)
 
int spektrum_rc::start (int argc, char *argv[])
 

Variables

volatile bool spektrum_rc::_task_should_exit = false
 
static bool spektrum_rc::_is_running = false
 
static px4_task_t spektrum_rc::_task_handle = -1
 

Detailed Description

This is a driver for a Spektrum satellite receiver connected to a Snapdragon on the serial port.

By default port J12 (next to J13, power module side) is used.

Definition in file spektrum_rc.cpp.

Macro Definition Documentation

◆ SPEKTRUM_UART_DEVICE_PATH

#define SPEKTRUM_UART_DEVICE_PATH   "/dev/tty-3"

Definition at line 56 of file spektrum_rc.cpp.

Referenced by spektrum_rc::task_main().

◆ UNUSED

#define UNUSED (   x)    (void)(x)

Function Documentation

◆ spektrum_rc_main()

int spektrum_rc_main ( int  argc,
char *  argv[] 
)

Definition at line 268 of file spektrum_rc.cpp.

References spektrum_rc::info(), spektrum_rc::start(), spektrum_rc::stop(), and spektrum_rc::usage().

Here is the call graph for this function: