Model { Name "pll" Version 5.0 SaveDefaultBlockParams on SampleTimeColors off LibraryLinkDisplay "none" WideLines off ShowLineDimensions off ShowPortDataTypes off ShowLoopsOnError on IgnoreBidirectionalLines off ShowStorageClass off ExecutionOrder off RecordCoverage off CovPath "/" CovSaveName "covdata" CovMetricSettings "dw" CovNameIncrementing off CovHtmlReporting on covSaveCumulativeToWorkspaceVar on CovSaveSingleToWorkspaceVar on CovCumulativeVarName "covCumulativeData" CovCumulativeReport off DataTypeOverride "UseLocalSettings" MinMaxOverflowLogging "UseLocalSettings" MinMaxOverflowArchiveMode "Overwrite" BlockNameDataTip off BlockParametersDataTip off BlockDescriptionStringDataTip off ToolBar on StatusBar on BrowserShowLibraryLinks off BrowserLookUnderMasks off Created "Wed Dec 25 02:52:01 2002" UpdateHistory "UpdateHistoryNever" ModifiedByFormat "%" LastModifiedBy "gokcek" ModifiedDateFormat "%" LastModifiedDate "Wed Aug 04 17:25:19 2004" ModelVersionFormat "1.%" ConfigurationManager "none" SimParamPage "Solver" LinearizationMsg "none" Profile off ParamWorkspaceSource "MATLABWorkspace" AccelSystemTargetFile "accel.tlc" AccelTemplateMakefile "accel_default_tmf" AccelMakeCommand "make_rtw" TryForcingSFcnDF off ExtModeMexFile "ext_comm" ExtModeBatchMode off ExtModeTrigType "manual" ExtModeTrigMode "normal" ExtModeTrigPort "1" ExtModeTrigElement "any" ExtModeTrigDuration 1000 ExtModeTrigHoldOff 0 ExtModeTrigDelay 0 ExtModeTrigDirection "rising" ExtModeTrigLevel 0 ExtModeArchiveMode "off" ExtModeAutoIncOneShot off ExtModeIncDirWhenArm off ExtModeAddSuffixToVar off ExtModeWriteAllDataToWs off ExtModeArmWhenConnect on ExtModeSkipDownloadWhenConnect off ExtModeLogAll on ExtModeAutoUpdateStatusClock on BufferReuse on RTWExpressionDepthLimit 5 SimulationMode "normal" Solver "ode5" SolverMode "Auto" StartTime "0.0" StopTime "S" MaxOrder 5 MaxStep "auto" MinStep "auto" MaxNumMinSteps "-1" InitialStep "auto" FixedStep "T" RelTol "1e-3" AbsTol "auto" OutputOption "RefineOutputTimes" OutputTimes "[]" Refine "1" LoadExternalInput off ExternalInput "[t, u]" LoadInitialState off InitialState "xInitial" SaveTime on TimeSaveName "tout" SaveState off StateSaveName "xout" SaveOutput on OutputSaveName "yout" SaveFinalState off FinalStateName "xFinal" SaveFormat "Array" Decimation "1" LimitDataPoints on MaxDataPoints "1000" SignalLoggingName "sigsOut" ConsistencyChecking "none" ArrayBoundsChecking "none" AlgebraicLoopMsg "warning" BlockPriorityViolationMsg "warning" MinStepSizeMsg "warning" InheritedTsInSrcMsg "warning" DiscreteInheritContinuousMsg "warning" MultiTaskRateTransMsg "error" SingleTaskRateTransMsg "none" CheckForMatrixSingularity "none" IntegerOverflowMsg "warning" Int32ToFloatConvMsg "warning" ParameterDowncastMsg "error" ParameterOverflowMsg "error" ParameterPrecisionLossMsg "warning" UnderSpecifiedDataTypeMsg "none" UnnecessaryDatatypeConvMsg "none" VectorMatrixConversionMsg "none" InvalidFcnCallConnMsg "error" SignalLabelMismatchMsg "none" UnconnectedInputMsg "warning" UnconnectedOutputMsg "warning" UnconnectedLineMsg "warning" SfunCompatibilityCheckMsg "none" RTWInlineParameters off BlockReductionOpt on BooleanDataType off ConditionallyExecuteInputs on ParameterPooling on OptimizeBlockIOStorage on ZeroCross on AssertionControl "UseLocalSettings" ProdHWDeviceType "Microprocessor" ProdHWWordLengths "8,16,32,32" RTWSystemTargetFile "grt.tlc" RTWTemplateMakefile "grt_default_tmf" RTWMakeCommand "make_rtw" RTWGenerateCodeOnly off RTWRetainRTWFile off TLCProfiler off TLCDebug off TLCCoverage off TLCAssertion off BlockDefaults { Orientation "right" ForegroundColor "black" BackgroundColor "white" DropShadow off NamePlacement "normal" FontName "Helvetica" FontSize 10 FontWeight "normal" FontAngle "normal" ShowName on } BlockParameterDefaults { Block { BlockType Clock DisplayTime off } Block { BlockType CombinatorialLogic TruthTable "[0 0;0 1;0 1;1 0;0 1;1 0;1 0;1 1]" } Block { BlockType Constant Value "1" VectorParams1D on ShowAdditionalParam off OutDataTypeMode "Inherit from 'Constant value'" OutDataType "sfix(16)" ConRadixGroup "Use specified scaling" OutScaling "2^0" } Block { BlockType Demux Outputs "4" DisplayOption "none" BusSelectionMode off } Block { BlockType Derivative } Block { BlockType EnablePort StatesWhenEnabling "held" ShowOutputPort off ZeroCross on } Block { BlockType FromWorkspace VariableName "simulink_input" SampleTime "-1" Interpolate on OutputAfterFinalValue "Extrapolation" } Block { BlockType Fcn Expr "sin(u[1])" } Block { BlockType Gain Gain "1" Multiplication "Element-wise(K.*u)" ShowAdditionalParam off ParameterDataTypeMode "Same as input" ParameterDataType "sfix(16)" ParameterScalingMode "Best Precision: Matrix-wise" ParameterScaling "2^0" OutDataTypeMode "Same as input" OutDataType "sfix(16)" OutScaling "2^0" LockScale off RndMeth "Floor" SaturateOnIntegerOverflow on } Block { BlockType Inport Port "1" PortDimensions "-1" SampleTime "-1" ShowAdditionalParam off LatchInput off DataType "auto" OutDataType "sfix(16)" OutScaling "2^0" SignalType "auto" SamplingMode "auto" Interpolate on } Block { BlockType Integrator ExternalReset "none" InitialConditionSource "internal" InitialCondition "0" LimitOutput off UpperSaturationLimit "inf" LowerSaturationLimit "-inf" ShowSaturationPort off ShowStatePort off AbsoluteTolerance "auto" ZeroCross on } Block { BlockType Logic Operator "AND" Inputs "2" ShowAdditionalParam off AllPortsSameDT on OutDataTypeMode "Logical (see Advanced Sim. Parameters)" LogicDataType "uint(8)" } Block { BlockType Memory X0 "0" InheritSampleTime off LinearizeMemory off RTWStateStorageClass "Auto" } Block { BlockType Mux Inputs "4" DisplayOption "none" } Block { BlockType Outport Port "1" OutputWhenDisabled "held" InitialOutput "[]" } Block { BlockType Product Inputs "2" Multiplication "Element-wise(.*)" ShowAdditionalParam off InputSameDT on OutDataTypeMode "Same as first input" OutDataType "sfix(16)" OutScaling "2^0" LockScale off RndMeth "Floor" SaturateOnIntegerOverflow on } Block { BlockType SubSystem ShowPortLabels on Permissions "ReadWrite" RTWSystemCode "Auto" RTWFcnNameOpts "Auto" RTWFileNameOpts "Auto" SimViewingDevice off DataTypeOverride "UseLocalSettings" MinMaxOverflowLogging "UseLocalSettings" } Block { BlockType Sum IconShape "rectangular" Inputs "++" ShowAdditionalParam off InputSameDT on OutDataTypeMode "Same as first input" OutDataType "sfix(16)" OutScaling "2^0" LockScale off RndMeth "Floor" SaturateOnIntegerOverflow on } Block { BlockType Switch Criteria "u2 >= Threshold" Threshold "0" ShowAdditionalParam off InputSameDT on OutDataTypeMode "Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow on ZeroCross on } Block { BlockType ToWorkspace VariableName "simulink_output" MaxDataPoints "1000" Decimation "1" SampleTime "0" } Block { BlockType TransferFcn Numerator "[1]" Denominator "[1 2 1]" AbsoluteTolerance "auto" Realization "auto" } Block { BlockType TriggerPort TriggerType "rising" ShowOutputPort off OutputDataType "auto" ZeroCross on } Block { BlockType Trigonometry Operator "sin" OutputSignalType "auto" } } AnnotationDefaults { HorizontalAlignment "center" VerticalAlignment "middle" ForegroundColor "black" BackgroundColor "white" DropShadow off FontName "Helvetica" FontSize 10 FontWeight "normal" FontAngle "normal" } LineDefaults { FontName "Helvetica" FontSize 9 FontWeight "normal" FontAngle "normal" } System { Name "pll" Location [26, 94, 677, 683] Open on ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" ZoomFactor "100" ReportName "simulink-default.rpt" Block { BlockType Clock Name "Clock" Position [490, 230, 510, 250] ShowName off Decimation "10" } Block { BlockType Constant Name "Constant" Position [115, 235, 145, 265] Orientation "up" NamePlacement "alternate" ShowName off Value "w0" } Block { BlockType Constant Name "Constant1" Position [115, 520, 145, 550] Orientation "up" NamePlacement "alternate" ShowName off Value "w0" } Block { BlockType Constant Name "Constant2" Position [55, 405, 85, 435] NamePlacement "alternate" ShowName off Value "0" } Block { BlockType Fcn Name "Fcn" Position [250, 120, 310, 150] ShowName off Expr "Vc*(u>=0)-Vc*(u<0)" } Block { BlockType Fcn Name "Fcn1" Position [250, 405, 310, 435] ShowName off Expr "Vc*(u>=0)-Vc*(u<0)" } Block { BlockType FromWorkspace Name "From\nWorkspace" Position [15, 123, 80, 147] ShowName off FontSize 10 VariableName "p" SampleTime "0" } Block { BlockType Gain Name "Gain" Position [270, 35, 300, 65] ShowName off Gain "Vc" } Block { BlockType Gain Name "Gain1" Position [270, 215, 300, 245] ShowName off Gain "Vc" } Block { BlockType Integrator Name "Integrator1" Ports [1, 1] Position [115, 175, 145, 205] Orientation "up" ShowName off } Block { BlockType Integrator Name "Integrator3" Ports [1, 1] Position [115, 460, 145, 490] Orientation "up" ShowName off } Block { BlockType SubSystem Name "Subsystem1" Ports [2, 2] Position [400, 120, 440, 180] ShowName off AttributesFormatString "PLL(NXOR)" TreatAsAtomicUnit off System { Name "Subsystem1" Location [72, 389, 877, 548] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" ZoomFactor "100" Block { BlockType Inport Name "In1" Position [25, 43, 55, 57] ShowName off } Block { BlockType Inport Name "In2" Position [25, 78, 55, 92] ShowName off Port "2" } Block { BlockType Constant Name "Constant" Position [480, 110, 510, 140] Orientation "up" NamePlacement "alternate" ShowName off Value "w0" } Block { BlockType Fcn Name "Fcn" Position [665, 55, 725, 85] ShowName off Expr "Vc*(u>=0)-Vc*(u<0)" } Block { BlockType Fcn Name "Fcn1" Position [240, 55, 300, 85] ShowName off Expr "-Vc*(u>=0.5)+Vc*(u<0.5)" } Block { BlockType Fcn Name "Fcn2" Position [80, 35, 140, 65] ShowName off Expr "1*(u>=0)+0*(u<0)" } Block { BlockType Fcn Name "Fcn3" Position [80, 70, 140, 100] ShowName off Expr "1*(u>=0)+0*(u<0)" } Block { BlockType Gain Name "Gain" Position [420, 55, 450, 85] ShowName off Gain "kw" } Block { BlockType Integrator Name "Integrator" Ports [1, 1] Position [540, 55, 570, 85] ShowName off } Block { BlockType Logic Name "Logical\nOperator" Ports [2, 1] Position [180, 52, 210, 83] ShowName off Operator "XOR" } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [485, 60, 505, 80] ShowName off IconShape "round" Inputs "|++" } Block { BlockType ToWorkspace Name "To Workspace1" Position [430, 15, 490, 45] ShowName off VariableName "v1" MaxDataPoints "inf" SampleTime "-1" SaveFormat "Array" } Block { BlockType TransferFcn Name "Transfer Fcn" Position [330, 52, 390, 88] ShowName off Numerator "nF" Denominator "dF" } Block { BlockType Trigonometry Name "Trigonometric\nFunction" Ports [1, 1] Position [605, 55, 635, 85] ShowName off Operator "cos" } Block { BlockType Outport Name "Out2" Position [750, 18, 780, 32] ShowName off } Block { BlockType Outport Name "Out1" Position [750, 63, 780, 77] ShowName off Port "2" } Line { SrcBlock "Gain" SrcPort 1 DstBlock "Sum" DstPort 1 } Line { SrcBlock "Sum" SrcPort 1 Points [0, 0; 5, 0] Branch { DstBlock "Integrator" DstPort 1 } Branch { Points [0, -45] DstBlock "Out2" DstPort 1 } } Line { SrcBlock "Constant" SrcPort 1 DstBlock "Sum" DstPort 2 } Line { SrcBlock "Integrator" SrcPort 1 DstBlock "Trigonometric\nFunction" DstPort 1 } Line { SrcBlock "Trigonometric\nFunction" SrcPort 1 DstBlock "Fcn" DstPort 1 } Line { SrcBlock "Transfer Fcn" SrcPort 1 Points [5, 0] Branch { DstBlock "Gain" DstPort 1 } Branch { Points [0, -40] DstBlock "To Workspace1" DstPort 1 } } Line { SrcBlock "Fcn3" SrcPort 1 Points [10, 0; 0, -10] DstBlock "Logical\nOperator" DstPort 2 } Line { SrcBlock "Fcn2" SrcPort 1 Points [10, 0; 0, 10] DstBlock "Logical\nOperator" DstPort 1 } Line { SrcBlock "In1" SrcPort 1 DstBlock "Fcn2" DstPort 1 } Line { SrcBlock "Fcn" SrcPort 1 DstBlock "Out1" DstPort 1 } Line { SrcBlock "In2" SrcPort 1 DstBlock "Fcn3" DstPort 1 } Line { SrcBlock "Logical\nOperator" SrcPort 1 DstBlock "Fcn1" DstPort 1 } Line { SrcBlock "Fcn1" SrcPort 1 DstBlock "Transfer Fcn" DstPort 1 } } } Block { BlockType SubSystem Name "Subsystem2" Ports [2, 2] Position [400, 205, 440, 265] ShowName off AttributesFormatString "PLL(EXOR)" TreatAsAtomicUnit off System { Name "Subsystem2" Location [170, 369, 975, 528] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" ZoomFactor "100" Block { BlockType Inport Name "In1" Position [25, 43, 55, 57] ShowName off } Block { BlockType Inport Name "In2" Position [25, 78, 55, 92] ShowName off Port "2" } Block { BlockType Constant Name "Constant" Position [480, 110, 510, 140] Orientation "up" NamePlacement "alternate" ShowName off Value "w0" } Block { BlockType Fcn Name "Fcn" Position [665, 55, 725, 85] ShowName off Expr "Vc*(u>=0)-Vc*(u<0)" } Block { BlockType Fcn Name "Fcn1" Position [240, 55, 300, 85] ShowName off Expr "Vc*(u>=0.5)-Vc*(u<0.5)" } Block { BlockType Fcn Name "Fcn2" Position [80, 35, 140, 65] ShowName off Expr "1*(u>=0)+0*(u<0)" } Block { BlockType Fcn Name "Fcn3" Position [80, 70, 140, 100] ShowName off Expr "1*(u>=0)+0*(u<0)" } Block { BlockType Gain Name "Gain" Position [420, 55, 450, 85] ShowName off Gain "kw" } Block { BlockType Integrator Name "Integrator" Ports [1, 1] Position [540, 55, 570, 85] ShowName off } Block { BlockType Logic Name "Logical\nOperator" Ports [2, 1] Position [180, 52, 210, 83] ShowName off Operator "XOR" } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [485, 60, 505, 80] ShowName off IconShape "round" Inputs "|++" } Block { BlockType ToWorkspace Name "To Workspace1" Position [420, 15, 480, 45] ShowName off VariableName "v2" MaxDataPoints "inf" SampleTime "-1" SaveFormat "Array" } Block { BlockType TransferFcn Name "Transfer Fcn" Position [330, 52, 390, 88] ShowName off Numerator "nF" Denominator "dF" } Block { BlockType Trigonometry Name "Trigonometric\nFunction" Ports [1, 1] Position [605, 55, 635, 85] ShowName off Operator "cos" } Block { BlockType Outport Name "Out2" Position [750, 18, 780, 32] ShowName off } Block { BlockType Outport Name "Out1" Position [750, 63, 780, 77] ShowName off Port "2" } Line { SrcBlock "Fcn1" SrcPort 1 DstBlock "Transfer Fcn" DstPort 1 } Line { SrcBlock "Logical\nOperator" SrcPort 1 DstBlock "Fcn1" DstPort 1 } Line { SrcBlock "In2" SrcPort 1 DstBlock "Fcn3" DstPort 1 } Line { SrcBlock "Fcn" SrcPort 1 DstBlock "Out1" DstPort 1 } Line { SrcBlock "In1" SrcPort 1 DstBlock "Fcn2" DstPort 1 } Line { SrcBlock "Fcn2" SrcPort 1 Points [10, 0; 0, 10] DstBlock "Logical\nOperator" DstPort 1 } Line { SrcBlock "Fcn3" SrcPort 1 Points [10, 0; 0, -10] DstBlock "Logical\nOperator" DstPort 2 } Line { SrcBlock "Transfer Fcn" SrcPort 1 Points [5, 0] Branch { DstBlock "Gain" DstPort 1 } Branch { Points [0, -40] DstBlock "To Workspace1" DstPort 1 } } Line { SrcBlock "Trigonometric\nFunction" SrcPort 1 DstBlock "Fcn" DstPort 1 } Line { SrcBlock "Integrator" SrcPort 1 DstBlock "Trigonometric\nFunction" DstPort 1 } Line { SrcBlock "Constant" SrcPort 1 DstBlock "Sum" DstPort 2 } Line { SrcBlock "Sum" SrcPort 1 Points [0, 0; 5, 0] Branch { Points [0, -45] DstBlock "Out2" DstPort 1 } Branch { DstBlock "Integrator" DstPort 1 } } Line { SrcBlock "Gain" SrcPort 1 DstBlock "Sum" DstPort 1 } } } Block { BlockType SubSystem Name "Subsystem21" Ports [2, 2] Position [400, 375, 440, 435] ShowName off AttributesFormatString "PLL(JKFF)" TreatAsAtomicUnit off System { Name "Subsystem21" Location [-27, 259, 985, 525] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" ZoomFactor "100" Block { BlockType Inport Name "In1" Position [40, 48, 70, 62] ShowName off } Block { BlockType Inport Name "In2" Position [40, 193, 70, 207] ShowName off Port "2" } Block { BlockType Constant Name "Constant" Position [855, 180, 885, 210] Orientation "up" NamePlacement "alternate" ShowName off Value "w0" } Block { BlockType Constant Name "Constant1" Position [140, 95, 170, 125] NamePlacement "alternate" ShowName off } Block { BlockType Reference Name "D Flip-Flop1" Ports [3, 2] Position [250, 162, 295, 238] ShowName off SourceBlock "simulink_extras/Flip Flops/D Flip-Flop" SourceType "DFlipFlop" } Block { BlockType Reference Name "D Flip-Flop2" Ports [3, 2] Position [250, 17, 295, 93] ShowName off SourceBlock "simulink_extras/Flip Flops/D Flip-Flop" SourceType "DFlipFlop" } Block { BlockType Fcn Name "Fcn" Position [1040, 125, 1100, 155] ShowName off Expr "Vc*(u>=0)-Vc*(u<0)" } Block { BlockType Fcn Name "Fcn2" Position [100, 40, 160, 70] ShowName off Expr "1*(u>=0)+0*(u<0)" } Block { BlockType Fcn Name "Fcn3" Position [100, 185, 160, 215] ShowName off Expr "1*(u>=0)+0*(u<0)" } Block { BlockType Gain Name "Gain" Position [795, 125, 825, 155] ShowName off Gain "kw" } Block { BlockType Gain Name "Gain1" Position [455, 70, 485, 100] ShowName off Gain "Vc" } Block { BlockType Gain Name "Gain2" Position [450, 180, 480, 210] ShowName off Gain "-Vc" } Block { BlockType Integrator Name "Integrator" Ports [1, 1] Position [915, 125, 945, 155] ShowName off } Block { BlockType Logic Name "Logical\nOperator1" Ports [2, 1] Position [520, 25, 555, 60] NamePlacement "alternate" ShowName off Operator "XOR" } Block { BlockType Logic Name "Logical\nOperator2" Ports [1, 1] Position [580, 27, 615, 63] NamePlacement "alternate" ShowName off Operator "NOT" } Block { BlockType Logic Name "Logical\nOperator3" Ports [2, 1] Position [265, 110, 300, 145] Orientation "left" NamePlacement "alternate" ShowName off Operator "NAND" } Block { BlockType Logic Name "Logical\nOperator4" Ports [2, 1] Position [385, 65, 420, 100] NamePlacement "alternate" ShowName off } Block { BlockType Logic Name "Logical\nOperator5" Ports [2, 1] Position [385, 175, 420, 210] NamePlacement "alternate" ShowName off } Block { BlockType Memory Name "Memory" Position [215, 115, 245, 145] Orientation "left" ShowName off } Block { BlockType Memory Name "Memory1" Position [660, 95, 690, 125] ShowName off } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [860, 130, 880, 150] ShowName off IconShape "round" Inputs "|++" } Block { BlockType Sum Name "Sum1" Ports [2, 1] Position [510, 140, 530, 160] ShowName off IconShape "round" } Block { BlockType Switch Name "Switch" Position [730, 125, 760, 155] Threshold "0.5" } Block { BlockType ToWorkspace Name "To Workspace4" Position [800, 55, 860, 85] ShowName off VariableName "v4" MaxDataPoints "inf" SampleTime "-1" SaveFormat "Array" } Block { BlockType TransferFcn Name "Transfer Fcn" Position [550, 132, 610, 168] ShowName off Numerator "nF" Denominator "dF" } Block { BlockType Trigonometry Name "Trigonometric\nFunction" Ports [1, 1] Position [980, 125, 1010, 155] ShowName off Operator "cos" } Block { BlockType Outport Name "Out2" Position [1125, 63, 1155, 77] ShowName off } Block { BlockType Outport Name "Out1" Position [1125, 133, 1155, 147] ShowName off Port "2" } Line { SrcBlock "Memory1" SrcPort 1 Points [10, 0; 0, 20] DstBlock "Switch" DstPort 1 } Line { SrcBlock "Switch" SrcPort 1 Points [0, 0; 5, 0] Branch { Points [0, -70] DstBlock "To Workspace4" DstPort 1 } Branch { DstBlock "Gain" DstPort 1 } } Line { SrcBlock "Transfer Fcn" SrcPort 1 Points [0, 0; 15, 0] Branch { Points [0, -40] DstBlock "Memory1" DstPort 1 } Branch { DstBlock "Switch" DstPort 3 } } Line { SrcBlock "Logical\nOperator2" SrcPort 1 Points [20, 0; 0, 95] DstBlock "Switch" DstPort 2 } Line { SrcBlock "Gain2" SrcPort 1 Points [35, 0] DstBlock "Sum1" DstPort 2 } Line { SrcBlock "Logical\nOperator1" SrcPort 1 DstBlock "Logical\nOperator2" DstPort 1 } Line { SrcBlock "D Flip-Flop2" SrcPort 2 Points [40, 0; 0, 110] DstBlock "Logical\nOperator5" DstPort 1 } Line { SrcBlock "D Flip-Flop1" SrcPort 2 Points [55, 0; 0, -130] DstBlock "Logical\nOperator4" DstPort 2 } Line { SrcBlock "In2" SrcPort 1 DstBlock "Fcn3" DstPort 1 } Line { SrcBlock "Fcn" SrcPort 1 DstBlock "Out1" DstPort 1 } Line { SrcBlock "In1" SrcPort 1 DstBlock "Fcn2" DstPort 1 } Line { SrcBlock "Trigonometric\nFunction" SrcPort 1 DstBlock "Fcn" DstPort 1 } Line { SrcBlock "Integrator" SrcPort 1 DstBlock "Trigonometric\nFunction" DstPort 1 } Line { SrcBlock "Constant" SrcPort 1 DstBlock "Sum" DstPort 2 } Line { SrcBlock "Sum" SrcPort 1 Points [0, 0; 5, 0] Branch { Points [0, -70] DstBlock "Out2" DstPort 1 } Branch { DstBlock "Integrator" DstPort 1 } } Line { SrcBlock "Gain" SrcPort 1 DstBlock "Sum" DstPort 1 } Line { SrcBlock "Constant1" SrcPort 1 Points [0, 0; 10, 0] Branch { Points [0, -80] DstBlock "D Flip-Flop2" DstPort 1 } Branch { Points [0, 65] DstBlock "D Flip-Flop1" DstPort 1 } } Line { SrcBlock "D Flip-Flop2" SrcPort 1 Points [0, 0; 25, 0] Branch { Points [30, 0] Branch { DstBlock "Logical\nOperator1" DstPort 1 } Branch { Points [0, 40] DstBlock "Logical\nOperator4" DstPort 1 } } Branch { Points [0, 85] DstBlock "Logical\nOperator3" DstPort 1 } } Line { SrcBlock "Logical\nOperator3" SrcPort 1 DstBlock "Memory" DstPort 1 } Line { SrcBlock "D Flip-Flop1" SrcPort 1 Points [0, 0; 25, 0] Branch { Points [0, -45] Branch { Points [175, 0; 0, -85] DstBlock "Logical\nOperator1" DstPort 2 } Branch { DstBlock "Logical\nOperator3" DstPort 2 } } Branch { Points [0, 20] DstBlock "Logical\nOperator5" DstPort 2 } } Line { SrcBlock "Fcn2" SrcPort 1 DstBlock "D Flip-Flop2" DstPort 2 } Line { SrcBlock "Fcn3" SrcPort 1 DstBlock "D Flip-Flop1" DstPort 2 } Line { SrcBlock "Sum1" SrcPort 1 DstBlock "Transfer Fcn" DstPort 1 } Line { SrcBlock "Memory" SrcPort 1 Points [0, 0; -10, 0] Branch { Points [0, 95] DstBlock "D Flip-Flop1" DstPort 3 } Branch { Points [0, -50] DstBlock "D Flip-Flop2" DstPort 3 } } Line { SrcBlock "Logical\nOperator4" SrcPort 1 DstBlock "Gain1" DstPort 1 } Line { SrcBlock "Gain1" SrcPort 1 Points [30, 0] DstBlock "Sum1" DstPort 1 } Line { SrcBlock "Logical\nOperator5" SrcPort 1 DstBlock "Gain2" DstPort 1 } } } Block { BlockType SubSystem Name "Subsystem3" Ports [2, 2] Position [400, 290, 440, 350] ShowName off AttributesFormatString "PLL(RSFF)" TreatAsAtomicUnit off System { Name "Subsystem3" Location [-20, 310, 992, 506] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" ZoomFactor "100" Block { BlockType Inport Name "In1" Position [30, 73, 60, 87] ShowName off } Block { BlockType Inport Name "In2" Position [30, 108, 60, 122] ShowName off Port "2" } Block { BlockType Constant Name "Constant" Position [740, 115, 770, 145] Orientation "up" NamePlacement "alternate" ShowName off Value "w0" } Block { BlockType Derivative Name "Derivative" Position [180, 65, 210, 95] ShowName off } Block { BlockType Derivative Name "Derivative1" Position [180, 100, 210, 130] ShowName off } Block { BlockType Fcn Name "Fcn" Position [925, 60, 985, 90] ShowName off Expr "Vc*(u>=0)-Vc*(u<0)" } Block { BlockType Fcn Name "Fcn1" Position [500, 60, 560, 90] ShowName off Expr "Vc*(u>=0.5)-Vc*(u<0.5)" } Block { BlockType Fcn Name "Fcn2" Position [85, 65, 145, 95] ShowName off Expr "1*(u>=0)+0*(u<0)" } Block { BlockType Fcn Name "Fcn3" Position [85, 100, 145, 130] ShowName off Expr "1*(u>=0)+0*(u<0)" } Block { BlockType Fcn Name "Fcn4" Position [240, 65, 300, 95] ShowName off Expr "1*(u>=0.5)+0*(u<0.5)" } Block { BlockType Fcn Name "Fcn5" Position [240, 100, 300, 130] ShowName off Expr "1*(u>=0.5)+0*(u<0.5)" } Block { BlockType Gain Name "Gain" Position [680, 60, 710, 90] ShowName off Gain "kw" } Block { BlockType Integrator Name "Integrator" Ports [1, 1] Position [800, 60, 830, 90] ShowName off } Block { BlockType Logic Name "Logical\nOperator1" Ports [2, 1] Position [345, 105, 380, 140] NamePlacement "alternate" ShowName off } Block { BlockType Logic Name "Logical\nOperator2" Ports [2, 1] Position [345, 55, 380, 90] NamePlacement "alternate" ShowName off } Block { BlockType Memory Name "Memory" Position [370, 20, 400, 50] Orientation "left" ShowName off } Block { BlockType Memory Name "Memory1" Position [370, 150, 400, 180] Orientation "left" ShowName off } Block { BlockType Reference Name "S-R\nFlip-Flop" Ports [2, 2] Position [405, 48, 450, 152] ShowName off SourceBlock "simulink_extras/Flip Flops/S-R\nFlip-Flop" SourceType "SRFlipFlop" initial_condition "0" } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [745, 65, 765, 85] ShowName off IconShape "round" Inputs "|++" } Block { BlockType ToWorkspace Name "To Workspace1" Position [685, 15, 745, 45] ShowName off VariableName "v3" MaxDataPoints "inf" SampleTime "-1" SaveFormat "Array" } Block { BlockType TransferFcn Name "Transfer Fcn" Position [590, 57, 650, 93] ShowName off Numerator "nF" Denominator "dF" } Block { BlockType Trigonometry Name "Trigonometric\nFunction" Ports [1, 1] Position [865, 60, 895, 90] ShowName off Operator "cos" } Block { BlockType Outport Name "Out2" Position [1010, 23, 1040, 37] ShowName off } Block { BlockType Outport Name "Out1" Position [1010, 68, 1040, 82] ShowName off Port "2" } Line { SrcBlock "Gain" SrcPort 1 DstBlock "Sum" DstPort 1 } Line { SrcBlock "Sum" SrcPort 1 Points [0, 0; 5, 0] Branch { DstBlock "Integrator" DstPort 1 } Branch { Points [0, -45] DstBlock "Out2" DstPort 1 } } Line { SrcBlock "Constant" SrcPort 1 DstBlock "Sum" DstPort 2 } Line { SrcBlock "Integrator" SrcPort 1 DstBlock "Trigonometric\nFunction" DstPort 1 } Line { SrcBlock "Trigonometric\nFunction" SrcPort 1 DstBlock "Fcn" DstPort 1 } Line { SrcBlock "Transfer Fcn" SrcPort 1 Points [0, 0; 5, 0] Branch { DstBlock "Gain" DstPort 1 } Branch { Points [0, -45] DstBlock "To Workspace1" DstPort 1 } } Line { SrcBlock "Fcn3" SrcPort 1 DstBlock "Derivative1" DstPort 1 } Line { SrcBlock "Fcn2" SrcPort 1 DstBlock "Derivative" DstPort 1 } Line { SrcBlock "In1" SrcPort 1 DstBlock "Fcn2" DstPort 1 } Line { SrcBlock "Fcn" SrcPort 1 DstBlock "Out1" DstPort 1 } Line { SrcBlock "In2" SrcPort 1 DstBlock "Fcn3" DstPort 1 } Line { SrcBlock "Fcn1" SrcPort 1 DstBlock "Transfer Fcn" DstPort 1 } Line { SrcBlock "S-R\nFlip-Flop" SrcPort 1 Points [0, 0; 20, 0] Branch { DstBlock "Fcn1" DstPort 1 } Branch { Points [0, 90] DstBlock "Memory1" DstPort 1 } } Line { SrcBlock "S-R\nFlip-Flop" SrcPort 2 Points [10, 0; 0, -90] DstBlock "Memory" DstPort 1 } Line { SrcBlock "Logical\nOperator2" SrcPort 1 DstBlock "S-R\nFlip-Flop" DstPort 1 } Line { SrcBlock "Logical\nOperator1" SrcPort 1 DstBlock "S-R\nFlip-Flop" DstPort 2 } Line { SrcBlock "Memory" SrcPort 1 Points [-45, 0; 0, 30] DstBlock "Logical\nOperator2" DstPort 1 } Line { SrcBlock "Memory1" SrcPort 1 Points [-45, 0; 0, -35] DstBlock "Logical\nOperator1" DstPort 2 } Line { SrcBlock "Derivative" SrcPort 1 DstBlock "Fcn4" DstPort 1 } Line { SrcBlock "Fcn4" SrcPort 1 DstBlock "Logical\nOperator2" DstPort 2 } Line { SrcBlock "Derivative1" SrcPort 1 DstBlock "Fcn5" DstPort 1 } Line { SrcBlock "Fcn5" SrcPort 1 DstBlock "Logical\nOperator1" DstPort 1 } } } Block { BlockType SubSystem Name "Subsystem5" Ports [2, 2] Position [400, 35, 440, 95] ShowName off AttributesFormatString "PLL(MULT)" TreatAsAtomicUnit off System { Name "Subsystem5" Location [112, 390, 824, 549] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" ZoomFactor "100" Block { BlockType Inport Name "In1" Position [30, 38, 60, 52] ShowName off } Block { BlockType Inport Name "In2" Position [30, 83, 60, 97] ShowName off Port "2" } Block { BlockType Constant Name "Constant" Position [400, 110, 430, 140] Orientation "up" NamePlacement "alternate" ShowName off Value "w0" } Block { BlockType Gain Name "Gain" Position [340, 55, 370, 85] ShowName off Gain "kw" } Block { BlockType Gain Name "Gain1" Position [585, 55, 615, 85] ShowName off Gain "Vc" } Block { BlockType Gain Name "Gain2" Position [185, 55, 215, 85] ShowName off Gain "4/pi/Vc" } Block { BlockType Integrator Name "Integrator" Ports [1, 1] Position [460, 55, 490, 85] ShowName off } Block { BlockType Product Name "Product" Ports [2, 1] Position [105, 51, 150, 84] ShowName off } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [405, 60, 425, 80] ShowName off IconShape "round" Inputs "|++" } Block { BlockType ToWorkspace Name "To Workspace1" Position [350, 15, 410, 45] ShowName off VariableName "v0" MaxDataPoints "inf" SampleTime "-1" SaveFormat "Array" } Block { BlockType TransferFcn Name "Transfer Fcn" Position [250, 52, 310, 88] ShowName off Numerator "nF" Denominator "dF" } Block { BlockType Trigonometry Name "Trigonometric\nFunction" Ports [1, 1] Position [525, 55, 555, 85] ShowName off Operator "cos" } Block { BlockType Outport Name "Out2" Position [650, 18, 680, 32] ShowName off } Block { BlockType Outport Name "Out1" Position [650, 63, 680, 77] ShowName off Port "2" } Line { SrcBlock "Product" SrcPort 1 DstBlock "Gain2" DstPort 1 } Line { SrcBlock "In2" SrcPort 1 Points [10, 0; 0, -15] DstBlock "Product" DstPort 2 } Line { SrcBlock "In1" SrcPort 1 Points [10, 0; 0, 15] DstBlock "Product" DstPort 1 } Line { SrcBlock "Transfer Fcn" SrcPort 1 Points [0, 0; 5, 0] Branch { Points [0, -40] DstBlock "To Workspace1" DstPort 1 } Branch { DstBlock "Gain" DstPort 1 } } Line { SrcBlock "Trigonometric\nFunction" SrcPort 1 DstBlock "Gain1" DstPort 1 } Line { SrcBlock "Integrator" SrcPort 1 DstBlock "Trigonometric\nFunction" DstPort 1 } Line { SrcBlock "Constant" SrcPort 1 DstBlock "Sum" DstPort 2 } Line { SrcBlock "Sum" SrcPort 1 Points [0, 0; 5, 0] Branch { DstBlock "Integrator" DstPort 1 } Branch { Points [0, -45] DstBlock "Out2" DstPort 1 } } Line { SrcBlock "Gain" SrcPort 1 DstBlock "Sum" DstPort 1 } Line { SrcBlock "Gain1" SrcPort 1 DstBlock "Out1" DstPort 1 } Line { SrcBlock "Gain2" SrcPort 1 DstBlock "Transfer Fcn" DstPort 1 } } } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [120, 125, 140, 145] ShowName off IconShape "round" Inputs "|++" } Block { BlockType Sum Name "Sum1" Ports [2, 1] Position [120, 410, 140, 430] ShowName off IconShape "round" Inputs "|++" } Block { BlockType ToWorkspace Name "To Workspace" Position [565, 225, 625, 255] ShowName off VariableName "t" MaxDataPoints "inf" SampleTime "-1" SaveFormat "Array" } Block { BlockType ToWorkspace Name "To Workspace2" Position [150, 55, 210, 85] ShowName off VariableName "q" MaxDataPoints "inf" SampleTime "-1" SaveFormat "Array" } Block { BlockType Trigonometry Name "Trigonometric\nFunction" Ports [1, 1] Position [175, 120, 205, 150] ShowName off Operator "cos" } Block { BlockType Trigonometry Name "Trigonometric\nFunction1" Ports [1, 1] Position [175, 405, 205, 435] ShowName off Operator "cos" } Line { SrcBlock "Clock" SrcPort 1 DstBlock "To Workspace" DstPort 1 } Line { SrcBlock "Fcn" SrcPort 1 Points [0, 0; 30, 0] Branch { DstBlock "Subsystem1" DstPort 1 } Branch { Points [0, 85] Branch { DstBlock "Subsystem2" DstPort 1 } Branch { Points [0, 85] Branch { DstBlock "Subsystem3" DstPort 1 } Branch { Points [0, 85] DstBlock "Subsystem21" DstPort 1 } } } } Line { SrcBlock "Sum" SrcPort 1 DstBlock "Trigonometric\nFunction" DstPort 1 } Line { SrcBlock "Constant" SrcPort 1 DstBlock "Integrator1" DstPort 1 } Line { SrcBlock "Trigonometric\nFunction" SrcPort 1 Points [0, 0; 15, 0] Branch { DstBlock "Fcn" DstPort 1 } Branch { Points [0, -85] DstBlock "Gain" DstPort 1 } } Line { SrcBlock "Integrator1" SrcPort 1 DstBlock "Sum" DstPort 2 } Line { SrcBlock "Constant2" SrcPort 1 DstBlock "Sum1" DstPort 1 } Line { SrcBlock "Sum1" SrcPort 1 DstBlock "Trigonometric\nFunction1" DstPort 1 } Line { SrcBlock "Constant1" SrcPort 1 DstBlock "Integrator3" DstPort 1 } Line { SrcBlock "Trigonometric\nFunction1" SrcPort 1 Points [0, 0; 15, 0] Branch { DstBlock "Fcn1" DstPort 1 } Branch { Points [0, -190] DstBlock "Gain1" DstPort 1 } } Line { SrcBlock "Integrator3" SrcPort 1 DstBlock "Sum1" DstPort 2 } Line { SrcBlock "Fcn1" SrcPort 1 Points [0, 0; 50, 0] Branch { Points [0, -85] Branch { DstBlock "Subsystem3" DstPort 2 } Branch { Points [0, -85] Branch { Points [0, -85] DstBlock "Subsystem1" DstPort 2 } Branch { DstBlock "Subsystem2" DstPort 2 } } } Branch { DstBlock "Subsystem21" DstPort 2 } } Line { SrcBlock "Gain" SrcPort 1 DstBlock "Subsystem5" DstPort 1 } Line { SrcBlock "Gain1" SrcPort 1 Points [25, 0; 0, -150] DstBlock "Subsystem5" DstPort 2 } Line { SrcBlock "From\nWorkspace" SrcPort 1 Points [10, 0] Branch { DstBlock "Sum" DstPort 1 } Branch { Points [0, -65] DstBlock "To Workspace2" DstPort 1 } } } }