mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-16 07:33:35 +08:00
Removed extra abstracton layer in systemlib
The calls to task_spawn_cmd, kill_all, and systemreset were wrappers
around the px4_{task_spawn_cmd|kill_all|systemreset} implementations.
Removed the wrappers and changed all calls to the px4_ equivalents.
NuttX specific code was moved into px4_tasks.h
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
This commit is contained in:
@@ -42,7 +42,6 @@ SRCS = err.c \
|
||||
cpuload.c \
|
||||
getopt_long.c \
|
||||
pid/pid.c \
|
||||
systemlib.c \
|
||||
airspeed.c \
|
||||
system_params.c \
|
||||
mavlink_log.c \
|
||||
|
||||
@@ -42,31 +42,12 @@
|
||||
#include <float.h>
|
||||
#include <stdint.h>
|
||||
#include <sched.h>
|
||||
|
||||
// OS specific settings defined in px4_tasks.h
|
||||
#include <px4_tasks.h>
|
||||
|
||||
__BEGIN_DECLS
|
||||
|
||||
/** Reboots the board */
|
||||
__EXPORT void systemreset(bool to_bootloader) noreturn_function;
|
||||
|
||||
/** Sends SIGUSR1 to all processes */
|
||||
__EXPORT void killall(void);
|
||||
|
||||
/** Default scheduler type */
|
||||
#if CONFIG_RR_INTERVAL > 0
|
||||
# define SCHED_DEFAULT SCHED_RR
|
||||
#else
|
||||
# define SCHED_DEFAULT SCHED_FIFO
|
||||
#endif
|
||||
|
||||
/** Starts a task and performs any specific accounting, scheduler setup, etc. */
|
||||
__EXPORT int task_spawn_cmd(const char *name,
|
||||
int priority,
|
||||
int scheduler,
|
||||
int stack_size,
|
||||
px4_main_t entry,
|
||||
char * const argv[]);
|
||||
|
||||
enum MULT_PORTS {
|
||||
MULT_0_US2_RXTX = 0,
|
||||
MULT_1_US2_FLOW,
|
||||
|
||||
Reference in New Issue
Block a user