⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ch3example15.mdl

📁 通信程序源代码和模型通信程序源代码和模型通信程序源代码和模型
💻 MDL
📖 第 1 页 / 共 2 页
字号:
";"
	  MaskInitialization	  "str=dspblkmagfft2('init');dspblkmagfft2('up"
"date');"
	  MaskDisplay		  "disp(str,'texmode','on');"
	  MaskSelfModifiable	  on
	  MaskIconFrame		  on
	  MaskIconOpaque	  on
	  MaskIconRotate	  "none"
	  MaskIconUnits		  "autoscale"
	  MaskValueString	  "Magnitude squared|on|fftsize"
	  System {
	    Name		    "Magnitude\nFFT"
	    Location		    [481, 433, 925, 544]
	    Open		    off
	    ModelBrowserVisibility  off
	    ModelBrowserWidth	    200
	    ScreenColor		    "white"
	    PaperOrientation	    "landscape"
	    PaperPositionMode	    "auto"
	    PaperType		    "A4"
	    PaperUnits		    "centimeters"
	    ZoomFactor		    "100"
	    Block {
	      BlockType		      Inport
	      Name		      "In"
	      Position		      [15, 38, 45, 52]
	    }
	    Block {
	      BlockType		      Reference
	      Name		      "Check Signal\nAttributes"
	      Ports		      [1, 1]
	      Position		      [65, 23, 135, 67]
	      SourceBlock	      "dspsigattribs/Check Signal\nAttributes"
	      SourceType	      "Check Signal Attributes"
	      SigAttribCheckMethod    "Matches attributes exactly"
	      Complexity	      "Ignore"
	      Frame		      "Sample-based"
	      DimsCheckMethod	      "Is..."
	      Dimensions	      "Row vector (2-D)"
	      DatatypeCheckMethod     "Ignore"
	      DatatypeGeneral	      "Boolean"
	      DtypeFloatSpecific      "Any floating-point"
	      DtypeFixedSpecific      "Any fixed-point"
	      DtypeIntSpecific	      "Any integer"
	      SampleMode	      "Ignore"
	    }
	    Block {
	      BlockType		      Reference
	      Name		      "FFT"
	      Ports		      [1, 1]
	      Position		      [230, 28, 270, 62]
	      SourceBlock	      "dspxfrm3/FFT"
	      SourceType	      "FFT"
	      CompMethod	      "Table lookup"
	      TableOpt		      "Speed"
	      BitRevOrder	      off
	    }
	    Block {
	      BlockType		      Math
	      Name		      "Magnitude\nSquared"
	      Ports		      [1, 1]
	      Position		      [290, 30, 320, 60]
	      Operator		      "magnitude^2"
	    }
	    Block {
	      BlockType		      Reference
	      Name		      "Zero Pad"
	      Ports		      [1, 1]
	      Position		      [160, 27, 205, 63]
	      SourceBlock	      "dspsigops/Zero Pad"
	      SourceType	      "Zero Pad"
	      padSigAt		      "End"
	      zpadAlong		      "None"
	      padNumOutRowsSpecMethod "User-specified"
	      numOutRows	      "fftsize"
	      padNumOutColsSpecMethod "User-specified"
	      numOutCols	      "1"
	      trunc_flag	      "None"
	    }
	    Block {
	      BlockType		      Outport
	      Name		      "Out"
	      Position		      [355, 38, 385, 52]
	    }
	    Line {
	      SrcBlock		      "Check Signal\nAttributes"
	      SrcPort		      1
	      DstBlock		      "Zero Pad"
	      DstPort		      1
	    }
	    Line {
	      SrcBlock		      "Zero Pad"
	      SrcPort		      1
	      DstBlock		      "FFT"
	      DstPort		      1
	    }
	    Line {
	      SrcBlock		      "FFT"
	      SrcPort		      1
	      DstBlock		      "Magnitude\nSquared"
	      DstPort		      1
	    }
	    Line {
	      SrcBlock		      "In"
	      SrcPort		      1
	      DstBlock		      "Check Signal\nAttributes"
	      DstPort		      1
	    }
	    Line {
	      SrcBlock		      "Magnitude\nSquared"
	      SrcPort		      1
	      DstBlock		      "Out"
	      DstPort		      1
	    }
	  }
	}
	Block {
	  BlockType		  Reference
	  Name			  "Normalization"
	  Ports			  [1, 1]
	  Position		  [235, 107, 285, 143]
	  SourceBlock		  "dspspect3/Short-Time FFT/Normalization"
	  SourceType		  "SubSystem"
	  ShowPortLabels	  on
	  Permissions		  "ReadWrite"
	  TreatAsAtomicUnit	  off
	  RTWSystemCode		  "Auto"
	  RTWFcnNameOpts	  "Auto"
	  RTWFileNameOpts	  "Auto"
	  SimViewingDevice	  off
	  DataTypeOverride	  "UseLocalSettings"
	  MinMaxOverflowLogging	  "UseLocalSettings"
	}
	Block {
	  BlockType		  Product
	  Name			  "Product2"
	  Ports			  [2, 1]
	  Position		  [375, 39, 400, 66]
	  ShowName		  off
	  Inputs		  "**"
	}
	Block {
	  BlockType		  Reference
	  Name			  "Window"
	  Ports			  [1, 2]
	  Position		  [65, 32, 145, 88]
	  SourceBlock		  "dspsigops/Window\nFunction"
	  SourceType		  "Window Function"
	  winmode		  "Generate and apply window"
	  wintype		  "Hann"
	  N			  "64"
	  Rs			  "Rs"
	  beta			  "beta"
	  winsamp		  "Periodic"
	  UserWindow		  "hamming"
	  OptParams		  off
	  UserParams		  "{1.0}"
	  datatype		  "Double"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Out"
	  Position		  [420, 48, 450, 62]
	  InitialOutput		  "0"
	}
	Line {
	  SrcBlock		  "Window"
	  SrcPort		  2
	  Points		  [20, 0; 0, 50]
	  DstBlock		  "Normalization"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Normalization"
	  SrcPort		  1
	  Points		  [70, 0]
	  DstBlock		  "Product2"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Digital Filter"
	  SrcPort		  1
	  DstBlock		  "Product2"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Product2"
	  SrcPort		  1
	  DstBlock		  "Out"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Window"
	  SrcPort		  1
	  DstBlock		  "Magnitude\nFFT"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Magnitude\nFFT"
	  SrcPort		  1
	  DstBlock		  "Digital Filter"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "In"
	  SrcPort		  1
	  DstBlock		  "Window"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      Reference
      Name		      "Spectrum\nScope"
      Ports		      [1]
      Position		      [490, 200, 525, 250]
      FontSize		      10
      SourceBlock	      "dspsnks4/Spectrum\nScope"
      SourceType	      "Spectrum Scope"
      ScopeProperties	      on
      Domain		      "Frequency"
      HorizSpan		      "1"
      UseBuffer		      off
      BufferSize	      "128"
      Overlap		      "64"
      inpFftLenInherit	      off
      FFTlength		      "128"
      numAvg		      "2"
      DisplayProperties	      off
      AxisGrid		      on
      Memory		      off
      FrameNumber	      on
      AxisLegend	      off
      AxisZoom		      off
      OpenScopeAtSimStart     on
      OpenScopeImmediately    off
      FigPos		      "get(0,'defaultfigureposition')"
      AxisProperties	      off
      XUnits		      "Hertz"
      XRange		      "[0...Fs]"
      InheritXIncr	      on
      XIncr		      "1.0"
      XLabel		      "Samples"
      YUnits		      "dB"
      YMin		      "-165.177421961562"
      YMax		      "25.374802604835"
      YLabel		      "Magnitude, dB"
      LineProperties	      off
    }
    Block {
      BlockType		      Reference
      Name		      "Vector\nScope"
      Ports		      [1]
      Position		      [470, 95, 505, 145]
      FontSize		      10
      SourceBlock	      "dspsnks4/Vector\nScope"
      SourceType	      "Vector Scope"
      ScopeProperties	      off
      Domain		      "Frequency"
      HorizSpan		      "1"
      DisplayProperties	      off
      AxisGrid		      on
      Memory		      off
      FrameNumber	      on
      AxisLegend	      off
      AxisZoom		      off
      OpenScopeAtSimStart     on
      OpenScopeImmediately    off
      FigPos		      "get(0,'defaultfigureposition')"
      AxisProperties	      on
      XUnits		      "Hertz"
      XRange		      "[0...Fs]"
      InheritXIncr	      on
      XIncr		      "1"
      XLabel		      "Time"
      YUnits		      "dB"
      YMin		      "-91.7706059887706"
      YMax		      "41.9940621522331"
      YLabel		      "Amplitude"
      LineProperties	      off
    }
    Block {
      BlockType		      Reference
      Name		      "Vector\nScope1"
      Ports		      [1]
      Position		      [550, 30, 585, 80]
      FontSize		      10
      SourceBlock	      "dspsnks4/Vector\nScope"
      SourceType	      "Vector Scope"
      ScopeProperties	      off
      Domain		      "Frequency"
      HorizSpan		      "1"
      DisplayProperties	      off
      AxisGrid		      on
      Memory		      off
      FrameNumber	      on
      AxisLegend	      off
      AxisZoom		      off
      OpenScopeAtSimStart     on
      OpenScopeImmediately    off
      FigPos		      "get(0,'defaultfigureposition')"
      AxisProperties	      on
      XUnits		      "Hertz"
      XRange		      "[0...Fs]"
      InheritXIncr	      on
      XIncr		      "1"
      XLabel		      "Time"
      YUnits		      "dB"
      YMin		      "-87.6360065553052"
      YMax		      "40.0363659429979"
      YLabel		      "Amplitude"
      LineProperties	      off
    }
    Block {
      BlockType		      Reference
      Name		      "Vector\nScope2"
      Ports		      [1]
      Position		      [410, 240, 445, 290]
      FontSize		      10
      SourceBlock	      "dspsnks4/Vector\nScope"
      SourceType	      "Vector Scope"
      ScopeProperties	      off
      Domain		      "Frequency"
      HorizSpan		      "1"
      DisplayProperties	      off
      AxisGrid		      on
      Memory		      off
      FrameNumber	      on
      AxisLegend	      off
      AxisZoom		      off
      OpenScopeAtSimStart     on
      OpenScopeImmediately    off
      FigPos		      "get(0,'defaultfigureposition')"
      AxisProperties	      on
      XUnits		      "Hertz"
      XRange		      "[0...Fs]"
      InheritXIncr	      on
      XIncr		      "1"
      XLabel		      "Time"
      YUnits		      "dB"
      YMin		      "-165.177421988534"
      YMax		      "25.3748026061803"
      YLabel		      "Amplitude"
      LineProperties	      off
    }
    Block {
      BlockType		      Reference
      Name		      "Window\nFunction"
      Ports		      [1, 1]
      Position		      [195, 94, 250, 146]
      FontSize		      10
      SourceBlock	      "dspsigops/Window\nFunction"
      SourceType	      "Window Function"
      winmode		      "Apply window to input"
      wintype		      "Kaiser"
      N			      "64"
      Rs		      "50"
      beta		      "10"
      winsamp		      "Periodic"
      UserWindow	      "hamming"
      OptParams		      off
      UserParams	      "{1.0}"
      datatype		      "Double"
    }
    Block {
      BlockType		      ZeroOrderHold
      Name		      "Zero-Order\nHold"
      Position		      [40, 101, 75, 139]
      SampleTime	      "1/200"
    }
    Line {
      SrcBlock		      "Clock"
      SrcPort		      1
      DstBlock		      "Fcn"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Window\nFunction"
      SrcPort		      1
      Points		      [10, 0]
      Branch {
	DstBlock		"Magnitude\nFFT"
	DstPort			1
      }
      Branch {
	Points			[0, -75]
	DstBlock		"FFT"
	DstPort			1
      }
      Branch {
	Points			[0, 60]
	DstBlock		"Buffer1"
	DstPort			1
      }
    }
    Line {
      SrcBlock		      "Zero-Order\nHold"
      SrcPort		      1
      DstBlock		      "Buffer"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Buffer1"
      SrcPort		      1
      DstBlock		      "Scope"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Magnitude\nFFT"
      SrcPort		      1
      DstBlock		      "Vector\nScope"
      DstPort		      1
    }
    Line {
      SrcBlock		      "FFT"
      SrcPort		      1
      DstBlock		      "Abs"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Abs"
      SrcPort		      1
      Points		      [0, 0; 10, 0]
      Branch {
	DstBlock		"Product"
	DstPort			1
      }
      Branch {
	Points			[0, 15]
	DstBlock		"Product"
	DstPort			2
      }
    }
    Line {
      SrcBlock		      "Product"
      SrcPort		      1
      DstBlock		      "Vector\nScope1"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Fcn"
      SrcPort		      1
      Points		      [10, 0; 0, 40; -230, 0; 0, 50]
      DstBlock		      "Zero-Order\nHold"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Buffer"
      SrcPort		      1
      Points		      [20, 0]
      Branch {
	DstBlock		"Window\nFunction"
	DstPort			1
      }
      Branch {
	Points			[0, 105; 75, 0]
	Branch {
	  DstBlock		  "Spectrum\nScope"
	  DstPort		  1
	}
	Branch {
	  Points		  [0, 40]
	  DstBlock		  "Short-Time FFT"
	  DstPort		  1
	}
      }
    }
    Line {
      SrcBlock		      "Short-Time FFT"
      SrcPort		      1
      DstBlock		      "Vector\nScope2"
      DstPort		      1
    }
    Annotation {
      Name		      "窗函数模块以及\n各种频谱计算模块的应用测试模型"
"\n文件名:ch3example15.mdl"
      Position		      [106, 269]
      DropShadow	      on
      FontName		      "Arial"
      FontSize		      12
    }
  }
}

⌨️ 快捷键说明

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