📄 power_svpwm.mdl
字号:
PaperType "usletter"
PaperUnits "inches"
TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000]
TiledPageScale 1
ShowPageBoundaries off
ZoomFactor "100"
Block {
BlockType Inport
Name "RPM"
Position [30, 123, 60, 137]
IconDisplay "Port number"
}
Block {
BlockType Saturate
Name "500-to-1725\nRPM"
Position [100, 115, 130, 145]
UpperLimit "1725"
LowerLimit "500"
}
Block {
BlockType Reference
Name "Discrete\nRate Limiter"
Ports [1, 1]
Position [185, 110, 230, 150]
DialogController "POWERSYS.PowerSysDialog"
SourceBlock "powerlib_extras/Discrete \nControl Blocks/D"
"iscrete\nRate Limiter"
SourceType "Discrete Rate Limiter"
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"
R "500"
F "-500"
Vinit "1725"
Ts "Ts"
}
Block {
BlockType DiscreteIntegrator
Name "Discrete-Time\nIntegrator"
Ports [1, 1]
Position [330, 112, 370, 148]
ShowName off
IntegratorMethod "Integration: Forward Euler"
ExternalReset "none"
InitialConditionSource "internal"
SampleTime "Ts"
IgnoreLimit off
ICPrevOutput "DiscIntNeverNeededParam"
ICPrevScaledInput "DiscIntNeverNeededParam"
Port {
PortNumber 1
Name "theta"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
}
Block {
BlockType Gain
Name "Gain"
Position [275, 114, 305, 146]
ShowName off
Gain "(2*pi*60)/1725"
}
Block {
BlockType Lookup
Name "Look-Up\nTable"
Position [325, 37, 375, 73]
InputValues "[500 1725 2500]"
OutputValues "[0.29 1 1]*0.957"
Port {
PortNumber 1
Name "m"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
}
Block {
BlockType Outport
Name "m"
Position [420, 48, 450, 62]
IconDisplay "Port number"
BusOutputAsStruct off
}
Block {
BlockType Outport
Name "theta"
Position [415, 123, 445, 137]
Port "2"
IconDisplay "Port number"
BusOutputAsStruct off
}
Line {
SrcBlock "Gain"
SrcPort 1
DstBlock "Discrete-Time\nIntegrator"
DstPort 1
}
Line {
SrcBlock "Discrete\nRate Limiter"
SrcPort 1
Points [0, 0; 15, 0]
Branch {
DstBlock "Gain"
DstPort 1
}
Branch {
Points [0, -75]
DstBlock "Look-Up\nTable"
DstPort 1
}
}
Line {
Name "m"
Labels [0, 0]
SrcBlock "Look-Up\nTable"
SrcPort 1
DstBlock "m"
DstPort 1
}
Line {
SrcBlock "RPM"
SrcPort 1
DstBlock "500-to-1725\nRPM"
DstPort 1
}
Line {
Name "theta"
Labels [0, 0]
SrcBlock "Discrete-Time\nIntegrator"
SrcPort 1
DstBlock "theta"
DstPort 1
}
Line {
SrcBlock "500-to-1725\nRPM"
SrcPort 1
DstBlock "Discrete\nRate Limiter"
DstPort 1
}
Annotation {
Name "Constant V/Hz\nControl"
Position [59, 28]
FontName "Arial"
FontSize 12
}
}
}
Block {
BlockType Reference
Name "DC Supply\n(325 V)"
Ports [0, 0, 0, 0, 0, 1, 1]
Position [96, 240, 124, 285]
Orientation "up"
NamePlacement "alternate"
DialogController "POWERSYS.PowerSysDialog"
SourceBlock "powerlib/Electrical\nSources/DC Voltage Source"
SourceType "DC Voltage Source"
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"
Amplitude "325"
Measurements "None"
}
Block {
BlockType Reference
Name "Discrete SV PWM\nGenerator"
Ports [2, 1]
Position [255, 100, 320, 160]
BackgroundColor "lightBlue"
DropShadow on
DialogController "POWERSYS.PowerSysDialog"
SourceBlock "powerlib_extras/Discrete \nControl Blocks/Discr"
"ete SV PWM\nGenerator"
SourceType "Discrete SV PWM Generator"
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"
InputType "Magnitude-Angle (rad)"
SwitchingPattern "Pattern #1"
Fc "1980"
ParUref "[0.8 -30 50]"
Ts "Ts"
}
Block {
BlockType Display
Name "Frequency (Hz)"
Ports [1]
Position [445, 492, 545, 518]
NamePlacement "alternate"
FontName "Arial"
Format "bank"
Decimation "1"
Lockdown off
SampleTime "Ts*1000"
}
Block {
BlockType Goto
Name "Goto"
Position [540, 246, 560, 264]
BackgroundColor "green"
ShowName off
GotoTag "m"
TagVisibility "global"
}
Block {
BlockType Reference
Name "MOSFET\nInverter"
Ports [1, 0, 0, 0, 0, 3, 2]
Position [255, 212, 325, 298]
Orientation "left"
BackgroundColor "yellow"
DropShadow on
DialogController "POWERSYS.PowerSysDialog"
SourceBlock "powerlib/Power\nElectronics/Universal Bridge"
SourceType "Universal Bridge"
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"
Arms "3"
SnubberResistance "1e5"
SnubberCapacitance "inf"
Device "MOSFET / Diodes"
Ron "0.2e-3"
Lon "0"
ForwardVoltages "[ 0 0 ]"
ForwardVoltage "0"
GTOparameters "[ 10e-6 , 20e-6 ]"
IGBTparameters "[ 1e-6 , 2e-6 ]"
Measurements "None"
converterType "Rectifier"
}
Block {
BlockType Scope
Name "Scope1"
Ports [4]
Position [295, 428, 325, 502]
BackgroundColor "green"
Floating off
Location [657, 51, 1148, 638]
Open off
NumInputPorts "4"
ZoomMode "yonly"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
axes2 "%<SignalLabel>"
axes3 "%<SignalLabel>"
axes4 "%<SignalLabel>"
}
TimeRange "1.5"
YMin "1200~160~40~5"
YMax "1800~240~70~15"
SaveName "VI_Stator1"
DataFormat "StructureWithTime"
LimitDataPoints off
SampleInput on
SampleTime "Ts*100"
}
Block {
BlockType SubSystem
Name "Signals"
Ports [0, 6]
Position [95, 386, 155, 504]
BackgroundColor "green"
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
FunctionWithSeparateData off
MaskHideContents off
Port {
PortNumber 1
Name "Vab_Stator (V)"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
Port {
PortNumber 2
Name "Ia_Stator (A)"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
Port {
PortNumber 3
Name "wm (RPM)"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
Port {
PortNumber 4
Name "Vab (Vrms)"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
Port {
PortNumber 5
Name "Freq (Hz)"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
Port {
PortNumber 6
Name "Te (N-m)"
PropagatedSignals "Electromagnetic torque Te (N*m)"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
System {
Name "Signals"
Location [24, 252, 799, 595]
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 Gain
Name "->RPM"
Position [320, 245, 350, 275]
Gain "30/pi"
}
Block {
BlockType Gain
Name "->rms"
Position [625, 120, 655, 150]
Gain "1/sqrt(2)"
}
Block {
BlockType BusSelector
Name "Bus\nSelector"
Ports [1, 2]
Position [145, 251, 150, 289]
ShowName off
OutputSignals "Mechanical.Rotor speed (wm),Mechanical.Elec"
"tromagnetic torque Te (N*m)"
Port {
PortNumber 1
Name "<Rotor speed (wm)>"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
Port {
PortNumber 2
Name "<Electromagnetic torque Te (N*m)>"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
}
Block {
BlockType SubSystem
Name "Discrete\nPLL-Driven\n Fundamental Value"
Ports [3, 2]
Position [515, 112, 590, 198]
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
FunctionWithSeparateData off
MaskHideContents off
MaskType "Discrete PLL-Driven Fundamental Value"
MaskDescription "This discrete block computes the fundamenta"
"l value of the input signal (port In) over a running window of one cycle of a"
" specified fundamental frequency (port Freq). Input port \"Sin_Cos\" (a two-d"
"imension signal) provides the reference frame required for the computation.. "
"\n First and second outputs return respectively the magnitude and phase (in d"
"egrees relative to the PLL phase) of the fundamental.\nFor the first cycle of"
" simulation, the ouputs are held constant to the values specified by the para"
"meter \"Initial input\"."
MaskPromptString "Initial fundamental frequency (Hz):|Initial"
" input: [ Mag Phase-relative-to-PLL(degrees) ]|Sample time:"
MaskStyleString "edit,edit,edit"
MaskTunableValueString "on,on,on"
MaskCallbackString "||"
MaskEnableString "on,on,on"
MaskVisibilityString "on,on,on"
MaskToolTipString "on,on,on"
MaskVarAliasString ",,"
MaskVariables "Finit=@1;Par_Init=@2;Ts=@3;"
MaskInitialization "Real_Init=Par_Init(1)*cos(pi/180*Par_Init(2"
"));\nImag_Init=Par_Init(1)*sin(pi/180*Par_Init(2));\n\n\n"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
MaskValueString "60|[220*sqrt(2) 0]|Ts*20"
MaskTabNameString ",,"
System {
Name "Discrete\nPLL-Driven\n Fundamental Value"
Location [60, 171, 882, 542]
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 "Freq"
Position [70, 133, 100, 147]
IconDisplay "Port number"
}
Block {
BlockType Inport
Name "Sin_Cos"
Position [75, 228, 105, 242]
Port "2"
IconDisplay "Port number"
}
Block {
BlockType Inport
Name "In"
Position [75, 188, 105, 202]
Port "3"
IconDisplay "Port number"
}
Block {
BlockType Demux
Name "Demux"
Ports [1, 2]
Position [310, 196, 315, 234]
BackgroundColor "black"
ShowName off
Outputs "2"
}
Block {
BlockType Reference
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -