plc.myforum.ro Forum Index plc.myforum.ro
PLCs users www.plc.myforum.ro!
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

RsLinx OPC Client libraries for Visual Studio

 
Post new topic   Reply to topic    plc.myforum.ro Forum Index -> ALLEN-BRADLEY(Rockwell Automation) Reg. U
View previous topic :: View next topic  
Author Message
luke
Junior 2
Junior 2


Joined: 11 May 2014
Posts: 27

PostPosted: 20/05/2014 18:33    Post subject: RsLinx OPC Client libraries for Visual Studio Reply with quote

RsLinx OPC Client libraries for Visual Studio

http://www.datafilehost.com/d/a07b339e
Back to top
View user's profile Send private message
luke
Junior 2
Junior 2


Joined: 11 May 2014
Posts: 27

PostPosted: 16/02/2018 18:11    Post subject: Reply with quote

[URL=https://userscloud.com/i2xvnbmcg0v5]RsLinx OPC Client sln.rar - 470 KB[/URL]
Back to top
View user's profile Send private message
luke
Junior 2
Junior 2


Joined: 11 May 2014
Posts: 27

PostPosted: 16/02/2018 18:38    Post subject: OPC Client c# .Net Sample (RSLinx OPC server) Reply with quote

OPC Client c# .Net Sample (RSLinx OPC server)

This is an example of communication with RSLinx OPC Server is the same for every OPC server).

Start by adding a reference to the OPC Foundation dlls:
- OpcNetApi.Com.dll
- OpcNetApi.dll
- OpcNetApi.Xml.dll
Then create Items that are shared for the all the form (or the project)
RsLinx OPC Client libraries for Visual Studio

Then create a button to connect (or just place the code after InitializeComponent(); if you want to autoconnect when the program starts)
Set the URL (in this sample there is the one of RSLinx) then add a group, add some items with theyr connection string, set the update time and the callback for the items that you want to read, then set a group for writings.

RsLinx OPC Client libraries for Visual Studio

This is the sample callback where i assign values that i read to a custom object.
Remember that the GUI and the OPC client runs on two different threads, so it's needed to use anonymous method for this (just use like is written in the sample).
With WPF and INotifyPropertyChanged it's not needed this.
You can just bind all your objects to the GUI items property, and this is really amazing and simple.
RsLinx OPC Client libraries for Visual Studio

This is the way to write a single word, basically lucrate a new one, check if in the write group there is already one of them, else i add it.
RsLinx OPC Client libraries for Visual Studio

This is a sample of how write from a button reading a textbox
RsLinx OPC Client libraries for Visual Studio

This code is written on a Micrologix / SLC platform and it reads only integer values, so when i read a value it's supposed to be a 16-bit word: that's why i cast it to (short). Remember that if you read a REAL value (F8:0 for example) you sould cast it to float and if you read from Controllogix or CompactLogix, you have to convert it to (int) because they are 32-bit words.

[URL=https://userscloud.com/y79pl2ql7nzv]OPC Client.rar - 211 KB[/URL]
Back to top
View user's profile Send private message
luke
Junior 2
Junior 2


Joined: 11 May 2014
Posts: 27

PostPosted: 16/02/2018 18:43    Post subject: WPF and OPC full sample project with RSLinx and data bindin Reply with quote

WPF and OPC full sample project with RSLinx and data binding

[URL=https://userscloud.com/dslz78kulbps]opc sample 2.rar - 251 KB[/URL]
Back to top
View user's profile Send private message
luke
Junior 2
Junior 2


Joined: 11 May 2014
Posts: 27

PostPosted: 16/02/2018 21:05    Post subject: opc core components redistributables-3.00 Reply with quote

opc-core-components-redistributables-3.00
The core components contains elements that are critical for all OPC Classic applications to work. The core components should be deployed to all PCs where OPC Classic will be used.


Includes the Core components binaries (*.DLL and *.EXE) - COM Proxy/Stub module, including OPCENUM.EXE. It also includes optional headers/libraries need to build OPC Classic applications in C++ or .NET.
[URL=https://userscloud.com/m486sdiztyby]opc-core-components-redistributables-3.00.107-20180130.zip - 5.1 MB[/URL]
Back to top
View user's profile Send private message
luke
Junior 2
Junior 2


Joined: 11 May 2014
Posts: 27

PostPosted: 16/02/2018 21:15    Post subject: Reply with quote

[URL=https://userscloud.com/2ogs06k2o4od]opc-ua-local-discovery-server-1.03.371.424-mergemodule-20171208.zip - 1.9 MB[/URL]
[URL=https://userscloud.com/1w1ot1s0vnqx]opc-ua-local-discovery-server-1.03.371.424-20171207.zip - 3.2 MB[/URL]
[URL=https://userscloud.com/36t1xydah5vh]opc-ua-java-stack-1.02-source-code-and-sample-applications-337.2-stable-20150603.zip - 14.4 MB[/URL]
[URL=https://userscloud.com/kfslhmc6fqk7]opc-ua-1.02-.net-stackandsamples-336.0-20150707.zip - 30.1 MB[/URL]
[URL=https://userscloud.com/uhavzfm7clul]opc-ua-1.02-.net-sample-applications-setup-336.0-20150630.zip - 15.4 MB[/URL]
Back to top
View user's profile Send private message
leodg1
Junior
Junior


Joined: 07 Feb 2015
Posts: 4

PostPosted: 05/04/2018 22:47    Post subject: help please Reply with quote

Hello I have this ERROR ” System.IO.FileNotFoundException: ‘Could not load file or assembly ‘OpcRcw.Dx, Version=1.0.1.21, Culture=neutral, PublicKeyToken=9a40e993cbface53′ or one of its dependencies. The system cannot find the file specified.’
” ANY ADVICE ?
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    plc.myforum.ro Forum Index -> ALLEN-BRADLEY(Rockwell Automation) Reg. U All times are GMT + 2 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Fa-ti si tu propriul forum GRATUIT, pe www.myforum.ro