Noob guide to OPC: how to write a C# Hello World client?

前端 未结 6 873
终归单人心
终归单人心 2021-02-10 16:36

Here is my situation:

We have a software that is used to monitor solar power plants developed. I have to introduce OPC as a new way to acquire data from the physical devi

相关标签:
6条回答
  • 2021-02-10 17:08

    I suggest you to look at the OpenOpcUa initiative. The full code for OPC UA client and server is available for download. This code run Windows, Linux and WVWorks. more information at www.openopcua.org

    0 讨论(0)
  • 2021-02-10 17:14

    I recommend you use the newest flavor of OPC, OPC UA.

    You can build a simple HMI app in C# using these free tools:

    1.Microsoft Visual Studio Express 2013 for Windows Desktop available from: http://www.microsoft.com/visualstudio/eng/products/visual-studio-express-for-windows-desktop.

    2.The latest source from this site: https://github.com/convertersystems/opc-ua-samples

    With this kit you can: Browse OPC UA servers directly from the Visual Studio IDE. Drag and drop the variable nodes to create a data subscription. Use bindings to animate your UI control's properties from the subscription's data values.

    Check out the sample application 'Workstation'.

    0 讨论(0)
  • 2021-02-10 17:15

    For testing purposes you can use OPC UaFx Client (.Net) whose NugetPackage can be found here: OPC UaFx Client in .Net

    Though it is proprietary, but it will run your application for 30 minutes, after 30 minutes the application can be re-run.

    0 讨论(0)
  • 2021-02-10 17:19

    Providing you with a tutorial... but a little bit of information first:

    OPC is everything but open (in an open source way)... the OPC foundation has specified a lot of things to standardize the way automation can communicate - on top of which you could build your own stack. Be warned, the stuf is HUGE(!). So to ease the workload a little, there is a hand full of companies providing you with stacks for different programming languages. Matrikon, Prosys, Unified Automation to name some of them.

    However to connect to a demoserver you need to implement a provider and do still need a stack providing you with the basic functionality and to download such a stack, your company must register with the supplier. There is no way round I'm afraid. However there were OpenSource projects: http://www.openopcua.org/ never tried the code though.

    BUT just to prove the usefulness check this tutorial http://doc.unifiedautomation.com/

    And a book written by the company owner of UA (maybe your company has "Springerlink" access?) http://www.springer.com/computer/information+systems+and+applications/book/978-3-540-68898-3

    0 讨论(0)
  • 2021-02-10 17:27

    You can download all OPC materials from OPC Foundation, specifically you are looking for the OPC .NET API 2.00 Source Code Download Link. It contains a solution that has the OPC dlls and sample clients (AE, DA, DX, HDA) to give you an idea of how OPC works. This source and DLLs are the basis for the OPC standards. Using these you can call to any proprietary OPC server that is compliant with the OPC standards.

    0 讨论(0)
  • 2021-02-10 17:32

    First you need to know which OPC you want to use.

    • "Classical OPC" DA/HDA and A&E based on Windows COM/DCOM
    • OPC XML/DA, DA as a web service but with some limited perfomance.
    • OPC UA, the last specification allowing you to implement it on non Windows platform and merging DA, HDA and A&E.

    After that, you could choose the language you want to use and so use some SDK free or not.

    One good website for OPC : http://www.opcconnect.com/source.php has lists of Toolkits you could use.

    0 讨论(0)
提交回复
热议问题