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

📄 testbcirobot3e_sim.mdl

📁 simulink real-time workshop for dragon12 development board from
💻 MDL
📖 第 1 页 / 共 5 页
字号:
	  ShowName		  off
	  Inputs		  "3"
	  ShowAdditionalParam	  on
	  InputSameDT		  off
	}
	Block {
	  BlockType		  RelationalOperator
	  Name			  "Relational\nOperator1"
	  Position		  [505, 47, 535, 78]
	  ShowName		  off
	  Operator		  "~="
	  InputSameDT		  off
	  LogicOutDataTypeMode	  "Specify via dialog"
	}
	Block {
	  BlockType		  Step
	  Name			  "Step"
	  Position		  [65, 70, 95, 100]
	  After			  "3"
	  SampleTime		  "0"
	}
	Block {
	  BlockType		  Step
	  Name			  "Step1"
	  Position		  [65, 115, 95, 145]
	  Time			  "2"
	  After			  "-2"
	  SampleTime		  "0"
	}
	Block {
	  BlockType		  Step
	  Name			  "Step2"
	  Position		  [65, 165, 95, 195]
	  Time			  "2.1"
	  After			  "-1"
	  SampleTime		  "0"
	}
	Block {
	  BlockType		  Step
	  Name			  "Step3"
	  Position		  [65, 215, 95, 245]
	  Time			  "4"
	  After			  "2"
	  SampleTime		  "0"
	}
	Block {
	  BlockType		  Step
	  Name			  "Step4"
	  Position		  [65, 260, 95, 290]
	  Time			  "4.2"
	  After			  "-2"
	  SampleTime		  "0"
	}
	Block {
	  BlockType		  Sum
	  Name			  "Sum"
	  Ports			  [5, 1]
	  Position		  [205, 165, 235, 215]
	  ShowName		  off
	  Inputs		  "+++++"
	  InputSameDT		  off
	  OutDataTypeMode	  "Inherit via internal rule"
	}
	Block {
	  BlockType		  ZeroOrderHold
	  Name			  "Zero-Order\nHold"
	  Position		  [760, 116, 795, 154]
	  ShowName		  off
	  SampleTime		  "0.1"
	}
	Block {
	  BlockType		  Quantizer
	  Name			  "integer"
	  Position		  [405, 175, 435, 205]
	  QuantizationInterval	  "1"
	}
	Block {
	  BlockType		  SubSystem
	  Name			  "myDLatch"
	  Ports			  [1, 1]
	  Position		  [580, 170, 645, 210]
	  NamePlacement		  "alternate"
	  TreatAsAtomicUnit	  off
	  System {
	    Name		    "myDLatch"
	    Location		    [52, 117, 528, 412]
	    Open		    off
	    ModelBrowserVisibility  off
	    ModelBrowserWidth	    200
	    ScreenColor		    "white"
	    PaperOrientation	    "landscape"
	    PaperPositionMode	    "auto"
	    PaperType		    "A4"
	    PaperUnits		    "centimeters"
	    ZoomFactor		    "100"
	    Block {
	      BlockType		      Inport
	      Name		      "In1"
	      Position		      [45, 128, 75, 142]
	    }
	    Block {
	      BlockType		      Constant
	      Name		      "Constant"
	      Position		      [105, 154, 125, 176]
	      ShowName		      off
	      Value		      "0"
	    }
	    Block {
	      BlockType		      Reference
	      Name		      "D Latch"
	      Ports		      [2, 2]
	      Position		      [225, 122, 275, 173]
	      SourceBlock	      "simulink_extras/Flip Flops/D Latch"
	      SourceType	      "DLatch"
	    }
	    Block {
	      BlockType		      RelationalOperator
	      Name		      "Relational\nOperator"
	      Position		      [160, 142, 190, 173]
	      ShowName		      off
	      Operator		      "~="
	      InputSameDT	      off
	    }
	    Block {
	      BlockType		      Scope
	      Name		      "Scope"
	      Ports		      [2]
	      Position		      [340, 50, 370, 85]
	      Location		      [188, 365, 512, 604]
	      Open		      off
	      NumInputPorts	      "2"
	      List {
		ListType		AxesTitles
		axes1			"%<SignalLabel>"
		axes2			"%<SignalLabel>"
	      }
	      List {
		ListType		SelectedSignals
		axes1			""
		axes2			""
	      }
	      YMin		      "-5~-5"
	      YMax		      "5~5"
	      SaveName		      "ScopeData3"
	      DataFormat	      "StructureWithTime"
	    }
	    Block {
	      BlockType		      Terminator
	      Name		      "Terminator"
	      Position		      [320, 150, 340, 170]
	      ShowName		      off
	    }
	    Block {
	      BlockType		      Outport
	      Name		      "Out1"
	      Position		      [360, 128, 390, 142]
	    }
	    Line {
	      SrcBlock		      "D Latch"
	      SrcPort		      2
	      DstBlock		      "Terminator"
	      DstPort		      1
	    }
	    Line {
	      SrcBlock		      "D Latch"
	      SrcPort		      1
	      Points		      [20, 0]
	      Branch {
		DstBlock		"Out1"
		DstPort			1
	      }
	      Branch {
		Points			[0, -60]
		DstBlock		"Scope"
		DstPort			2
	      }
	    }
	    Line {
	      SrcBlock		      "In1"
	      SrcPort		      1
	      Points		      [0, 0; 55, 0]
	      Branch {
		Points			[0, 15]
		DstBlock		"Relational\nOperator"
		DstPort			1
	      }
	      Branch {
		Points			[65, 0]
		Branch {
		  DstBlock		  "D Latch"
		  DstPort		  1
		}
		Branch {
		  Points		  [0, -75]
		  DstBlock		  "Scope"
		  DstPort		  1
		}
	      }
	    }
	    Line {
	      SrcBlock		      "Constant"
	      SrcPort		      1
	      DstBlock		      "Relational\nOperator"
	      DstPort		      2
	    }
	    Line {
	      SrcBlock		      "Relational\nOperator"
	      SrcPort		      1
	      DstBlock		      "D Latch"
	      DstPort		      2
	    }
	  }
	}
	Block {
	  BlockType		  Outport
	  Name			  "left"
	  Position		  [890, 33, 920, 47]
	}
	Block {
	  BlockType		  Outport
	  Name			  "dir_L"
	  Position		  [890, 223, 920, 237]
	  Port			  "2"
	}
	Block {
	  BlockType		  Outport
	  Name			  "right"
	  Position		  [890, 83, 920, 97]
	  Port			  "3"
	}
	Block {
	  BlockType		  Outport
	  Name			  "dir_R"
	  Position		  [890, 258, 920, 272]
	  Port			  "4"
	}
	Line {
	  SrcBlock		  "0 ... 3"
	  SrcPort		  1
	  DstBlock		  "integer"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  " left "
	  SrcPort		  1
	  DstBlock		  "Multiport\nSwitch1"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  " right "
	  SrcPort		  1
	  DstBlock		  "Multiport\nSwitch1"
	  DstPort		  3
	}
	Line {
	  SrcBlock		  " straight "
	  SrcPort		  1
	  DstBlock		  "Multiport\nSwitch1"
	  DstPort		  4
	}
	Line {
	  SrcBlock		  "Multiport\nSwitch1"
	  SrcPort		  1
	  DstBlock		  "Demux1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Demux1"
	  SrcPort		  1
	  DstBlock		  "Data Type Conversion2"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Demux1"
	  SrcPort		  2
	  DstBlock		  "Data Type Conversion3"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "1 ... 3"
	  SrcPort		  1
	  DstBlock		  "Multiport\nSwitch1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Data Type Conversion2"
	  SrcPort		  1
	  DstBlock		  "dir_L"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Data Type Conversion3"
	  SrcPort		  1
	  DstBlock		  "dir_R"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "myDLatch"
	  SrcPort		  1
	  DstBlock		  "1 ... 3"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Sum"
	  SrcPort		  1
	  DstBlock		  "0 ... 3"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "integer"
	  SrcPort		  1
	  Points		  [35, 0]
	  Branch {
	    DstBlock		    "myDLatch"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, 25]
	    DstBlock		    "Goto6"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, -120]
	    DstBlock		    "Relational\nOperator1"
	    DstPort		    2
	  }
	}
	Line {
	  SrcBlock		  "Step"
	  SrcPort		  1
	  Points		  [65, 0; 0, 85]
	  DstBlock		  "Sum"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Step1"
	  SrcPort		  1
	  Points		  [50, 0; 0, 50]
	  DstBlock		  "Sum"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Step2"
	  SrcPort		  1
	  Points		  [35, 0; 0, 10]
	  DstBlock		  "Sum"
	  DstPort		  3
	}
	Line {
	  SrcBlock		  "Step3"
	  SrcPort		  1
	  Points		  [30, 0; 0, -30]
	  DstBlock		  "Sum"
	  DstPort		  4
	}
	Line {
	  SrcBlock		  "Step4"
	  SrcPort		  1
	  Points		  [65, 0; 0, -65]
	  DstBlock		  "Sum"
	  DstPort		  5
	}
	Line {
	  SrcBlock		  "Constant1"
	  SrcPort		  1
	  DstBlock		  "Relational\nOperator1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Data Type Conversion"
	  SrcPort		  1
	  DstBlock		  "left"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Data Type Conversion1"
	  SrcPort		  1
	  DstBlock		  "right"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Relational\nOperator1"
	  SrcPort		  1
	  Points		  [0, 0; 85, 0]
	  Branch {
	    Points		    [0, -25]
	    DstBlock		    "Data Type Conversion"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, 25; 110, 0]
	    Branch {
	      DstBlock		      "Data Type Conversion1"
	      DstPort		      1
	    }
	    Branch {
	      Points		      [0, 45]
	      DstBlock		      "Zero-Order\nHold"
	      DstPort		      1
	    }
	  }
	}
	Line {
	  SrcBlock		  "Zero-Order\nHold"
	  SrcPort		  1
	  DstBlock		  "Display1"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      From
      Name		      "From"
      Position		      [75, 488, 140, 502]
      BackgroundColor	      "red"
      ShowName		      off
      CloseFcn		      "tagdialog Close"
      GotoTag		      "mot_ctrl"
      Port {
	PortNumber		1
	Name			"motor ctrl"
	TestPoint		off
	LinearAnalysisOutput	off
	LinearAnalysisInput	off
	RTWStorageClass		"Auto"
	DataLogging		off
	DataLoggingNameMode	"SignalName"
	DataLoggingDecimateData	off
	DataLoggingDecimation	"2"
	DataLoggingLimitDataPoints off
	DataLoggingMaxPoints	"5000"
      }
    }
    Block {
      BlockType		      From
      Name		      "From1"
      Position		      [75, 428, 140, 442]
      BackgroundColor	      "red"
      ShowName		      off
      CloseFcn		      "tagdialog Close"
      GotoTag		      "pulse_right"
      Port {
	PortNumber		1
	Name			"pulse right"
	TestPoint		off
	LinearAnalysisOutput	off
	LinearAnalysisInput	off
	RTWStorageClass		"Auto"
	DataLogging		off
	DataLoggingNameMode	"SignalName"
	DataLoggingDecimateData	off
	DataLoggingDecimation	"2"
	DataLoggingLimitDataPoints off
	DataLoggingMaxPoints	"5000"
      }
    }
    Block {
      BlockType		      From
      Name		      "From3"
      Position		      [75, 388, 140, 402]
      BackgroundColor	      "red"
      ShowName		      off
      CloseFcn		      "tagdialog Close"
      GotoTag		      "command"
      Port {
	PortNumber		1
	Name			"command"
	TestPoint		off
	LinearAnalysisOutput	off
	LinearAnalysisInput	off
	RTWStorageClass		"Auto"
	DataLogging		off
	DataLoggingNameMode	"SignalName"
	DataLoggingDecimateData	off
	DataLoggingDecimation	"2"
	DataLoggingLimitDataPoints off
	DataLoggingMaxPoints	"5000"
      }
    }
    Block {
      BlockType		      From
      Name		      "From4"
      Position		      [75, 408, 140, 422]
      BackgroundColor	      "red"
      ShowName		      off
      CloseFcn		      "tagdialog Close"
      GotoTag		      "pulse_left"
      Port {
	PortNumber		1
	Name			"pulse left"
	TestPoint		off
	LinearAnalysisOutput	off
	LinearAnalysisInput	off
	RTWStorageClass		"Auto"
	DataLogging		off
	DataLoggingNameMode	"SignalName"
	DataLoggingDecimateData	off
	DataLoggingDecimation	"2"
	DataLoggingLimitDataPoints off
	DataLoggingMaxPoints	"5000"
      }
    }
    Block {
      BlockType		      From
      Name		      "From5"
      Position		      [75, 448, 140, 462]
      BackgroundColor	      "red"
      ShowName		      off
      CloseFcn		      "tagdialog Close"
      GotoTag		      "dir_left"
      Port {
	PortNumber		1
	Name			"dir left"
	TestPoint		off
	LinearAnalysisOutput	off
	LinearAnalysisInput	off
	RTWStorageClass		"Auto"
	DataLogging		off
	DataLoggingNameMode	"SignalName"
	DataLoggingDecimateData	off
	DataLoggingDecimation	"2"
	DataLoggingLimitDataPoints off
	DataLoggingMaxPoints	"5000"
      }
    }

⌨️ 快捷键说明

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