📄 sltank2.mdl
字号:
Model {
Name "sltank2"
Version 4.00
SampleTimeColors off
LibraryLinkDisplay "none"
WideLines off
ShowLineDimensions off
ShowPortDataTypes off
RecordCoverage off
CovPath "/"
CovSaveName "covdata"
CovNameIncrementing off
CovHtmlReporting on
BlockParametersDataTip on
BlockDescriptionStringDataTip off
ToolBar on
StatusBar off
BrowserShowLibraryLinks off
BrowserLookUnderMasks off
PreLoadFcn "tank2=readfis('tank2');"
Created "Wed Oct 06 16:08:40 1999"
Creator "pascal"
UpdateHistory "UpdateHistoryNever"
ModifiedByFormat "%<Auto>"
LastModifiedBy "pascal"
ModifiedDateFormat "%<Auto>"
LastModifiedDate "Wed Aug 09 17:56:01 2000"
ModelVersionFormat "1.%<AutoIncrement:7>"
ConfigurationManager "none"
DefaultBlockFontName "Helvetica"
DefaultBlockFontSize 10
DefaultBlockFontWeight "normal"
DefaultBlockFontAngle "normal"
DefaultAnnotationFontName "Helvetica"
DefaultAnnotationFontSize 10
DefaultAnnotationFontWeight "normal"
DefaultAnnotationFontAngle "normal"
DefaultLineFontName "Helvetica"
DefaultLineFontSize 9
DefaultLineFontWeight "normal"
DefaultLineFontAngle "normal"
SimParamPage "Solver"
StartTime "0"
StopTime "10000"
SolverMode "SingleTasking"
Solver "ode23"
RelTol "1e-3"
AbsTol "1e-6"
Refine "1"
MaxStep "0.2"
MinStep "auto"
MaxNumMinSteps "-1"
InitialStep "auto"
FixedStep "auto"
MaxOrder 5
OutputOption "RefineOutputTimes"
OutputTimes "[]"
LoadExternalInput off
ExternalInput "[t, u]"
SaveTime off
TimeSaveName "tout"
SaveState off
StateSaveName "xout"
SaveOutput off
OutputSaveName "yout"
LoadInitialState off
InitialState "xInitial"
SaveFinalState off
FinalStateName "xFinal"
SaveFormat "Array"
LimitDataPoints off
MaxDataPoints "1000"
Decimation "1"
AlgebraicLoopMsg "warning"
MinStepSizeMsg "warning"
UnconnectedInputMsg "warning"
UnconnectedOutputMsg "warning"
UnconnectedLineMsg "warning"
InheritedTsInSrcMsg "warning"
SingleTaskRateTransMsg "none"
MultiTaskRateTransMsg "error"
IntegerOverflowMsg "warning"
CheckForMatrixSingularity "none"
UnnecessaryDatatypeConvMsg "none"
Int32ToFloatConvMsg "warning"
SignalLabelMismatchMsg "none"
LinearizationMsg "none"
VectorMatrixConversionMsg "none"
SfunCompatibilityCheckMsg "none"
BlockPriorityViolationMsg "warning"
ArrayBoundsChecking "none"
ConsistencyChecking "none"
ZeroCross on
Profile off
SimulationMode "normal"
RTWSystemTargetFile "grt.tlc"
RTWInlineParameters off
RTWRetainRTWFile off
RTWTemplateMakefile "grt_default_tmf"
RTWMakeCommand "make_rtw"
RTWGenerateCodeOnly off
TLCProfiler off
TLCDebug off
TLCCoverage off
AccelSystemTargetFile "accel.tlc"
AccelTemplateMakefile "accel_default_tmf"
AccelMakeCommand "make_rtw"
ExtModeMexFile "ext_comm"
ExtModeBatchMode off
ExtModeTrigType "manual"
ExtModeTrigMode "oneshot"
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 off
ExtModeLogAll on
OptimizeBlockIOStorage on
BufferReuse on
ParameterPooling on
BlockReductionOpt off
BooleanDataType off
BlockDefaults {
Orientation "right"
ForegroundColor "black"
BackgroundColor "white"
DropShadow off
NamePlacement "normal"
FontName "Helvetica"
FontSize 10
FontWeight "normal"
FontAngle "normal"
ShowName on
}
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 "sltank2"
Location [297, 143, 891, 444]
Open on
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
AutoZoom on
ReportName "simulink-default.rpt"
Block {
BlockType SubSystem
Name "Animation"
Ports [2]
Position [45, 184, 85, 226]
Orientation "left"
ShowPortLabels off
TreatAsAtomicUnit off
RTWSystemCode "Auto"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "Animation"
Location [528, 313, 866, 519]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
AutoZoom on
Block {
BlockType Inport
Name "in_1"
Position [20, 25, 40, 45]
Port "1"
Interpolate on
}
Block {
BlockType Inport
Name "in_2"
Position [20, 85, 40, 105]
Port "2"
Interpolate on
}
Block {
BlockType Mux
Name "Mux2"
Ports [2, 1]
Position [95, 50, 125, 85]
Inputs "2"
DisplayOption "none"
}
Block {
BlockType "S-Function"
Name "S-Function"
Ports [1]
Position [165, 46, 220, 94]
FunctionName "animtank"
Parameters "1"
PortCounts "[]"
SFunctionModules "''"
}
Block {
BlockType Scope
Name "Scope1"
Ports [1]
Position [180, 115, 210, 145]
Floating off
Location [68, 146, 342, 467]
Open off
NumInputPorts "1"
TickLabels "on"
ZoomMode "on"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
}
Grid "on"
TimeRange "200.000000"
YMin "-2.000000"
YMax "2.000000"
SaveToWorkspace off
SaveName "ScopeData"
DataFormat "Array"
LimitDataPoints on
MaxDataPoints "5000"
Decimation "1"
SampleInput off
SampleTime "0"
}
Line {
SrcBlock "in_2"
SrcPort 1
DstBlock "Mux2"
DstPort 2
}
Line {
SrcBlock "in_1"
SrcPort 1
DstBlock "Mux2"
DstPort 1
}
Line {
SrcBlock "Mux2"
SrcPort 1
Points [0, 0]
Branch {
DstBlock "S-Function"
DstPort 1
}
Branch {
Points [0, 60]
DstBlock "Scope1"
DstPort 1
}
}
}
}
Block {
BlockType SubSystem
Name "Derivative"
Ports [1, 1]
Position [165, 116, 205, 154]
ShowPortLabels off
TreatAsAtomicUnit off
RTWSystemCode "Auto"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
System {
Name "Derivative"
Location [234, 567, 500, 708]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
AutoZoom on
Block {
BlockType Inport
Name "in_1"
Position [15, 45, 35, 65]
Port "1"
Interpolate on
}
Block {
BlockType Derivative
Name "Derivative"
Position [60, 39, 110, 71]
}
Block {
BlockType Saturate
Name "level\nchange"
Position [135, 39, 170, 71]
UpperLimit "0.1"
LowerLimit "-0.1"
LinearizeAsGain on
}
Block {
BlockType Outport
Name "out_1"
Position [200, 45, 220, 65]
Port "1"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Line {
SrcBlock "in_1"
SrcPort 1
DstBlock "Derivative"
DstPort 1
}
Line {
SrcBlock "level\nchange"
SrcPort 1
DstBlock "out_1"
DstPort 1
}
Line {
SrcBlock "Derivative"
SrcPort 1
DstBlock "level\nchange"
DstPort 1
}
}
}
Block {
BlockType Reference
Name "Fuzzy Logic\nController"
Ports [1, 1]
Position [300, 50, 360, 100]
FontName "Arial"
SourceBlock "fuzblock/Fuzzy Logic \nController"
SourceType "FIS"
fis "tank2"
}
Block {
BlockType Mux
Name "Mux1"
Ports [2, 1]
Position [245, 56, 275, 89]
Inputs "2"
DisplayOption "none"
}
Block {
BlockType Reference
Name "PID \nController"
Ports [1, 1]
Position [310, 185, 350, 225]
SourceBlock "simulink_extras/Additional\nLinear/PID Controll"
"er"
SourceType "PID Controller"
P "2"
I "0"
D "1"
}
Block {
BlockType SubSystem
Name "Set Point"
Ports [0, 1]
Position [45, 32, 85, 78]
ShowPortLabels off
TreatAsAtomicUnit off
RTWSystemCode "Auto"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
System {
Name "Set Point"
Location [228, 242, 439, 430]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
AutoZoom on
Block {
BlockType Constant
Name "Constant"
Position [45, 31, 70, 59]
Value "1"
VectorParams1D on
}
Block {
BlockType SignalGenerator
Name "Signal\nGenerator"
Position [35, 108, 80, 142]
WaveForm "square"
Amplitude "0.500000"
Frequency "0.250000"
Units "rad/sec"
VectorParams1D on
}
Block {
BlockType Sum
Name "Sum1"
Ports [2, 1]
Position [115, 60, 135, 100]
IconShape "rectangular"
Inputs "+-"
SaturateOnIntegerOverflow on
}
Block {
BlockType Outport
Name "out_1"
Position [165, 70, 185, 90]
Port "1"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Line {
SrcBlock "Sum1"
SrcPort 1
DstBlock "out_1"
DstPort 1
}
Line {
SrcBlock "Constant"
SrcPort 1
Points [15, 0; 0, 25]
DstBlock "Sum1"
DstPort 1
}
Line {
SrcBlock "Signal\nGenerator"
SrcPort 1
Points [10, 0; 0, -35]
DstBlock "Sum1"
DstPort 2
}
}
}
Block {
BlockType SubSystem
Name "Switch"
Ports [2, 1]
Position [400, 114, 445, 161]
ShowPortLabels off
TreatAsAtomicUnit off
RTWSystemCode "Auto"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
System {
Name "Switch"
Location [300, 134, 545, 301]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
AutoZoom on
Block {
BlockType Inport
Name "in_1"
Position [30, 15, 50, 35]
Port "1"
Interpolate on
}
Block {
BlockType Inport
Name "in_2"
Position [35, 110, 55, 130]
Port "2"
Interpolate on
}
Block {
BlockType Switch
Name "Switch"
Position [110, 43, 140, 97]
Threshold "0"
}
Block {
BlockType Constant
Name "const"
Position [15, 56, 55, 84]
Value "0.5"
VectorParams1D on
}
Block {
BlockType Outport
Name "out_1"
Position [170, 60, 190, 80]
Port "1"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Line {
SrcBlock "in_2"
SrcPort 1
DstBlock "Switch"
DstPort 3
}
Line {
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -