📄 qpskuntitled.mdl
字号:
BackgroundColor "white"
DropShadow off
NamePlacement "normal"
FontName "Helvetica"
FontSize 10
FontWeight "normal"
FontAngle "normal"
ShowName on
}
BlockParameterDefaults {
Block {
BlockType Constant
Value "1"
VectorParams1D on
OutDataTypeMode "Inherit from 'Constant value'"
OutDataType "sfix(16)"
ConRadixGroup "Use specified scaling"
OutScaling "2^0"
SampleTime "inf"
}
Block {
BlockType Display
Format "short"
Decimation "10"
Floating off
SampleTime "-1"
}
Block {
BlockType FrameConversion
OutFrame "Frame based"
}
Block {
BlockType Gain
Gain "1"
Multiplication "Element-wise(K.*u)"
ParameterDataTypeMode "Same as input"
ParameterDataType "sfix(16)"
ParameterScalingMode "Best Precision: Matrix-wise"
ParameterScaling "2^0"
OutDataTypeMode "Same as input"
OutDataType "sfix(16)"
OutScaling "2^0"
LockScale off
RndMeth "Floor"
SaturateOnIntegerOverflow on
SampleTime "-1"
}
Block {
BlockType Ground
}
Block {
BlockType Inport
BusObject "BusObject"
BusOutputAsStruct off
PortDimensions "-1"
SampleTime "-1"
DataType "auto"
OutDataType "sfix(16)"
OutScaling "2^0"
SignalType "auto"
SamplingMode "auto"
Interpolate on
}
Block {
BlockType Outport
Port "1"
BusObject "BusObject"
BusOutputAsStruct off
PortDimensions "-1"
SampleTime "-1"
DataType "auto"
OutDataType "sfix(16)"
OutScaling "2^0"
SignalType "auto"
SamplingMode "auto"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType RandomNumber
Mean "0"
Variance "1"
Seed "0"
SampleTime "-1"
VectorParams1D on
}
Block {
BlockType RelationalOperator
Operator ">="
InputSameDT on
LogicOutDataTypeMode "Logical (see Configuration Parameters: Optimiza"
"tion)"
LogicDataType "uint(8)"
ZeroCross on
SampleTime "-1"
}
Block {
BlockType Selector
InputType "Vector"
IndexMode "One-based"
ElementSrc "Internal"
Elements "1"
RowSrc "Internal"
Rows "1"
ColumnSrc "Internal"
Columns "1"
InputPortWidth "-1"
IndexIsStartValue off
OutputPortSize "1"
}
Block {
BlockType "S-Function"
FunctionName "system"
PortCounts "[]"
SFunctionModules "''"
}
Block {
BlockType SubSystem
ShowPortLabels on
Permissions "ReadWrite"
PermitHierarchicalResolution "All"
SystemSampleTime "-1"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
SimViewingDevice off
DataTypeOverride "UseLocalSettings"
MinMaxOverflowLogging "UseLocalSettings"
}
Block {
BlockType Sum
IconShape "rectangular"
Inputs "++"
InputSameDT on
OutDataTypeMode "Same as first input"
OutDataType "sfix(16)"
OutScaling "2^0"
LockScale off
RndMeth "Floor"
SaturateOnIntegerOverflow on
SampleTime "-1"
}
Block {
BlockType ToWorkspace
VariableName "simulink_output"
MaxDataPoints "1000"
Decimation "1"
SampleTime "0"
FixptAsFi off
}
}
AnnotationDefaults {
HorizontalAlignment "center"
VerticalAlignment "middle"
ForegroundColor "black"
BackgroundColor "white"
DropShadow off
FontName "Helvetica"
FontSize 10
FontWeight "normal"
FontAngle "normal"
}
LineDefaults {
FontName "Helvetica"
FontSize 9
FontWeight "normal"
FontAngle "normal"
}
System {
Name "QPSKuntitled"
Location [75, 250, 1008, 620]
Open on
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "A4"
PaperUnits "centimeters"
ZoomFactor "100"
ReportName "simulink-default.rpt"
Block {
BlockType Reference
Name "AWGN\nChannel"
Ports [1, 1]
Position [265, 104, 345, 146]
SourceBlock "commchan2/AWGN\nChannel"
SourceType "AWGN Channel"
ShowPortLabels on
seed "67"
noiseMode "Signal to noise ratio (SNR)"
EbNodB "10"
EsNodB "10"
SNRdB "SNR"
bitsPerSym "1"
Ps "1"
Tsym "1"
variance "0.1"
}
Block {
BlockType Sum
Name "Add"
Ports [2, 1]
Position [385, 107, 415, 138]
InputSameDT off
OutDataTypeMode "Inherit via internal rule"
OutScaling "2^-10"
SaturateOnIntegerOverflow off
}
Block {
BlockType Reference
Name "Bernoulli Binary\nGenerator"
Ports [0, 1]
Position [20, 103, 100, 147]
FontName "Arial"
SourceBlock "commrandsrc2/Bernoulli Binary\nGenerator"
SourceType "Bernoulli Binary Generator"
ShowPortLabels on
P "0.5"
seed "[61 45]"
Ts "0.01"
frameBased off
sampPerFrame "1"
orient off
}
Block {
BlockType Reference
Name "Bit to Integer\nConverter"
Ports [1, 1]
Position [540, 103, 620, 147]
SourceBlock "commutil2/Bit to Integer\nConverter"
SourceType "Bit to Integer Converter"
nbits "2"
}
Block {
BlockType Reference
Name "Bit to Integer\nConverter1"
Ports [1, 1]
Position [430, 18, 510, 62]
SourceBlock "commutil2/Bit to Integer\nConverter"
SourceType "Bit to Integer Converter"
nbits "2"
}
Block {
BlockType Display
Name "Display"
Ports [1]
Position [825, 186, 915, 254]
Decimation "1"
}
Block {
BlockType Reference
Name "Error Rate\nCalculation"
Ports [2, 1]
Position [660, 86, 735, 139]
SourceBlock "commsink2/Error Rate\nCalculation"
SourceType "Error Rate Calculation"
N "0"
st_delay "0"
cp_mode "Entire frame"
subframe "[]"
PMode "Port"
WsName "ErrorVec"
RsMode2 off
stop off
numErr "100"
maxBits "1e6"
}
Block {
BlockType Reference
Name "Gaussian Noise\nGenerator"
Ports [0, 1]
Position [235, 238, 315, 282]
FontName "Arial"
FontSize 10
SourceBlock "commnoisgen2/Gaussian Noise\nGenerator"
SourceType "Gaussian Noise Generator"
ShowPortLabels on
m "1.5"
d "1"
s "41"
Ts "1"
frameBased off
sampPerFrame "1"
orient off
}
Block {
BlockType Reference
Name "QPSK\nDemodulator\nBaseband"
Ports [1, 1]
Position [440, 100, 515, 150]
SourceBlock "commdigbbndpm2/QPSK\nDemodulator\nBaseband"
SourceType "QPSK Demodulator Baseband"
ShowPortLabels on
OutType "Bit"
Dec "Gray"
Ph "pi/4"
numSamp "1"
}
Block {
BlockType Reference
Name "QPSK\nModulator\nBaseband"
Ports [1, 1]
Position [125, 101, 200, 149]
SourceBlock "commdigbbndpm2/QPSK\nModulator\nBaseband"
SourceType "QPSK Modulator Baseband"
ShowPortLabels on
InType "Bit"
Enc "Gray"
Ph "pi/4"
numSamp "1"
}
Block {
BlockType Selector
Name "Selector"
Ports [1, 1]
Position [765, 96, 805, 134]
InputPortWidth "3"
}
Block {
BlockType ToWorkspace
Name "To Workspace"
Position [845, 99, 920, 131]
VariableName "BitErrorRate"
MaxDataPoints "inf"
SampleTime "-1"
SaveFormat "Array"
}
Line {
SrcBlock "Bernoulli Binary\nGenerator"
SrcPort 1
Points [0, 0]
Branch {
DstBlock "QPSK\nModulator\nBaseband"
DstPort 1
}
Branch {
Points [0, -85]
DstBlock "Bit to Integer\nConverter1"
DstPort 1
}
}
Line {
SrcBlock "QPSK\nDemodulator\nBaseband"
SrcPort 1
DstBlock "Bit to Integer\nConverter"
DstPort 1
}
Line {
SrcBlock "Bit to Integer\nConverter"
SrcPort 1
DstBlock "Error Rate\nCalculation"
DstPort 2
}
Line {
SrcBlock "Error Rate\nCalculation"
SrcPort 1
Points [0, 0; 5, 0]
Branch {
DstBlock "Selector"
DstPort 1
}
Branch {
Points [0, 105]
DstBlock "Display"
DstPort 1
}
}
Line {
SrcBlock "Bit to Integer\nConverter1"
SrcPort 1
Points [130, 0]
DstBlock "Error Rate\nCalculation"
DstPort 1
}
Line {
SrcBlock "Selector"
SrcPort 1
DstBlock "To Workspace"
DstPort 1
}
Line {
SrcBlock "QPSK\nModulator\nBaseband"
SrcPort 1
DstBlock "AWGN\nChannel"
DstPort 1
}
Line {
SrcBlock "AWGN\nChannel"
SrcPort 1
Points [20, 0]
DstBlock "Add"
DstPort 1
}
Line {
SrcBlock "Add"
SrcPort 1
DstBlock "QPSK\nDemodulator\nBaseband"
DstPort 1
}
Line {
SrcBlock "Gaussian Noise\nGenerator"
SrcPort 1
Points [50, 0]
DstBlock "Add"
DstPort 2
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -