Git Product home page Git Product logo

opc2powerbi's Introduction

OPC2PowerBI

This tool allows to connect to OPC UA and DA servers, poll for data and subscribe to events and write data in real time to MS PowerBI using the OData Feed data source.

It is simple to configure, the opc2powerbi.conf file is self explained, it must be put in the same folder as the exe file.

After configuring OPC servers and tags, create a new OData Feed data source in PowerBI and type http://127.0.0.1:8080/odata in the URL field.

Data refreshs must be forced manually. As far as I know OData data source does not support periodic updates (DirectQuery) in PowerBI.

The code is written in C# and it uses the h-OPC library for C#.

To provide user/password credentials for the connection, format the server URL as below.

opc.tcp://user:[email protected]:53530/OPCUA/SimulationServer

Warning: The h-opc library is unmaintained legacy and is known to have problems to enable OPC connections using certificates.

Version 0.5 requires the .NET 6.0 runtime.

Executable binaries are available for download in the Releases section.

Need any help? Create an issue here or contact me. Here is my LinkedIn contact: https://www.linkedin.com/in/ricardo-olsen/.

Example of config file:

#port service_name
8080, odata

# OPC SERVERS

#  OPC_UA_URL,                   READ_INTERVAL_IN_SECONDS,  SERVER_NAME, CERTIFICATE_FILE_PATH, CERTIFICATE_PASSWORD
opc.tcp://opcuaserver.com:48484, 10,                        Server1,     certfile.cer,          password

# OPC TAGS TO READ FROM THE SERVER

# OPC_TAG_PATH                        ,TYPE(opt) ,SUBSCRIBE ,TAG(must be unique)
ns=1;s=Countries.US.Queens.Latitude   ,    ,Y         ,US.Queens.Latitude                
ns=1;s=Countries.US.Queens.Longitude  ,    ,N         ,US.Queens.Longitude    
# ... repeat for more servers

#  OPC_DA_URL,                           READ_INTERVAL_IN_SECONDS,  SERVER_NAME,
opcda://127.0.0.1/Prosys.OPC.Simulation, 20,                        Server5
# OPC_TAG_PATH                        ,TYPE(opt) ,SUBSCRIBE ,TAG(must be unique)
Random.PsFloat1                       ,float     ,Y         ,
Random.PsInteger1                     ,VT_I4     ,N         ,
Random.PsBool1                        ,bool      ,N         ,
Random.PsState1                       ,state     ,N         ,
Random.PsDateTime1                    ,DateTime  ,N         ,

opc2powerbi's People

Contributors

riclolsen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

opc2powerbi's Issues

OPCDA to MQTT

Hi Ricardo,
What is the chance of creating a similar tool that can publish to a MQTT broker (Standard or Sparkplug B) instead of to an OData source?

Help on error message

Hi,

I am getting this error when trying to start the exe. I have tried versions 0.1 and 0.3.
Can you help me, please.
errormsg

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.