EasyManua.ls Logo

Minebea CSD-814B - Page 180

Minebea CSD-814B
183 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
167
13−3−3.
Sample program for RS−422
1000 '
1010 '---------------------------------------------
1020 'CSD−814B Sample program for RS−422
1030 'Minebea Co., Ltd. Measuring Components Div.
1040 '---------------------------------------------
1050 '
1060 'Transfers data to ID0 and ID2 orderly.
1070 'It is decided as “Time−out” when the data is not returned within 3 s
after transferring command.
1080 '----------------< Start >-----------------
1090 '
1100 CLS
1110 '----------------< Command Table >---------------
1120 OPTION BASE 1 : DIM TXD$(10), IXD$(10)
1130 '
1140 TXD$(1) = “R020” : INX$(1) = “Reading−out display value for ID0”
1150 TXD$(2) = “R122” : INX$(2) = “Reading−out Net Weight for ID1”
1160 TXD$(3) = “R224” : INX$(3) = “Reading−out Gross Weight for ID2”
1170 TXD$(4) = “R030” : INX$(4) = “Reading−out S1 set value for ID0”
1180 TXD$(5) = “R131” : INX$(5) = “Reading−out S1 set value for ID1”
1190 TXD$(6) = “R232” : INX$(6) = “Reading−out S1 set value for ID2”
1200 '
1210 '----------------< RS port declaration >----------------
1220 OPEN “COM : 071NN” AS #1 : ’Odd number parity, Data length : 7 bits
Stop bit : 1 bit
1230 ON COM GOSUB 1740 : ’Receiving process : Interruption drives.
1240 COM ON
1250 '
1260 '----------------< Initial setting >-----------------
1270 C = 10 : ’Data counter limit
1280 S = 1 : ’Data pointer
1290 NN# = 0 : ’Receiving counter
1300 TM = 3 : ’Time−out limit (second)
1310 SW = 0 : ’RS receiving flag

Table of Contents

Related product manuals