📄 timing_recovery_1.mdl
字号:
OutDataTypeMode "Inherit from 'Constant value'"
OutDataType "sfix(16)"
ConRadixGroup "Use specified scaling"
OutScaling "2^0"
SampleTime "inf"
FramePeriod "inf"
}
Block {
BlockType SubSystem
Name "Limited Phase Unwrapper"
Ports [3, 1]
Position [760, 122, 835, 228]
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
FunctionWithSeparateData off
MaskHideContents off
Port {
PortNumber 1
Name "Carrier Phase Error"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
System {
Name "Limited Phase Unwrapper"
Location [72, 162, 715, 432]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
TiledPaperMargins "[0.500000, 0.500000, 0.500000, 0."
"500000]"
TiledPageScale 1
ShowPageBoundaries off
ZoomFactor "100"
Block {
BlockType Inport
Name "Phase in"
Position [30, 53, 60, 67]
IconDisplay "Port number"
}
Block {
BlockType Inport
Name "Limit"
Position [35, 223, 65, 237]
Port "2"
IconDisplay "Port number"
}
Block {
BlockType Inport
Name "Tolerance1"
Position [35, 173, 65, 187]
Port "3"
IconDisplay "Port number"
}
Block {
BlockType Abs
Name "Abs"
Position [265, 95, 295, 125]
SaturateOnIntegerOverflow on
ZeroCross on
SampleTime "-1"
}
Block {
BlockType Reference
Name "Delay"
Ports [1, 1]
Position [110, 90, 165, 130]
SourceBlock "dspsigops/Delay"
SourceType "Delay"
dly_unit "Samples"
delay "1"
ic_detail "off"
dif_ic_for_ch "off"
dif_ic_for_dly "off"
ic "0"
reset_popup "None"
}
Block {
BlockType SubSystem
Name "N*2*pi accumulator"
Ports [2, 1, 1]
Position [415, 187, 500, 243]
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
FunctionWithSeparateData off
MaskHideContents off
System {
Name "N*2*pi accumulator"
Location [173, 226, 750, 509]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
TiledPaperMargins "[0.500000, 0.500000, 0.500000, 0."
"500000]"
TiledPageScale 1
ShowPageBoundaries off
ZoomFactor "100"
Block {
BlockType Inport
Name "add_sub"
Position [30, 148, 60, 162]
IconDisplay "Port number"
}
Block {
BlockType Inport
Name "Limit"
Position [25, 18, 55, 32]
Port "2"
IconDisplay "Port number"
}
Block {
BlockType EnablePort
Name "Enable"
Ports []
Position [360, 180, 380, 200]
}
Block {
BlockType Reference
Name "DSP\nConstant1"
Ports [0, 1]
Position [90, 199, 125, 231]
SourceBlock "dspsrcs4/DSP\nConstant"
SourceType "DSP Constant"
ShowPortLabels "on"
SystemSampleTime "-1"
FunctionWithSeparateData "off"
RTWMemSecFuncInitTerm "Inherit from model"
RTWMemSecFuncExecute "Inherit from model"
RTWMemSecDataConstants "Inherit from model"
RTWMemSecDataInternal "Inherit from model"
RTWMemSecDataParameters "Inherit from model"
Value "-2*pi"
SampleMode "Discrete"
discreteOutput "Sample-based"
continuousOutput "Sample-based"
sampTime "-1"
framePeriod "2"
additionalParams "off"
allowOverrides "on"
dataType "Inherit from 'Constant value'"
isSigned "on"
wordLen "16"
udDataType "sfix(16)"
fracBitsMode "Best precision"
numFracBits "15"
InterpretAs1D "-inf"
Ts "-inf"
FramebasedOutput "-inf"
}
Block {
BlockType Gain
Name "Gain"
Position [335, 65, 365, 95]
Gain "-1"
ParameterDataTypeMode "Inherit via internal rule"
OutDataTypeMode "Inherit via internal rule"
SaturateOnIntegerOverflow off
}
Block {
BlockType Reference
Name "Integer Delay"
Ports [1, 1]
Position [215, 43, 250, 77]
SourceBlock "simulink/Discrete/Integer Delay"
SourceType "Integer Delay"
vinit "0.0"
samptime "-1"
NumDelays "1"
}
Block {
BlockType Product
Name "Product"
Ports [2, 1]
Position [160, 146, 205, 179]
InputSameDT off
RndMeth "Floor"
}
Block {
BlockType Reference
Name "Saturation\nDynamic"
Ports [3, 1]
Position [385, 27, 465, 93]
SourceBlock "simulink/Discontinuities/Saturati"
"on\nDynamic"
SourceType "Saturation Dynamic"
ShowPortLabels "on"
SystemSampleTime "-1"
FunctionWithSeparateData "off"
RTWMemSecFuncInitTerm "Inherit from model"
RTWMemSecFuncExecute "Inherit from model"
RTWMemSecDataConstants "Inherit from model"
RTWMemSecDataInternal "Inherit from model"
RTWMemSecDataParameters "Inherit from model"
}
Block {
BlockType Signum
Name "Sign"
Position [90, 140, 120, 170]
}
Block {
BlockType Sum
Name "Sum2"
Ports [2, 1]
Position [280, 50, 300, 70]
ShowName off
IconShape "round"
Inputs "|++"
InputSameDT off
OutDataTypeMode "single"
}
Block {
BlockType Outport
Name "K*2*pi"
Position [520, 53, 550, 67]
IconDisplay "Port number"
BusOutputAsStruct off
}
Line {
SrcBlock "Integer Delay"
SrcPort 1
DstBlock "Sum2"
DstPort 1
}
Line {
SrcBlock "DSP\nConstant1"
SrcPort 1
Points [15, 0]
DstBlock "Product"
DstPort 2
}
Line {
SrcBlock "Sign"
SrcPort 1
DstBlock "Product"
DstPort 1
}
Line {
SrcBlock "Product"
SrcPort 1
Points [80, 0]
DstBlock "Sum2"
DstPort 2
}
Line {
SrcBlock "add_sub"
SrcPort 1
DstBlock "Sign"
DstPort 1
}
Line {
SrcBlock "Sum2"
SrcPort 1
DstBlock "Saturation\nDynamic"
DstPort 2
}
Line {
SrcBlock "Saturation\nDynamic"
SrcPort 1
Points [25, 0]
Branch {
DstBlock "K*2*pi"
DstPort 1
}
Branch {
Points [0, 65; -340, 0; 0, -65]
DstBlock "Integer Delay"
DstPort 1
}
}
Line {
SrcBlock "Gain"
SrcPort 1
DstBlock "Saturation\nDynamic"
DstPort 3
}
Line {
SrcBlock "Limit"
SrcPort 1
Points [260, 0; 0, 15]
Branch {
DstBlock "Gain"
DstPort 1
}
Branch {
DstBlock "Saturation\nDynamic"
DstPort 1
}
}
}
}
Block {
BlockType RelationalOperator
Name "Relational\nOperator"
Position [385, 102, 415, 133]
InputSameDT off
}
Block {
BlockType Sum
Name "Sum"
Ports [2, 1]
Position [195, 100, 215, 120]
ShowName off
IconShape "round"
Inputs "|-+"
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
}
Block {
BlockType Sum
Name "Sum1"
Ports [2, 1]
Position [535, 50, 555, 70]
ShowName off
IconShape "round"
Inputs "|++"
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
}
Block {
BlockType Outport
Name "Phase out"
Position [580, 53, 610, 67]
IconDisplay "Port number"
BusOutputAsStruct off
}
Line {
SrcBlock "Phase in"
SrcPort 1
Points [25, 0]
Branch {
DstBlock "Sum1"
DstPort 1
}
Branch {
Points [0, 50]
Branch {
Points [0, 45; 115, 0]
DstBlock "Sum"
DstPort 2
}
Branch {
DstBlock "Delay"
DstPort 1
}
}
}
Line {
SrcBlock "Delay"
SrcPort 1
DstBlock "Sum"
DstPort 1
}
Line {
SrcBlock "Sum"
SrcPort 1
Points [25, 0]
Branch {
DstBlock "Abs"
DstPort 1
}
Branch {
Points [0, 90]
DstBlock "N*2*pi accumulator"
DstPort 1
}
}
Line {
SrcBlock "Abs"
SrcPort 1
DstBlock "Relational\nOperator"
DstPort 1
}
Line {
SrcBlock "Tolerance1"
SrcPort 1
Points [255, 0; 0, -55]
DstBlock "Relational\nOperator"
DstPort 2
}
Line {
SrcBlock "Relational\nOperator"
SrcPort 1
Points [35, 0]
DstBlock "N*2*pi accumulator"
DstPort enable
}
Line {
SrcBlock "N*2*pi accumulator"
SrcPort 1
Points [40, 0]
DstBlock "Sum1"
DstPort 2
}
Line {
SrcBlock "Sum1"
SrcPort 1
DstBlock "Phase out"
DstPort 1
}
Line {
SrcBlock "Limit"
SrcPort 1
DstBlock "N*2*pi accumulator"
DstPort 2
}
}
}
Block {
BlockType Reference
Name "Manual Switch2"
Ports [2, 1]
Position [640, 257, 670, 293]
Orientation "left"
SourceBlock "simulink/Signal\nRouting/Manual Swi"
"tch"
SourceType "Manual Switch"
ShowPortLabels "on"
SystemSampleTime "-1"
FunctionWithSeparateData "off"
RTWMemSecFuncInitTerm "Inherit from model"
RTWMemSecFuncExecute "Inherit from model"
RTWMemSecDataConstants "Inherit from model"
RTWMemSecDataInternal "Inherit from model"
RTWMemSecDataParameters "Inherit from model"
sw "0"
action "0"
Port {
PortNumber 1
Name "phase error"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
}
Block {
BlockType SubSystem
Name "P+I Loop Filter"
Ports [1, 1]
Position [370, 245, 460, 305]
Orientation "left"
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
FunctionWithSeparateData off
MaskHideContents off
Port {
PortNumber 1
Name "NCO control"
RTWStorageClass "Auto"
DataLoggingNameMode "SignalName"
}
System {
Name "P+I Loop Filter"
Location [99, 160, 702, 412]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnit
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -