mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-15 20:35:33 +03:00
fix ifdefs
This commit is contained in:
parent
13c009da64
commit
01e8d99937
1 changed files with 4 additions and 7 deletions
|
@ -44,8 +44,6 @@
|
|||
|
||||
#include "pwm_output.h"
|
||||
|
||||
#ifdef USE_DSHOT
|
||||
|
||||
#include "pwm_output_dshot_shared.h"
|
||||
|
||||
FAST_RAM_ZERO_INIT uint8_t dmaMotorTimerCount = 0;
|
||||
|
@ -184,16 +182,14 @@ static uint16_t decodeProshotPacket(uint32_t buffer[])
|
|||
return value >> 4;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef USE_DSHOT_TELEMETRY
|
||||
|
||||
uint16_t getDshotTelemetry(uint8_t index)
|
||||
{
|
||||
return dmaMotors[index].dshotTelemetryValue;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
FAST_CODE void pwmDshotSetDirectionOutput(
|
||||
motorDmaOutput_t * const motor, bool output
|
||||
#ifndef USE_DSHOT_TELEMETRY
|
||||
|
@ -205,6 +201,8 @@ FAST_CODE void pwmDshotSetDirectionOutput(
|
|||
#endif
|
||||
);
|
||||
|
||||
#ifdef USE_DSHOT_TELEMETRY
|
||||
|
||||
void pwmStartDshotMotorUpdate(uint8_t motorCount)
|
||||
{
|
||||
if (useDshotTelemetry) {
|
||||
|
@ -250,4 +248,3 @@ void pwmStartDshotMotorUpdate(uint8_t motorCount)
|
|||
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue