qpsk_test.mdl

来自「this is one of the QPSK modulation」· MDL 代码 · 共 1,427 行 · 第 1/3 页

MDL
1,427
字号
      MaskPortRotate	      "default"
      MaskIconUnits	      "autoscale"
      System {
	Name			"IQ Demapper"
	Location		[166, 107, 1178, 769]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"A4"
	PaperUnits		"centimeters"
	TiledPaperMargins	[1.270000, 1.270000, 1.270000, 1.270000]
	TiledPageScale		1
	ShowPageBoundaries	off
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "In"
	  Position		  [45, 198, 75, 212]
	  IconDisplay		  "Port number"
	  OutDataType		  "sfix(16)"
	  OutScaling		  "2^0"
	}
	Block {
	  BlockType		  Reference
	  Name			  "Integer to Bit\nConverter"
	  Ports			  [1, 1]
	  Position		  [330, 183, 410, 227]
	  SourceBlock		  "commutil2/Integer to Bit\nConverter"
	  SourceType		  "Integer to Bit Converter"
	  nbits			  "2"
	  signedInputValues	  "Unsigned"
	  bitOrder		  "MSB first"
	  outDtype		  "Same as input"
	}
	Block {
	  BlockType		  Math
	  Name			  "Math\nFunction"
	  Ports			  [1, 1]
	  Position		  [125, 190, 155, 220]
	  ShowName		  off
	  Operator		  "conj"
	  OutDataType		  "sfix(16)"
	  OutScaling		  "2^0"
	}
	Block {
	  BlockType		  Reference
	  Name			  "QPSK\nDemodulator\nBaseband"
	  Ports			  [1, 1]
	  Position		  [205, 180, 280, 230]
	  NamePlacement		  "alternate"
	  DialogController	  "commDDGCreate"
	  DialogControllerArgs	  "DataTag0"
	  SourceBlock		  "commdigbbndpm3/QPSK\nDemodulator\nBaseband"
	  SourceType		  "QPSK Demodulator Baseband"
	  Ph			  "pi/4"
	  Dec			  "Gray"
	  OutType		  "Integer"
	  DecType		  "Hard decision"
	  VarSource		  "Dialog"
	  Variance		  "1"
	  outDtype1		  "Inherit via internal rule"
	  outDtype2		  "Inherit via internal rule"
	  derotateFactorDTMode	  "Same word length as input"
	  derotateFactorWordLen	  "16"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Out"
	  Position		  [430, 198, 460, 212]
	  IconDisplay		  "Port number"
	  OutDataType		  "sfix(16)"
	  OutScaling		  "2^0"
	}
	Line {
	  SrcBlock		  "QPSK\nDemodulator\nBaseband"
	  SrcPort		  1
	  DstBlock		  "Integer to Bit\nConverter"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "In"
	  SrcPort		  1
	  DstBlock		  "Math\nFunction"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Math\nFunction"
	  SrcPort		  1
	  DstBlock		  "QPSK\nDemodulator\nBaseband"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Integer to Bit\nConverter"
	  SrcPort		  1
	  DstBlock		  "Out"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "Modulador"
      Ports		      [1, 1]
      Position		      [200, 115, 335, 235]
      ShowName		      off
      FontName		      "Arial"
      FontSize		      8
      MinAlgLoopOccurrences   off
      PropExecContextOutsideSubsystem off
      RTWSystemCode	      "Auto"
      FunctionWithSeparateData off
      Opaque		      off
      RequestExecContextInheritance off
      MaskHideContents	      off
      MaskDisplay	      "disp('Modulador');"
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskPortRotate	      "default"
      MaskIconUnits	      "autoscale"
      System {
	Name			"Modulador"
	Location		[183, 181, 1195, 843]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"A4"
	PaperUnits		"centimeters"
	TiledPaperMargins	[1.270000, 1.270000, 1.270000, 1.270000]
	TiledPageScale		1
	ShowPageBoundaries	off
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "In"
	  Position		  [15, 33, 45, 47]
	  IconDisplay		  "Port number"
	  OutDataType		  "sfix(16)"
	  OutScaling		  "2^0"
	}
	Block {
	  BlockType		  Reference
	  Name			  "Bit to Integer\nConverter"
	  Ports			  [1, 1]
	  Position		  [100, 18, 180, 62]
	  SourceBlock		  "commutil2/Bit to Integer\nConverter"
	  SourceType		  "Bit to Integer Converter"
	  nbits			  "2"
	  bitOrder		  "MSB first"
	  signedOutputValues	  "Unsigned"
	  outDtype		  "Same as input"
	  outDtypeSigned	  "Inherit via internal rule"
	}
	Block {
	  BlockType		  Math
	  Name			  "Math\nFunction"
	  Ports			  [1, 1]
	  Position		  [345, 25, 375, 55]
	  ShowName		  off
	  Operator		  "conj"
	  OutDataType		  "sfix(16)"
	  OutScaling		  "2^0"
	}
	Block {
	  BlockType		  Reference
	  Name			  "QPSK\nModulator\nBaseband"
	  Ports			  [1, 1]
	  Position		  [215, 16, 290, 64]
	  DialogController	  "commDDGCreate"
	  DialogControllerArgs	  "DataTag1"
	  SourceBlock		  "commdigbbndpm3/QPSK\nModulator\nBaseband"
	  SourceType		  "QPSK Modulator Baseband"
	  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"
	  InType		  "Integer"
	  Enc			  "Gray"
	  Ph			  "pi/4"
	  outDtype		  "double"
	  outWordLen		  "16"
	  outUDDataType		  "sfix(16)"
	  outFracLenMode	  "Best precision"
	  outFracLen		  "15"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Out"
	  Position		  [430, 33, 460, 47]
	  IconDisplay		  "Port number"
	  OutDataType		  "sfix(16)"
	  OutScaling		  "2^0"
	}
	Line {
	  SrcBlock		  "In"
	  SrcPort		  1
	  DstBlock		  "Bit to Integer\nConverter"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "QPSK\nModulator\nBaseband"
	  SrcPort		  1
	  DstBlock		  "Math\nFunction"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Math\nFunction"
	  SrcPort		  1
	  DstBlock		  "Out"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Bit to Integer\nConverter"
	  SrcPort		  1
	  DstBlock		  "QPSK\nModulator\nBaseband"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      Reference
      Name		      "Saida do Modulador"
      Tag		      "ScatterPlot"
      Ports		      [1]
      Position		      [405, 389, 515, 491]
      FontSize		      8
      SourceBlock	      "commsink2/Discrete-Time\nScatter Plot\nScope"
      SourceType	      "Discrete-Time Scatter Plot Scope"
      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"
      sampPerSymb	      "1"
      offsetEye		      "0"
      numTraces		      "64"
      numNewFrames	      "64"
      LineMarkers	      "."
      LineColors	      "b"
      fading		      on
      render		      on
      AxisGrid		      on
      xMin		      "-0.77781"
      xMax		      "0.7813455"
      yMin		      "-0.77781"
      yMax		      "0.7813455"
      inphaseLabel	      "In-phase Amplitude"
      quadratureLabel	      "Quadrature Amplitude"
      openScopeAtSimStart     on
      FrameNumber	      off
      FigPos		      "get(0,'defaultfigureposition');"
      figTitle		      "Scatter Plot"
      numLinesMax	      "8"
      block_type_	      "scatter"
    }
    Block {
      BlockType		      Reference
      Name		      "Spectrum\nScope"
      Ports		      [1]
      Position		      [445, 252, 475, 298]
      ShowName		      off
      DialogController	      "dspdialog.SpectrumScope"
      DialogControllerArgs    "DataTag2"
      FontName		      "Arial"
      FontSize		      8
      SourceBlock	      "dspsnks4/Spectrum\nScope"
      SourceType	      "Spectrum Scope"
      ShowPortLabels	      "none"
      SystemSampleTime	      "-1"
      FunctionWithSeparateData off
      RTWMemSecFuncInitTerm   "Inherit from model"
      RTWMemSecFuncExecute    "Inherit from model"
      RTWMemSecDataConstants  "Inherit from model"
      RTWMemSecDataInternal   "Inherit from model"
      RTWMemSecDataParameters "Inherit from model"
      ScopeProperties	      on
      Domain		      "Frequency"
      HorizSpan		      "1"
      UseBuffer		      on
      BufferSize	      "1024"
      Overlap		      "0"
      inpFftLenInherit	      on
      FFTlength		      "1024"
      numAvg		      "5"
      DisplayProperties	      off
      AxisGrid		      off
      Memory		      off
      FrameNumber	      off
      AxisLegend	      off
      AxisZoom		      off
      OpenScopeAtSimStart     on
      OpenScopeImmediately    off
      FigPos		      "get(0,'defaultfigureposition')"
      AxisProperties	      off
      XUnits		      "Hertz"
      XRange		      "[0...Fs/2]"
      XDisplay		      "0"
      InheritXIncr	      on
      XIncr		      "1.0"
      XLabel		      "Samples"
      XLimit		      "Auto"
      YUnits		      "dB"
      XMax		      "1"
      XMin		      "0"
      YMin		      "-49.5851620683178"
      YMax		      "-17.4535357375183"
      YLabel		      "Magnitude-squared, dB"
      LineProperties	      off
      wintypeSpecScope	      "Hann"
      RsSpecScope	      "50"
      betaSpecScope	      "5"
      winsampSpecScope	      "Periodic"
      XAxisParamsVer	      "6.9"
    }
    Block {
      BlockType		      Reference
      Name		      "Spectrum\nScope1"
      Ports		      [1]
      Position		      [895, 16, 925, 64]
      ShowName		      off
      DialogController	      "dspdialog.SpectrumScope"
      DialogControllerArgs    "DataTag3"
      FontName		      "Arial"
      FontSize		      8
      SourceBlock	      "dspsnks4/Spectrum\nScope"
      SourceType	      "Spectrum Scope"
      ShowPortLabels	      "none"
      SystemSampleTime	      "-1"
      FunctionWithSeparateData off
      RTWMemSecFuncInitTerm   "Inherit from model"
      RTWMemSecFuncExecute    "Inherit from model"
      RTWMemSecDataConstants  "Inherit from model"
      RTWMemSecDataInternal   "Inherit from model"
      RTWMemSecDataParameters "Inherit from model"
      ScopeProperties	      on
      Domain		      "Frequency"
      HorizSpan		      "1"
      UseBuffer		      on
      BufferSize	      "1024"
      Overlap		      "0"
      inpFftLenInherit	      on
      FFTlength		      "1024"
      numAvg		      "5"
      DisplayProperties	      off
      AxisGrid		      off
      Memory		      off
      FrameNumber	      off
      AxisLegend	      off
      AxisZoom		      off
      OpenScopeAtSimStart     on
      OpenScopeImmediately    off
      FigPos		      "get(0,'defaultfigureposition')"
      AxisProperties	      off
      XUnits		      "Hertz"
      XRange		      "[0...Fs/2]"
      XDisplay		      "0"
      InheritXIncr	      on
      XIncr		      "1.0"
      XLabel		      "Samples"
      XLimit		      "Auto"
      YUnits		      "dB"
      XMax		      "1"
      XMin		      "0"
      YMin		      "-51.7490793915629"
      YMax		      "-17.1080597361603"
      YLabel		      "Magnitude-squared, dB"
      LineProperties	      off
      wintypeSpecScope	      "Hann"
      RsSpecScope	      "50"
      betaSpecScope	      "5"
      winsampSpecScope	      "Periodic"
      XAxisParamsVer	      "6.9"
    }
    Line {
      SrcBlock		      "Data From MAC"
      SrcPort		      1
      DstBlock		      "Modulador"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Modulador"
      SrcPort		      1
      Points		      [5, 0]
      Branch {
	Points			[15, 0]
	Branch {
	  DstBlock		  "AWGN\nChannel"
	  DstPort		  1
	}
	Branch {
	  DstBlock		  "Buffer"
	  DstPort		  1
	}
      }
      Branch {
	Points			[0, 265]
	DstBlock		"Saida do Modulador"
	DstPort			1
      }
    }
    Line {
      SrcBlock		      "AWGN\nChannel"
      SrcPort		      1
      DstBlock		      "IQ Demapper"
      DstPort		      1
    }
    Line {
      SrcBlock		      "IQ Demapper"
      SrcPort		      1
      Points		      [5, 0]
      Branch {
	DstBlock		"Data to MAC"
	DstPort			1
      }
      Branch {
	Points			[-5, 0]
	DstBlock		"Gain"
	DstPort			1
      }
    }
    Line {
      SrcBlock		      "Buffer"
      SrcPort		      1
      DstBlock		      "Spectrum\nScope"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Buffer1"
      SrcPort		      1
      DstBlock		      "Spectrum\nScope1"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Gain"
      SrcPort		      1
      DstBlock		      "Buffer1"
      DstPort		      1
    }
  }
}
MatData {
  NumRecords		  4
  DataRecord {
    Tag			    DataTag3
    Data		    "  %)30     .    ,     8    (    !          %    \"                0         0          "
  }
  DataRecord {
    Tag			    DataTag2
    Data		    "  %)30     .    ,     8    (    !          %    \"                0         0          "
  }
  DataRecord {
    Tag			    DataTag1
    Data		    "  %)30     .    <     8    (     0         %    \"     $    !     0         .    0     8    (    !     "
    "     %    \"     $    -     0         0    #0   %%04TM-;V1U;&%T;W(    "
  }
  DataRecord {
    Tag			    DataTag0
    Data		    "  %)30     .    <     8    (     0         %    \"     $    !     0         .    0     8    (    !     "
    "     %    \"     $    /     0         0    #P   %%04TM$96UO9'5L871O<@ "
  }
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?