Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
nikhar-abbas committed Sep 20, 2019
1 parent f59093e commit 44cb23a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Source/ControllerBlocks.f90
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ SUBROUTINE StateMachine(CntrPar, LocalVar)
IF (LocalVar%PitCom(1) >= CntrPar%VS_Rgn3Pitch) THEN ! We are in region 3
IF (CntrPar%VS_ControlMode == 1) THEN ! Constant power tracking
LocalVar%VS_State = 5
LocalVar%PC_State = 2
LocalVar%PC_State = 1
ELSE ! Constant torque tracking
LocalVar%VS_State = 4
LocalVar%PC_State = 1
Expand Down Expand Up @@ -88,7 +88,7 @@ SUBROUTINE WindSpeedEstimator(LocalVar, CntrPar, objInst)
! Wind Speed Estimator estimates wind speed at hub height. Currently implements two types of estimators
! WE_Mode = 0, Filter hub height wind speed as passed from servodyn using first order low pass filter with 1Hz cornering frequency
! WE_Mode = 1, Use Inversion and Inveriance filter as defined by Ortege et. al.
USE DRC_Types!, ONLY : LocalVariables, ControlParameters, Obj
USE DRC_Types, ONLY : LocalVariables, ControlParameters, ObjectInstances
IMPLICIT NONE

! Inputs
Expand Down Expand Up @@ -117,7 +117,7 @@ SUBROUTINE SetpointSmoother(LocalVar, CntrPar, objInst)
! Setpoint smoother modifies controller reference in order to separate generator torque and blade pitch control actions
! SS_Mode = 0, No setpoint smoothing
! SS_Mode = 1, Implement setpoint smoothing
USE DRC_Types!, ONLY : LocalVariables, ControlParameters, ObjectInstances
USE DRC_Types, ONLY : LocalVariables, ControlParameters, ObjectInstances
IMPLICIT NONE

! Inputs
Expand All @@ -127,7 +127,7 @@ SUBROUTINE SetpointSmoother(LocalVar, CntrPar, objInst)
! Allocate Variables
Real(4) :: DelOmega ! Reference generator speed shift, rad/s.

! Setpoint Smoothing
! ------ Setpoint Smoothing ------
IF ( CntrPar%SS_Mode == 1) THEN
! Find setpoint shift amount
DelOmega = (LocalVar%BlPitch(1) - CntrPar%PC_MinPit)*CntrPar%SS_VSGainBias - (CntrPar%VS_RtTq - LocalVar%VS_LastGenTrq)*CntrPar%SS_PCGainBias
Expand Down

0 comments on commit 44cb23a

Please sign in to comment.