mirror of https://github.com/ArduPilot/ardupilot
AP_RCProtocol: add separate define for AP_RCPROTOCOL_ST24_ENABLED
This commit is contained in:
parent
5c815e2c32
commit
1225d4c88f
|
@ -66,7 +66,9 @@ void AP_RCProtocol::init()
|
|||
#if AP_RCPROTOCOL_FPORT2_ENABLED
|
||||
backend[AP_RCProtocol::FPORT2] = new AP_RCProtocol_FPort2(*this, true);
|
||||
#endif
|
||||
#if AP_RCPROTOCOL_ST24_ENABLED
|
||||
backend[AP_RCProtocol::ST24] = new AP_RCProtocol_ST24(*this);
|
||||
#endif
|
||||
#if AP_RCPROTOCOL_FPORT_ENABLED
|
||||
backend[AP_RCProtocol::FPORT] = new AP_RCProtocol_FPort(*this, true);
|
||||
#endif
|
||||
|
@ -451,8 +453,10 @@ const char *AP_RCProtocol::protocol_name_from_protocol(rcprotocol_t protocol)
|
|||
case CRSF:
|
||||
return "CRSF";
|
||||
#endif
|
||||
#if AP_RCPROTOCOL_ST24_ENABLED
|
||||
case ST24:
|
||||
return "ST24";
|
||||
#endif
|
||||
#if AP_RCPROTOCOL_FPORT_ENABLED
|
||||
case FPORT:
|
||||
return "FPORT";
|
||||
|
|
|
@ -49,7 +49,9 @@ public:
|
|||
#if AP_RCPROTOCOL_CRSF_ENABLED
|
||||
CRSF = 8,
|
||||
#endif
|
||||
#if AP_RCPROTOCOL_ST24_ENABLED
|
||||
ST24 = 9,
|
||||
#endif
|
||||
#if AP_RCPROTOCOL_FPORT_ENABLED
|
||||
FPORT = 10,
|
||||
#endif
|
||||
|
@ -126,7 +128,9 @@ public:
|
|||
#if AP_RCPROTOCOL_SRXL2_ENABLED
|
||||
case SRXL2:
|
||||
#endif
|
||||
#if AP_RCPROTOCOL_ST24_ENABLED
|
||||
case ST24:
|
||||
#endif
|
||||
case NONE:
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -44,7 +44,7 @@
|
|||
*/
|
||||
#include "AP_RCProtocol_config.h"
|
||||
|
||||
#if AP_RCPROTOCOL_ENABLED
|
||||
#if AP_RCPROTOCOL_ST24_ENABLED
|
||||
|
||||
#include "AP_RCProtocol_ST24.h"
|
||||
|
||||
|
@ -238,4 +238,4 @@ void AP_RCProtocol_ST24::process_byte(uint8_t byte, uint32_t baudrate)
|
|||
_process_byte(byte);
|
||||
}
|
||||
|
||||
#endif // AP_RCPROTOCOL_ENABLED
|
||||
#endif // AP_RCPROTOCOL_ST24_ENABLED
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
#include "AP_RCProtocol_config.h"
|
||||
|
||||
#if AP_RCPROTOCOL_ENABLED
|
||||
#if AP_RCPROTOCOL_ST24_ENABLED
|
||||
|
||||
#include "AP_RCProtocol_Backend.h"
|
||||
#include "SoftSerial.h"
|
||||
|
@ -154,4 +154,4 @@ private:
|
|||
SoftSerial ss{115200, SoftSerial::SERIAL_CONFIG_8N1};
|
||||
};
|
||||
|
||||
#endif // AP_RCPROTOCOL_ENABLED
|
||||
#endif // AP_RCPROTOCOL_ST24_ENABLED
|
||||
|
|
|
@ -34,6 +34,10 @@
|
|||
#define AP_RCPROTOCOL_SRXL2_ENABLED AP_RCPROTOCOL_BACKEND_DEFAULT_ENABLED
|
||||
#endif
|
||||
|
||||
#ifndef AP_RCPROTOCOL_ST24_ENABLED
|
||||
#define AP_RCPROTOCOL_ST24_ENABLED AP_RCPROTOCOL_BACKEND_DEFAULT_ENABLED
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef AP_RCPROTOCOL_SBUS_NI_ENABLED
|
||||
#define AP_RCPROTOCOL_SBUS_NI_ENABLED AP_RCPROTOCOL_BACKEND_DEFAULT_ENABLED && AP_RCPROTOCOL_SBUS_ENABLED
|
||||
|
|
Loading…
Reference in New Issue