Model { Name "dft" Version 7.4 MdlSubVersion 0 GraphicalInterface { NumRootInports 1 Inport { Name "i_alpha" } NumRootOutports 2 Outport { BusObject "" BusOutputAsStruct "off" Name "out_test" } Outport { BusObject "" BusOutputAsStruct "off" Name "out_test2" } ParameterArgumentNames "" ComputedModelVersion "1.170" NumModelReferences 0 NumTestPointedSignals 0 } SavedCharacterEncoding "windows-1252" SaveDefaultBlockParams on ScopeRefreshTime 0.035000 OverrideScopeRefreshTime on DisableAllScopes off DataTypeOverride "UseLocalSettings" MinMaxOverflowLogging "UseLocalSettings" MinMaxOverflowArchiveMode "Overwrite" MaxMDLFileLineLength 120 Created "Tue Jan 26 17:09:30 2010" Creator "Administrator" UpdateHistory "UpdateHistoryNever" ModifiedByFormat "%" LastModifiedBy "Administrator" ModifiedDateFormat "%" LastModifiedDate "Thu Feb 25 16:11:37 2010" RTWModifiedTimeStamp 189014986 ModelVersionFormat "1.%" ConfigurationManager "None" SampleTimeColors off SampleTimeAnnotations off LibraryLinkDisplay "none" WideLines off ShowLineDimensions off ShowPortDataTypes on ShowLoopsOnError on IgnoreBidirectionalLines off ShowStorageClass off ShowTestPointIcons on ShowSignalResolutionIcons on ShowViewerIcons on SortedOrder off ExecutionContextIcon off ShowLinearizationAnnotations on BlockNameDataTip off BlockParametersDataTip off BlockDescriptionStringDataTip off ToolBar on StatusBar on BrowserShowLibraryLinks off BrowserLookUnderMasks off SimulationMode "normal" LinearizationMsg "none" Profile off ParamWorkspaceSource "MATLABWorkspace" AccelSystemTargetFile "accel.tlc" AccelTemplateMakefile "accel_default_tmf" AccelMakeCommand "make_rtw" TryForcingSFcnDF off RecordCoverage off CovPath "/" CovSaveName "covdata" CovMetricSettings "dw" CovNameIncrementing off CovHtmlReporting on CovForceBlockReductionOff on covSaveCumulativeToWorkspaceVar on CovSaveSingleToWorkspaceVar on CovCumulativeVarName "covCumulativeData" CovCumulativeReport off CovReportOnPause on CovModelRefEnable "Off" CovExternalEMLEnable off ExtModeBatchMode off ExtModeEnableFloating on ExtModeTrigType "manual" ExtModeTrigMode "normal" ExtModeTrigPort "1" ExtModeTrigElement "any" ExtModeTrigDuration 1000 ExtModeTrigDurationFloating "auto" 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 ShowModelReferenceBlockVersion off ShowModelReferenceBlockIO off Array { Type "Handle" Dimension 1 Simulink.ConfigSet { $ObjectID 1 Version "1.6.0" Array { Type "Handle" Dimension 8 Simulink.SolverCC { $ObjectID 2 Version "1.6.0" StartTime "0.0" StopTime "10.0" AbsTol "auto" FixedStep "0.01" InitialStep "auto" MaxNumMinSteps "-1" MaxOrder 5 ZcThreshold "auto" ConsecutiveZCsStepRelTol "10*128*eps" MaxConsecutiveZCs "1000" ExtrapolationOrder 4 NumberNewtonIterations 1 MaxStep "auto" MinStep "auto" MaxConsecutiveMinStep "1" RelTol "1e-3" SolverMode "SingleTasking" Solver "ode3" SolverName "ode3" ShapePreserveControl "DisableAll" ZeroCrossControl "UseLocalSettings" ZeroCrossAlgorithm "Nonadaptive" AlgebraicLoopSolver "TrustRegion" SolverResetMethod "Fast" PositivePriorityOrder off AutoInsertRateTranBlk off SampleTimeConstraint "Unconstrained" InsertRTBMode "Whenever possible" } Simulink.DataIOCC { $ObjectID 3 Version "1.6.0" Decimation "1" ExternalInput "[t, u]" FinalStateName "xFinal" InitialState "xInitial" LimitDataPoints on MaxDataPoints "1000" LoadExternalInput off LoadInitialState off SaveFinalState off SaveCompleteFinalSimState off SaveFormat "StructureWithTime" SaveOutput on SaveState off SignalLogging on InspectSignalLogs off SaveTime on ReturnWorkspaceOutputs off StateSaveName "xout" TimeSaveName "tout" OutputSaveName "yout" SignalLoggingName "logsout" OutputOption "RefineOutputTimes" OutputTimes "[]" ReturnWorkspaceOutputsName "out" Refine "1" } Simulink.OptimizationCC { $ObjectID 4 Version "1.6.0" Array { Type "Cell" Dimension 7 Cell "BooleansAsBitfields" Cell "PassReuseOutputArgsAs" Cell "PassReuseOutputArgsThreshold" Cell "ZeroExternalMemoryAtStartup" Cell "ZeroInternalMemoryAtStartup" Cell "OptimizeModelRefInitCode" Cell "NoFixptDivByZeroProtection" PropName "DisabledProps" } BlockReduction on BooleanDataType on ConditionallyExecuteInputs on InlineParams off UseIntDivNetSlope off InlineInvariantSignals off OptimizeBlockIOStorage on BufferReuse on EnhancedBackFolding off StrengthReduction off EnforceIntegerDowncast on ExpressionFolding on BooleansAsBitfields off EnableMemcpy on MemcpyThreshold 64 PassReuseOutputArgsAs "Structure reference" ExpressionDepthLimit 2147483647 FoldNonRolledExpr on LocalBlockOutputs on RollThreshold 5 SystemCodeInlineAuto off StateBitsets off DataBitsets off UseTempVars off ZeroExternalMemoryAtStartup on ZeroInternalMemoryAtStartup on InitFltsAndDblsToZero off NoFixptDivByZeroProtection off EfficientFloat2IntCast off EfficientMapNaN2IntZero on OptimizeModelRefInitCode off LifeSpan "inf" BufferReusableBoundary on SimCompilerOptimization "Off" AccelVerboseBuild off } Simulink.DebuggingCC { $ObjectID 5 Version "1.6.0" RTPrefix "error" ConsistencyChecking "none" ArrayBoundsChecking "none" SignalInfNanChecking "none" SignalRangeChecking "none" ReadBeforeWriteMsg "UseLocalSettings" WriteAfterWriteMsg "UseLocalSettings" WriteAfterReadMsg "UseLocalSettings" AlgebraicLoopMsg "warning" ArtificialAlgebraicLoopMsg "warning" SaveWithDisabledLinksMsg "warning" SaveWithParameterizedLinksMsg "warning" CheckSSInitialOutputMsg on UnderspecifiedInitializationDetection "Classic" MergeDetectMultiDrivingBlocksExec "none" CheckExecutionContextPreStartOutputMsg off CheckExecutionContextRuntimeOutputMsg off SignalResolutionControl "UseLocalSettings" BlockPriorityViolationMsg "warning" MinStepSizeMsg "warning" TimeAdjustmentMsg "none" MaxConsecutiveZCsMsg "error" SolverPrmCheckMsg "warning" InheritedTsInSrcMsg "warning" DiscreteInheritContinuousMsg "warning" MultiTaskDSMMsg "error" MultiTaskCondExecSysMsg "error" MultiTaskRateTransMsg "error" SingleTaskRateTransMsg "none" TasksWithSamePriorityMsg "warning" SigSpecEnsureSampleTimeMsg "warning" CheckMatrixSingularityMsg "none" IntegerOverflowMsg "warning" Int32ToFloatConvMsg "warning" ParameterDowncastMsg "error" ParameterOverflowMsg "error" ParameterUnderflowMsg "none" ParameterPrecisionLossMsg "warning" ParameterTunabilityLossMsg "warning" FixptConstUnderflowMsg "none" FixptConstOverflowMsg "none" FixptConstPrecisionLossMsg "none" UnderSpecifiedDataTypeMsg "none" UnnecessaryDatatypeConvMsg "none" VectorMatrixConversionMsg "none" InvalidFcnCallConnMsg "error" FcnCallInpInsideContextMsg "Use local settings" SignalLabelMismatchMsg "none" UnconnectedInputMsg "warning" UnconnectedOutputMsg "warning" UnconnectedLineMsg "warning" SFcnCompatibilityMsg "none" UniqueDataStoreMsg "none" BusObjectLabelMismatch "warning" RootOutportRequireBusObject "warning" AssertControl "UseLocalSettings" EnableOverflowDetection off ModelReferenceIOMsg "none" ModelReferenceVersionMismatchMessage "none" ModelReferenceIOMismatchMessage "none" ModelReferenceCSMismatchMessage "none" UnknownTsInhSupMsg "warning" ModelReferenceDataLoggingMessage "warning" ModelReferenceSymbolNameMessage "warning" ModelReferenceExtraNoncontSigs "error" StateNameClashWarn "warning" SimStateInterfaceChecksumMismatchMsg "warning" StrictBusMsg "Warning" LoggingUnavailableSignals "error" BlockIODiagnostic "none" } Simulink.HardwareCC { $ObjectID 6 Version "1.6.0" ProdBitPerChar 8 ProdBitPerShort 16 ProdBitPerInt 32 ProdBitPerLong 32 ProdIntDivRoundTo "Undefined" ProdEndianess "Unspecified" ProdWordSize 32 ProdShiftRightIntArith on ProdHWDeviceType "32-bit Generic" TargetBitPerChar 8 TargetBitPerShort 16 TargetBitPerInt 32 TargetBitPerLong 32 TargetShiftRightIntArith on TargetIntDivRoundTo "Undefined" TargetEndianess "Unspecified" TargetWordSize 32 TargetTypeEmulationWarnSuppressLevel 0 TargetPreprocMaxBitsSint 32 TargetPreprocMaxBitsUint 32 TargetHWDeviceType "Specified" TargetUnknown off ProdEqTarget on } Simulink.ModelReferenceCC { $ObjectID 7 Version "1.6.0" UpdateModelReferenceTargets "IfOutOfDateOrStructuralChange" CheckModelReferenceTargetMessage "error" ModelReferenceNumInstancesAllowed "Multi" ModelReferencePassRootInputsByReference on ModelReferenceMinAlgLoopOccurrences off } Simulink.SFSimCC { $ObjectID 8 Version "1.6.0" SFSimEnableDebug on SFSimOverflowDetection on SFSimEcho on SimBlas on SimCtrlC on SimExtrinsic on SimIntegrity on SimUseLocalCustomCode off SimBuildMode "sf_incremental_build" } Simulink.RTWCC { $BackupClass "Simulink.RTWCC" $ObjectID 9 Version "1.6.0" Array { Type "Cell" Dimension 6 Cell "IncludeHyperlinkInReport" Cell "GenerateTraceInfo" Cell "GenerateTraceReport" Cell "GenerateTraceReportSl" Cell "GenerateTraceReportSf" Cell "GenerateTraceReportEml" PropName "DisabledProps" } SystemTargetFile "tct.tlc" GenCodeOnly off MakeCommand "make_rtw" GenerateMakefile on TemplateMakefile "tct_msvc.tmf" Description "TwinCAT Target" GenerateReport off SaveLog off RTWVerbose on RetainRTWFile off ProfileTLC off TLCDebug off TLCCoverage off TLCAssert off ProcessScriptMode "Default" ConfigurationMode "Optimized" ProcessScript "tct_make_rtw_hook" ConfigAtBuild off RTWUseLocalCustomCode off RTWUseSimCustomCode off IncludeHyperlinkInReport off LaunchReport off TargetLang "C" IncludeBusHierarchyInRTWFileBlockHierarchyMap off IncludeERTFirstTime off GenerateTraceInfo off GenerateTraceReport off GenerateTraceReportSl off GenerateTraceReportSf off GenerateTraceReportEml off GenerateCodeInfo off RTWCompilerOptimization "Off" CheckMdlBeforeBuild "Off" Array { Type "Handle" Dimension 2 Simulink.CodeAppCC { $ObjectID 10 Version "1.6.0" Array { Type "Cell" Dimension 19 Cell "IgnoreCustomStorageClasses" Cell "IgnoreTestpoints" Cell "InsertBlockDesc" Cell "SFDataObjDesc" Cell "SimulinkDataObjDesc" Cell "DefineNamingRule" Cell "SignalNamingRule" Cell "ParamNamingRule" Cell "InlinedPrmAccess" Cell "CustomSymbolStr" Cell "CustomSymbolStrGlobalVar" Cell "CustomSymbolStrType" Cell "CustomSymbolStrField" Cell "CustomSymbolStrFcn" Cell "CustomSymbolStrFcnArg" Cell "CustomSymbolStrBlkIO" Cell "CustomSymbolStrTmpVar" Cell "CustomSymbolStrMacro" Cell "ReqsInCode" PropName "DisabledProps" } ForceParamTrailComments off GenerateComments on IgnoreCustomStorageClasses on IgnoreTestpoints off IncHierarchyInIds off MaxIdLength 31 PreserveName off PreserveNameWithParent off ShowEliminatedStatement off IncAutoGenComments off SimulinkDataObjDesc off SFDataObjDesc off IncDataTypeInIds off MangleLength 1 CustomSymbolStrGlobalVar "$R$N$M" CustomSymbolStrType "$N$R$M" CustomSymbolStrField "$N$M" CustomSymbolStrFcn "$R$N$M$F" CustomSymbolStrFcnArg "rt$I$N$M" CustomSymbolStrBlkIO "rtb_$N$M" CustomSymbolStrTmpVar "$N$M" CustomSymbolStrMacro "$R$N$M" DefineNamingRule "None" ParamNamingRule "None" SignalNamingRule "None" InsertBlockDesc off SimulinkBlockComments on EnableCustomComments off InlinedPrmAccess "Literals" ReqsInCode off UseSimReservedNames off } Simulink.STFCustomTargetCC { $BackupClass "Simulink.TargetCC" $ObjectID 11 Version "1.6.0" Array { Type "Cell" Dimension 30 Cell "ExtMode" Cell "ExtModeTransport" Cell "ExtModeStaticAlloc" Cell "LogMatFile" Cell "GeneratePreprocessorConditionals" Cell "IncludeMdlTerminateFcn" Cell "CombineOutputUpdateFcns" Cell "SuppressErrorStatus" Cell "ERTCustomFileBanners" Cell "GenerateSampleERTMain" Cell "GenerateTestInterfaces" Cell "ModelStepFunctionPrototypeControlCompliant" Cell "CPPClassGenCompliant" Cell "MultiInstanceERTCode" Cell "PurelyIntegerCode" Cell "SupportNonFinite" Cell "SupportComplex" Cell "SupportAbsoluteTime" Cell "SupportContinuousTime" Cell "SupportNonInlinedSFcns" Cell "PortableWordSizes" Cell "ModelReferenceCompliant" Cell "CompOptLevelCompliant" Cell "MatFileLoggingName" Cell "ExtModeStaticAllocSize" Cell "ExtModeRtExecCommands" Cell "ExtModeRtWaitOnStartDefault" Cell "LogVarNameModifier" Cell "LogRelToModelDir" Cell "MatFileLoggingDir" PropName "DisabledProps" } TargetFcnLib "ansi_tfl_table_tmw.mat" TargetLibSuffix "" TargetPreCompLibLocation "" TargetFunctionLibrary "ANSI_C" UtilityFuncGeneration "Auto" ERTMultiwordTypeDef "System defined" ERTMultiwordLength 256 MultiwordLength 2048 GenerateFullHeader on GenerateSampleERTMain off GenerateTestInterfaces off IsPILTarget off ModelReferenceCompliant on ParMdlRefBuildCompliant off CompOptLevelCompliant on IncludeMdlTerminateFcn on GeneratePreprocessorConditionals "Disable all" CombineOutputUpdateFcns off SuppressErrorStatus off ERTFirstTimeCompliant off IncludeFileDelimiter "Auto" ERTCustomFileBanners off SupportAbsoluteTime on LogVarNameModifier "rt_" MatFileLogging off MultiInstanceERTCode off SupportNonFinite on SupportComplex on PurelyIntegerCode off SupportContinuousTime on SupportNonInlinedSFcns on SupportVariableSizeSignals off EnableShiftOperators on ParenthesesLevel "Nominal" PortableWordSizes off ModelStepFunctionPrototypeControlCompliant off CPPClassGenCompliant off AutosarCompliant off SystemTargetFile "tct.tlc" DialogCategory 0 CustomProperty { DataType "RTWOptions_EnumType_c__TwinCAT_TcTarget_tlc_tct_1ClassIdSpecification" EnumStrPairs { Value 0 String "user defined fix class id" Value 1 String "generate automatically - unique for this model" Value 2 String "generate automatically - unique for each build" } Name "ClassIdSpecification" Value "user defined fix class id" } CustomProperty { DataType "string" Name "UserDefinedClassId" Value "hex2dec('8700000')" } CustomProperty { DataType "int32" Name "AdsPortNumber" Value 350 } CustomProperty { DataType "RTWOptions_EnumType_c__TwinCAT_TcTarget_tlc_tct_1TC_Build_Targets_popup" EnumStrPairs { Value 0 String "Both CE and NT target system" Value 1 String "Only CE target system" Value 2 String "Only NT/XP target system" } Name "TC_Build_Targets_popup" Value "Only NT/XP target system" } CustomProperty { DataType "string" Name "TC_Build_Targets" Value "NT" } CustomProperty { DataType "slbool" Name "ExtMode" Value off } CustomProperty { DataType "RTWOptions_EnumType_c__TwinCAT_TcTarget_tlc_tct_1ExtModeTransport" EnumStrPairs { Value 0 String "ADS" } Name "ExtModeTransport" Value "ADS" } CustomProperty { DataType "slbool" Name "ExtModeStaticAlloc" Value on } CustomProperty { DataType "int32" Name "ExtModeStaticAllocSize" Value 1000000 } CustomProperty { DataType "slbool" Name "ExtModeRtExecCommands" Value off } CustomProperty { DataType "slbool" Name "ExtModeRtWaitOnStartDefault" Value off } CustomProperty { DataType "string" Name "ExtModeUseStaticLib" Value "off" } CustomProperty { DataType "slbool" Name "LogMatFile" Value off } CustomProperty { DataType "slbool" Name "LogRelToModelDir" Value on } CustomProperty { DataType "string" Name "MatFileLoggingDir" Value "TctDataLogging\\\\--" } CustomProperty { DataType "string" Name "MatFileLoggingName" Value "_" } } PropName "Components" } } PropName "Components" } Name "Configuration" ExtraOptions "-aGenerateTraceInfo=0 -aIgnoreTestpoints=0 " CurrentDlgPage "Data Import//Export" ConfigPrmDlgPosition " [ 177, 361, 1057, 991 ] " } PropName "ConfigurationSets" } Simulink.ConfigSet { $PropName "ActiveConfigurationSet" $ObjectID 1 } BlockDefaults { ForegroundColor "black" BackgroundColor "white" DropShadow off NamePlacement "normal" FontName "Helvetica" FontSize 10 FontWeight "normal" FontAngle "normal" ShowName on BlockRotation 0 BlockMirror off } AnnotationDefaults { HorizontalAlignment "center" VerticalAlignment "middle" ForegroundColor "black" BackgroundColor "white" DropShadow off FontName "Helvetica" FontSize 10 FontWeight "normal" FontAngle "normal" UseDisplayTextAsClickCallback off } LineDefaults { FontName "Helvetica" FontSize 9 FontWeight "normal" FontAngle "normal" } BlockParameterDefaults { Block { BlockType Demux Outputs "4" DisplayOption "none" BusSelectionMode off } Block { BlockType Gain Gain "1" Multiplication "Element-wise(K.*u)" ParamMin "[]" ParamMax "[]" ParameterDataTypeMode "Same as input" ParameterDataType "fixdt(1,16,0)" ParameterScalingMode "Best Precision: Matrix-wise" ParameterScaling "[]" ParamDataTypeStr "Inherit: Same as input" OutMin "[]" OutMax "[]" OutDataTypeMode "Same as input" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: Same as input" LockScale off RndMeth "Floor" SaturateOnIntegerOverflow on SampleTime "-1" } Block { BlockType Inport Port "1" UseBusObject off BusObject "BusObject" BusOutputAsStruct off PortDimensions "-1" VarSizeSig "Inherit" SampleTime "-1" OutMin "[]" OutMax "[]" DataType "auto" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: auto" LockScale off SignalType "auto" SamplingMode "auto" LatchByDelayingOutsideSignal off LatchByCopyingInsideSignal off Interpolate on } Block { BlockType Memory X0 "0" InheritSampleTime off LinearizeMemory off LinearizeAsDelay off StateMustResolveToSignalObject off RTWStateStorageClass "Auto" } Block { BlockType Outport Port "1" UseBusObject off BusObject "BusObject" BusOutputAsStruct off PortDimensions "-1" VarSizeSig "Inherit" SampleTime "-1" OutMin "[]" OutMax "[]" DataType "auto" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: auto" LockScale off SignalType "auto" SamplingMode "auto" SourceOfInitialOutputValue "Dialog" OutputWhenDisabled "held" InitialOutput "[]" } Block { BlockType Product Inputs "2" Multiplication "Element-wise(.*)" CollapseMode "All dimensions" CollapseDim "1" InputSameDT on OutMin "[]" OutMax "[]" OutDataTypeMode "Same as first input" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: Same as first input" LockScale off RndMeth "Zero" SaturateOnIntegerOverflow on SampleTime "-1" } Block { BlockType "S-Function" FunctionName "system" SFunctionModules "''" PortCounts "[]" SFunctionDeploymentMode off } Block { BlockType Scope ModelBased off TickLabels "OneTimeTick" ZoomMode "on" Grid "on" TimeRange "auto" YMin "-5" YMax "5" SaveToWorkspace off SaveName "ScopeData" LimitDataPoints on MaxDataPoints "5000" Decimation "1" SampleInput off SampleTime "-1" } Block { BlockType Sin SineType "Time based" TimeSource "Use simulation time" SampleTime "-1" VectorParams1D on } Block { BlockType Step Time "1" Before "0" After "1" SampleTime "-1" VectorParams1D on ZeroCross on } Block { BlockType SubSystem ShowPortLabels "FromPortIcon" Permissions "ReadWrite" PermitHierarchicalResolution "All" TreatAsAtomicUnit off CheckFcnCallInpInsideContextMsg off SystemSampleTime "-1" RTWFcnNameOpts "Auto" RTWFileNameOpts "Auto" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" SimViewingDevice off DataTypeOverride "UseLocalSettings" MinMaxOverflowLogging "UseLocalSettings" } Block { BlockType Sum IconShape "rectangular" Inputs "++" CollapseMode "All dimensions" CollapseDim "1" InputSameDT on AccumDataTypeStr "Inherit: Inherit via internal rule" OutMin "[]" OutMax "[]" OutDataTypeMode "Same as first input" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: Same as first input" LockScale off RndMeth "Floor" SaturateOnIntegerOverflow on SampleTime "-1" } Block { BlockType Terminator } Block { BlockType ZeroOrderHold SampleTime "1" } } System { Name "dft" Location [158, 255, 1296, 715] Open on ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" ReportName "simulink-default.rpt" SIDHighWatermark 210 Block { BlockType Inport Name "i_alpha" SID 173 Position [15, 178, 45, 192] IconDisplay "Port number" OutDataType "fixdt(1, 16)" OutScaling "2^0" } Block { BlockType SubSystem Name "Embedded\nMATLAB Function" SID 174 Ports [2, 2] Position [565, 15, 695, 250] LibraryVersion "1.30" PermitHierarchicalResolution "ExplicitOnly" MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off MaskType "Stateflow" MaskDescription "Embedded MATLAB block" MaskDisplay "disp('calc_ampl_pha');" MaskSelfModifiable on MaskIconFrame on MaskIconOpaque off MaskIconRotate "none" MaskPortRotate "default" MaskIconUnits "autoscale" System { Name "Embedded\nMATLAB Function" Location [257, 457, 812, 717] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" SIDHighWatermark 38 SIDPrevWatermark 38 Block { BlockType Inport Name "dft_re" SID 33 Position [20, 101, 40, 119] IconDisplay "Port number" } Block { BlockType Inport Name "dft_im" SID 38 Position [20, 136, 40, 154] Port "2" IconDisplay "Port number" } Block { BlockType Demux Name " Demux " SID 7 Ports [1, 1] Position [270, 230, 320, 270] Outputs "1" } Block { BlockType "S-Function" Name " SFunction " SID 6 Tag "Stateflow S-Function dft 2" Ports [2, 3] Position [180, 110, 230, 230] FunctionName "sf_sfun" PortCounts "[2 3]" EnableBusSupport on Port { PortNumber 2 Name "amplitude" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 3 Name "phase" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } } Block { BlockType Terminator Name " Terminator " SID 9 Position [460, 241, 480, 259] } Block { BlockType Outport Name "amplitude" SID 5 Position [460, 101, 480, 119] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "phase" SID 28 Position [460, 136, 480, 154] Port "2" IconDisplay "Port number" } Line { SrcBlock " SFunction " SrcPort 1 DstBlock " Demux " DstPort 1 } Line { SrcBlock "dft_re" SrcPort 1 DstBlock " SFunction " DstPort 1 } Line { SrcBlock "dft_im" SrcPort 1 DstBlock " SFunction " DstPort 2 } Line { Name "amplitude" Labels [0, 0] SrcBlock " SFunction " SrcPort 2 DstBlock "amplitude" DstPort 1 } Line { Name "phase" Labels [0, 0] SrcBlock " SFunction " SrcPort 3 DstBlock "phase" DstPort 1 } Line { SrcBlock " Demux " SrcPort 1 DstBlock " Terminator " DstPort 1 } } } Block { BlockType Gain Name "Gain2" SID 175 Position [605, 345, 635, 375] Gain "1000" ParameterDataTypeMode "Inherit via internal rule" ParameterDataType "fixdt(1, 16)" ParameterScaling "2^0" ParamDataTypeStr "Inherit: Inherit via internal rule" OutDataTypeMode "int16" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "int16" SaturateOnIntegerOverflow off } Block { BlockType Gain Name "Gain6" SID 176 Position [95, 170, 125, 200] ParameterDataTypeMode "Inherit via internal rule" ParameterDataType "fixdt(1, 16)" ParameterScaling "2^0" ParamDataTypeStr "Inherit: Inherit via internal rule" OutDataTypeMode "int16" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "int16" SaturateOnIntegerOverflow off } Block { BlockType Reference Name "Manual Switch2" SID 177 Ports [2, 1] Position [190, 112, 220, 148] LibraryVersion "1.762" SourceBlock "simulink/Signal\nRouting/Manual Switch" SourceType "Manual Switch" ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData off RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" sw "1" action "0" varsize off } Block { BlockType Scope Name "Scope1" SID 178 Ports [4] Position [1020, 232, 1050, 308] Floating off Location [1103, 294, 1552, 772] Open off NumInputPorts "4" ZoomMode "xonly" List { ListType AxesTitles axes1 "%" axes2 "%" axes3 "%" axes4 "%" } YMin "-2~-1~-5~-5" YMax "2~1~5~5" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType SubSystem Name "Subsystem\nCosinus Implementation" SID 179 Ports [1, 1] Position [325, 155, 460, 225] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Subsystem\nCosinus Implementation" Location [367, 580, 1042, 800] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "i_alpha" SID 180 Position [25, 143, 55, 157] IconDisplay "Port number" } Block { BlockType Memory Name "Memory" SID 181 Position [385, 165, 415, 195] BlockMirror on } Block { BlockType Product Name "Product1" SID 182 Ports [2, 1] Position [260, 39, 300, 186] InputSameDT off OutDataTypeMode "double" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "double" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product3" SID 183 Ports [2, 1] Position [105, 27, 140, 118] InputSameDT off OutDataTypeMode "double" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "double" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product4" SID 184 Ports [2, 1] Position [500, 40, 540, 155] InputSameDT off OutDataTypeMode "double" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "double" SaturateOnIntegerOverflow off } Block { BlockType Step Name "Step" SID 185 Position [25, 35, 55, 65] Time "0.08" Before "1" After "0" SampleTime "0" } Block { BlockType Step Name "Step1" SID 186 Position [385, 55, 415, 85] Time "0.08" SampleTime "0" } Block { BlockType ZeroOrderHold Name "Zero-Order\nHold1" SID 187 Position [185, 60, 215, 90] SampleTime "0.01" } Block { BlockType ZeroOrderHold Name "Zero-Order\nHold2" SID 188 Position [185, 135, 215, 165] SampleTime "0.01" } Block { BlockType Sum Name "addition" SID 189 Ports [2, 1] Position [385, 107, 415, 138] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "fixdt(1, 16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sin Name "cos" SID 190 Ports [0, 1] Position [25, 80, 55, 110] Amplitude "4" Bias "0" Frequency "80" Phase "90" Samples "10" Offset "0" SampleTime "0" } Block { BlockType Outport Name "out_dft_im" SID 191 Position [620, 93, 650, 107] IconDisplay "Port number" OutDataType "fixdt(1, 16)" OutScaling "2^0" } Line { SrcBlock "i_alpha" SrcPort 1 DstBlock "Zero-Order\nHold2" DstPort 1 } Line { SrcBlock "Product4" SrcPort 1 DstBlock "out_dft_im" DstPort 1 } Line { SrcBlock "Step1" SrcPort 1 DstBlock "Product4" DstPort 1 } Line { SrcBlock "Product3" SrcPort 1 DstBlock "Zero-Order\nHold1" DstPort 1 } Line { SrcBlock "cos" SrcPort 1 DstBlock "Product3" DstPort 2 } Line { SrcBlock "Step" SrcPort 1 DstBlock "Product3" DstPort 1 } Line { SrcBlock "Zero-Order\nHold2" SrcPort 1 DstBlock "Product1" DstPort 2 } Line { SrcBlock "Zero-Order\nHold1" SrcPort 1 DstBlock "Product1" DstPort 1 } Line { SrcBlock "Memory" SrcPort 1 Points [-35, 0; 0, -50] DstBlock "addition" DstPort 2 } Line { SrcBlock "addition" SrcPort 1 Points [30, 0] Branch { DstBlock "Product4" DstPort 2 } Branch { Points [0, 55] DstBlock "Memory" DstPort 1 } } Line { SrcBlock "Product1" SrcPort 1 DstBlock "addition" DstPort 1 } } } Block { BlockType SubSystem Name "Subsystem\nSinus Implemenation" SID 192 Ports [1, 2] Position [325, 42, 460, 113] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Subsystem\nSinus Implemenation" Location [382, 387, 1135, 789] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "i_alpha" SID 193 Position [25, 148, 55, 162] IconDisplay "Port number" } Block { BlockType Gain Name "Gain1" SID 194 Position [185, 280, 215, 310] Gain "1000" ParameterDataTypeMode "Inherit via internal rule" ParameterDataType "fixdt(1, 16)" ParameterScaling "2^0" ParamDataTypeStr "Inherit: Inherit via internal rule" OutDataTypeMode "int16" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "int16" SaturateOnIntegerOverflow off } Block { BlockType Memory Name "Memory" SID 195 Position [385, 170, 415, 200] BlockMirror on } Block { BlockType Product Name "Product1" SID 196 Ports [2, 1] Position [260, 44, 300, 191] InputSameDT off OutDataTypeMode "double" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "double" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product3" SID 197 Ports [2, 1] Position [105, 32, 140, 123] InputSameDT off OutDataTypeMode "double" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "double" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product4" SID 198 Ports [2, 1] Position [500, 45, 540, 160] InputSameDT off OutDataTypeMode "double" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "double" SaturateOnIntegerOverflow off } Block { BlockType Scope Name "Scope1" SID 199 Ports [5] Position [660, 220, 690, 310] Floating off Location [876, 333, 1400, 843] Open off NumInputPorts "5" List { ListType AxesTitles axes1 "%" axes2 "%" axes3 "%" axes4 "%" axes5 "%" } YMin "-5~-5~-5~-5~-5" YMax "5~5~5~5~5" SaveName "ScopeData3" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Step Name "Step" SID 200 Position [25, 40, 55, 70] Time "0.08" Before "1" After "0" SampleTime "0" } Block { BlockType Step Name "Step1" SID 201 Position [385, 60, 415, 90] Time "0.08" SampleTime "0" } Block { BlockType ZeroOrderHold Name "Zero-Order\nHold1" SID 202 Position [185, 65, 215, 95] SampleTime "0.01" } Block { BlockType ZeroOrderHold Name "Zero-Order\nHold2" SID 203 Position [185, 140, 215, 170] SampleTime "0.01" } Block { BlockType Sum Name "addition" SID 204 Ports [2, 1] Position [385, 112, 415, 143] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "fixdt(1, 16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sin Name "sin" SID 205 Ports [0, 1] Position [25, 85, 55, 115] Amplitude "4" Bias "0" Frequency "80" Phase "0" Samples "10" Offset "0" SampleTime "0" } Block { BlockType Outport Name "out_dft_re" SID 206 Position [640, 98, 670, 112] IconDisplay "Port number" OutDataType "fixdt(1, 16)" OutScaling "2^0" } Block { BlockType Outport Name "out_test" SID 207 Position [265, 288, 295, 302] Port "2" IconDisplay "Port number" DataType "int16" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "int16" } Line { SrcBlock "Product1" SrcPort 1 Points [15, 0] Branch { DstBlock "addition" DstPort 1 } Branch { Points [0, 145] DstBlock "Scope1" DstPort 3 } } Line { SrcBlock "addition" SrcPort 1 Points [30, 0] Branch { Points [0, 55] DstBlock "Memory" DstPort 1 } Branch { Points [10, 0] Branch { Points [0, 155] DstBlock "Scope1" DstPort 4 } Branch { DstBlock "Product4" DstPort 2 } } } Line { SrcBlock "Memory" SrcPort 1 Points [-35, 0; 0, -50] DstBlock "addition" DstPort 2 } Line { SrcBlock "Zero-Order\nHold1" SrcPort 1 Points [15, 0] Branch { DstBlock "Product1" DstPort 1 } Branch { Points [0, 145] DstBlock "Scope1" DstPort 1 } } Line { SrcBlock "Zero-Order\nHold2" SrcPort 1 Points [25, 0] Branch { DstBlock "Product1" DstPort 2 } Branch { Points [0, 90] DstBlock "Scope1" DstPort 2 } } Line { SrcBlock "Step" SrcPort 1 DstBlock "Product3" DstPort 1 } Line { SrcBlock "sin" SrcPort 1 DstBlock "Product3" DstPort 2 } Line { SrcBlock "Product3" SrcPort 1 Points [10, 0] Branch { DstBlock "Zero-Order\nHold1" DstPort 1 } Branch { Points [0, 215] DstBlock "Gain1" DstPort 1 } } Line { SrcBlock "Step1" SrcPort 1 DstBlock "Product4" DstPort 1 } Line { SrcBlock "Product4" SrcPort 1 Points [20, 0] Branch { Points [0, 200] DstBlock "Scope1" DstPort 5 } Branch { DstBlock "out_dft_re" DstPort 1 } } Line { SrcBlock "i_alpha" SrcPort 1 DstBlock "Zero-Order\nHold2" DstPort 1 } Line { SrcBlock "Gain1" SrcPort 1 DstBlock "out_test" DstPort 1 } } } Block { BlockType Sin Name "i_alpha_test" SID 208 Ports [0, 1] Position [15, 105, 45, 135] Amplitude "4" Bias "0" Frequency "80" Phase "0" Samples "10" Offset "0" SampleTime "0" } Block { BlockType Outport Name "out_test" SID 209 Position [520, 18, 550, 32] IconDisplay "Port number" DataType "int16" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "int16" } Block { BlockType Outport Name "out_test2" SID 210 Position [715, 353, 745, 367] Port "2" IconDisplay "Port number" DataType "int16" OutDataType "fixdt(1, 16)" OutScaling "2^0" OutDataTypeStr "int16" } Line { SrcBlock "i_alpha" SrcPort 1 DstBlock "Gain6" DstPort 1 } Line { SrcBlock "Gain6" SrcPort 1 Points [25, 0; 0, -45] DstBlock "Manual Switch2" DstPort 2 } Line { SrcBlock "i_alpha_test" SrcPort 1 DstBlock "Manual Switch2" DstPort 1 } Line { SrcBlock "Subsystem\nSinus Implemenation" SrcPort 1 Points [0, 15; 75, 0] Branch { DstBlock "Embedded\nMATLAB Function" DstPort 1 } Branch { Points [0, 205] DstBlock "Scope1" DstPort 3 } } Line { SrcBlock "Subsystem\nCosinus Implementation" SrcPort 1 Points [40, 0] Branch { DstBlock "Embedded\nMATLAB Function" DstPort 2 } Branch { Points [0, 110] DstBlock "Scope1" DstPort 4 } } Line { SrcBlock "Manual Switch2" SrcPort 1 Points [45, 0] Branch { Points [0, -50] DstBlock "Subsystem\nSinus Implemenation" DstPort 1 } Branch { Points [0, 60] Branch { DstBlock "Subsystem\nCosinus Implementation" DstPort 1 } Branch { Points [0, 170] DstBlock "Gain2" DstPort 1 } } } Line { SrcBlock "Gain2" SrcPort 1 DstBlock "out_test2" DstPort 1 } Line { SrcBlock "Subsystem\nSinus Implemenation" SrcPort 2 Points [40, 0] DstBlock "out_test" DstPort 1 } Line { SrcBlock "Embedded\nMATLAB Function" SrcPort 1 Points [210, 0; 0, 165] DstBlock "Scope1" DstPort 1 } Annotation { Position [201, 129] } } } # Finite State Machines # # Stateflow Version 7.1 (R2009a) dated Jul 17 2009, 10:24:20 # # Stateflow { machine { id 1 name "dft" created "10-Feb-2010 11:54:08" isLibrary 0 firstTarget 11 sfVersion 71014000.00001 } chart { id 2 name "Embedded\nMATLAB Function" windowPosition [296.813 314.45 200.25 189.75] viewLimits [0 156.75 0 153.75] screen [1 1 1920 1080 1.333333333333333] treeNode [0 3 0 0] firstTransition 5 firstJunction 4 viewObj 2 machine 1 toolbarMode LIBRARY_TOOLBAR subviewS { } ssIdHighWaterMark 29 decomposition CLUSTER_CHART type EML_CHART firstData 6 chartFileNumber 2 disableImplicitCasting 1 eml { name "calc_ampl_pha" } } state { id 3 labelString "eML_blk_kernel()" position [18 64.5 118 66] fontSize 12 chart 2 treeNode [2 0 0 0] superState SUBCHART subviewer 2 ssIdNumber 1 type FUNC_STATE decomposition CLUSTER_STATE eml { isEML 1 script "function [amplitude, phase] = calc_ampl_pha(dft_re, dft_im)\n\n%amplitude = dft_re;\nphase = dft_" "im;\n\n% Berechnung der Amplitude und der Phase\namplitude = sqrt(dft_re * dft_re + dft_im * dft_im);\n%phase = " "atand(dft_im / dft_re);\n\n%=========================================================\n% Parameter\n%N = 8;\n%fs" " = 10000;\n%dft_re = 0;\n%dft_im = 0;\n%f = (0:(N-1))./N*fs;\n\n% Zeit\n%t = 0:1/fs:(N-1)*1/fs;\n\n% Sinus & Cos" "inus Signal erzeugen\n%sinus = sin(2*pi*2000*t);\n%x = sin(2*pi*2000*t);\n%y = cos(2*pi*2000*t);\n\n%subplot(2,1" ",1);plot(x);\n%subplot(2,1,2);plot(y,'rs','LineWidth',2);\n\n%for i = 0 : (N-1)\n% dft_re = dft_re + (sinus *" " x(i+1));\n% dft_im = dft_im + (sinus * y(i+1));\n%end\n\n% Berechnung der Amplitude und der Phase\n%a= sum(d" "ft_re);\n%b= sum(dft_im);\n\n\n" editorLayout "100 M4x1[156 210 1012 758]" } } junction { id 4 position [23.5747 49.5747 7] chart 2 linkNode [2 0 0] subviewer 2 ssIdNumber 3 type CONNECTIVE_JUNCTION } transition { id 5 labelString "{eML_blk_kernel();}" labelPosition [32.125 19.875 102.544 14.964] fontSize 12 src { intersection [0 0 1 0 23.5747 14.625 0 0] } dst { id 4 intersection [7 0 -1 -1 23.5747 42.5747 0 0] } midPoint [23.5747 24.9468] chart 2 linkNode [2 0 0] dataLimits [23.575 23.575 14.625 34.575] subviewer 2 drawStyle SMART executionOrder 1 ssIdNumber 2 } data { id 6 ssIdNumber 5 name "amplitude" linkNode [2 0 7] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 7 ssIdNumber 19 name "phase" linkNode [2 6 8] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 8 ssIdNumber 24 name "dft_re" linkNode [2 7 9] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 9 ssIdNumber 29 name "dft_im" linkNode [2 8 0] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } instance { id 10 name "Embedded\nMATLAB Function" machine 1 chart 2 } target { id 11 name "sfun" description "Default Simulink S-Function Target." machine 1 linkNode [1 0 12] } target { id 12 name "rtw" machine 1 linkNode [1 11 0] } }