📄 svpwm.mdl
字号:
Block {
BlockType Constant
Value "1"
VectorParams1D on
SamplingMode "Sample based"
OutMin "[]"
OutMax "[]"
OutDataTypeMode "Inherit from 'Constant value'"
OutDataType "fixdt(1,16,0)"
ConRadixGroup "Use specified scaling"
OutScaling "[]"
SampleTime "inf"
FramePeriod "inf"
}
Block {
BlockType Lookup
InputValues "[-4:5]"
Table " rand(1,10)-0.5"
LookUpMeth "Interpolation-Extrapolation"
OutMin "[]"
OutMax "[]"
OutDataTypeMode "Same as input"
OutDataType "fixdt(1,16,0)"
OutScaling "[]"
LockScale off
RndMeth "Floor"
SaturateOnIntegerOverflow on
SampleTime "-1"
LUTDesignTableMode "Redesign Table"
LUTDesignDataSource "Block Dialog"
LUTDesignFunctionName "sqrt(x)"
LUTDesignUseExistingBP on
LUTDesignRelError "0.01"
LUTDesignAbsError "1e-6"
}
Block {
BlockType RelationalOperator
Operator ">="
InputSameDT on
LogicOutDataTypeMode "Logical (see Configuration Parameters: Optimization)"
LogicDataType "uint(8)"
ZeroCross on
SampleTime "-1"
}
Block {
BlockType Saturate
UpperLimit "0.5"
LowerLimit "-0.5"
LinearizeAsGain on
ZeroCross on
SampleTime "-1"
OutMin "[]"
OutMax "[]"
OutDataTypeMode "Same as input"
OutDataType "fixdt(1,16,0)"
OutScaling "[]"
LockScale off
RndMeth "Floor"
}
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 Trigonometry
Operator "sin"
OutputSignalType "auto"
SampleTime "-1"
}
}
AnnotationDefaults {
HorizontalAlignment "center"
VerticalAlignment "middle"
ForegroundColor "black"
BackgroundColor "white"
DropShadow off
FontName "Arial"
FontSize 10
FontWeight "normal"
FontAngle "normal"
UseDisplayTextAsClickCallback off
}
LineDefaults {
FontName "Arial"
FontSize 9
FontWeight "normal"
FontAngle "normal"
}
System {
Name "Svpwm"
Location [2, 78, 1014, 725]
Open on
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000]
TiledPageScale 1
ShowPageBoundaries off
ZoomFactor "100"
ReportName "simulink-default.rpt"
Block {
BlockType Reference
Name "DC Supply\n(300 V)"
Ports [0, 0, 0, 0, 0, 1, 1]
Position [366, 235, 394, 280]
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 "300"
Measurements "None"
}
Block {
BlockType SubSystem
Name "Embedded\nMATLAB Function1"
Ports [3, 2]
Position [200, 116, 270, 164]
PermitHierarchicalResolution "ExplicitOnly"
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
FunctionWithSeparateData off
Array {
Type "Handle"
Dimension 0
PropName "AvailSigsLoadSave"
}
MaskType "Stateflow"
MaskDescription "Embedded MATLAB block"
MaskDisplay "disp('fcn');"
MaskSelfModifiable on
MaskIconFrame on
MaskIconOpaque off
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "Embedded\nMATLAB Function1"
Location [257, 457, 812, 717]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000]
TiledPageScale 1
ShowPageBoundaries off
ZoomFactor "100"
Block {
BlockType Inport
Name "Ua"
Position [20, 101, 40, 119]
IconDisplay "Port number"
OutDataType "sfix(16)"
OutScaling "2^0"
}
Block {
BlockType Inport
Name "Ub"
Position [20, 136, 40, 154]
Port "2"
IconDisplay "Port number"
OutDataType "sfix(16)"
OutScaling "2^0"
}
Block {
BlockType Inport
Name "Uc"
Position [20, 171, 40, 189]
Port "3"
IconDisplay "Port number"
OutDataType "sfix(16)"
OutScaling "2^0"
}
Block {
BlockType Demux
Name " Demux "
Ports [1, 1]
Position [270, 180, 320, 220]
Outputs "1"
}
Block {
BlockType "S-Function"
Name " SFunction "
Tag "Stateflow S-Function Svpwm 7"
Ports [3, 3]
Position [180, 100, 230, 180]
FunctionName "sf_sfun"
PortCounts "[3 3]"
EnableBusSupport on
Port {
PortNumber 2
Name "Ualpha"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
Port {
PortNumber 3
Name "Ubeta"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
}
Block {
BlockType Terminator
Name " Terminator "
Position [460, 191, 480, 209]
}
Block {
BlockType Outport
Name "Ualpha"
Position [460, 101, 480, 119]
IconDisplay "Port number"
OutDataType "sfix(16)"
OutScaling "2^0"
}
Block {
BlockType Outport
Name "Ubeta"
Position [460, 136, 480, 154]
Port "2"
IconDisplay "Port number"
OutDataType "sfix(16)"
OutScaling "2^0"
}
Line {
SrcBlock " SFunction "
SrcPort 1
Points [20, 0]
DstBlock " Demux "
DstPort 1
}
Line {
SrcBlock " Demux "
SrcPort 1
DstBlock " Terminator "
DstPort 1
}
Line {
SrcBlock "Ua"
SrcPort 1
DstBlock " SFunction "
DstPort 1
}
Line {
SrcBlock "Ub"
SrcPort 1
Points [120, 0]
DstBlock " SFunction "
DstPort 2
}
Line {
SrcBlock "Uc"
SrcPort 1
DstBlock " SFunction "
DstPort 3
}
Line {
Name "Ualpha"
Labels [0, 0]
SrcBlock " SFunction "
SrcPort 2
DstBlock "Ualpha"
DstPort 1
}
Line {
Name "Ubeta"
Labels [0, 0]
SrcBlock " SFunction "
SrcPort 3
DstBlock "Ubeta"
DstPort 1
}
}
}
Block {
BlockType Display
Name "Frequency (Hz)"
Ports [1]
Position [715, 487, 815, 513]
NamePlacement "alternate"
Format "bank"
Decimation "1"
Lockdown off
SampleTime "Ts*1000"
}
Block {
BlockType Goto
Name "Goto"
Position [820, 241, 840, 259]
BackgroundColor "green"
ShowName off
GotoTag "m"
TagVisibility "global"
}
Block {
BlockType Reference
Name "IBGT Inverter"
Ports [1, 0, 0, 0, 0, 3, 2]
Position [465, 215, 530, 305]
Orientation "left"
BackgroundColor "yellow"
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 "IGBT / Diodes"
Ron "1e-3"
Lon "0"
ForwardVoltages "[ 1 0.8 ]"
ForwardVoltage "0"
GTOparameters "[ 10e-6 , 20e-6 ]"
IGBTparameters "[ 1e-6 , 2e-6 ]"
Measurements "UAB UBC UCA UDC voltages"
converterType "Rectifier"
}
Block {
BlockType Reference
Name "Permanent Magnet\nSynchronous Machine"
Ports [1, 1, 0, 0, 0, 3]
Position [715, 213, 800, 287]
DialogController "POWERSYS.PowerSysDialog"
FontSize 11
SourceBlock "powerlib/Machines/Permanent Magnet\nSynchronous Machine"
SourceType "Permanent Magnet Synchronous Machine"
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"
FluxDistribution "Sinusoidal"
MechanicalLoad "Torque Tm"
PresetModel "No"
ShowDetailedParameters on
Resistance "2.88"
Inductance "8.5e-3"
dqInductances "[8.5e-3 8.5e-3]"
Flux "0.175"
Flat "120"
Mechanical "[8e-4 0 4]"
PolePairs "4"
}
Block {
BlockType Scope
Name "Scope1"
Ports [4]
Position [580, 408, 610, 482]
BackgroundColor "green"
Floating off
Location [408, 112, 899, 699]
Open off
NumInputPorts "4"
ZoomMode "yonly"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
axes2 "%<SignalLabel>"
axes3 "%<SignalLabel>"
axes4 "%<SignalLabel>"
}
TimeRange "0.6 "
YMin "300~160~40~5"
YMax "575~240~70~15"
SaveName "VI_Stator1"
DataFormat "StructureWithTime"
LimitDataPoints off
SampleInput on
SampleTime "Ts*100"
}
Block {
BlockType Scope
Name "Scope2"
Ports [1]
Position [415, 479, 445, 511]
Floating off
Location [5, 48, 1029, 741]
Open off
NumInputPorts "1"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
}
DataFormat "StructureWithTime"
SampleTime "0"
}
Block {
BlockType SubSystem
Name "Signals"
Ports [0, 7]
Position [260, 376, 320, 494]
BackgroundColor "green"
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
FunctionWithSeparateData off
Port {
PortNumber 1
Name "Vab_Stator (V)"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
Port {
PortNumber 2
Name "Ia_Stator (A)"
RTWStorageClass "Auto"
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -