📄 ofdm1.mdl
字号:
SourceBlock "commcnvcod2/Viterbi Decoder"
SourceType "Viterbi Decoder"
trellis "poly2trellis(7, [151 133])"
dectype "Hard Decision"
nsdecb "4"
tbdepth "100"
opmode "Continuous"
reset off
outDataType "double"
}
Block {
BlockType Outport
Name "Out2"
Position [40, 138, 70, 152]
Orientation "left"
IconDisplay "Port number"
BusOutputAsStruct off
}
Block {
BlockType Outport
Name "Out1"
Position [30, 53, 60, 67]
Orientation "left"
Port "2"
IconDisplay "Port number"
BusOutputAsStruct off
}
Line {
SrcBlock "In1"
SrcPort 1
Points [0, 5]
DstBlock "Rectangular QAM\nDemodulator\nBaseband"
DstPort 1
}
Line {
SrcBlock "Viterbi Decoder"
SrcPort 1
DstBlock "Out1"
DstPort 1
}
Line {
SrcBlock "Matrix\nDeinterleaver"
SrcPort 1
DstBlock "Viterbi Decoder"
DstPort 1
}
Line {
SrcBlock "Rectangular QAM\nDemodulator\nBaseband"
SrcPort 1
Points [-50, 0]
Branch {
Points [0, 85]
DstBlock "Out2"
DstPort 1
}
Branch {
DstBlock "Matrix\nDeinterleaver"
DstPort 1
}
}
}
}
Block {
BlockType SubSystem
Name "Subsystem7"
Ports [3, 1]
Position [445, 282, 545, 398]
Orientation "left"
BackgroundColor "lightBlue"
FontSize 10
TreatAsAtomicUnit off
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
MaskHideContents off
MaskDisplay "disp('channel estimate\\nequilization')"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "Subsystem7"
Location [105, 482, 1087, 863]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "100"
Block {
BlockType Inport
Name "r_sig"
Position [15, 88, 45, 102]
IconDisplay "Port number"
}
Block {
BlockType Inport
Name "r_pn "
Position [15, 178, 45, 192]
Port "2"
IconDisplay "Port number"
}
Block {
BlockType Inport
Name "t_pn"
Position [15, 248, 45, 262]
Port "3"
IconDisplay "Port number"
}
Block {
BlockType Reference
Name "Frame Status\nConversion"
Ports [1, 1]
Position [500, 222, 550, 258]
SourceBlock "dspobslib/Frame Status\nConversion"
SourceType "Frame Status Conversion"
ShowPortLabels off
growRefPort off
outframe "Frame-based"
}
Block {
BlockType Math
Name "Math\nFunction"
Ports [1, 1]
Position [275, 275, 305, 305]
Operator "magnitude^2"
}
Block {
BlockType Reference
Name "Mean"
Ports [1, 1]
Position [305, 194, 345, 246]
DialogController "dspDDGCreate"
DialogControllerArgs "DataTag2"
FontSize 10
SourceBlock "dspstat3/Mean"
SourceType "Mean"
run off
reset_popup "None"
additionalParams off
allowOverrides on
outputMode "Same as accumulator"
outputWordLength "32"
outputFracLength "30"
accumMode "Same as input"
accumWordLength "32"
accumFracLength "30"
roundingMode "Floor"
overflowMode off
LockScale off
}
Block {
BlockType Reference
Name "Mean1"
Ports [1, 1]
Position [350, 264, 375, 316]
DialogController "dspDDGCreate"
DialogControllerArgs "DataTag3"
FontSize 10
SourceBlock "dspstat3/Mean"
SourceType "Mean"
run off
reset_popup "None"
additionalParams off
allowOverrides on
outputMode "Same as accumulator"
outputWordLength "32"
outputFracLength "30"
accumMode "Same as input"
accumWordLength "32"
accumFracLength "30"
roundingMode "Floor"
overflowMode off
LockScale off
}
Block {
BlockType Product
Name "Product"
Ports [2, 1]
Position [145, 152, 185, 288]
Inputs "/*"
InputSameDT off
RndMeth "Floor"
}
Block {
BlockType Product
Name "Product1"
Ports [2, 1]
Position [740, 98, 760, 162]
Inputs "**"
InputSameDT off
RndMeth "Floor"
}
Block {
BlockType Product
Name "Product2"
Ports [2, 1]
Position [420, 202, 455, 273]
Inputs "*/"
InputSameDT off
RndMeth "Floor"
}
Block {
BlockType Terminator
Name "Terminator"
Position [850, 200, 870, 220]
}
Block {
BlockType Reference
Name "Transpose1"
Ports [1, 1]
Position [210, 200, 245, 240]
FontSize 10
SourceBlock "dspmtrx3/Transpose"
SourceType "Transpose"
Hermitian off
overflowFlag on
}
Block {
BlockType Reference
Name "Transpose2"
Ports [1, 1]
Position [580, 220, 635, 260]
FontSize 10
SourceBlock "dspmtrx3/Transpose"
SourceType "Transpose"
Hermitian off
overflowFlag on
}
Block {
BlockType Selector
Name "del dc1"
Ports [1, 1]
Position [70, 158, 120, 212]
InputType "Matrix"
Elements "[1 3]"
Rows "[1:30 32:61]"
Columns "-1"
InputPortWidth "3"
}
Block {
BlockType Selector
Name "del dc2"
Ports [1, 1]
Position [335, 68, 385, 122]
InputType "Matrix"
Elements "[1 3]"
Rows "[1:30 32:61]"
Columns "-1"
InputPortWidth "3"
}
Block {
BlockType Selector
Name "del dc3"
Ports [1, 1]
Position [65, 228, 115, 282]
InputType "Matrix"
Elements "[1 3]"
Rows "[1:30 32:61]"
Columns "-1"
InputPortWidth "3"
}
Block {
BlockType Outport
Name "Out1"
Position [880, 123, 910, 137]
IconDisplay "Port number"
BusOutputAsStruct off
}
Line {
SrcBlock "Product"
SrcPort 1
DstBlock "Transpose1"
DstPort 1
}
Line {
SrcBlock "r_sig"
SrcPort 1
DstBlock "del dc2"
DstPort 1
}
Line {
SrcBlock "r_pn "
SrcPort 1
DstBlock "del dc1"
DstPort 1
}
Line {
SrcBlock "t_pn"
SrcPort 1
DstBlock "del dc3"
DstPort 1
}
Line {
SrcBlock "del dc1"
SrcPort 1
DstBlock "Product"
DstPort 1
}
Line {
SrcBlock "del dc2"
SrcPort 1
Points [250, 0]
Branch {
Points [0, 20]
DstBlock "Product1"
DstPort 1
}
Branch {
Points [0, -50; 210, 0; 0, 85]
DstBlock "Out1"
DstPort 1
}
}
Line {
SrcBlock "Product1"
SrcPort 1
Points [45, 0; 0, 80]
DstBlock "Terminator"
DstPort 1
}
Line {
SrcBlock "Transpose1"
SrcPort 1
Points [5, 0]
Branch {
Points [0, 70]
DstBlock "Math\nFunction"
DstPort 1
}
Branch {
DstBlock "Mean"
DstPort 1
}
}
Line {
SrcBlock "Math\nFunction"
SrcPort 1
DstBlock "Mean1"
DstPort 1
}
Line {
SrcBlock "Product2"
SrcPort 1
DstBlock "Frame Status\nConversion"
DstPort 1
}
Line {
SrcBlock "Frame Status\nConversion"
SrcPort 1
DstBlock "Transpose2"
DstPort 1
}
Line {
SrcBlock "Transpose2"
SrcPort 1
Points [75, 0; 0, -95]
DstBlock "Product1"
DstPort 2
}
Line {
SrcBlock "Mean"
SrcPort 1
DstBlock "Product2"
DstPort 1
}
Line {
SrcBlock "Mean1"
SrcPort 1
Points [10, 0; 0, -35]
DstBlock "Product2"
DstPort 2
}
Line {
SrcBlock "del dc3"
SrcPort 1
DstBlock "Product"
DstPort 2
}
}
}
Block {
BlockType ToWorkspace
Name "To Workspace"
Position [380, 225, 460, 255]
BackgroundColor "cyan"
VariableName "code_error"
MaxDataPoints "inf"
SampleTime "-1"
SaveFormat "Array"
}
Block {
BlockType ToWorkspace
Name "To Workspace1"
Position [710, 210, 810, 240]
BackgroundColor "cyan"
VariableName "no_code_error"
MaxDataPoints "inf"
SampleTime "-1"
SaveFormat "Array"
}
Block {
BlockType SubSystem
Name "channel"
Ports [1, 1]
Position [819, 150, 921, 240]
Orientation "down"
BackgroundColor "gray"
TreatAsAtomicUnit off
MinAlgLoopOccurrences off
RTWSystemCode "Auto"
MaskHideContents off
MaskDisplay "disp ('channel')"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "channel"
Location [412, 294, 777, 568]
Open on
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "100"
Block {
BlockType Inport
Name "In1"
Position [140, 15, 170, 30]
Orientation "down"
IconDisplay "Port number"
}
Block {
BlockType Reference
Name "AWGN\nChannel"
Ports [1, 1]
Position [115, 145, 195, 185]
Orientation "down"
FontSize 10
SourceBlock "commchan3/AWGN\nChannel"
SourceType "AWGN Channel"
ShowPortLabels on
seed "679886"
noiseMode "Signal to noise ratio (SNR)"
EbNodB "snrr"
EsNodB "15"
SNRdB "45"
bitsPerSym "1"
Ps "1/480"
Tsym "1/1000/480"
variance "1"
}
Block {
BlockType Outport
Name "Out1"
Position [140, 220, 170, 235]
Orientation "down"
IconDisplay "Port number"
BusOutputAsStruct off
}
Line {
SrcBlock "AWGN\nChannel"
SrcPort 1
Points [0, 0]
DstBlock "Out1"
DstPort 1
}
Line {
SrcBlock "In1"
SrcPort 1
DstBlock "AWGN\nChannel"
DstPort 1
}
}
}
Block {
BlockType SubSystem
Name "train sequence"
Ports [0, 1]
Position [395, 31, 505, 79]
BackgroundColor "yellow"
TreatAsAtomicUnit off
MinAlgLoopOccurrences off
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -