Index: firmware/App/Controllers/BoostPump.c =================================================================== diff -u -r4f6fd067c5d0477537facbaf7ab5ecb9522c4cc1 -r319d8e8f56e60bec2c38c79e1de0acc4841551a9 --- firmware/App/Controllers/BoostPump.c (.../BoostPump.c) (revision 4f6fd067c5d0477537facbaf7ab5ecb9522c4cc1) +++ firmware/App/Controllers/BoostPump.c (.../BoostPump.c) (revision 319d8e8f56e60bec2c38c79e1de0acc4841551a9) @@ -83,6 +83,7 @@ static OVERRIDE_F32_T targetBoostPumpPressure; ///< Target Boost max allowed pressure (in PSI). static F32 boostPumpDutyCyclePctSet; ///< Currently set Boost pump PWM duty cycle. static F32 boostPumpOpenLoopTargetDutyCycle; ///< Target Boost pump open loop PWM. + // ********** private function prototypes ********** static BOOST_PUMP_STATE_T handleBoostPumpOffState( void ); @@ -121,20 +122,20 @@ isBoostPumpOn = FALSE; stopPumpRequest = FALSE; boostControlTimerCounter = 0; - boostPumpDutyCyclePctSet = 0; - boostPumpOpenLoopTargetDutyCycle = 0; + boostPumpDutyCyclePctSet = 0.0; + boostPumpOpenLoopTargetDutyCycle = 0.0; boostPumpDataPublicationTimerCounter = DATA_PUBLISH_COUNTER_START_COUNT; boostPumpDataPublishInterval.data = BOOST_DATA_PUB_INTERVAL; boostPumpDataPublishInterval.ovData = BOOST_CONTROL_INTERVAL; boostPumpDataPublishInterval.ovInitData = 0; boostPumpDataPublishInterval.override = OVERRIDE_RESET; - targetBoostPumpFlowRate.data = 0; - targetBoostPumpFlowRate.ovData = 0; - targetBoostPumpFlowRate.ovInitData = 0; + targetBoostPumpFlowRate.data = 0.0; + targetBoostPumpFlowRate.ovData = 0.0; + targetBoostPumpFlowRate.ovInitData = 0.0; targetBoostPumpFlowRate.override = OVERRIDE_RESET; - targetBoostPumpPressure.data = 0; - targetBoostPumpPressure.ovData = 0; - targetBoostPumpPressure.ovInitData = 0; + targetBoostPumpPressure.data = 0.0; + targetBoostPumpPressure.ovData = 0.0; + targetBoostPumpPressure.ovInitData = 0.0; targetBoostPumpPressure.override = OVERRIDE_RESET; stopBoostPump(); @@ -150,7 +151,6 @@ *************************************************************************/ void execBoostPumpController( void ) { - // Update Boost pump feedback from FPGA readFluidPumps(); @@ -281,7 +281,6 @@ boostPumpDutyCyclePctSet = runPIController( PI_CONTROLLER_ID_BOOST_PUMP_FLOW, getTargetBoostPumpFlowRateLPM(), getFlowRate( P7_FLOW ) ); setFluidPumpPctToPWMDutyCycle( P12_PUMP, boostPumpDutyCyclePctSet ); boostControlTimerCounter = 0; - } return state; @@ -305,7 +304,6 @@ boostPumpDutyCyclePctSet = runPIController( PI_CONTROLLER_ID_BOOST_PUMP_PRES, getTargetBoostPumpPressure(), getFilteredPressure( M3_PRES ) ); setFluidPumpPctToPWMDutyCycle( P12_PUMP, boostPumpDutyCyclePctSet ); boostControlTimerCounter = 0; - } return state; @@ -338,11 +336,11 @@ // Clear previous target data if ( getTargetBoostPumpPressure() > 0.0F ) { - targetBoostPumpPressure.data = 0; + targetBoostPumpPressure.data = 0.0; } if ( boostPumpOpenLoopTargetDutyCycle > 0.0F ) { - boostPumpOpenLoopTargetDutyCycle = 0; + boostPumpOpenLoopTargetDutyCycle = 0.0; } result = TRUE; } @@ -381,11 +379,11 @@ // Clear previous target data if ( getTargetBoostPumpFlowRateLPM() > 0.0F ) { - targetBoostPumpFlowRate.data = 0; + targetBoostPumpFlowRate.data = 0.0; } if ( boostPumpOpenLoopTargetDutyCycle > 0.0F ) { - boostPumpOpenLoopTargetDutyCycle = 0; + boostPumpOpenLoopTargetDutyCycle = 0.0; } result = TRUE; } @@ -416,19 +414,19 @@ if ( ( dutyCycle >= MIN_FLUID_PUMP_DUTY_CYCLE_PCT ) && ( dutyCycle <= MAX_FLUID_PUMP_DUTY_CYCLE_PCT ) ) { boostPumpOpenLoopTargetDutyCycle = dutyCycle; - boostPumpControlMode = BOOST_PUMP_OPEN_LOOP_STATE; + boostPumpControlMode = PUMP_CONTROL_MODE_OPEN_LOOP; status = TRUE; // Set the new duty cycle of the pump setFluidPumpPctToPWMDutyCycle( P12_PUMP, boostPumpOpenLoopTargetDutyCycle ); // Clear previous target data if ( getTargetBoostPumpFlowRateLPM() > 0.0F ) { - targetBoostPumpFlowRate.data = 0; + targetBoostPumpFlowRate.data = 0.0; } if ( getTargetBoostPumpPressure() > 0.0F ) { - targetBoostPumpPressure.data = 0; + targetBoostPumpPressure.data = 0.0; } } else @@ -642,5 +640,4 @@ return result; } - /**@}*/ Index: firmware/App/Controllers/BoostPump.h =================================================================== diff -u -rcd1aa72cf45af72e12e47f61df2b218e5683cd64 -r319d8e8f56e60bec2c38c79e1de0acc4841551a9 --- firmware/App/Controllers/BoostPump.h (.../BoostPump.h) (revision cd1aa72cf45af72e12e47f61df2b218e5683cd64) +++ firmware/App/Controllers/BoostPump.h (.../BoostPump.h) (revision 319d8e8f56e60bec2c38c79e1de0acc4841551a9) @@ -18,7 +18,6 @@ #ifndef __BOOSTPUMP_H__ #define __BOOSTPUMP_H__ - #include "FluidPump.h" #include "FPCommon.h" @@ -71,8 +70,6 @@ BOOL testBoostPumpTargetPressureOverride( MESSAGE_T *message ); BOOL testBoostPumpTargetFlowOverride( MESSAGE_T *message ); - - /**@}*/ #endif