您当前的位置:五五电子网电子知识plc技术PLC入门上位机与OMRON PLC通信与监控设计 正文
上位机与OMRON PLC通信与监控设计

上位机与OMRON PLC通信与监控设计

点击数:7598 次   录入时间:03-04 11:35:38   整理:http://www.55dianzi.com   PLC入门

f1,f2:byte;

begin

f1:=0;

f2:=0;

datacheck:=0;

len:=length(s);

tmpvar:=0;

for i:=1 to len do

begin

datacheck:=ord(datacheck) xor ord(s[i]);

end;

f1:=datacheck and $0f;

f2:=datacheck and $f0;

f2:=f2 shr 4;

result:=inttostr(f2)+inttostr(f1);

end;

// 调用mscomm控件实现plc通信

procedure tform1.handshake_plc;

上一页  [1] [2] [3] [4] [5] [6]  下一页


本文关键字:通信  监控  PLC入门plc技术 - PLC入门