6FX1111-0AG02-+-6FX1111-0AG02
6FX1111-0AG02-+-6FX1111-0AG02
個人感覺好像用R、S更復雜一些,要考慮條件,經常出現(xiàn)R和S條件同時滿足的情況,導致控制出問題。
答:采用賦值(=)還是R/S S/R要根據(jù)實際情況來確定的, R S指令能實現(xiàn)的功能,賦值(=)指令不一定可以實現(xiàn),而賦值指令能實現(xiàn)的功能就一定可以用 R S指令來做到。
然而如果用 R S指令來替代賦值指令功能,則會導致程序指令數(shù)量大幅增加,使得簡單程序變得更復雜,程序變得很冗長,也無形中加長了循環(huán)周期時長,對小程序來說影響不大,但對于復雜的大型程序來說這是不可取的,程序越精簡,執(zhí)行就越精準,用無謂的語句來使程序變復雜是編程的忌諱。就如樓上所舉的例子,用賦值指令二條語句就能完成的,用R、S指令就至少需要4條指令。
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
公司 名稱:廈門泰尼電氣有限公司
固定 電話:0592-6809819
聯(lián) 系 人:張亮
傳 真:0592-6890859【請備注“張亮”收】
商 務 Q Q: 2314094943
手 機:18030028083
Q Q 郵 箱:2314094943@qq.com
需要可以聯(lián)系絕對給你滿意的價格
公司地址:廈門市海滄區(qū)海滄街道濱湖一里7號2008室
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
“經常出現(xiàn)R和S條件同時滿足的情況,導致控制出問題。”這就要看你的實際需要來選擇R/S(置位優(yōu)先)還是S/R(復位優(yōu)先)了,選擇R/S當條件同時滿足時結果是1(置位),而選擇S/R則當條件同時滿足時結果為0(復位)。明白了這一點,就不會導致控制出問題了。
賦值指令和S R指令無所謂哪一個更好,要根據(jù)你的程序所需來確定。編程的原則是越簡單越好,千萬不要簡單語句復雜化。
你需要了解r,s以及線圈的功能。線圈的功能就是保持線圈的值和狀態(tài)位一致,r是狀態(tài)為1復位輸出,s狀態(tài)為1置位輸出。r,s可以保持輸出狀態(tài)狀態(tài),知道下一個指令改變輸出值。
Reliance Electric 0-51893-4 FCCE General Field Supply
Reliance Electric 57414-1P Modbus Interface Module
RELIANCE ELECTRIC AC DRIVE 1AC2002U
Reliance Electric S20-204P2C1000/?S20204P2C1000
One-day shipping available
Reliance Electric Resolver Input 57411-1
Reliance Electric 48267-L 9.420 OHM Resistor NEW
RELIANCE ELECTRIC RESISTOR SCALING MODULE 805403-R2
Reliance Electric 8647511R Stack Rectifier 86475-11R
Reliance Electric 0-51847-4 VLDE Voltage Level Detector
Reliance Electric CDE 311A10 Relay 311A10-115 NEW
Reliance Electric 1AC2002U AC Drive #8330
Reliance Electric MD65 1HP AC Drive 6MDDN-2P3102
Expedited shipping available
RELIANCE ELECTRIC DRIVE BOARD MODEL# 0-52803-2
One-day shipping available
RELIANCE ELECTRIC PRINTED CIRCUIT 115VAC INPUT CARD
REMANUFACTURED RELIANCE ELECTRIC DIODE 405919-43AW
One-day shipping available
Reliance Electric 0-51865-14 CLDR Drive Module
Reliance Electric IRCG DC Drive Relay Module 0-51839-8
Reliance Electric Cable # 802815-22
Expedited shipping available
Reliance Electric 0-54381 Sequence Detector Card NEW
RELIANCE ELECTRIC 57416 REMOTE I/O COMMUNICATIONS MOD
Reliance Electric 14C225 Test Meter Adapter Kit 0-57006
Reliance Electric 0-52803-2 FVCC Control Card 0528032
Reliance Electric 0-52803-2 FVCC Frequency to Voltage
New Reliance Electric Sleeve 411621-09A 41162109A
Expedited shipping available
RELIANCE ELECTRIC 0-52012 PC BOARD 052012 NEW
Reliance Electric 0-51665 DRIVE CIRCUIT Board 051665
RELIANCE ELECTRIC RE0418X CARBON BRUSH LOT OF 6 NIB
NEW, Reliance Electric HR500 Servo Drive
One-day shipping available
Reliance Electric Rack 45C913 Shark 6 Slot (5 I/O)
Reliance Electric Recitifier Stack 86474-1S NEW #23166
RELIANCE ELECTRIC CO. 7018191AB POWER CUBE
Reliance Electric RE 109081-102 RC 109081102RC
Reliance Electric UDRA Board # 80950-00
Expedited shipping available
RELIANCE ELECTRIC 419904-1BX REPLACEMENT BRUSH LOT OF 7
RELIANCE ELECTRIC CLRA MODULE 0-52824
RELIANCE ELECTRIC M3452-H9C00 SNUBBER RESISTOR NIB
RELIANCE ELECTRIC 600442-14A CAPACITOR 3000MFD NEW
Reliance Electric ES281CMB 275W Power Supply 57491
Reliance Electric AutoMate # 802802-R
Expedited shipping available
**NEW** Reliance Electric PC Board # 0-48652-30
Expedited shipping available
RELIANCE ELECTRIC 410403-51AW100 AMP THYRISTOR
One-day shipping available
NEW RELIANCE ELECTRIC BRUSH BOX OF 8 419904-1AR
RELIANCE ELECTRIC 57400-1 115VAC/DC INPUT MODULE
One-day shipping available
RELIANCE ELECTRIC 0-54349 PLC MODULE
Reliance Electric 86474-7S Thyristor Assembly
NEW RELIANCE ELECTRIC RECTIFIER STACK ASSY. 86466-11R
RELIANCE ELECTRIC 0-57010 PC BOARD 057010 NEW
NIB Reliance Electric Drive Board Relay 0-55325-60
Expedited shipping available
RELIANCE ELECTRIC TLOA MODULE 0-52806
RELIANCE ELECTRIC PRINTED CIRCUIT AUTO BUS
NEW RELIANCE ELECTRIC 0-52808-5 FACTORY REBUILD
Reliance Electric Printed Circuit Extender Board USED?
NEW RELIANCE ELECTRIC RECTIFIER STACK ASSY. 86466 87R
Reliance Electric 803623-R Battery Backup Unit 803623R
Reliance Electric 0-52860 VSAA Drive Regulator 052860
Reliance Electric DVDT Interface Board 0-58706-23
Reliance Electric MD65 2HP AC Drive 6MDEN-3P0102
Expedited shipping available
RELIANCE ELECTRIC CCRA 809.44-00 CONTROL CARD
Reliance Electric 57400-1 115 V AC/DC Input Module RE
**NIB** Reliance Electric Transistor 602909-123AW
Expedited shipping available
RELIANCE ELECTRIC DFSA MODULE 0-52823
New Reliance Electric 0-51377-35 Master Connection
One-day shipping available
New Reliance Electric 0-51377-38 Test Card