[PXX2] R9M/R9 BIND options added
This commit is contained in:
@@ -124,7 +124,7 @@ void setupPulsesDSM2()
|
||||
|
||||
extmodulePulsesData.dsm2.ptr = extmodulePulsesData.dsm2.pulses;
|
||||
|
||||
switch (moduleSettings[EXTERNAL_MODULE].protocol) {
|
||||
switch (moduleState[EXTERNAL_MODULE].protocol) {
|
||||
case PROTOCOL_CHANNELS_DSM2_LP45:
|
||||
dsmDat[0] = 0x00;
|
||||
break;
|
||||
@@ -140,21 +140,21 @@ void setupPulsesDSM2()
|
||||
if (dsm2BindTimer > 0) {
|
||||
dsm2BindTimer--;
|
||||
if (switchState(SW_DSM2_BIND)) {
|
||||
moduleSettings[EXTERNAL_MODULE].mode = MODULE_MODE_BIND;
|
||||
moduleState[EXTERNAL_MODULE].mode = MODULE_MODE_BIND;
|
||||
dsmDat[0] |= DSM2_SEND_BIND;
|
||||
}
|
||||
}
|
||||
else if (moduleSettings[EXTERNAL_MODULE].mode == MODULE_MODE_RANGECHECK) {
|
||||
else if (moduleState[EXTERNAL_MODULE].mode == MODULE_MODE_RANGECHECK) {
|
||||
dsmDat[0] |= DSM2_SEND_RANGECHECK;
|
||||
}
|
||||
else {
|
||||
moduleSettings[EXTERNAL_MODULE].mode = 0;
|
||||
moduleState[EXTERNAL_MODULE].mode = 0;
|
||||
}
|
||||
#else
|
||||
if (moduleSettings[EXTERNAL_MODULE].mode == MODULE_MODE_BIND) {
|
||||
if (moduleState[EXTERNAL_MODULE].mode == MODULE_MODE_BIND) {
|
||||
dsmDat[0] |= DSM2_SEND_BIND;
|
||||
}
|
||||
else if (moduleSettings[EXTERNAL_MODULE].mode == MODULE_MODE_RANGECHECK) {
|
||||
else if (moduleState[EXTERNAL_MODULE].mode == MODULE_MODE_RANGECHECK) {
|
||||
dsmDat[0] |= DSM2_SEND_RANGECHECK;
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -154,16 +154,16 @@ void sendFrameProtocolHeader(uint8_t port, bool failsafe)
|
||||
int8_t optionValue = g_model.moduleData[port].multi.optionValue;
|
||||
|
||||
uint8_t protoByte = 0;
|
||||
if (moduleSettings[port].mode == MODULE_MODE_BIND)
|
||||
if (moduleState[port].mode == MODULE_MODE_BIND)
|
||||
protoByte |= MULTI_SEND_BIND;
|
||||
else if (moduleSettings[port].mode == MODULE_MODE_RANGECHECK)
|
||||
else if (moduleState[port].mode == MODULE_MODE_RANGECHECK)
|
||||
protoByte |= MULTI_SEND_RANGECHECK;
|
||||
|
||||
// rfProtocol
|
||||
if (g_model.moduleData[port].getMultiProtocol(true) == MM_RF_PROTO_DSM2) {
|
||||
|
||||
// Autobinding should always be done in DSMX 11ms
|
||||
if (g_model.moduleData[port].multi.autoBindMode && moduleSettings[port].mode == MODULE_MODE_BIND)
|
||||
if (g_model.moduleData[port].multi.autoBindMode && moduleState[port].mode == MODULE_MODE_BIND)
|
||||
subtype = MM_RF_DSM2_SUBTYPE_AUTO;
|
||||
|
||||
// Multi module in DSM mode wants the number of channels to be used as option value
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
#include "pulses/pxx2.h"
|
||||
|
||||
uint8_t s_pulses_paused = 0;
|
||||
ModuleSettings moduleSettings[NUM_MODULES];
|
||||
ModuleState moduleState[NUM_MODULES];
|
||||
InternalModulePulsesData intmodulePulsesData __DMA;
|
||||
ExternalModulePulsesData extmodulePulsesData __DMA;
|
||||
TrainerPulsesData trainerPulsesData __DMA;
|
||||
@@ -94,7 +94,7 @@ uint8_t getRequiredProtocol(uint8_t module)
|
||||
// The module is set to OFF during one second before BIND start
|
||||
{
|
||||
static tmr10ms_t bindStartTime = 0;
|
||||
if (moduleSettings[module].mode == MODULE_MODE_BIND) {
|
||||
if (moduleState[module].mode == MODULE_MODE_BIND) {
|
||||
if (bindStartTime == 0) bindStartTime = get_tmr10ms();
|
||||
if ((tmr10ms_t)(get_tmr10ms() - bindStartTime) < 100) {
|
||||
protocol = PROTOCOL_CHANNELS_NONE;
|
||||
@@ -125,7 +125,7 @@ uint8_t getRequiredProtocol(uint8_t module)
|
||||
|
||||
#if 0
|
||||
// will need an EEPROM conversion
|
||||
if (moduleSettings[module].mode == MODULE_OFF) {
|
||||
if (moduleState[module].mode == MODULE_OFF) {
|
||||
protocol = PROTOCOL_CHANNELS_NONE;
|
||||
}
|
||||
#endif
|
||||
@@ -263,7 +263,7 @@ void setupPulsesInternalModule(uint8_t protocol)
|
||||
#if defined(PXX2)
|
||||
case PROTOCOL_CHANNELS_PXX2:
|
||||
intmodulePulsesData.pxx2.setupFrame(INTERNAL_MODULE);
|
||||
scheduleNextMixerCalculation(INTERNAL_MODULE, moduleSettings[INTERNAL_MODULE].mode == MODULE_MODE_SPECTRUM_ANALYSER || moduleSettings[INTERNAL_MODULE].mode == MODULE_MODE_POWER_METER ? 1 : PXX2_PERIOD);
|
||||
scheduleNextMixerCalculation(INTERNAL_MODULE, moduleState[INTERNAL_MODULE].mode == MODULE_MODE_SPECTRUM_ANALYSER || moduleState[INTERNAL_MODULE].mode == MODULE_MODE_POWER_METER ? 1 : PXX2_PERIOD);
|
||||
break;
|
||||
#endif
|
||||
|
||||
@@ -362,9 +362,9 @@ bool setupPulses(uint8_t module)
|
||||
|
||||
heartbeat |= (HEART_TIMER_PULSES << module);
|
||||
|
||||
if (moduleSettings[module].protocol != protocol) {
|
||||
disablePulses(module, moduleSettings[module].protocol);
|
||||
moduleSettings[module].protocol = protocol;
|
||||
if (moduleState[module].protocol != protocol) {
|
||||
disablePulses(module, moduleState[module].protocol);
|
||||
moduleState[module].protocol = protocol;
|
||||
enablePulses(module, protocol);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -28,9 +28,9 @@
|
||||
#include "pulses/pxx2.h"
|
||||
|
||||
#if NUM_MODULES > 1
|
||||
#define IS_RANGECHECK_ENABLE() (moduleSettings[0].mode == MODULE_MODE_RANGECHECK || moduleSettings[1].mode == MODULE_MODE_RANGECHECK)
|
||||
#define IS_RANGECHECK_ENABLE() (moduleState[0].mode == MODULE_MODE_RANGECHECK || moduleState[1].mode == MODULE_MODE_RANGECHECK)
|
||||
#else
|
||||
#define IS_RANGECHECK_ENABLE() (moduleSettings[0].mode == MODULE_MODE_RANGECHECK)
|
||||
#define IS_RANGECHECK_ENABLE() (moduleState[0].mode == MODULE_MODE_RANGECHECK)
|
||||
#endif
|
||||
|
||||
#if defined(PCBSKY9X) && defined(DSM2)
|
||||
@@ -79,15 +79,82 @@ enum ModuleSettingsMode
|
||||
MODULE_MODE_RESET
|
||||
};
|
||||
|
||||
PACK(struct ModuleSettings {
|
||||
|
||||
PACK(struct PXX2Version {
|
||||
uint8_t major;
|
||||
uint8_t revision:4;
|
||||
uint8_t minor:4;
|
||||
});
|
||||
|
||||
PACK(struct PXX2HardwareInformation {
|
||||
uint8_t modelID;
|
||||
PXX2Version hwVersion;
|
||||
PXX2Version swVersion;
|
||||
uint8_t variant;
|
||||
});
|
||||
|
||||
PACK(struct ModuleInformation {
|
||||
int8_t current;
|
||||
int8_t maximum;
|
||||
uint8_t timeout;
|
||||
PXX2HardwareInformation information;
|
||||
struct {
|
||||
PXX2HardwareInformation information;
|
||||
} receivers[PXX2_MAX_RECEIVERS_PER_MODULE];
|
||||
});
|
||||
|
||||
struct ModuleSettings {
|
||||
uint8_t state; // 0x00 = READ 0x40 = WRITE
|
||||
tmr10ms_t retryTime;
|
||||
uint8_t rfProtocol;
|
||||
uint8_t externalAntenna;
|
||||
int8_t txPower;
|
||||
};
|
||||
|
||||
struct ReceiverSettings {
|
||||
uint8_t state; // 0x00 = READ 0x40 = WRITE
|
||||
tmr10ms_t timeout;
|
||||
uint8_t receiverId;
|
||||
uint8_t dirty;
|
||||
uint8_t telemetryDisabled;
|
||||
uint8_t pwmRate;
|
||||
uint8_t outputsCount;
|
||||
uint8_t outputsMapping[24];
|
||||
};
|
||||
|
||||
PACK(struct ModuleState {
|
||||
uint8_t protocol:4;
|
||||
uint8_t mode:4;
|
||||
uint8_t paused:1;
|
||||
uint8_t spare:7;
|
||||
uint16_t counter;
|
||||
union {
|
||||
ModuleInformation * moduleInformation;
|
||||
ModuleSettings * moduleSettings;
|
||||
};
|
||||
void readModuleInformation(ModuleInformation * destination, int8_t first, int8_t last)
|
||||
{
|
||||
moduleInformation = destination;
|
||||
moduleInformation->current = first;
|
||||
moduleInformation->maximum = last;
|
||||
mode = MODULE_MODE_GET_HARDWARE_INFO;
|
||||
}
|
||||
void readModuleSettings(ModuleSettings * destination)
|
||||
{
|
||||
moduleSettings = destination;
|
||||
moduleSettings->state = PXX2_SETTINGS_READ;
|
||||
mode = MODULE_MODE_MODULE_SETTINGS;
|
||||
}
|
||||
void writeModuleSettings(ModuleSettings * source)
|
||||
{
|
||||
moduleSettings = source;
|
||||
moduleSettings->state = PXX2_SETTINGS_WRITE;
|
||||
moduleSettings->retryTime = 0;
|
||||
mode = MODULE_MODE_MODULE_SETTINGS;
|
||||
}
|
||||
});
|
||||
|
||||
extern ModuleSettings moduleSettings[NUM_MODULES];
|
||||
extern ModuleState moduleState[NUM_MODULES];
|
||||
|
||||
template<class T> struct PpmPulsesData {
|
||||
T pulses[20];
|
||||
@@ -241,16 +308,16 @@ enum ChannelsProtocols {
|
||||
PROTOCOL_CHANNELS_PXX2
|
||||
};
|
||||
|
||||
inline bool pulsesStarted() { return moduleSettings[0].protocol != PROTOCOL_CHANNELS_UNINITIALIZED; }
|
||||
inline bool pulsesStarted() { return moduleState[0].protocol != PROTOCOL_CHANNELS_UNINITIALIZED; }
|
||||
inline void pausePulses() { s_pulses_paused = true; }
|
||||
inline void resumePulses() { s_pulses_paused = false; }
|
||||
|
||||
#define SEND_FAILSAFE_NOW(idx) moduleSettings[idx].counter = 1
|
||||
#define SEND_FAILSAFE_NOW(idx) moduleState[idx].counter = 1
|
||||
|
||||
inline void SEND_FAILSAFE_1S()
|
||||
{
|
||||
for (int i=0; i<NUM_MODULES; i++) {
|
||||
moduleSettings[i].counter = 100;
|
||||
moduleState[i].counter = 100;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -60,22 +60,22 @@ template <class PxxTransport>
|
||||
uint8_t Pxx1Pulses<PxxTransport>::addFlag1(uint8_t module)
|
||||
{
|
||||
uint8_t flag1 = (g_model.moduleData[module].rfProtocol << 6);
|
||||
if (moduleSettings[module].mode == MODULE_MODE_BIND) {
|
||||
if (moduleState[module].mode == MODULE_MODE_BIND) {
|
||||
flag1 |= (g_eeGeneral.countryCode << 1) | PXX_SEND_BIND;
|
||||
}
|
||||
else if (moduleSettings[module].mode == MODULE_MODE_RANGECHECK) {
|
||||
else if (moduleState[module].mode == MODULE_MODE_RANGECHECK) {
|
||||
flag1 |= PXX_SEND_RANGECHECK;
|
||||
}
|
||||
else {
|
||||
bool failsafeNeeded = g_model.moduleData[module].failsafeMode != FAILSAFE_NOT_SET && g_model.moduleData[module].failsafeMode != FAILSAFE_RECEIVER;
|
||||
if (moduleSettings[module].counter-- == 0) {
|
||||
if (moduleState[module].counter-- == 0) {
|
||||
// counter is also used for knowing if the frame is odd / even
|
||||
moduleSettings[module].counter = 1000;
|
||||
moduleState[module].counter = 1000;
|
||||
if (failsafeNeeded) {
|
||||
flag1 |= PXX_SEND_FAILSAFE;
|
||||
}
|
||||
}
|
||||
if (failsafeNeeded && moduleSettings[module].counter == 0 && g_model.moduleData[module].channelsCount > 0) {
|
||||
if (failsafeNeeded && moduleState[module].counter == 0 && g_model.moduleData[module].channelsCount > 0) {
|
||||
flag1 |= PXX_SEND_FAILSAFE;
|
||||
}
|
||||
}
|
||||
@@ -219,7 +219,7 @@ void Pxx1Pulses<PxxTransport>::setupFrame(uint8_t module)
|
||||
PxxTransport::initFrame(PXX_PULSES_PERIOD);
|
||||
|
||||
#if defined(PXX_FREQUENCY_HIGH)
|
||||
if (moduleSettings[module].protocol == PROTOCOL_CHANNELS_PXX1_SERIAL) {
|
||||
if (moduleState[module].protocol == PROTOCOL_CHANNELS_PXX1_SERIAL) {
|
||||
add8ChannelsFrame(module, 0);
|
||||
if (sentModuleChannels(module) > 8) {
|
||||
add8ChannelsFrame(module, 8);
|
||||
@@ -229,7 +229,7 @@ void Pxx1Pulses<PxxTransport>::setupFrame(uint8_t module)
|
||||
#endif
|
||||
|
||||
uint8_t sendUpperChannels = 0;
|
||||
if (moduleSettings[module].counter & 0x01) {
|
||||
if (moduleState[module].counter & 0x01) {
|
||||
sendUpperChannels = g_model.moduleData[module].channelsCount;
|
||||
}
|
||||
|
||||
|
||||
+32
-28
@@ -25,11 +25,11 @@ uint8_t Pxx2Pulses::addFlag0(uint8_t module)
|
||||
{
|
||||
uint8_t flag0 = g_model.header.modelId[module] & 0x3F;
|
||||
if (g_model.moduleData[module].failsafeMode != FAILSAFE_NOT_SET && g_model.moduleData[module].failsafeMode != FAILSAFE_RECEIVER) {
|
||||
if (moduleSettings[module].counter == 0) {
|
||||
if (moduleState[module].counter == 0) {
|
||||
flag0 |= PXX2_CHANNELS_FLAG0_FAILSAFE;
|
||||
}
|
||||
}
|
||||
if (moduleSettings[module].mode == MODULE_MODE_RANGECHECK) {
|
||||
if (moduleState[module].mode == MODULE_MODE_RANGECHECK) {
|
||||
flag0 |= PXX2_CHANNELS_FLAG0_RANGECHECK;
|
||||
}
|
||||
Pxx2Transport::addByte(flag0);
|
||||
@@ -130,20 +130,22 @@ void Pxx2Pulses::setupTelemetryFrame(uint8_t module)
|
||||
|
||||
void Pxx2Pulses::setupHardwareInfoFrame(uint8_t module)
|
||||
{
|
||||
if (reusableBuffer.hardwareAndSettings.modules[module].timeout == 0) {
|
||||
if (reusableBuffer.hardwareAndSettings.modules[module].current <= reusableBuffer.hardwareAndSettings.modules[module].maximum) {
|
||||
ModuleInformation * destination = moduleState[module].moduleInformation;
|
||||
|
||||
if (destination->timeout == 0) {
|
||||
if (destination->current <= destination->maximum) {
|
||||
addFrameType(PXX2_TYPE_C_MODULE, PXX2_TYPE_ID_HW_INFO);
|
||||
Pxx2Transport::addByte(reusableBuffer.hardwareAndSettings.modules[module].current);
|
||||
reusableBuffer.hardwareAndSettings.modules[module].timeout = 60; /* 300ms */
|
||||
reusableBuffer.hardwareAndSettings.modules[module].current++;
|
||||
Pxx2Transport::addByte(destination->current);
|
||||
destination->timeout = 60; /* 300ms */
|
||||
destination->current++;
|
||||
}
|
||||
else {
|
||||
moduleSettings[module].mode = MODULE_MODE_NORMAL;
|
||||
moduleState[module].mode = MODULE_MODE_NORMAL;
|
||||
setupChannelsFrame(module);
|
||||
}
|
||||
}
|
||||
else {
|
||||
reusableBuffer.hardwareAndSettings.modules[module].timeout--;
|
||||
destination->timeout--;
|
||||
setupChannelsFrame(module);
|
||||
}
|
||||
}
|
||||
@@ -169,20 +171,22 @@ void Pxx2Pulses::setupRegisterFrame(uint8_t module)
|
||||
|
||||
void Pxx2Pulses::setupModuleSettingsFrame(uint8_t module)
|
||||
{
|
||||
if (get_tmr10ms() > reusableBuffer.hardwareAndSettings.moduleSettings.timeout) {
|
||||
ModuleSettings * destination = moduleState[module].moduleSettings;
|
||||
|
||||
if (get_tmr10ms() > destination->retryTime) {
|
||||
addFrameType(PXX2_TYPE_C_MODULE, PXX2_TYPE_ID_TX_SETTINGS);
|
||||
uint8_t flag0 = 0;
|
||||
if (reusableBuffer.hardwareAndSettings.moduleSettings.state == PXX2_SETTINGS_WRITE)
|
||||
if (destination->state == PXX2_SETTINGS_WRITE)
|
||||
flag0 |= PXX2_TX_SETTINGS_FLAG0_WRITE;
|
||||
Pxx2Transport::addByte(flag0);
|
||||
if (reusableBuffer.hardwareAndSettings.moduleSettings.state == PXX2_SETTINGS_WRITE) {
|
||||
uint8_t flag1 = reusableBuffer.hardwareAndSettings.moduleSettings.rfProtocol << 4;
|
||||
if (reusableBuffer.hardwareAndSettings.moduleSettings.externalAntenna)
|
||||
if (destination->state == PXX2_SETTINGS_WRITE) {
|
||||
uint8_t flag1 = destination->rfProtocol << 4;
|
||||
if (destination->externalAntenna)
|
||||
flag1 |= PXX2_TX_SETTINGS_FLAG1_EXTERNAL_ANTENNA;
|
||||
Pxx2Transport::addByte(flag1);
|
||||
Pxx2Transport::addByte(reusableBuffer.hardwareAndSettings.moduleSettings.txPower);
|
||||
Pxx2Transport::addByte(destination->txPower);
|
||||
}
|
||||
reusableBuffer.hardwareAndSettings.moduleSettings.timeout = get_tmr10ms() + 200/*next try in 2s*/;
|
||||
destination->retryTime = get_tmr10ms() + 200/*next try in 2s*/;
|
||||
}
|
||||
else {
|
||||
setupChannelsFrame(module);
|
||||
@@ -220,7 +224,7 @@ void Pxx2Pulses::setupBindFrame(uint8_t module)
|
||||
{
|
||||
if (reusableBuffer.moduleSetup.pxx2.bindStep == BIND_WAIT) {
|
||||
if (get_tmr10ms() > reusableBuffer.moduleSetup.pxx2.bindWaitTimeout) {
|
||||
moduleSettings[module].mode = MODULE_MODE_NORMAL;
|
||||
moduleState[module].mode = MODULE_MODE_NORMAL;
|
||||
reusableBuffer.moduleSetup.pxx2.bindStep = BIND_OK;
|
||||
POPUP_INFORMATION(STR_BIND_OK);
|
||||
}
|
||||
@@ -229,7 +233,7 @@ void Pxx2Pulses::setupBindFrame(uint8_t module)
|
||||
|
||||
addFrameType(PXX2_TYPE_C_MODULE, PXX2_TYPE_ID_BIND);
|
||||
|
||||
if (reusableBuffer.moduleSetup.pxx2.bindStep == BIND_RX_NAME_SELECTED) {
|
||||
if (reusableBuffer.moduleSetup.pxx2.bindStep == BIND_OPTIONS_SELECTED) {
|
||||
Pxx2Transport::addByte(0x01);
|
||||
for (uint8_t i=0; i<PXX2_LEN_RX_NAME; i++) {
|
||||
Pxx2Transport::addByte(reusableBuffer.moduleSetup.pxx2.bindCandidateReceiversNames[reusableBuffer.moduleSetup.pxx2.bindSelectedReceiverIndex][i]);
|
||||
@@ -250,17 +254,17 @@ void Pxx2Pulses::setupResetFrame(uint8_t module)
|
||||
addFrameType(PXX2_TYPE_C_MODULE, PXX2_TYPE_ID_RESET);
|
||||
Pxx2Transport::addByte(reusableBuffer.moduleSetup.pxx2.resetReceiverIndex);
|
||||
Pxx2Transport::addByte(reusableBuffer.moduleSetup.pxx2.resetReceiverFlags);
|
||||
moduleSettings[module].mode = MODULE_MODE_NORMAL;
|
||||
moduleState[module].mode = MODULE_MODE_NORMAL;
|
||||
}
|
||||
|
||||
void Pxx2Pulses::setupSpectrumAnalyser(uint8_t module)
|
||||
{
|
||||
if (moduleSettings[module].counter > 1000) {
|
||||
moduleSettings[module].counter = 1002;
|
||||
if (moduleState[module].counter > 1000) {
|
||||
moduleState[module].counter = 1002;
|
||||
return;
|
||||
}
|
||||
|
||||
moduleSettings[module].counter = 1002;
|
||||
moduleState[module].counter = 1002;
|
||||
|
||||
addFrameType(PXX2_TYPE_C_POWER_METER, PXX2_TYPE_ID_SPECTRUM);
|
||||
Pxx2Transport::addByte(0x00);
|
||||
@@ -271,12 +275,12 @@ void Pxx2Pulses::setupSpectrumAnalyser(uint8_t module)
|
||||
|
||||
void Pxx2Pulses::setupPowerMeter(uint8_t module)
|
||||
{
|
||||
if (moduleSettings[module].counter > 1000) {
|
||||
moduleSettings[module].counter = 1002;
|
||||
if (moduleState[module].counter > 1000) {
|
||||
moduleState[module].counter = 1002;
|
||||
return;
|
||||
}
|
||||
|
||||
moduleSettings[module].counter = 1002;
|
||||
moduleState[module].counter = 1002;
|
||||
|
||||
addFrameType(PXX2_TYPE_C_POWER_METER, PXX2_TYPE_ID_POWER_METER);
|
||||
Pxx2Transport::addByte(0x00);
|
||||
@@ -294,7 +298,7 @@ void Pxx2Pulses::setupFrame(uint8_t module)
|
||||
{
|
||||
initFrame();
|
||||
|
||||
switch (moduleSettings[module].mode) {
|
||||
switch (moduleState[module].mode) {
|
||||
case MODULE_MODE_GET_HARDWARE_INFO:
|
||||
setupHardwareInfoFrame(module);
|
||||
break;
|
||||
@@ -333,8 +337,8 @@ void Pxx2Pulses::setupFrame(uint8_t module)
|
||||
break;
|
||||
}
|
||||
|
||||
if (moduleSettings[module].counter-- == 0) {
|
||||
moduleSettings[module].counter = 1000;
|
||||
if (moduleState[module].counter-- == 0) {
|
||||
moduleState[module].counter = 1000;
|
||||
}
|
||||
|
||||
endFrame();
|
||||
|
||||
+1
-15
@@ -124,6 +124,7 @@ enum PXX2RegisterSteps {
|
||||
enum PXX2BindSteps {
|
||||
BIND_START,
|
||||
BIND_RX_NAME_SELECTED,
|
||||
BIND_OPTIONS_SELECTED,
|
||||
BIND_WAIT,
|
||||
BIND_OK
|
||||
};
|
||||
@@ -270,19 +271,4 @@ class Pxx2Pulses: public PxxPulses<Pxx2Transport> {
|
||||
}
|
||||
};
|
||||
|
||||
PACK(struct PXX2Version
|
||||
{
|
||||
uint8_t major;
|
||||
uint8_t revision:4;
|
||||
uint8_t minor:4;
|
||||
});
|
||||
|
||||
PACK(struct PXX2HardwareInformation
|
||||
{
|
||||
uint8_t modelID;
|
||||
PXX2Version hwVersion;
|
||||
PXX2Version swVersion;
|
||||
uint8_t variant;
|
||||
});
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user