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

📄 pidex0.mdl

📁 关于电机的.m程序
💻 MDL
📖 第 1 页 / 共 4 页
字号:
	      ShowName		      off
	    }
	    Block {
	      BlockType		      Saturate
	      Name		      "Saturation"
	      Position		      [365, 100, 385, 120]
	      ShowName		      off
	      UpperLimit	      "sat"
	      LowerLimit	      "-sat"
	    }
	    Block {
	      BlockType		      Sum
	      Name		      "Sum"
	      Ports		      [3, 1]
	      Position		      [315, 100, 335, 120]
	      ShowName		      off
	      IconShape		      "round"
	      Inputs		      "+++"
	    }
	    Block {
	      BlockType		      Sum
	      Name		      "Sum1"
	      Ports		      [2, 1]
	      Position		      [335, 165, 355, 185]
	      Orientation	      "left"
	      ShowName		      off
	      IconShape		      "round"
	      Inputs		      "-+"
	    }
	    Block {
	      BlockType		      Switch
	      Name		      "Switch"
	      Position		      [180, 91, 210, 129]
	      InputSameDT	      off
	    }
	    Block {
	      BlockType		      Scope
	      Name		      "response"
	      Ports		      [1]
	      Position		      [440, 17, 470, 73]
	      ForegroundColor	      "darkGreen"
	      Location		      [609, 179, 1147, 491]
	      Open		      off
	      NumInputPorts	      "1"
	      ZoomMode		      "xonly"
	      List {
		ListType		AxesTitles
		axes1			"System response 1"
	      }
	      List {
		ListType		SelectedSignals
		axes1			""
	      }
	      TimeRange		      "1"
	      YMin		      "0"
	      YMax		      "0.7"
	      SaveName		      "ScopeData1"
	      DataFormat	      "StructureWithTime"
	      LimitDataPoints	      off
	    }
	    Block {
	      BlockType		      Outport
	      Name		      "c"
	      Position		      [410, 103, 440, 117]
	      InitialOutput	      "0"
	    }
	    Line {
	      SrcBlock		      "Switch"
	      SrcPort		      1
	      DstBlock		      "Integrator"
	      DstPort		      1
	    }
	    Line {
	      SrcBlock		      "Sum1"
	      SrcPort		      1
	      Points		      [-185, 0; 0, -65]
	      DstBlock		      "Switch"
	      DstPort		      2
	    }
	    Line {
	      SrcBlock		      "Constant"
	      SrcPort		      1
	      DstBlock		      "Switch"
	      DstPort		      3
	    }
	    Line {
	      SrcBlock		      "Integrator"
	      SrcPort		      1
	      Points		      [10, 0]
	      Branch {
		DstBlock		"Sum"
		DstPort			2
	      }
	      Branch {
		Points			[0, -65]
		DstBlock		"response"
		DstPort			1
	      }
	    }
	    Line {
	      SrcBlock		      "Gain"
	      SrcPort		      1
	      DstBlock		      "Switch"
	      DstPort		      1
	    }
	    Line {
	      SrcBlock		      "Saturation"
	      SrcPort		      1
	      Points		      [0, 0; 5, 0]
	      Branch {
		Points			[0, 90]
		DstBlock		"Sum1"
		DstPort			2
	      }
	      Branch {
		DstBlock		"c"
		DstPort			1
	      }
	    }
	    Line {
	      SrcBlock		      "Sum"
	      SrcPort		      1
	      Points		      [5, 0]
	      Branch {
		DstBlock		"Sum1"
		DstPort			1
	      }
	      Branch {
		DstBlock		"Saturation"
		DstPort			1
	      }
	    }
	    Line {
	      SrcBlock		      "Gain2"
	      SrcPort		      1
	      DstBlock		      "Derivative"
	      DstPort		      1
	    }
	    Line {
	      SrcBlock		      "Derivative"
	      SrcPort		      1
	      Points		      [60, 0]
	      DstBlock		      "Sum"
	      DstPort		      3
	    }
	    Line {
	      SrcBlock		      "er"
	      SrcPort		      1
	      Points		      [0, 0; 10, 0]
	      Branch {
		DstBlock		"Gain"
		DstPort			1
	      }
	      Branch {
		Points			[0, 50]
		DstBlock		"Gain2"
		DstPort			1
	      }
	      Branch {
		Points			[0, -50]
		DstBlock		"Gain1"
		DstPort			1
	      }
	    }
	    Line {
	      SrcBlock		      "Gain1"
	      SrcPort		      1
	      Points		      [200, 0]
	      DstBlock		      "Sum"
	      DstPort		      1
	    }
	    Annotation {
	      Name		      "limiter"
	      Position		      [371, 84]
	    }
	    Annotation {
	      Name		      "antiwindup action by stopping integrati"
"on"
	      Position		      [195, 81]
	    }
	  }
	}
	Block {
	  BlockType		  Sum
	  Name			  "Sum"
	  Ports			  [2, 1]
	  Position		  [90, 90, 110, 110]
	  ShowName		  off
	  IconShape		  "round"
	  Inputs		  "|+-"
	}
	Block {
	  BlockType		  SubSystem
	  Name			  "plant"
	  Ports			  [1, 1]
	  Position		  [235, 66, 345, 134]
	  BackgroundColor	  "orange"
	  ShowName		  off
	  TreatAsAtomicUnit	  off
	  MaskPromptString	  "Gain|Time constant [s]|Time delay [s]"
	  MaskStyleString	  "edit,edit,edit"
	  MaskTunableValueString  "on,on,on"
	  MaskCallbackString	  "||"
	  MaskEnableString	  "on,on,on"
	  MaskVisibilityString	  "on,on,on"
	  MaskToolTipString	  "on,on,on"
	  MaskVarAliasString	  ",,"
	  MaskVariables		  "Ka=@1;Ta=@2;Td=@3;"
	  MaskDisplay		  "disp('PLANT')"
	  MaskIconFrame		  on
	  MaskIconOpaque	  on
	  MaskIconRotate	  "none"
	  MaskIconUnits		  "autoscale"
	  MaskValueString	  "1|0.25|0.05"
	  System {
	    Name		    "plant"
	    Location		    [589, 459, 873, 569]
	    Open		    off
	    ModelBrowserVisibility  off
	    ModelBrowserWidth	    200
	    ScreenColor		    "white"
	    PaperOrientation	    "landscape"
	    PaperPositionMode	    "auto"
	    PaperType		    "usletter"
	    PaperUnits		    "inches"
	    ZoomFactor		    "100"
	    Block {
	      BlockType		      Inport
	      Name		      "In1"
	      Position		      [25, 38, 55, 52]
	      ForegroundColor	      "red"
	    }
	    Block {
	      BlockType		      TransferFcn
	      Name		      "G(s)"
	      Position		      [80, 27, 140, 63]
	      ForegroundColor	      "red"
	      Numerator		      "[Ka]"
	      Denominator	      "[Ta 1]"
	    }
	    Block {
	      BlockType		      TransportDelay
	      Name		      "Transport\nDelay"
	      Position		      [175, 30, 205, 60]
	      ForegroundColor	      "red"
	      DelayTime		      "Td"
	      BufferSize	      "2048"
	    }
	    Block {
	      BlockType		      Outport
	      Name		      "Out1"
	      Position		      [230, 38, 260, 52]
	      ForegroundColor	      "red"
	    }
	    Line {
	      SrcBlock		      "Transport\nDelay"
	      SrcPort		      1
	      DstBlock		      "Out1"
	      DstPort		      1
	    }
	    Line {
	      SrcBlock		      "In1"
	      SrcPort		      1
	      DstBlock		      "G(s)"
	      DstPort		      1
	    }
	    Line {
	      SrcBlock		      "G(s)"
	      SrcPort		      1
	      DstBlock		      "Transport\nDelay"
	      DstPort		      1
	    }
	  }
	}
	Block {
	  BlockType		  Outport
	  Name			  "Out1"
	  Position		  [410, 93, 440, 107]
	}
	Line {
	  SrcBlock		  "PID controller2"
	  SrcPort		  1
	  DstBlock		  "plant"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Sum"
	  SrcPort		  1
	  DstBlock		  "PID controller2"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "plant"
	  SrcPort		  1
	  Points		  [25, 0]
	  Branch {
	    DstBlock		    "Out1"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, 75; -275, 0]
	    DstBlock		    "Sum"
	    DstPort		    2
	  }
	}
	Line {
	  SrcBlock		  "In1"
	  SrcPort		  1
	  DstBlock		  "Sum"
	  DstPort		  1
	}
	Annotation {
	  Name			  "Kpu = 0.83\n Tu  = 11.6"
	  Position		  [435, 163]
	  FontName		  "Arial"
	  FontSize		  16
	}
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "Switch Case Action\nSubsystem3"
      Ports		      [1, 1, 0, 0, 0, 0, 0, 1]
      Position		      [425, 253, 495, 287]
      TreatAsAtomicUnit	      on
      System {
	Name			"Switch Case Action\nSubsystem3"
	Location		[582, 601, 1108, 798]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "In1"
	  Position		  [30, 93, 60, 107]
	}
	Block {
	  BlockType		  ActionPort
	  Name			  "Action Port"
	  Position		  [170, 15, 229, 43]
	  ActionType		  "case"
	}
	Block {
	  BlockType		  SubSystem
	  Name			  "PID controller3"
	  Ports			  [1, 1]
	  Position		  [150, 74, 210, 126]
	  BackgroundColor	  "yellow"
	  TreatAsAtomicUnit	  off
	  MaskDescription	  "Proportional-Integral Speed Controller"
	  MaskPromptString	  "Proportional gain (Kp)|Integral gain (Ki)|D"
"erivative gain (Kd)|Saturation limit [pu]"
	  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;Kd=@3;sat=@4;"
	  MaskDisplay		  "plot(0,0,100,100,[35,35,65],[70,30,30],[35,"
"65],[45,60])\n"
	  MaskIconFrame		  on
	  MaskIconOpaque	  on
	  MaskIconRotate	  "none"
	  MaskIconUnits		  "autoscale"
	  MaskValueString	  "0.5|0.09|0.77|inf"
	  System {
	    Name		    "PID controller3"
	    Location		    [570, 579, 991, 822]
	    Open		    off
	    ModelBrowserVisibility  off
	    ModelBrowserWidth	    200
	    ScreenColor		    "lightBlue"
	    PaperOrientation	    "landscape"
	    PaperPositionMode	    "auto"
	    PaperType		    "usletter"
	    PaperUnits		    "inches"
	    ZoomFactor		    "100"
	    Block {
	      BlockType		      Inport
	      Name		      "er"
	      Position		      [15, 73, 45, 87]
	    }
	    Block {
	      BlockType		      Gain
	      Name		      "Gain"
	      Position		      [85, 66, 110, 94]
	      ShowName		      off
	      Gain		      "Ki"
	    }
	    Block {
	      BlockType		      Gain
	      Name		      "Gain1"
	      Position		      [85, 16, 115, 44]
	      ShowName		      off
	      Gain		      "Kp"
	    }
	    Block {
	      BlockType		      Gain
	      Name		      "Gain2"
	      Position		      [85, 115, 115, 145]
	      ShowName		      off
	      Gain		      "Kd"
	    }
	    Block {
	      BlockType		      Integrator
	      Name		      "Integrator"
	      Ports		      [1, 1]
	      Position		      [140, 65, 165, 95]
	      ShowName		      off
	      LimitOutput	      on
	      UpperSaturationLimit    "sat"
	      LowerSaturationLimit    "-sat"
	    }
	    Block {
	      BlockType		      Saturate
	      Name		      "Saturation"
	      Position		      [235, 70, 255, 90]
	      ShowName		      off
	      UpperLimit	      "sat"
	      LowerLimit	      "-sat"
	    }
	    Block {
	      BlockType		      Sum
	      Name		      "Sum"
	      Ports		      [3, 1]
	      Position		      [185, 70, 205, 90]
	      ShowName		      off
	      IconShape		      "round"
	      Inputs		      "+++"
	    }
	    Block {
	      BlockType		      TransferFcn
	      Name		      "approximate\nderivative"
	      Position		      [135, 112, 185, 148]
	      Numerator		      "[1 0]"
	      Denominator	      "[1e-3 1]"
	    }
	    Block {
	      BlockType		      Outport
	      Name		      "c"
	      Position		      [270, 73, 300, 87]
	      InitialOutput	      "0"
	    }
	    Line {
	      SrcBlock		      "Gain1"
	      SrcPort		      1
	      Points		      [75, 0]
	      DstBlock		      "Sum"
	      DstPort		      1
	    }
	    Line {

⌨️ 快捷键说明

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