📄 demo3.mdl
字号:
ExternalReset "none" InitialConditionSource "internal" InitialCondition "0" LimitOutput off UpperSaturationLimit "inf" LowerSaturationLimit "-inf" ShowSaturationPort off ShowStatePort off AbsoluteTolerance "auto" IgnoreLimit off ZeroCross on ContinuousStateAttributes "''" } Block { BlockType MATLABFcn MATLABFcn "sin" OutputDimensions "-1" OutputSignalType "auto" Output1D on SampleTime "-1" } Block { BlockType Mux Inputs "4" DisplayOption "none" UseBusObject off BusObject "BusObject" NonVirtualBus off } Block { BlockType Outport Port "1" UseBusObject off BusObject "BusObject" BusOutputAsStruct off PortDimensions "-1" SampleTime "-1" OutMin "[]" OutMax "[]" DataType "auto" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: auto" SignalType "auto" SamplingMode "auto" OutputWhenDisabled "held" InitialOutput "[]" } Block { BlockType "S-Function" FunctionName "system" SFunctionModules "''" PortCounts "[]" SFunctionDeploymentMode off } Block { BlockType SubSystem ShowPortLabels "FromPortIcon" Permissions "ReadWrite" PermitHierarchicalResolution "All" TreatAsAtomicUnit off CheckFcnCallInpInsideContextMsg off SystemSampleTime "-1" RTWFcnNameOpts "Auto" RTWFileNameOpts "Auto" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" SimViewingDevice off DataTypeOverride "UseLocalSettings" MinMaxOverflowLogging "UseLocalSettings" } Block { BlockType Sum IconShape "rectangular" Inputs "++" CollapseMode "All dimensions" CollapseDim "1" InputSameDT on AccumDataTypeStr "Inherit: Inherit via internal rule" OutMin "[]" OutMax "[]" OutDataTypeMode "Same as first input" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: Same as first input" LockScale off RndMeth "Floor" SaturateOnIntegerOverflow on SampleTime "-1" } Block { BlockType ToWorkspace VariableName "simulink_output" MaxDataPoints "1000" Decimation "1" SampleTime "0" FixptAsFi off } Block { BlockType Terminator } } AnnotationDefaults { HorizontalAlignment "center" VerticalAlignment "middle" ForegroundColor "black" BackgroundColor "white" DropShadow off FontName "Helvetica" FontSize 10 FontWeight "normal" FontAngle "normal" UseDisplayTextAsClickCallback off } LineDefaults { FontName "Helvetica" FontSize 9 FontWeight "normal" FontAngle "normal" } System { Name "demo3" Location [662, 76, 1404, 418] Open on ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "portrait" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" ReportName "simulink-default.rpt" Block { BlockType Clock Name "Clock" Position [310, 241, 380, 269] DisplayTime on Decimation "10" } Block { BlockType Gain Name "Kd" Position [540, 60, 570, 90] ForegroundColor "gray" } Block { BlockType Gain Name "Kp" Position [510, 15, 540, 45] ForegroundColor "gray" Gain "100" } Block { BlockType Reference Name "Model Info" Ports [] Position [25, 248, 228, 302] ShowName off FontName "Arial" SourceBlock "simulink/Model-Wide\nUtilities/Model Info" SourceType "CMBlock" 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" InitialBlockCM "none" BlockCM "none" Frame "on" DisplayStringWithTags "Puma560 computed torque control\n%<Creator>\n%<LastModificationDate>" MaskDisplayString "Puma560 computed torque control\\npic\\n18-May-2008 11:07:16" HorizontalTextAlignment "Left" LeftAlignmentValue "0.02" SourceBlockDiagram "demo3" TagMaxNumber "20" } Block { BlockType Mux Name "Mux" Ports [4, 1] Position [505, 240, 510, 330] ShowName off DisplayOption "bar" } Block { BlockType Reference Name "Robot" Ports [1, 3] Position [300, 114, 415, 186] BackgroundColor "red" DropShadow on SourceBlock "roblocks/Robot" SourceType "" 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" robot "p560" q0 "[0 0 0 0 0 0]" } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [450, 20, 470, 40] ForegroundColor "gray" ShowName off IconShape "round" Inputs "|+-" } Block { BlockType Sum Name "Sum1" Ports [2, 1] Position [480, 65, 500, 85] ForegroundColor "gray" ShowName off IconShape "round" Inputs "|+-" } Block { BlockType Sum Name "Sum2" Ports [2, 1] Position [595, 20, 615, 40] ForegroundColor "gray" ShowName off IconShape "round" Inputs "|++" } Block { BlockType Terminator Name "Terminator" Position [105, 160, 125, 180] ShowName off } Block { BlockType Terminator Name "Terminator1" Position [435, 165, 455, 185] ShowName off } Block { BlockType ToWorkspace Name "To Workspace" Position [535, 270, 595, 300] VariableName "simout" MaxDataPoints "inf" SampleTime "-1" SaveFormat "Array" } Block { BlockType Reference Name "jtraj" Ports [0, 3] Position [35, 116, 85, 184] BackgroundColor "red" LinkData { BlockName "MATLAB Fcn" DialogParameters { MATLABFcn "squeeze(interp1(t,q,u))" } BlockName "MATLAB Fcn1" DialogParameters { MATLABFcn "squeeze(interp1(t,qd,u))" } BlockName "MATLAB Fcn2" DialogParameters { MATLABFcn "squeeze(interp1(t,qdd,u))" } } SourceBlock "roblocks/jtraj" SourceType "" 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" q0 "[0 0 0 0 0 0]" qf "[pi/4 pi/2 -pi/2 0 0 0]" tmax "10" } Block { BlockType Reference Name "plot" Ports [1] Position [640, 97, 720, 153] BackgroundColor "red" SourceBlock "roblocks/plot" SourceType "" 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" robot "p560" } Block { BlockType Reference Name "rne" Ports [3, 1] Position [165, 117, 260, 183] BackgroundColor "red" SourceBlock "roblocks/rne" SourceType "" 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" robot "perturb(p560)" grav "[0 0 9.81]" } Line { SrcBlock "Sum" SrcPort 1 DstBlock "Kp" DstPort 1 } Line { SrcBlock "Kp" SrcPort 1 DstBlock "Sum2" DstPort 1 } Line { SrcBlock "Robot" SrcPort 1 Points [40, 0] Branch { DstBlock "plot" DstPort 1 } Branch { Points [0, 150] DstBlock "Mux" DstPort 2 } Branch { DstBlock "Sum" DstPort 2 } } Line { SrcBlock "Robot" SrcPort 2 Points [70, 0] Branch { DstBlock "Mux" DstPort 3 } Branch { DstBlock "Sum1" DstPort 2 } } Line { SrcBlock "Sum2" SrcPort 1 Points [0, 190; -475, 0; 0, -50] DstBlock "rne" DstPort 3 } Line { SrcBlock "rne" SrcPort 1 Points [10, 0] Branch { DstBlock "Robot" DstPort 1 } Branch { Points [0, 165] DstBlock "Mux" DstPort 4 } } Line { SrcBlock "jtraj" SrcPort 1 Points [15, 0] Branch { Points [0, -100] DstBlock "Sum" DstPort 1 } Branch { DstBlock "rne" DstPort 1 } } Line { SrcBlock "jtraj" SrcPort 2 Points [30, 0] Branch { DstBlock "rne" DstPort 2 } Branch { Points [0, -75] DstBlock "Sum1" DstPort 1 } } Line { SrcBlock "Mux" SrcPort 1 DstBlock "To Workspace" DstPort 1 } Line { SrcBlock "Clock" SrcPort 1 DstBlock "Mux" DstPort 1 } Line { SrcBlock "Sum1" SrcPort 1 DstBlock "Kd" DstPort 1 } Line { SrcBlock "Kd" SrcPort 1 Points [30, 0] DstBlock "Sum2" DstPort 2 } Line { SrcBlock "jtraj" SrcPort 3 DstBlock "Terminator" DstPort 1 } Line { SrcBlock "Robot" SrcPort 3 DstBlock "Terminator1" DstPort 1 } Annotation { Name "Puma 560 computed torque control" Position [163, 18] FontSize 18 FontWeight "bold" } Annotation { Name "trajectory\n(demand)" Position [57, 215] ForegroundColor "blue" } Annotation { Name "robot state\n(actual)" Position [524, 159] ForegroundColor "orange" } Annotation { Name "error" Position [540, 211] ForegroundColor "gray" } }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -