📄 motor_test.mdl
字号:
}
Block {
BlockType Mux
Inputs "4"
DisplayOption "none"
BusObject "BusObject"
NonVirtualBus off
}
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 Product
Inputs "2"
Multiplication "Element-wise(.*)"
InputSameDT on
OutDataTypeMode "Same as first input"
OutDataType "sfix(16)"
OutScaling "2^0"
LockScale off
RndMeth "Zero"
SaturateOnIntegerOverflow on
SampleTime "-1"
}
Block {
BlockType RelationalOperator
Operator ">="
InputSameDT on
LogicOutDataTypeMode "Logical (see Configuration Parameters: Optimiza"
"tion)"
LogicDataType "uint(8)"
ZeroCross on
SampleTime "-1"
}
Block {
BlockType Scope
Floating off
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 "0"
}
Block {
BlockType Selector
InputType "Vector"
IndexMode "One-based"
ElementSrc "Internal"
Elements "1"
RowSrc "Internal"
Rows "1"
ColumnSrc "Internal"
Columns "1"
InputPortWidth "-1"
IndexIsStartValue off
OutputPortSize "1"
}
Block {
BlockType "S-Function"
FunctionName "system"
SFunctionModules "''"
PortCounts "[]"
}
Block {
BlockType Sin
SineType "Time based"
TimeSource "Use simulation time"
Amplitude "1"
Bias "0"
Frequency "1"
Phase "0"
Samples "10"
Offset "0"
SampleTime "-1"
VectorParams1D on
}
Block {
BlockType Step
Time "1"
Before "0"
After "1"
SampleTime "-1"
VectorParams1D on
ZeroCross on
}
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 Switch
Criteria "u2 >= Threshold"
Threshold "0"
InputSameDT on
OutDataTypeMode "Inherit via internal rule"
RndMeth "Floor"
SaturateOnIntegerOverflow on
ZeroCross on
SampleTime "-1"
}
Block {
BlockType TransferFcn
Numerator "[1]"
Denominator "[1 2 1]"
AbsoluteTolerance "auto"
Realization "auto"
}
Block {
BlockType Trigonometry
Operator "sin"
OutputSignalType "auto"
SampleTime "-1"
}
}
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 "motor_test"
Location [9, 82, 1243, 977]
Open on
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "156"
ReportName "simulink-default.rpt"
Block {
BlockType SubSystem
Name "Asynchronous Motor1"
Ports [2, 3]
Position [510, 77, 570, 213]
FontSize 12
TreatAsAtomicUnit off
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
MaskType "Asynchronous Motor(Under dq)"
MaskDescription "Asynchronous Motor(Under dq)(By:ZhuShiwu)"
MaskPromptString "Stator resistance Rs(ohm)|Stator inductance Ls("
"H)|Rotor resistance Rr(ohm)|Rotor inductance Lr(H)|Mutual inductance Lm(H)|Pa"
"irs of poles Np()|Inertia J(kg.m^2)"
MaskStyleString "edit,edit,edit,edit,edit,edit,edit"
MaskTunableValueString "on,on,on,on,on,on,on"
MaskCallbackString "||||||"
MaskEnableString "on,on,on,on,on,on,on"
MaskVisibilityString "on,on,on,on,on,on,on"
MaskToolTipString "on,on,on,on,on,on,on"
MaskVarAliasString ",,,,,,"
MaskVariables "R1=@1;L1=@2;R2=@3;L2=@4;Lm=@5;Np=@6;J=@7;"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
MaskValueString "4.1|0.545|2.5|0.553|0.510|2|0.02"
MaskTabNameString ",,,,,,"
System {
Name "Asynchronous Motor1"
Location [-2, 82, 1249, 982]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "100"
Block {
BlockType Inport
Name "Uabc"
Position [90, 388, 120, 402]
Port "1"
IconDisplay "Port number"
LatchInput off
}
Block {
BlockType Inport
Name "TL"
Position [95, 648, 125, 662]
Port "2"
IconDisplay "Port number"
LatchInput off
}
Block {
BlockType Constant
Name "Constant"
Position [670, 250, 695, 270]
Value "0.0001"
}
Block {
BlockType Demux
Name "Demux"
Ports [1, 2]
Position [260, 401, 265, 439]
BackgroundColor "black"
ShowName off
Outputs "2"
DisplayOption "bar"
}
Block {
BlockType Gain
Name "Gain1"
Position [512, 250, 538, 280]
Orientation "down"
NamePlacement "alternate"
ShowName off
Gain "L1-Lm^2/L2"
}
Block {
BlockType Gain
Name "Gain2"
Position [555, 184, 630, 226]
ShowName off
Gain "Lm*R2/L2"
}
Block {
BlockType Gain
Name "Gain3"
Position [527, 520, 553, 555]
Orientation "up"
ShowName off
Gain "L1-Lm^2/L2"
}
Block {
BlockType Gain
Name "Gain4"
Position [685, 487, 710, 513]
Orientation "left"
NamePlacement "alternate"
ShowName off
Gain "Lm/L2"
}
Block {
BlockType Gain
Name "Gain5"
Position [570, 137, 630, 163]
Orientation "left"
NamePlacement "alternate"
ShowName off
Gain "Lm*R2/L2/L2"
}
Block {
BlockType Gain
Name "Gain6"
Position [720, 587, 750, 613]
ShowName off
Gain "Np*Lm/L2"
}
Block {
BlockType Gain
Name "Gain7"
Position [1025, 597, 1060, 623]
ShowName off
Gain "Np/J"
}
Block {
BlockType Gain
Name "Gain8"
Position [1185, 597, 1220, 623]
ShowName off
Gain "60/(2*pi*Np)"
}
Block {
BlockType Gain
Name "Gain9"
Position [622, 520, 648, 555]
Orientation "up"
ShowName off
Gain "Lm*R2/L2"
}
Block {
BlockType Integrator
Name "Integrator"
Ports [1, 1]
Position [1100, 595, 1130, 625]
ShowName off
IgnoreLimit off
}
Block {
BlockType Integrator
Name "Integrator1"
Ports [1, 1]
Position [405, 440, 435, 470]
Orientation "left"
NamePlacement "alternate"
ShowName off
IgnoreLimit off
}
Block {
BlockType Integrator
Name "Integrator3"
Ports [1, 1]
Position [935, 280, 965, 310]
ShowName off
IgnoreLimit off
}
Block {
BlockType Mux
Name "Mux1"
Ports [2, 1]
Position [1005, 49, 1020, 116]
ShowName off
Inputs "2"
}
Block {
BlockType Product
Name "Product"
Ports [2, 1]
Position [400, 372, 430, 403]
Orientation "left"
NamePlacement "alternate"
ShowName off
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
SaturateOnIntegerOverflow off
}
Block {
BlockType Product
Name "Product1"
Ports [2, 1]
Position [400, 492, 430, 523]
Orientation "left"
NamePlacement "alternate"
ShowName off
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
SaturateOnIntegerOverflow off
}
Block {
BlockType Product
Name "Product2"
Ports [2, 1]
Position [400, 287, 430, 318]
Orientation "left"
NamePlacement "alternate"
ShowName off
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
SaturateOnIntegerOverflow off
}
Block {
BlockType Product
Name "Product3"
Ports [2, 1]
Position [850, 577, 880, 608]
ShowName off
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
SaturateOnIntegerOverflow off
}
Block {
BlockType Product
Name "Product4"
Ports [2, 1]
Position [627, 425, 658, 455]
Orientation "up"
ShowName off
Inputs "*/"
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
SaturateOnIntegerOverflow off
}
Block {
BlockType Scope
Name "Scope1"
Ports [4]
Position [1195, 719, 1230, 906]
Location [5, 56, 1285, 997]
Open off
NumInputPorts "4"
ZoomMode "yonly"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
axes2 "%<SignalLabel>"
axes3 "%<SignalLabel>"
axes4 "%<SignalLabel>"
}
YMin "2.13689~2.24466~-334.853~4.75"
YMax "2.36183~2.48094~-302.963~5.25"
SaveName "ScopeData1"
DataFormat "StructureWithTime"
LimitDataPoints off
}
Block {
BlockType Sum
Name "Sum"
Ports [3, 1]
Position [375, 181, 395, 229]
ShowName off
Inputs "+++"
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
}
Block {
BlockType Sum
Name "Sum1"
Ports [2, 1]
Position [950, 583, 970, 632]
ShowName off
Inputs "+-"
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
}
Block {
BlockType Sum
Name "Sum2"
Ports [3, 1]
Position [380, 576, 400, 624]
ShowName off
Inputs "--+"
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
}
Block {
BlockType Sum
Name "Sum3"
Ports [2, 1]
Position [615, 378, 630, 407]
Orientation "left"
NamePlacement "alternate"
ShowName off
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
}
Block {
BlockType Sum
Name "Sum4"
Ports [2, 1]
Position [765, 198, 780, 227]
ShowName off
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
}
Block {
BlockType TransferFcn
Name "Transfer Fcn"
Position [445, 188, 495, 222]
Denominator "[L1-Lm^2/L2 R1+R2*Lm^2/L2/L2]"
}
Block {
BlockType TransferFcn
Name "Transfer Fcn1"
Position [665, 188, 715, 222]
ShowName off
Denominator "[1 R2/L2]"
}
Block {
BlockType TransferFcn
Name "Transfer Fcn2"
Position [445, 583, 495, 617]
ShowName off
Denominator "[L1-Lm^2/L2 R1+R2*Lm^2/L2/L2]"
}
Block {
BlockType SubSystem
Name "abc->mt"
Ports [2, 1]
Position [165, 371, 225, 469]
FontSize 12
TreatAsAtomicUnit off
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
MaskType "dq/ABC convert"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "abc->mt"
Location [2, 82, 1270, 960]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -