⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 imvectrol5.mdl

📁 关于电机的.m程序
💻 MDL
📖 第 1 页 / 共 4 页
字号:
      Open		      on
      NumInputPorts	      "1"
      ZoomMode		      "yonly"
      List {
	ListType		AxesTitles
	axes1			"Currents [A]"
      }
      List {
	ListType		SelectedSignals
	axes1			""
      }
      TimeRange		      "0.8"
      YMin		      "-125"
      YMax		      "125"
      SaveName		      "ScopeData2"
      DataFormat	      "StructureWithTime"
      LimitDataPoints	      off
      SampleTime	      "5e-6"
    }
    Block {
      BlockType		      SubSystem
      Name		      "Speed controller"
      Ports		      [1, 1]
      Position		      [120, 217, 180, 273]
      NamePlacement	      "alternate"
      TreatAsAtomicUnit	      off
      MaskType		      "PI controller"
      MaskDescription	      "Proportional-Integral Speed Controller"
      MaskPromptString	      "Proportional gain (Kp)|Integral gain (Ki)|Torqu"
"e limit (N.m)|Sampling time (s)"
      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      ",,,"
      MaskVariables	      "Kp=@1;Ki=@2;Tlim=@3;Ts=@4;"
      MaskDisplay	      "plot(0,0,100,100,[35,35,65],[70,30,30],[35,65],"
"[45,60])"
      MaskIconFrame	      on
      MaskIconOpaque	      off
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      MaskValueString	      "100|5200|300|0"
      System {
	Name			"Speed controller"
	Location		[145, 61, 523, 202]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "we"
	  Position		  [35, 63, 65, 77]
	}
	Block {
	  BlockType		  Gain
	  Name			  "Gain"
	  Position		  [150, 81, 175, 109]
	  ShowName		  off
	  Gain			  "Ki"
	}
	Block {
	  BlockType		  Gain
	  Name			  "Gain1"
	  Position		  [185, 26, 215, 54]
	  ShowName		  off
	  Gain			  "Kp"
	}
	Block {
	  BlockType		  Integrator
	  Name			  "Integrator2"
	  Ports			  [1, 1]
	  Position		  [195, 80, 225, 110]
	  ShowName		  off
	  LimitOutput		  on
	  UpperSaturationLimit	  "Tlim"
	  LowerSaturationLimit	  "-Tlim"
	}
	Block {
	  BlockType		  Saturate
	  Name			  "Saturation"
	  Position		  [290, 60, 310, 80]
	  ShowName		  off
	  UpperLimit		  "Tlim"
	  LowerLimit		  "-Tlim"
	}
	Block {
	  BlockType		  Sum
	  Name			  "Sum2"
	  Ports			  [2, 1]
	  Position		  [245, 60, 265, 80]
	  ShowName		  off
	  IconShape		  "round"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Te*"
	  Position		  [325, 63, 355, 77]
	  InitialOutput		  "0"
	}
	Line {
	  SrcBlock		  "Gain1"
	  SrcPort		  1
	  Points		  [35, 0]
	  DstBlock		  "Sum2"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Gain"
	  SrcPort		  1
	  DstBlock		  "Integrator2"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Saturation"
	  SrcPort		  1
	  DstBlock		  "Te*"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "we"
	  SrcPort		  1
	  Points		  [0, 0; 55, 0]
	  Branch {
	    Points		    [0, 25]
	    DstBlock		    "Gain"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, -30]
	    DstBlock		    "Gain1"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "Sum2"
	  SrcPort		  1
	  DstBlock		  "Saturation"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Integrator2"
	  SrcPort		  1
	  Points		  [0, 0]
	  DstBlock		  "Sum2"
	  DstPort		  2
	}
      }
    }
    Block {
      BlockType		      Constant
      Name		      "Stator\nframe"
      Position		      [535, 248, 565, 272]
      Value		      "0"
    }
    Block {
      BlockType		      Sum
      Name		      "Sum"
      Ports		      [2, 1]
      Position		      [430, 210, 450, 230]
      ShowName		      off
      IconShape		      "round"
      Inputs		      "|-+"
    }
    Block {
      BlockType		      Sum
      Name		      "Sum1"
      Ports		      [2, 1]
      Position		      [80, 235, 100, 255]
      ShowName		      off
      IconShape		      "round"
      Inputs		      "|+-"
    }
    Block {
      BlockType		      Sum
      Name		      "Sum2"
      Ports		      [3, 1]
      Position		      [740, 220, 760, 240]
      ShowName		      off
      IconShape		      "round"
      Inputs		      "-+-"
    }
    Block {
      BlockType		      SubSystem
      Name		      "Theta Calculator"
      Ports		      [3, 1]
      Position		      [305, 114, 360, 176]
      NamePlacement	      "alternate"
      TreatAsAtomicUnit	      off
      System {
	Name			"Theta Calculator"
	Location		[49, 99, 533, 306]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "Iq"
	  Position		  [15, 23, 45, 37]
	}
	Block {
	  BlockType		  Inport
	  Name			  "Phir"
	  Position		  [15, 58, 45, 72]
	  Port			  "2"
	}
	Block {
	  BlockType		  Inport
	  Name			  "wm"
	  Position		  [225, 78, 255, 92]
	  Port			  "3"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn"
	  Position		  [105, 40, 265, 60]
	  ShowName		  off
	  Expr			  "34.7e-3*u[1]/(u[2]*0.1557+1e-3)"
	  Port {
	    PortNumber		    1
	    Name		    "wr"
	    TestPoint		    off
	    LinearAnalysisOutput    off
	    LinearAnalysisInput	    off
	    RTWStorageClass	    "Auto"
	    DataLogging		    off
	    DataLoggingNameMode	    "SignalName"
	    DataLoggingDecimateData off
	    DataLoggingDecimation   "2"
	    DataLoggingLimitDataPoints off
	    DataLoggingMaxPoints    "5000"
	  }
	}
	Block {
	  BlockType		  Integrator
	  Name			  "Integrator2"
	  Ports			  [1, 1]
	  Position		  [330, 55, 360, 85]
	  ShowName		  off
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux"
	  Ports			  [2, 1]
	  Position		  [70, 12, 75, 83]
	  ShowName		  off
	  Inputs		  "2"
	}
	Block {
	  BlockType		  Sum
	  Name			  "Sum"
	  Ports			  [2, 1]
	  Position		  [305, 33, 315, 102]
	  ShowName		  off
	}
	Block {
	  BlockType		  Outport
	  Name			  "theta"
	  Position		  [380, 63, 410, 77]
	  InitialOutput		  "0"
	}
	Line {
	  SrcBlock		  "Integrator2"
	  SrcPort		  1
	  DstBlock		  "theta"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Sum"
	  SrcPort		  1
	  DstBlock		  "Integrator2"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "wm"
	  SrcPort		  1
	  DstBlock		  "Sum"
	  DstPort		  2
	}
	Line {
	  Name			  "wr"
	  Labels		  [0, 1]
	  SrcBlock		  "Fcn"
	  SrcPort		  1
	  DstBlock		  "Sum"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Phir"
	  SrcPort		  1
	  DstBlock		  "Mux"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Iq"
	  SrcPort		  1
	  DstBlock		  "Mux"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Mux"
	  SrcPort		  1
	  DstBlock		  "Fcn"
	  DstPort		  1
	}
	Annotation {
	  Name			  " Theta= Electrical angle= integ ( wr + wm)"
	  Position		  [122, 124]
	}
	Annotation {
	  Name			  "wr = Rotor frequency (rad/s) = Lm *Iq / ( T"
"r  * Phir)"
	  Position		  [149, 141]
	}
	Annotation {
	  Name			  "Lm = 34.7 mH"
	  Position		  [339, 124]
	}
	Annotation {
	  Name			  "Rr=  0.228 ohms"
	  Position		  [344, 164]
	}
	Annotation {
	  Name			  "Lr = Ll'r +Lm = 0.8 +34.7= 35.5 mH"
	  Position		  [389, 144]
	}
	Annotation {
	  Name			  "wm= Rotor  speed (rad/s)"
	  Position		  [114, 156]
	}
	Annotation {
	  Name			  "Tr = Lr / Rr = 0.1557 s"
	  Position		  [354, 189]
	}
      }
    }
    Block {
      BlockType		      Step
      Name		      "Tl"
      Position		      [640, 148, 670, 172]
      ForegroundColor	      "red"
      NamePlacement	      "alternate"
      Time		      "0.6"
      After		      "200"
      SampleTime	      "0"
      Port {
	PortNumber		1
	Name			"Tl"
	TestPoint		off
	LinearAnalysisOutput	off
	LinearAnalysisInput	off
	RTWStorageClass		"Auto"
	DataLogging		off
	DataLoggingNameMode	"SignalName"
	DataLoggingDecimateData	off
	DataLoggingDecimation	"2"
	DataLoggingLimitDataPoints off
	DataLoggingMaxPoints	"5000"
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "abc2dq"
      Ports		      [2, 1]
      Position		      [440, 109, 500, 156]
      NamePlacement	      "alternate"
      TreatAsAtomicUnit	      off
      System {
	Name			"abc2dq"
	Location		[625, 529, 1023, 685]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "iabc"
	  Position		  [20, 87, 50, 103]
	}
	Block {
	  BlockType		  Inport
	  Name			  "theta"
	  Position		  [20, 42, 50, 58]
	  Port			  "2"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn"
	  Position		  [165, 22, 220, 58]
	  Expr			  "u(1)*cos(u(4))+u(2)*cos(u(4)-2*pi/3)+u(3)*c"
"os(u(4)+2*pi/3)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn1"
	  Position		  [165, 92, 220, 128]
	  Expr			  "-u(1)*sin(u(4))-u(2)*sin(u(4)-2*pi/3)-u(3)*"
"sin(u(4)+2*pi/3)"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux1"
	  Ports			  [2, 1]
	  Position		  [125, 82, 130, 133]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux3"
	  Ports			  [2, 1]
	  Position		  [125, 12, 130, 63]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux5"
	  Ports			  [2, 1]
	  Position		  [270, 45, 275, 105]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Gain
	  Name			  "d"
	  Position		  [295, 56, 325, 94]
	  ShowName		  off
	  Gain			  "2/3"
	  SaturateOnIntegerOverflow off
	}
	Block {
	  BlockType		  Outport
	  Name			  "idq"
	  Position		  [345, 68, 375, 82]
	}
	Line {
	  SrcBlock		  "Mux3"
	  SrcPort		  1
	  DstBlock		  "Fcn"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Fcn"
	  SrcPort		  1
	  Points		  [25, 0; 0, 20]
	  DstBlock		  "Mux5"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Mux5"
	  SrcPort		  1
	  DstBlock		  "d"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Mux1"
	  SrcPort		  1
	  DstBlock		  "Fcn1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Fcn1"
	  SrcPort		  1
	  Points		  [25, 0; 0, -20]
	  DstBlock		  "Mux5"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "iabc"
	  SrcPort		  1
	  Points		  [15, 0]
	  Branch {
	    DstBlock		    "Mux1"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, -70]
	    DstBlock		    "Mux3"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "theta"
	  SrcPort		  1
	  Points		  [30, 0]
	  Branch {
	    DstBlock		    "Mux3"
	    DstPort		    2
	  }
	  Branch {
	    Points		    [0, 70]
	    DstBlock		    "Mux1"
	    DstPort		    2
	  }
	}
	Line {
	  SrcBlock		  "d"
	  SrcPort		  1
	  DstBlock		  "idq"
	  DstPort		  1
	}
	Annotation {
	  Position		  [79, 10]
	}
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "dq2abc"
      Ports		      [2, 1]
      Position		      [325, 236, 385, 289]
      NamePlacement	      "alternate"
      TreatAsAtomicUnit	      off
      System {
	Name			"dq2abc"
	Location		[646, 472, 1000, 688]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "idq"
	  Position		  [20, 82, 50, 98]
	}
	Block {
	  BlockType		  Inport
	  Name			  "theta"
	  Position		  [20, 177, 50, 193]
	  Port			  "2"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn"
	  Position		  [165, 22, 220, 58]
	  Expr			  "u(1)*cos(u(3))-u(2)*sin(u(3))"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn1"
	  Position		  [165, 87, 220, 123]
	  Expr			  "u(1)*cos(u(3)-2*pi/3)-u(2)*sin(u(3)-2*pi/3)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn2"
	  Position		  [165, 157, 220, 193]
	  Expr			  "u(1)*cos(u(3)+2*pi/3)-u(2)*sin(u(3)+2*pi/3)"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux1"
	  Ports			  [2, 1]
	  Position		  [125, 77, 130, 128]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux3"
	  Ports			  [2, 1]
	  Position		  [125, 12, 130, 63]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux4"
	  Ports			  [2, 1]
	  Position		  [125, 147, 130, 198]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux5"
	  Ports			  [3, 1]
	  Position		  [270, 75, 275, 135]
	  ShowName		  off
	  Inputs		  "3"
	  DisplayOption		  "bar"
	}
	Block {

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -