diff --git a/firmware/auxout.cpp b/firmware/auxout.cpp index 2e23203..b6e29d8 100644 --- a/firmware/auxout.cpp +++ b/firmware/auxout.cpp @@ -82,7 +82,6 @@ void SetAuxDac(int channel, float voltage) { voltage = voltage / AUXOUT_GAIN; auto duty = voltage / VCC_VOLTS; - duty = 1.0 - duty; duty = clampF(0, duty, 1); auxDac.SetDuty(auxOutPwmCh[channel], duty); diff --git a/firmware/boards/f1_dual/io/io_pins.h b/firmware/boards/f1_dual/io/io_pins.h index 8b1183e..24f4a23 100644 --- a/firmware/boards/f1_dual/io/io_pins.h +++ b/firmware/boards/f1_dual/io/io_pins.h @@ -55,7 +55,7 @@ // PB15 - TIM1_CH3N #define AUXOUT_DAC_PWM_CHANNEL_1 2 // CH2N and CH3N are complementary outputs -#define AUXOUT_DAC_PWM_OUTPUT_MODE PWM_COMPLEMENTARY_OUTPUT_ACTIVE_HIGH +#define AUXOUT_DAC_PWM_OUTPUT_MODE PWM_COMPLEMENTARY_OUTPUT_ACTIVE_LOW #define ID_SEL1_PORT GPIOC #define ID_SEL1_PIN 13 diff --git a/firmware/boards/f1_rev2/io/io_pins.h b/firmware/boards/f1_rev2/io/io_pins.h index f3d2e85..aae02b0 100644 --- a/firmware/boards/f1_rev2/io/io_pins.h +++ b/firmware/boards/f1_rev2/io/io_pins.h @@ -47,7 +47,7 @@ // PB15 - TIM1_CH3N #define AUXOUT_DAC_PWM_CHANNEL_1 2 // CH2N and CH3N are complementary outputs -#define AUXOUT_DAC_PWM_OUTPUT_MODE PWM_COMPLEMENTARY_OUTPUT_ACTIVE_HIGH +#define AUXOUT_DAC_PWM_OUTPUT_MODE PWM_COMPLEMENTARY_OUTPUT_ACTIVE_LOW #define ID_SEL1_PORT GPIOC #define ID_SEL1_PIN 13