All Projects → leogle → OPCAutomationDotNet

leogle / OPCAutomationDotNet

Licence: Apache-2.0 license
C#封装的OPC客户端与服务端

Programming Languages

C#
18002 projects

Projects that are alternatives of or similar to OPCAutomationDotNet

terraform-provider-opc
Terraform Oracle Public Cloud provider
Stars: ✭ 29 (-53.97%)
Mutual labels:  opc
milo-ece2017
Materials about my talk around Eclipse Milo at EclipseCon Europe 2017
Stars: ✭ 22 (-65.08%)
Mutual labels:  opc
Sharpscada
C# SCADA
Stars: ✭ 2,043 (+3142.86%)
Mutual labels:  opc
Open62541
Open source implementation of OPC UA (OPC Unified Architecture) aka IEC 62541 licensed under Mozilla Public License v2.0
Stars: ✭ 1,643 (+2507.94%)
Mutual labels:  opc
ASMD
OPC UA Address Space Model Designer
Stars: ✭ 47 (-25.4%)
Mutual labels:  opc
node-opcda
Node.js package to access OPC Da 2.0 for reading and writing. Welcome your PLC JavaScript overlords. Better yet, program them!
Stars: ✭ 30 (-52.38%)
Mutual labels:  opc
OPC-Classic-SDK
Softing OPC Classic SDK
Stars: ✭ 30 (-52.38%)
Mutual labels:  opc

使用C#进行封装的OPC客户端和服务端

依赖项:

*OPCAutomation
*wtOPCSvr

客户端使用方法:

//初始化客户端
private OPCClientWrapper opcClient;
opcClient.Init("127.0.0.1", GlobalConfig.Instance.ConfigItem.Local.DataSourceName);
//添加点位变化事件回调
opcClient.OpcDataChangedEvent += new OPCDataChangedHandler(OpcClient_OpcDataChangedEvent);
//添加监视点位
opcClient.MonitorOPCItem(name);

服务端使用方法:

//初始化
 private OPCSvrWapper opcServer;
 opcServer = new OPCSvrWapper();
opcServer.CLSIDServer = "AD5F2291-D45D-494C-8C08-62EA58512F9F";
opcServer.ServerName = SERVER_NAME;
//启动
opcServer.StartOPCServer();
//添加点位
opcServer.AddTag(name, value, value.ToString(), quality, false);
opcServer.UpdateTag(name, value, quality);

注意:由于OPC服务端在加载大量标签时占用较大内存,且.net程序有最大内存限制,超过内存会报OutMemory异常, 在需要监测大量设备时请谨慎使用,目前测试服务端可支撑20,000点点位监视,超过该范围情况请尝试使用C++调用wtOpcSvr.dll

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].