mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-19 22:35:23 +03:00
Renamed fc_msp* files to msp*
This commit is contained in:
parent
f5e25eb9b4
commit
8044d08fb3
17 changed files with 27 additions and 49 deletions
|
@ -99,8 +99,8 @@ extern uint8_t __config_end;
|
|||
#include "flight/servos.h"
|
||||
|
||||
#include "interface/cli.h"
|
||||
#include "interface/fc_msp.h"
|
||||
#include "interface/fc_msp_box.h"
|
||||
#include "interface/msp.h"
|
||||
#include "interface/msp_box.h"
|
||||
#include "interface/msp_protocol.h"
|
||||
#include "interface/settings.h"
|
||||
|
||||
|
|
|
@ -74,8 +74,8 @@
|
|||
#include "flight/pid.h"
|
||||
#include "flight/servos.h"
|
||||
|
||||
#include "interface/fc_msp.h"
|
||||
#include "interface/fc_msp_box.h"
|
||||
#include "interface/msp.h"
|
||||
#include "interface/msp_box.h"
|
||||
#include "interface/msp_protocol.h"
|
||||
|
||||
#include "io/asyncfatfs/asyncfatfs.h"
|
||||
|
@ -95,11 +95,10 @@
|
|||
#include "io/vtx.h"
|
||||
#include "io/vtx_string.h"
|
||||
|
||||
#include "msp/msp.h"
|
||||
#include "msp/msp_serial.h"
|
||||
|
||||
#include "rx/msp.h"
|
||||
#include "rx/rx.h"
|
||||
#include "rx/msp.h"
|
||||
|
||||
#include "scheduler/scheduler.h"
|
||||
|
|
@ -17,10 +17,34 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "msp/msp.h"
|
||||
#include "common/streambuf.h"
|
||||
|
||||
// return positive for ACK, negative on error, zero for no reply
|
||||
typedef enum {
|
||||
MSP_RESULT_ACK = 1,
|
||||
MSP_RESULT_ERROR = -1,
|
||||
MSP_RESULT_NO_REPLY = 0,
|
||||
MSP_RESULT_CMD_UNKNOWN = -2, // don't know how to process command, try next handler
|
||||
} mspResult_e;
|
||||
|
||||
typedef enum {
|
||||
MSP_DIRECTION_REPLY = 0,
|
||||
MSP_DIRECTION_REQUEST = 1
|
||||
} mspDirection_e;
|
||||
|
||||
typedef struct mspPacket_s {
|
||||
sbuf_t buf;
|
||||
int16_t cmd;
|
||||
int16_t result;
|
||||
uint8_t direction;
|
||||
} mspPacket_t;
|
||||
|
||||
struct serialPort_s;
|
||||
typedef void (*mspPostProcessFnPtr)(struct serialPort_s *port); // msp post process function, used for gracefully handling reboots, etc.
|
||||
typedef mspResult_e (*mspProcessCommandFnPtr)(mspPacket_t *cmd, mspPacket_t *reply, mspPostProcessFnPtr *mspPostProcessFn);
|
||||
typedef void (*mspProcessReplyFnPtr)(mspPacket_t *cmd);
|
||||
|
||||
|
||||
void mspInit(void);
|
||||
mspResult_e mspFcProcessCommand(mspPacket_t *cmd, mspPacket_t *reply, mspPostProcessFnPtr *mspPostProcessFn);
|
||||
void mspFcProcessReply(mspPacket_t *reply);
|
||||
|
||||
void mspSerialProcessStreamSchedule(void);
|
|
@ -32,7 +32,7 @@
|
|||
|
||||
#include "flight/mixer.h"
|
||||
|
||||
#include "interface/fc_msp_box.h"
|
||||
#include "interface/msp_box.h"
|
||||
|
||||
#include "sensors/sensors.h"
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue