Skip to content

Commit

Permalink
Update msp.c
Browse files Browse the repository at this point in the history
  • Loading branch information
yrik committed Apr 13, 2024
1 parent 334438b commit d69b8c4
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/main/rx/msp.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@ static uint16_t mspFrame[MAX_SUPPORTED_RC_CHANNEL_COUNT];
static bool rxMspFrameDone = false;
static bool rxMspOverrideFrameDone = false;

// Initialize ROLL, PITCH, and YAW channels to 1500
mspFrame[0] = 1500; // ROLL
mspFrame[1] = 1500; // PITCH
mspFrame[2] = 1500; // YAW

float rxMspReadRawRC(const rxRuntimeState_t *rxRuntimeState, uint8_t chan)
{
UNUSED(rxRuntimeState);
Expand Down Expand Up @@ -92,10 +97,5 @@ void rxMspInit(const rxConfig_t *rxConfig, rxRuntimeState_t *rxRuntimeState)
rxRuntimeState->channelCount = MAX_SUPPORTED_RC_CHANNEL_COUNT;
rxRuntimeState->rcReadRawFn = rxMspReadRawRC;
rxRuntimeState->rcFrameStatusFn = rxMspFrameStatus;

// Initialize ROLL, PITCH, and YAW channels to 1500
mspFrame[0] = 1500; // ROLL
mspFrame[1] = 1500; // PITCH
mspFrame[2] = 1500; // YAW
}
#endif

0 comments on commit d69b8c4

Please sign in to comment.