Has anybody tried to use the AF SDK with Mono?
Can you use WebAPI instead?
That might work., but the AF-SDK would definitely be better for the application I have in mind.
Are you referring to the Mono-Project? If so, what's are you intending to do? Do you possibly plan developing an AF SDK application for a non-Windows platform?
Yes, I am referring to a Mono-project. I have a application that "compiles" itself and information using mono. The application explicitly states that some VS .NET/c# code is not compatible with it and that Mono needs to be used. I want to make this application AF aware.
I really have no experience with this Mono-project and I am not sure who in this community or OSIsoft has experience with this product. That is why my suggestion for you is simple: create a simple project and test it. In case you have issues just use PI Web API, a RESTful web service on top of the PI System instead of PI AF SDK. PI Web API is compatible with non-Windows programming languages and you don't need .NET Framework on the client in order to use this product.
Hope this helps!
It took me some time to get started with Mono but I've successfully tried this in the meantime. I've created a Gtk# 2.0 Project, and created a simple form with just 2 buttons. The project has a reference to the most recent AF SDK assembly (RDA) and is targeted to x86 platform - I don't see any option to build for 64-bit. Behind Button # 1 a connection against a PI Data Archive is established, some tags queried and events retrieved for a period of time until the connection becomes closed. Button # 2 does similar with AF Attribute values.
I was able to copy and paste code from another Visual Studio project and it works without changing a single line of code. We don't know what future brings and there's a chance an incompatibility becomes introduces either on the Gtk side, AF SDK side or with something either one depends on. Based on my experience, I consider the chance rather unlikely.
I was about to try the same experiment. Unfortunately, I am trying to use MonDev and I can't even get it to install. It tells me GTK is not on the machine, but it is and is in the path. Where did you install GTK in regards to the Mono directory?
I used a Windows Server 2008 R2 Enterprise addition - not intentionally but because it was available and installed Gtk# for .Net 2.12.26
I am not a friend of compiling applications at the command prompt. I tried it but ran into issues and searched for something that allows me creating Gtk# project consisting of multiple files without the requirement for me to understand all the details. I don't want to make any advertisement but when you search the internet for gtk mono editor project, a site offering a development environment for download should be within the first results.
The major concept with the open-source Mono-Project is to offer developers the ability to build cross-platform applications that can be compiled on Mac OS X, Linux and Windows. Using AF SDK with mono libraries however can only work on Windows platforms because AF SDK is offered for Windows only and to my knowledge there are no plans to offer AF SDK for Linux or Mac OS X. Users interested building platform independent applications or applications on non-Windows platforms must be using PI Data Access technologies that are supported on non-Windows platforms like PI JDBC and PI System Web API.
Gregor, the application I want to hook AF into runs in Windows but has to be compiled with Mono. So, Linux is not the issue.
Please accept my apology. The goal was to set the expectations right for all users stumbling across this thread in future.
Retrieving data ...