Location:
Search - rslinx delphi
Search list
Description: 先运行力控应用程序(如演示工程——反应釜),实时数据库系统亦随之启动。
然后启动delphi6.0,创建一个新的工程。
在form1窗体中,放置DdeClientConv控件(system标签页),设置ConnectMode属性值为ddeAutomatic、DdeService属性值为db、DdeTopic属性值为db;
接下来放置DdeClientItem控件(system标签页),设置DdeConv为DdeClientConv1,设置DdeItem属性值为所要读取的数据库点参数值如dbmixvol.pv;
放置一个edit控件;
放置一个timer控件,设置interval属性值为100;在ontimer脚本中加入:
procedure TForm1.Timer1Timer(Sender: TObject)
begin
edit1.text:=form1.DdeClientItem1.Text
end
-opc rslinx
Platform: |
Size: 5120 |
Author: 慰藉 |
Hits:
Description: AB通讯程序不需要更改可以直接使用,RSLinx必须有授权否则无法通讯。
如果被挂起来可以考虑放到线程里面运行比较稳定,具体使用如有不清楚的可以打电话给我,后面有Delphi版和C版都不需要更改只要将PLC变量填入指定数组就可以读出和写入数据,Delphi版和C版相对复杂点但稳定性可移植性比较强适合做大程序
-The AB communication procedure does not need to change may use directly, otherwise RSLinx must have the authorization to be unable the communication.if is hung may consider that puts moves to the thread inside is quite stable, the concrete use like has not clearly may telephone to give me, behind has the Delphi version and the C version does not need to change, so long as fills in the PLC variable assigns the array to be possible to read out and the write data, Delphi version and C version relatively complex spot, but the stable probability is quite strong suitably to make big procedure
Platform: |
Size: 2048 |
Author: 夏永康 |
Hits: