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

📄 freeportcomm_tx_simple2.mdl

📁 simulink real-time workshop for dragon12 development board from
💻 MDL
📖 第 1 页 / 共 2 页
字号:
      MaskCallbackString      "||"
      MaskEnableString	      "on,on,on"
      MaskVisibilityString    "on,on,on"
      MaskToolTipString	      "on,on,on"
      MaskVarAliasString      ",,"
      MaskVariables	      "port=@1;pin=&2;sampletime=@3;"
      MaskInitialization      "[portstr, pinstr, pins] = mbc_digitalinput(port"
", pin, sampletime);\n"
      MaskDisplay	      "fprintf('%s\\nPins: %s', portstr, pinstr)"
      MaskSelfModifiable      on
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      MaskValueString	      "Port H|0 1 2 3 4 |0.1"
      System {
	Name			"Digital input"
	Location		[262, 81, 703, 287]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"A4"
	PaperUnits		"centimeters"
	ZoomFactor		"100"
	Block {
	  BlockType		  Demux
	  Name			  "Demux"
	  Ports			  [1, 5]
	  Position		  [215, 19, 220, 201]
	  BackgroundColor	  "black"
	  ShowName		  off
	  Outputs		  "5"
	}
	Block {
	  BlockType		  "S-Function"
	  Name			  "Digital Input SFcn"
	  Tag			  "MC9S12target"
	  Ports			  [0, 1]
	  Position		  [40, 91, 165, 129]
	  List {
	    ListType		    RTWdata
	    portStr		    "PTH"
	    ddrStr		    "DDRH"
	    pinMask		    "31"
	    pinStr		    "0,1,2,3,4"
	  }
	  FontSize		  12
	  FunctionName		  "digIn_sfcn_9S12"
	  Parameters		  "sampletime, port, pins"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Out1"
	  Position		  [375, 26, 395, 44]
	}
	Block {
	  BlockType		  Outport
	  Name			  "Out2"
	  Position		  [375, 71, 395, 89]
	  FontSize		  12
	  Port			  "2"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Out3"
	  Position		  [375, 116, 395, 134]
	  FontSize		  12
	  Port			  "3"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Out4"
	  Position		  [375, 161, 395, 179]
	  FontSize		  12
	  Port			  "4"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Out5"
	  Position		  [375, 206, 395, 224]
	  FontSize		  12
	  Port			  "5"
	}
	Line {
	  SrcBlock		  "Digital Input SFcn"
	  SrcPort		  1
	  DstBlock		  "Demux"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Demux"
	  SrcPort		  1
	  Points		  [0, -5]
	  DstBlock		  "Out1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Demux"
	  SrcPort		  2
	  DstBlock		  "Out2"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Demux"
	  SrcPort		  3
	  DstBlock		  "Out3"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Demux"
	  SrcPort		  4
	  DstBlock		  "Out4"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Demux"
	  SrcPort		  5
	  DstBlock		  "Out5"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      Display
      Name		      "Display"
      Ports		      [1]
      Position		      [370, 163, 450, 267]
      Decimation	      "1"
    }
    Block {
      BlockType		      SubSystem
      Name		      "FreePortComms_TX"
      Tag		      "MC9S12Target_FreePortCom"
      Ports		      [1]
      Position		      [320, 24, 480, 126]
      AncestorBlock	      "mc9S12tool/Send user data"
      FontSize		      12
      ShowPortLabels	      off
      TreatAsAtomicUnit	      off
      MaskHelp		      "helpview('C:\\Documents and Settings\\fwornle\\"
"My Documents\\frank\\_cProgs\\Motorola\\rtmc9S12_CW_R13\\bin\\mc9S12.map', 'm"
"c9S12_FPRXD_In_blkref')"
      MaskPromptString	      "Sample time|Communication port|Baudrate|Channel"
" number|Number of elements|Data Type|Block sends raw data"
      MaskStyleString	      "edit,popup(SCI0|SCI1|COM1|COM2|COM3|COM4),popup"
"(300|600|1200|2400|4800|9600|19200|38400|57600|115200),edit,edit,popup(SINGLE"
"|INT8|UINT8|INT16|UINT16|INT32|UINT32|BOOLEAN),checkbox"
      MaskTunableValueString  "on,on,on,on,on,on,on"
      MaskCallbackString      "||||||"
      MaskEnableString	      "on,on,on,on,on,on,on"
      MaskVisibilityString    "on,on,on,on,on,on,on"
      MaskToolTipString	      "on,on,on,on,on,on,on"
      MaskVarAliasString      ",,,,,,"
      MaskVariables	      "sampletime=@1;port=@2;baudrate=@3;channel=@4;bu"
"f_size=@5;data_type=@6;format=@7;"
      MaskInitialization      "[buf_sizestr, portNamestr, baudratestr, channel"
"str, data_type_str, sampletime_str] = mbc_freeporttxd(sampletime, port, baudr"
"ate, channel, buf_size, data_type, format);\n"
      MaskDisplay	      "fprintf('Transmit %s element(s)\\nComm port: %s"
"\\nBaudrate: %s bps\\nChannel: %s\\nData type: %s\\n Sample rate: %s', buf_si"
"zestr, portNamestr, baudratestr, channelstr, data_type_str, sampletime_str)"
      MaskSelfModifiable      on
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      MaskValueString	      "0.1|SCI0|115200|0|5|UINT8|off"
      System {
	Name			"FreePortComms_TX"
	Location		[542, 167, 996, 332]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"A4"
	PaperUnits		"centimeters"
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "In1"
	  Position		  [45, 60, 65, 80]
	  FontSize		  12
	}
	Block {
	  BlockType		  DataTypeConversion
	  Name			  "Data Type Conversion"
	  Position		  [160, 56, 215, 84]
	  DataType		  "uint8"
	}
	Block {
	  BlockType		  "S-Function"
	  Name			  "SEND_VIA_FREE_PORT"
	  Tag			  "MC9S12target"
	  Ports			  [1]
	  Position		  [280, 49, 420, 91]
	  List {
	    ListType		    RTWdata
	    portStr		    "0"
	    portNameStr		    "SCI0"
	    baudrateStr		    "115200"
	    formatStr		    "0"
	  }
	  FontSize		  12
	  FunctionName		  "freePortComms_txd"
	  Parameters		  "sampletime, channel, buf_size, data_type, p"
"ort, baudrate, format"
	  MaskIconFrame		  on
	  MaskIconOpaque	  on
	  MaskIconRotate	  "none"
	  MaskIconUnits		  "autoscale"
	}
	Line {
	  SrcBlock		  "Data Type Conversion"
	  SrcPort		  1
	  DstBlock		  "SEND_VIA_FREE_PORT"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "In1"
	  SrcPort		  1
	  DstBlock		  "Data Type Conversion"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      Mux
      Name		      "Mux"
      Ports		      [5, 1]
      Position		      [170, 35, 175, 115]
      ShowName		      off
      Inputs		      "5"
      DisplayOption	      "bar"
    }
    Line {
      SrcBlock		      "Digital input"
      SrcPort		      1
      DstBlock		      "Mux"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Digital input"
      SrcPort		      2
      DstBlock		      "Mux"
      DstPort		      2
    }
    Line {
      SrcBlock		      "Digital input"
      SrcPort		      3
      DstBlock		      "Mux"
      DstPort		      3
    }
    Line {
      SrcBlock		      "Digital input"
      SrcPort		      4
      DstBlock		      "Mux"
      DstPort		      4
    }
    Line {
      SrcBlock		      "Digital input"
      SrcPort		      5
      DstBlock		      "Mux"
      DstPort		      5
    }
    Line {
      SrcBlock		      "Mux"
      SrcPort		      1
      Points		      [75, 0]
      Branch {
	Points			[0, 140]
	DstBlock		"Display"
	DstPort			1
      }
      Branch {
	DstBlock		"FreePortComms_TX"
	DstPort			1
      }
    }
  }
}

⌨️ 快捷键说明

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