📄 im0623.mdl
字号:
BlockType Reference
Name "Repeating\nSequence1"
Ports [0, 1]
Position [65, 455, 95, 485]
SourceBlock "simulink/Sources/Repeating\nSequence"
SourceType "Repeating table"
ShowPortLabels on
rep_seq_t "[0 0.2 0.2 0.6 0.6 1.0 1.0 1.8]"
rep_seq_y "[120 120 100 100 80 80 100 100]"
}
Block {
BlockType SubSystem
Name "Speed\ncontroller"
Ports [1, 1]
Position [35, 186, 90, 224]
TreatAsAtomicUnit off
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
MaskHideContents off
MaskType "PI controller"
MaskDescription "Pi controller"
MaskHelp "Input: Error;\\nOutput: PI output;\\nParamemetr"
"s: PI gain (Ki),\\n Time constant (Ti),\\n Limits (LimitH, LimitL)"
MaskPromptString "Ki=|Ti=|LimitH=|LimitL="
MaskStyleString "edit,edit,edit,edit"
MaskTunableValueString "on,on,on,on"
MaskCallbackString "|||"
MaskEnableString "on,on,on,on"
MaskVisibilityString "on,on,on,on"
MaskToolTipString "on,on,on,on"
MaskVarAliasString ",,,"
MaskInitialization "Ki=@1; Ti=@2; LimitH=@3; LimitL=@4;"
MaskDisplay "disp('PI\\ncontroller')"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
MaskValueString "10|0.3|5|-5"
MaskTabNameString ",,,"
System {
Name "Speed\ncontroller"
Location [115, 95, 493, 220]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "100"
Block {
BlockType Inport
Name "Speed\nerror"
Position [15, 65, 35, 85]
IconDisplay "Port number"
}
Block {
BlockType Gain
Name "K/Ti"
Position [80, 62, 105, 88]
Gain "Ki/Ti"
}
Block {
BlockType Gain
Name "Ki"
Position [105, 12, 135, 38]
Gain "Ki"
}
Block {
BlockType SubSystem
Name "Limited\nIntegrator"
Ports [1, 1]
Position [135, 60, 175, 90]
TreatAsAtomicUnit off
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
MaskHideContents off
MaskType "Limited Integrator."
MaskDescription "Limited Integrator"
MaskHelp "Implements a limited integrator with \\nan "
"expression of the form:\\n\\nif(x<=lb and u<0) or (x>=ub and u>0)\\n xdot=0"
"\\nelse\\n xdot=u"
MaskPromptString "Lower bound:|Upper bound:|Initial condition"
":"
MaskStyleString "edit,edit,edit"
MaskTunableValueString "on,on,on"
MaskCallbackString "||"
MaskEnableString "on,on,on"
MaskVisibilityString "on,on,on"
MaskToolTipString "on,on,on"
MaskVarAliasString ",,"
MaskInitialization "lower_limit=@1;upper_limit=@2;X0=@3;"
MaskDisplay "plot(-1,-0.2,3.5,1.2,[0.05,1,2,2.9],[0,0,1,"
"1]);disp(' 1/s ')"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
MaskValueString "LimitL|LimitH|0"
MaskTabNameString ",,"
System {
Name "Limited\nIntegrator"
Location [452, 229, 1117, 789]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "100"
Block {
BlockType Inport
Name "Inport"
Position [25, 85, 45, 105]
IconDisplay "Port number"
}
Block {
BlockType Constant
Name "Constant"
Position [325, 179, 395, 201]
ShowName off
Value "upper_limit"
}
Block {
BlockType Constant
Name "Constant1"
Position [325, 345, 390, 365]
ShowName off
Value "lower_limit"
}
Block {
BlockType Constant
Name "Constant2"
Position [20, 135, 40, 155]
Value "0"
}
Block {
BlockType Constant
Name "Constant3"
Position [355, 260, 375, 280]
ShowName off
Value "0"
}
Block {
BlockType Constant
Name "Constant4"
Position [355, 425, 375, 445]
ShowName off
Value "0"
}
Block {
BlockType Integrator
Name "Integrator"
Ports [1, 1]
Position [165, 99, 200, 141]
InitialCondition "X0"
IgnoreLimit off
}
Block {
BlockType Logic
Name "Logical\nOperator"
Ports [2, 1]
Position [570, 280, 605, 315]
ShowName off
}
Block {
BlockType Logic
Name "Logical\nOperator1"
Ports [2, 1]
Position [490, 200, 525, 235]
ShowName off
Operator "OR"
}
Block {
BlockType Logic
Name "Logical\nOperator2"
Ports [2, 1]
Position [490, 360, 525, 395]
ShowName off
Operator "OR"
}
Block {
BlockType RelationalOperator
Name "Relational\noperator"
Position [415, 151, 445, 204]
ShowName off
Operator "<="
}
Block {
BlockType RelationalOperator
Name "Relational\noperator1"
Position [415, 312, 445, 368]
ShowName off
}
Block {
BlockType RelationalOperator
Name "Relational\noperator2"
Position [415, 231, 445, 284]
ShowName off
Operator "<="
}
Block {
BlockType RelationalOperator
Name "Relational\noperator3"
Position [415, 396, 445, 449]
ShowName off
}
Block {
BlockType Saturate
Name "Saturation"
Position [325, 110, 350, 130]
UpperLimit "upper_limit"
LowerLimit "lower_limit"
}
Block {
BlockType Switch
Name "Switch"
Position [110, 80, 135, 160]
Threshold "0.5"
}
Block {
BlockType Outport
Name "Outport"
Position [515, 110, 535, 130]
IconDisplay "Port number"
BusOutputAsStruct off
InitialOutput "0"
}
Line {
SrcBlock "Integrator"
SrcPort 1
Points [0, 0]
Branch {
Points [40, 0; 0, 45; 70, 0]
Branch {
DstBlock "Relational\noperator"
DstPort 1
}
Branch {
Points [0, 160]
DstBlock "Relational\noperator1"
DstPort 1
}
}
Branch {
DstBlock "Saturation"
DstPort 1
}
}
Line {
SrcBlock "Constant4"
SrcPort 1
DstBlock "Relational\noperator3"
DstPort 2
}
Line {
SrcBlock "Constant3"
SrcPort 1
DstBlock "Relational\noperator2"
DstPort 2
}
Line {
SrcBlock "Logical\nOperator2"
SrcPort 1
Points [10, 0; 0, -75]
DstBlock "Logical\nOperator"
DstPort 2
}
Line {
SrcBlock "Relational\noperator3"
SrcPort 1
Points [10, 0; 0, -40]
DstBlock "Logical\nOperator2"
DstPort 2
}
Line {
SrcBlock "Relational\noperator1"
SrcPort 1
Points [10, 0; 0, 30]
DstBlock "Logical\nOperator2"
DstPort 1
}
Line {
SrcBlock "Logical\nOperator1"
SrcPort 1
Points [10, 0; 0, 70]
DstBlock "Logical\nOperator"
DstPort 1
}
Line {
SrcBlock "Relational\noperator2"
SrcPort 1
Points [15, 0; 0, -35]
DstBlock "Logical\nOperator1"
DstPort 2
}
Line {
SrcBlock "Relational\noperator"
SrcPort 1
Points [15, 0; 0, 30]
DstBlock "Logical\nOperator1"
DstPort 1
}
Line {
SrcBlock "Constant2"
SrcPort 1
DstBlock "Switch"
DstPort 3
}
Line {
SrcBlock "Logical\nOperator"
SrcPort 1
Points [15, 0; 0, 190; -540, 0; 0, -370]
DstBlock "Switch"
DstPort 2
}
Line {
SrcBlock "Constant1"
SrcPort 1
DstBlock "Relational\noperator1"
DstPort 2
}
Line {
SrcBlock "Constant"
SrcPort 1
DstBlock "Relational\noperator"
DstPort 2
}
Line {
SrcBlock "Switch"
SrcPort 1
DstBlock "Integrator"
DstPort 1
}
Line {
SrcBlock "Inport"
SrcPort 1
Points [15, 0]
Branch {
Points [0, 150]
Branch {
Points [0, 165]
DstBlock "Relational\noperator3"
DstPort 1
}
Branch {
DstBlock "Relational\noperator2"
DstPort 1
}
}
Branch {
DstBlock "Switch"
DstPort 1
}
}
Line {
SrcBlock "Saturation"
SrcPort 1
DstBlock "Outport"
DstPort 1
}
}
}
Block {
BlockType Saturate
Name "Saturation"
Position [280, 43, 310, 67]
UpperLimit "LimitH"
LowerLimit "LimitL"
}
Block {
BlockType Sum
Name "Sum"
Ports [2, 1]
Position [230, 45, 250, 65]
}
Block {
BlockType Outport
Name "Te*"
Position [345, 45, 365, 65]
IconDisplay "Port number"
BusOutputAsStruct off
InitialOutput "0"
}
Line {
SrcBlock "K/Ti"
SrcPort 1
DstBlock "Limited\nIntegrator"
DstPort 1
}
Line {
SrcBlock "Limited\nIntegrator"
SrcPort 1
Points [25, 0; 0, -15]
DstBlock "Sum"
DstPort 2
}
Line {
SrcBlock "Sum"
SrcPort 1
DstBlock "Saturation"
DstPort 1
}
Line {
SrcBlock "Ki"
SrcPort 1
Points [65, 0; 0, 25]
DstBlock "Sum"
DstPort 1
}
Line {
SrcBlock "Saturation"
SrcPort 1
DstBlock "Te*"
DstPort 1
}
Line {
SrcBlock "Speed\nerror"
SrcPort 1
Points [0, 0; 15, 0]
Branch {
DstBlock "K/Ti"
DstPort 1
}
Branch {
Points [0, -50]
DstBlock "Ki"
DstPort 1
}
}
}
}
Block {
BlockType Step
Name "Speed\nreference1"
Position [145, 255, 175, 285]
Orientation "left"
Time "0"
Before "1200*pi/30"
After "1200*pi/30"
SampleTime "0"
}
Block {
BlockType Scope
Name "Speed (rpm)1"
Ports [1]
Position [670, 354, 700, 386]
Floating off
Location [356, 128, 968, 562]
Open off
NumInputPorts "1"
TickLabels "on"
ZoomMode "xonly"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
}
TimeRange "1"
YMin "-10"
YMax "130"
SaveName "ScopeData1"
DataFormat "Array"
LimitDataPoints off
}
Block {
BlockType Scope
Name "Speed (rpm)2"
Ports [2]
Position [890, 226, 920, 259]
Floating off
Location [121, 102, 733, 536]
Open off
NumInputPorts "2"
TickLabels "on"
ZoomMode "xonly"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
axes2 "%<SignalLabel>"
}
TimeRange "3"
YMin "-1~-1"
YMax "1~1"
SaveName "ScopeData3"
DataFormat "Array"
LimitDataPoints off
}
Block {
BlockType Scope
Name "Speed (rpm)3"
Ports [1]
Position [220, 414, 250, 446]
Floating off
Location [323, 150, 935, 584]
Open off
NumInputPorts "1"
TickLabels "on"
ZoomMode "xonly"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
}
TimeRange "1"
YMin "-0.7"
YMax "0.7"
SaveName "ScopeData9"
DataFormat "Array"
LimitDataPoints off
}
Block {
BlockType Scope
Name "Speed (rpm)4"
Ports [1]
Position [400, 344, 430, 376]
Floating off
Location [72, 128, 684, 562]
Open off
NumInputPorts "1"
TickLabels "on"
ZoomMode "xonly"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
}
TimeRange "3"
YMin "-20"
YMax "140"
SaveName "ScopeData7"
DataFormat "Array"
LimitDataPoints off
}
Block {
BlockType Scope
Name "Speed (rpm)5"
Ports [1]
Position [380, 79, 410, 111]
Floating off
Location [301, 122, 913, 556]
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -