📄 sim9.mdl
字号:
RTWCAPIParams off
RTWCAPIStates off
GenerateASAP2 off
}
PropName "Components"
}
}
PropName "Components"
}
Name "Configuration"
SimulationMode "normal"
CurrentDlgPage "Solver"
}
PropName "ConfigurationSets"
}
Simulink.ConfigSet {
$PropName "ActiveConfigurationSet"
$ObjectID 1
}
BlockDefaults {
Orientation "right"
ForegroundColor "black"
BackgroundColor "white"
DropShadow off
NamePlacement "normal"
FontName "Helvetica"
FontSize 10
FontWeight "normal"
FontAngle "normal"
ShowName on
}
BlockParameterDefaults {
Block {
BlockType Constant
Value "1"
VectorParams1D on
OutDataTypeMode "Inherit from 'Constant value'"
OutDataType "sfix(16)"
ConRadixGroup "Use specified scaling"
OutScaling "2^0"
SampleTime "inf"
}
Block {
BlockType Display
Format "short"
Decimation "10"
Floating off
SampleTime "-1"
}
Block {
BlockType Inport
BusObject "BusObject"
BusOutputAsStruct off
PortDimensions "-1"
SampleTime "-1"
DataType "auto"
OutDataType "sfix(16)"
OutScaling "2^0"
SignalType "auto"
SamplingMode "auto"
Interpolate on
}
Block {
BlockType Memory
X0 "0"
InheritSampleTime off
LinearizeMemory off
StateMustResolveToSignalObject off
RTWStateStorageClass "Auto"
}
Block {
BlockType Outport
Port "1"
BusObject "BusObject"
BusOutputAsStruct off
PortDimensions "-1"
SampleTime "-1"
DataType "auto"
OutDataType "sfix(16)"
OutScaling "2^0"
SignalType "auto"
SamplingMode "auto"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType RelationalOperator
Operator ">="
InputSameDT on
LogicOutDataTypeMode "Logical (see Configuration Parameters: Optimiza"
"tion)"
LogicDataType "uint(8)"
ZeroCross on
SampleTime "-1"
}
Block {
BlockType SubSystem
ShowPortLabels on
Permissions "ReadWrite"
PermitHierarchicalResolution "All"
SystemSampleTime "-1"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
SimViewingDevice off
DataTypeOverride "UseLocalSettings"
MinMaxOverflowLogging "UseLocalSettings"
}
Block {
BlockType Sum
IconShape "rectangular"
Inputs "++"
InputSameDT on
OutDataTypeMode "Same as first input"
OutDataType "sfix(16)"
OutScaling "2^0"
LockScale off
RndMeth "Floor"
SaturateOnIntegerOverflow on
SampleTime "-1"
}
Block {
BlockType WhileIterator
MaxIters "5"
WhileBlockType "while"
ResetStates "held"
ShowIterationPort off
OutputDataType "int32"
}
}
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 "Sim9"
Location [149, 104, 881, 441]
Open on
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "100"
ReportName "simulink-default.rpt"
Block {
BlockType Constant
Name "Constant"
Position [80, 77, 120, 123]
BackgroundColor "magenta"
Value "300"
}
Block {
BlockType Constant
Name "Constant1"
Position [80, 169, 120, 211]
BackgroundColor "magenta"
Value "0"
}
Block {
BlockType Display
Name "Number"
Ports [1]
Position [550, 91, 625, 139]
BackgroundColor "lightBlue"
FontSize 10
Decimation "1"
}
Block {
BlockType RelationalOperator
Name "Relational\nOperator"
Position [185, 161, 220, 199]
BackgroundColor "cyan"
Operator ">"
InputSameDT off
LogicOutDataTypeMode "Boolean"
}
Block {
BlockType SubSystem
Name "While \nSubsystem"
Ports [2, 1]
Position [275, 86, 390, 139]
BackgroundColor "green"
FontSize 10
TreatAsAtomicUnit on
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
System {
Name "While \nSubsystem"
Location [281, 147, 835, 484]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "100"
Block {
BlockType Inport
Name "In1"
Position [290, 227, 340, 253]
Orientation "left"
BackgroundColor "green"
Port "1"
IconDisplay "Port number"
LatchInput off
}
Block {
BlockType Inport
Name "IC"
Position [40, 104, 80, 126]
BackgroundColor "green"
Port "2"
IconDisplay "Port number"
LatchInput off
}
Block {
BlockType Memory
Name "Memory"
Position [330, 147, 365, 183]
Orientation "left"
BackgroundColor "yellow"
InheritSampleTime on
}
Block {
BlockType RelationalOperator
Name "Relational\nOperator"
Position [175, 204, 220, 251]
Orientation "left"
BackgroundColor "lightBlue"
Operator "<="
InputSameDT off
LogicOutDataTypeMode "Boolean"
}
Block {
BlockType Sum
Name "Sum"
Ports [2, 1]
Position [285, 85, 325, 115]
BackgroundColor "cyan"
ShowName off
IconShape "round"
Inputs "|++"
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
SaturateOnIntegerOverflow off
}
Block {
BlockType WhileIterator
Name "While Iterator"
Ports [2, 1]
Position [125, 68, 235, 132]
BackgroundColor "magenta"
MaxIters "-1"
ResetStates "reset"
ShowIterationPort on
OutputDataType "double"
}
Block {
BlockType Outport
Name "Out1"
Position [425, 30, 470, 50]
BackgroundColor "green"
IconDisplay "Port number"
BusOutputAsStruct off
}
Line {
SrcBlock "IC"
SrcPort 1
DstBlock "While Iterator"
DstPort 2
}
Line {
SrcBlock "Relational\nOperator"
SrcPort 1
Points [-140, 0; 0, -145]
DstBlock "While Iterator"
DstPort 1
}
Line {
SrcBlock "In1"
SrcPort 1
DstBlock "Relational\nOperator"
DstPort 2
}
Line {
Labels [1, 0]
SrcBlock "Sum"
SrcPort 1
Points [65, 0]
Branch {
Points [60, 0; 0, 115]
DstBlock "Relational\nOperator"
DstPort 1
}
Branch {
Points [0, 65]
DstBlock "Memory"
DstPort 1
}
}
Line {
SrcBlock "While Iterator"
SrcPort 1
Points [5, 0]
Branch {
DstBlock "Sum"
DstPort 1
}
Branch {
Points [0, -60]
DstBlock "Out1"
DstPort 1
}
}
Line {
SrcBlock "Memory"
SrcPort 1
Points [-20, 0]
DstBlock "Sum"
DstPort 2
}
}
}
Block {
BlockType Outport
Name "Out1"
Position [465, 190, 510, 210]
BackgroundColor "cyan"
IconDisplay "Port number"
BusOutputAsStruct off
}
Line {
SrcBlock "Constant"
SrcPort 1
Points [0, 0; 20, 0]
Branch {
Points [0, 70]
DstBlock "Relational\nOperator"
DstPort 1
}
Branch {
DstBlock "While \nSubsystem"
DstPort 1
}
}
Line {
SrcBlock "Constant1"
SrcPort 1
DstBlock "Relational\nOperator"
DstPort 2
}
Line {
SrcBlock "Relational\nOperator"
SrcPort 1
Points [20, 0; 0, -55]
DstBlock "While \nSubsystem"
DstPort 2
}
Line {
SrcBlock "While \nSubsystem"
SrcPort 1
Points [0, 0; 30, 0]
Branch {
Points [0, 85]
DstBlock "Out1"
DstPort 1
}
Branch {
DstBlock "Number"
DstPort 1
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -