📄 powerwindowlib.mdl
字号:
Ports [2, 1]
Position [55, 117, 120, 168]
ShowPortLabels on
TreatAsAtomicUnit off
RTWSystemCode "Auto"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
System {
Name "object"
Location [195, 206, 745, 493]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "automatic"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "100"
Block {
BlockType Inport
Name "position"
Position [20, 47, 50, 63]
Port "1"
LatchInput off
Interpolate on
}
Block {
BlockType Inport
Name "velocity"
Position [25, 222, 55, 238]
Port "2"
LatchInput off
Interpolate on
}
Block {
BlockType Constant
Name "Constant1"
Position [265, 16, 285, 34]
ShowName off
Value "1"
VectorParams1D on
}
Block {
BlockType Constant
Name "Constant2"
Position [290, 81, 310, 99]
ShowName off
Value "0"
VectorParams1D on
}
Block {
BlockType Constant
Name "Constant3"
Position [295, 196, 315, 214]
ShowName off
Value "0"
VectorParams1D on
}
Block {
BlockType Constant
Name "Constant5"
Position [80, 59, 115, 81]
ShowName off
Value "0.30"
VectorParams1D on
}
Block {
BlockType From
Name "From4"
Position [85, 15, 180, 35]
ShowName off
CloseFcn "tagdialog Close"
GotoTag "object_present"
}
Block {
BlockType Logic
Name "Logical\nOperator"
Ports [2, 1]
Position [220, 42, 250, 73]
Operator "AND"
Inputs "2"
}
Block {
BlockType MultiPortSwitch
Name "Multiport\nSwitch"
Ports [3, 1]
Position [340, 50, 375, 130]
Inputs "2"
}
Block {
BlockType MultiPortSwitch
Name "Multiport\nSwitch1"
Ports [3, 1]
Position [340, 165, 375, 245]
Inputs "2"
}
Block {
BlockType Sum
Name "Sum1"
Ports [2, 1]
Position [295, 55, 315, 75]
ShowName off
IconShape "round"
Inputs "++|"
SaturateOnIntegerOverflow on
}
Block {
BlockType Sum
Name "Sum2"
Ports [2, 1]
Position [155, 105, 175, 125]
ShowName off
IconShape "round"
Inputs "|-+"
SaturateOnIntegerOverflow on
}
Block {
BlockType Sum
Name "Sum3"
Ports [2, 1]
Position [455, 80, 475, 100]
ShowName off
IconShape "round"
Inputs "|++"
SaturateOnIntegerOverflow on
}
Block {
BlockType Gain
Name "damper"
Position [405, 190, 435, 220]
Gain "500"
Multiplication "Element-wise(K.*u)"
SaturateOnIntegerOverflow on
}
Block {
BlockType RelationalOperator
Name "obstruction1"
Position [160, 47, 190, 78]
Operator ">"
}
Block {
BlockType Gain
Name "spring"
Position [400, 75, 430, 105]
Gain "50"
Multiplication "Element-wise(K.*u)"
SaturateOnIntegerOverflow on
}
Block {
BlockType Outport
Name "torque"
Position [510, 83, 540, 97]
Port "1"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Line {
SrcBlock "spring"
SrcPort 1
DstBlock "Sum3"
DstPort 1
}
Line {
SrcBlock "Sum3"
SrcPort 1
DstBlock "torque"
DstPort 1
}
Line {
SrcBlock "damper"
SrcPort 1
Points [25, 0]
DstBlock "Sum3"
DstPort 2
}
Line {
SrcBlock "Constant5"
SrcPort 1
Points [0, 0; 10, 0]
Branch {
DstBlock "obstruction1"
DstPort 2
}
Branch {
Points [0, 45]
DstBlock "Sum2"
DstPort 1
}
}
Line {
SrcBlock "Sum1"
SrcPort 1
Points [0, 0]
Branch {
DstBlock "Multiport\nSwitch"
DstPort 1
}
Branch {
Points [0, 115]
DstBlock "Multiport\nSwitch1"
DstPort 1
}
}
Line {
SrcBlock "Constant2"
SrcPort 1
DstBlock "Multiport\nSwitch"
DstPort 2
}
Line {
SrcBlock "Sum2"
SrcPort 1
DstBlock "Multiport\nSwitch"
DstPort 3
}
Line {
SrcBlock "Constant1"
SrcPort 1
Points [15, 0]
DstBlock "Sum1"
DstPort 1
}
Line {
SrcBlock "position"
SrcPort 1
Points [0, 0; 10, 0]
Branch {
DstBlock "obstruction1"
DstPort 1
}
Branch {
Points [0, 85]
DstBlock "Sum2"
DstPort 2
}
}
Line {
SrcBlock "Multiport\nSwitch"
SrcPort 1
DstBlock "spring"
DstPort 1
}
Line {
SrcBlock "Constant3"
SrcPort 1
DstBlock "Multiport\nSwitch1"
DstPort 2
}
Line {
SrcBlock "velocity"
SrcPort 1
DstBlock "Multiport\nSwitch1"
DstPort 3
}
Line {
SrcBlock "Multiport\nSwitch1"
SrcPort 1
DstBlock "damper"
DstPort 1
}
Line {
SrcBlock "obstruction1"
SrcPort 1
DstBlock "Logical\nOperator"
DstPort 2
}
Line {
SrcBlock "Logical\nOperator"
SrcPort 1
Points [10, 0; 0, 5]
DstBlock "Sum1"
DstPort 2
}
Line {
SrcBlock "From4"
SrcPort 1
Points [10, 0; 0, 25]
DstBlock "Logical\nOperator"
DstPort 1
}
}
}
Block {
BlockType SubSystem
Name "window"
Ports [2, 3]
Position [165, 37, 230, 93]
ForegroundColor "red"
ShowPortLabels on
TreatAsAtomicUnit off
RTWSystemCode "Auto"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
System {
Name "window"
Location [256, 78, 993, 632]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "100"
Block {
BlockType Inport
Name "wi"
Position [15, 423, 45, 437]
Port "1"
LatchInput off
Interpolate on
}
Block {
BlockType Inport
Name "Fx"
Position [15, 498, 45, 512]
Port "2"
LatchInput off
Interpolate on
}
Block {
BlockType SubSystem
Name "Atomic Subsystem"
Ports []
Position [400, 236, 575, 499]
ForegroundColor "white"
ShowName off
ShowPortLabels on
TreatAsAtomicUnit on
RTWSystemCode "Auto"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
MaskDisplay "image(imread('window1c.jpg'))"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "Atomic Subsystem"
Location [489, 302, 987, 602]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
}
}
Block {
BlockType Demux
Name "Demux1"
Ports [1, 6]
Position [580, 194, 585, 266]
BackgroundColor "black"
ShowName off
Outputs "6"
BusSelectionMode off
}
Block {
BlockType Demux
Name "Demux2"
Ports [1, 3]
Position [115, 324, 120, 396]
Orientation "left"
BackgroundColor "black"
ShowName off
Outputs "3"
BusSelectionMode off
}
Block {
BlockType Reference
Name "GND"
Tag "__orphan__"
Ports [0, 0, 0, 0, 0, 0, 1]
Position [550, 29, 570, 71]
Orientation "left"
ForegroundColor "red"
NamePlacement "alternate"
ShowName off
SourceBlock "mblibv1/Bodies/Ground"
SourceType "msb"
PortType "workingframe"
PhysicalDomain "Mechanical"
DialogClass "GroundBlock"
ClassName "Ground"
CoordPosition "[10 0 0]"
CoordPositionUnits "cm"
StateVectorMgrId "-1"
}
Block {
BlockType Reference
Name "GND2"
Tag "__orphan__"
Ports [0, 0, 0, 0, 0, 0, 1]
Position [395, 185, 415, 225]
Orientation "left"
ForegroundColor "red"
ShowName off
SourceBlock "mblibv1/Bodies/Ground"
SourceType "msb"
PortType "workingframe"
PhysicalDomain "Mechanical"
DialogClass "GroundBlock"
ClassName "Ground"
CoordPosition "[0 0 0]"
CoordPositionUnits "m"
StateVectorMgrId "-1"
}
Block {
BlockType Mux
Name "Mux"
Ports [2, 1]
Position [580, 139, 585, 186]
ShowName off
Inputs "2"
DisplayOption "bar"
}
Block {
BlockType Reference
Name "Revolute1"
Tag "Factory generic"
Description "Mechanical Blockset"
Ports [0, 0, 0, 0, 0, 1, 1]
Position [135, 198, 175, 232]
Orientation "left"
ForegroundColor "red"
ShowName off
SourceBlock "mblibv1/Joints/Revolute"
SourceType "msb"
PhysicalDomain "mechanical"
SubClassName "Unknown"
PortType "blob"
LConnTagsString "__newl0"
RConnTagsString "__newr0"
NumSAPorts "0"
CutJoint "off"
Primitives "revolute"
PrimitiveProps "R1$WORLD$[0 0 1]$revolute"
ClassName "Joint"
DialogClass "JointBlock"
}
Block {
BlockType Reference
Name "Revolute6"
Tag "Factory generic"
Description "Mechanical Blockset"
Ports [0, 0, 0, 0, 0, 1, 1]
Position [300, 188, 340, 222]
Orientation "left"
ForegroundColor "red"
ShowName off
SourceBlock "mblibv1/Joints/Revolute"
SourceType "msb"
PhysicalDomain "mechanical"
SubClassName "Unknown"
PortType "blob"
LConnTagsString "__newl0"
RConnTagsString "__newr0"
NumSAPorts "0"
CutJoint "off"
Primitives "revolute"
PrimitiveProps "R1$WORLD$[1 0 0]$revolute"
ClassName "Joint"
DialogClass "JointBlock"
}
Block {
BlockType Reference
Name "Revolute8"
Tag "Factory generic"
Description "Mechanical Blockset"
Ports [0, 0, 0, 0, 0, 2, 1]
Position [300, 350, 340, 385]
Orientation "left"
ForegroundColor "red"
ShowName off
SourceBlock "mblibv1/Joints/Revolute"
SourceType "msb"
PhysicalDomain "mechanical"
SubClassName "Unknown"
PortType "blob"
LConnTagsString "__newl0|SA1"
RConnTagsString "__newr0"
NumSAPorts "1"
CutJoint "off"
Primitives "revolute"
PrimitiveProps "R1$WORLD$[0 0 1]$revolute"
ClassName "Joint"
DialogClass "JointBlock"
}
Block {
BlockType Sum
Name "Sum1"
Ports [2, 1]
Position [675, 220, 695, 240]
Orientation "up"
NamePlacement "alternate"
ShowName off
IconShape "round"
Inputs "++|"
SaturateOnIntegerOverflow on
}
Block {
BlockType Sum
Name "Sum2"
Ports [2, 1]
Position [75, 420, 95, 440]
NamePlacement "alternate"
ShowName off
IconShape "round"
Inputs "-+|"
SaturateOnIntegerOverflow on
}
Block {
BlockType Reference
Name "angle\nmeasurement"
Tag "__orphan__"
Description "Mechanical Blockset"
Ports [0, 1, 0, 0, 0, 1]
Position [300, 108, 335, 142]
ForegroundColor "blue"
SourceBlock "mblibv1/Sensors & \nActuators/Joint Sen"
"sor"
SourceType "msb"
PortType "blob"
PhysicalDomain "Mechanical"
Muxed "on"
Pose "off"
Angle "on"
AngleUnits "rad"
ArcVelocity "off"
ArcVelocityUnits "deg/s"
ArcAcceleration "off"
ArcAccelerationUnits "deg/s
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -