mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-25 01:05:27 +03:00
Style fixes
This commit is contained in:
parent
0b9105294b
commit
bfabf48ca7
1 changed files with 9 additions and 10 deletions
|
@ -507,22 +507,21 @@ void processSmartPortTelemetry(smartPortPayload_t *payload, volatile bool *clear
|
||||||
#if defined(USE_MSP_OVER_TELEMETRY)
|
#if defined(USE_MSP_OVER_TELEMETRY)
|
||||||
if (skipRequests) {
|
if (skipRequests) {
|
||||||
skipRequests--;
|
skipRequests--;
|
||||||
}
|
} else if (payload && smartPortPayloadContainsMSP(payload)) {
|
||||||
else if (payload && smartPortPayloadContainsMSP(payload)) {
|
|
||||||
// Do not check the physical ID here again
|
// Do not check the physical ID here again
|
||||||
// unless we start receiving other sensors' packets
|
// unless we start receiving other sensors' packets
|
||||||
// Pass only the payload: skip frameId
|
// Pass only the payload: skip frameId
|
||||||
uint8_t *frameStart = (uint8_t *)&payload->valueId;
|
uint8_t *frameStart = (uint8_t *)&payload->valueId;
|
||||||
smartPortMspReplyPending = handleMspFrame(frameStart, SMARTPORT_MSP_PAYLOAD_SIZE);
|
smartPortMspReplyPending = handleMspFrame(frameStart, SMARTPORT_MSP_PAYLOAD_SIZE);
|
||||||
|
|
||||||
//Don't send MSP response if MSP command is MSP_EEPROM_WRITE
|
// Don't send MSP response if MSP command is MSP_EEPROM_WRITE
|
||||||
//CPU just got out of suspended state after writeEEPROM()
|
// CPU just got out of suspended state after writeEEPROM()
|
||||||
//We don't know if the receiver is listening again
|
// We don't know if the receiver is listening again
|
||||||
//Skip a few telemetry requests before sending response
|
// Skip a few telemetry requests before sending response
|
||||||
if (cmdIsEepromWrite(payload) && smartPortMspReplyPending) {
|
if (cmdIsEepromWrite(payload) && smartPortMspReplyPending) {
|
||||||
skipRequests = SMARTPORT_REQUEST_SKIPS_AFTER_EEPROMWRITE;
|
skipRequests = SMARTPORT_REQUEST_SKIPS_AFTER_EEPROMWRITE;
|
||||||
*clearToSend = false;
|
*clearToSend = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
UNUSED(payload);
|
UNUSED(payload);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue