Skip navigation
All Places > PI Developers Club > Blog > 2010 > November
2010
skwan

AF, AF 2010, AF 2010 R2, ...

Posted by skwan Employee Nov 24, 2010

So, this is my first blog at vCampus.  Actually this is my first blog ever, anywhere .  First a quick introduction, my name is Steve Kwan and I'm the Product Manager for AF.  I joined OSIsoft back in June this year (2010) and I have to say I'm very fortunate to work with a smart and talented group of people at OSIsoft.  I was met some of you vCampus members at the vCampus Live! event a few months ago and I've been trying to get smarter by following the vCampus community via forums and such.  I have to say I'm amazed by the experience and expertise of the vCampus community.

 

As you may already learned by my post on vCampus last week, AF 2010 R2 was posted as a Community Technology Preview (CTP) for the vCampus community.  AF 2010 R2 would be the first AF release that I'm involved with at OSIsoft as product manager.  I am fortunate enough to have a great bunch of very smarts people developing what I feel is an extremely important piece of software as we move the PI System from a tag centric world to an asset centric world.  I have already seen some great work produced by OSIsoft's partners, system integrators, etc. that leverage the features and functions of AF.  I'm proud to be part of this evolution.

 

AF 2010 R2 will provide to you a very important piece of software, the AF Builder.  For many people, it will be the primary way to interact with AF.  Our work is not complete, there are many features and functions of AF that aren't yet supported by the AF Builder.  We will continue to improve on it, hopefully with your feedback and encouragement.  AF 2010 R2 also includes a whole slew of fixed and enhancements that are spelled out in the released notes.  Please consult these release notes for additional details.  As of this time, we're looking at releasing AF 2010 R2 some time towards the latter part of December.

 

We release CTP to the vCampus community for several reasons.  First off, you deserve the opportunity to be the first to try out the latest and greatest.  More importantly, I know you won't be bashful in providing useful feedback to us to improve the software.  So don't be shy, give it a try and by all means, provide to us any feedback that you may have via forum postings or emails.  You are welcome to email BetaAF@osisoft.com and myself at skwan@osisoft.com

 

Looking ahead past AF 2010 R2 into 2011, we have plans to add a bunch of features and enhancements to AF.  Many other OSIsoft products will be released based on the infrastructure AF provides.  Stay tuned, myself and the other product managers will keep you updated.  For a sneak peak, please visit our PI Product Roadmap webpage at: http://techsupport.osisoft.com/TechSupport/NonTemplates/roadmap.aspx

 

Best regards,

 

Steve Kwan

OSIsoft vCampus turned 2 !!

Posted by spilon Nov 23, 2010

Yes, blow the candles: the vCampus program had its 2-year anniversary last Tuesday, November 16th !!

 

Everybody is really busy these days (noticed the website upgrade? ) and this kind of went unnoticed, but I think it is important to take a minute and realize where we're at and where we're coming from. We announced the vCampus program back in October 2008, at the Amsterdam Users Conference - it went live on November 16th, 2008 and consisted of our first true online community.

 

In 2 years, we went from nothing to:

Thanks to everybody on the community, whether you are a customer, a partner or an OSIsoft employee! This has been a very exciting journey so far, and definitely improved how we interact and communicate with our developers and integrators community - by helping all of you guys build higher-value and higher-quality solutions (hopefully!), and by helping us understand how you use our products and what you need from us. I hope you feel the same way and that this will last for a very long time!

 

And off to our 3rd year together!

25 Years ago Microsoft released its first version of then-GUI Windows 1.0. I let you enjoy a screenshot of how it looked back then and compare it with where we are standing right now!

 

No question how instrumental Windows has been in the ubiquity of Personal Computers. I'm not old enough to remember but I've heard when OSIsoft was making the decision to provide PI for PCs, many people in the industry thought that would be an absolute waste as "the PCs are just toys" and "no one is going to use toys in a plant"!

 

To read more on the history of Windows see this nice article.

 

3733.windows1screen.jpg

Hello, JDBC Developers of the world!

 

If you are familiar with JDBC and the Java Platform, you probably know that the latest version of the JDBC API is 4.0 and the latest version of the Java Platform is 6 (these were released December 11th, 2006). This is what our PI JDBC Driver supports.

 

In this first year of existence of our PI JDBC Driver, we received a few requests to support the older JDBC 3.0 API, which was included in on Java SE 1.4 (a.k.a 4). We originally planned to implement this "retrograde feature" in the 2010 R2 release (v1.1) that's coming up by the end of the year, but decided against that for a couple reasons:

  1. We had a lot of new exciting features to implement, and any time spent on this would obviously prevent our small (but oh so smart!) team to work on these...
    Per the PI System Roadmap, expect this release by the end of the year
  2. Some of the major players people would integrate PI JDBC with (e.g. SAP Business Objects, IBM Cognos), ended up upgrading their offerings to support the JDBC 4.0 API.
  3. There is a workaround to use SQL Server (which you most likely have, because of AF ) as a bridge with Microsoft's SQL Server JDBC Driver, which supports both 3.0 and 4.0

So, the question to you all: do you think it's valuable for us to consider implementing the older JDBC 3.0 API and support for older Java runtimes such as JRE5 and/or JRE4, in a subsequent release of PI JDBC? If so, why? Please include your platform and other Application Server details which prevent you from upgrading to JRE6.

System.out.println("Looking forward to hearing from you all!");
System.exit(0);

Have you ever desired to know what is a most likely trajectory your tag is going to follow? Ever wanted to be able to predict which way an equipment's temperature or pressure is moving based on what you have seen in the past several hours? How about ability to predict when an equipment is likely to fail? If so, you may be interested in this post. This is a sequel to my previous post on combining PI and R.

 

Our goal here is to write a script in R that reads PI data and makes some projections into the future. Here is how I'm composing the story: we collect PI data from a single tag into a flat text file. We can do this in several ways such as using PI DataLink or piconfig scripting. Then we read the values and timestamps from the file into R in the form of two vectors (I have added some noise to the values to make the situation more realistic). Note that R doesn't like commas; so different entries are separated either by space or end-of-line character.

 

The next step is to make a regression to best model the values as a function of time. I have used a 3rd degree polynomial. The degree is arbitrary and should be chosen to best represent the physical model. The blue part of the resulting graph shows the real events in dots and the continuous line shows the regression model.

 

The next step is to put this whole thing to a test. The green part of the graph is the prediction. Some more events are read from PI which have not been used to make the regression. Those are plotted against what the regression model is predicting. Note how closely the model follows the data; but of course as we get farther in time the quality of the predictor deteriorates.

 

This is a predictor based on a polynomial regression. There are many other ways to make such models. My goal here is to showcase one example of how effectively and simply PI and R could be combined to create such predictive models. The other stressing point is the performance. The whole procedure finishes in a blink of an eye on my humbly light-weight laptop  Please find attached the R script along with the flat file containing PI data.

 

Prediction-Graph.JPG

 

 

The evolution of the geek

Posted by spilon Nov 16, 2010

Off my daily dose of techy/geeky readings, I'd like to share one that's admittedly not really useful, but pretty funny. Plus, it follows up on another discussion thread from a couple weeks ago, thanks to Matt Rivet.

 

It also (sort of) confirms what I have been hearing from people in the last couple years, with regards to our choice of the "where PI Geeks meet..." tagline for the OSIsoft vCampus Live! events: geek is the new cool

 

So here it is: the evolution of the geek. Enjoy!

 

101116_2D00_TheEvolutionOfTheGeek.jpgand finally, the PI geeks: 101116_2D00_PIGeeks.png

Hey there! Sorry it's been a while since I last blogged... OSIsoft vCampus Live! 2010 and the transition from the vCampus Team to Product Management made the last couple months pretty busy!

 

As you may have noticed on the blogosphere lately, the "HTML5 vs. Silverlight" debate has been keeping people pretty busy too... actually, we also had our share of that debate over here, on vCampus. As I pointed out a couple times in this discussion thread I just linked, Microsoft still considers Silverlight very important and wishes to entertain development around both HTML5 and Silverlight.

 

As a matter of fact, we just received this invitation for a special event, from our contacts at Microsoft:

 

UPDATE: I got this "Questions & Answers" document from Microsoft, after I blogged about this. Hope this helps!

 

 101115_2D00_SilverlightFirestarter.png

 

I'm assuming we'll see good discussion on the forums again, after the event 

MichaelvdV@Atos

3rd party appstore

Posted by MichaelvdV@Atos Nov 8, 2010

About a year ago, our fellow vCampus member MOH M ERIGH opened a thread about a 3rd party vCampus appstore.

 

Since then, a lot of good discussion has evolved around this subject. Personally, I really like the idea of 3rd party companies (or individuals) to have the opportunity to offer applications to other OSIsoft partners and customers.

 

I’m pleased to announce the initial development of a OSIsoft Appstore. Please note that this is purely the technical development. The procedural and legal issues involved have not been addressed.

 

The main idea behind this development is simple: let’s make a practical start implementing this idea.

 

You can find the development version here:

 

http://vcampusappstore.cloudapp.net/ [Silverlight 4]

 

For the Cloud fans here: it’s a Windows Azure Cloud application, that uses SQL Azure for the backend, and Silverlight 4 for the frontend. It was hacked together over the weekend, so understandibly, it's not at all done yet.

 

At this point it’s populated with some mock data. The usage is pretty simple. On the left side you have the ability to browse through categories (or select ‘companies’  to browse by company). On the right upper pane, you will find all the products that belong to the selection. On the right pane, you will find the detailed information about the product. If you want to order a product, you are presented with a form to fill out. You can ask question to the owner in the same way.

 

Note: not all product categories have products in this mockup J

 

I’m hoping this will be received with enthusiasm. I’m not trying to hijack the idea here, it’s just to make a start with creating a 3rd party OSIsoft appstore.

 

I would like to invite everyone to have a look, and give your reaction. Maybe it will be time to further crystallize the idea and set up specifications.

 

I haven’t looked at any of the legal stuff, but my initial thought would be that this is just a marketplace to bring customers and companies together. Information about the product and ordering the product is a deal between the costumer and the company.

 

EDIT: The application can be offline or faulting sometimes. This is because I'm developing in the same instance. I hope to resolve this asap.

 

EDIT2: Updates on the development progress can be found at [DEAD LINK] http://vcampus.osisoft.com/forums/p/1492/7666.aspx#7666

MichaelvdV@Atos

Let's become Rebels!

Posted by MichaelvdV@Atos Nov 4, 2010

After vCampus Live! I haven't been that active on vCampus. Were doing some pretty exciting projects here at Atos, but that keeps me away from being as active on vCampus as I sometimes would like to be. In the mean time, a lot has happened. There are some pretty good discussions going on about Silverlight vs HTML5, the envisioning of an 3rd party appstore, and off course Cloud computing and PI.

 

The last one, is the one I would like to talk about. Ahmad asked us:

 

"As the community on the cutting edge of PI development and integration, what do you think of offering PI as a service in the Cloud? What are the potential opportunities? How about the challenges? What would it take to win the trust of customers to let someone else host their PI System? How would you envision the interaction between the PI System and data sources in the plants? Would it provide a good opportunity for our partners? Share your ideas with us."

 

These are all pretty good and challenging questions. Specially, the first two questions. What are the opportunities, and what are the challenges? These questions cannot be answered quickly. But, it really provides the opportunity for some good and deep thinking.

 

The 3rd question: "What would it take to win the trust of customers to let someone else host their PI System?" is another very interesting one, but not as interesting as the first two questions. I would like to say, that this question is interesting, but totally irrelevant.

 

But,  this is the question that everyone is trying to answer. The overall consensus seems to be that (existing) PI costumers would in no way allow their data to be stored in ‘the cloud', and therefore, that cloud computing and PI is not a viable option.  Let's assume for now, that our traditional customers are not in any way interested in hosting their PI data in the cloud.

 

With establishing this assumption, let us look back at the primary (and most important question): "What are the potential opportunities?"

 

 "What are potential opportunities of cloud computing", and "No way I'm going to host my data off-premise". This is not mutually exclusive. It's very thought provoking though, and allows for creative ‘potential opportunities'.

 

Wikipedia offers the following definition to cloud computing:

 

"Cloud computing is Web-based processing, whereby shared resources, software, and information are provided to computers and other devices (such as smart phones) on demand over the Internet."

 

This in itself contains the answer to question number one. Sharing information and software. This opens up the new  opportunities: offering time series data storage and calculations as a service for the internet.

 

This is a paradigm fork for us, which is not excluding the ‘traditional' usage of the PI system. Cloud computing in itself is a paradigm shift, so we have to shift paradigm to see the opportunities! One paradigm will support the other.

 

Let's envision some potential opportunities:

  • Offering a public ‘on demand' service to web applications or application servers to store logging information and time series information, run calculations, and provide visualization for them. Things like number of hits, Performance Information, database usages, etc. These figures will become more and more important in the ‘on demand world', to become or remain sustainable.
  • Offering domain specific time series storage and calculations, stuff like GPS locations. Think about storing GPS locations (time stamped) for car rental/lease companies, transport companies, UPS, etc.
  • Offering the ability to share, compare and publish data. Sustainability and environmental data, weather information, traffic information, etc. There is an ongoing demand for open-governments and companies. Why not use technologies like Web services and OData to give companies and governments the opportunity to publish this information. Give client applications the possibility to combine and join information from different sources.
  • Offer the ability to run complex and ‘on the fly' calculations that take a lot of resources
  • Etc. etc. etc.

The basis of my thought process are that cloud computing is a paradigm shift in itself. We are trying to fit in using our ‘old ways'. We have to shift paradigm ourselves to be able to fully appreciate the opportunities of Cloud Computing. We must not see Cloud Computing as this big threatening thing that we don't fully understand, we have to embrace it for what it is, and see the opportunities that it offers.

 

We are the Empire, the internet and Cloud Computing are the Rebels. We are used to tight contracts, procedures and safety and we are bound by that. The internet and cloud computing is free,  anarchy like and not bound to rules. We have to become Rebels to fully appreciate the possibilities, and become entrepreneurs in this new environment.

 

If we want in, we have to play by the rules of the Internet.

 

Disclaimer: This article is meant to be thought provoking, and in no way discredit or disrespect anyone's opinion

hanyong

Importing AF Data to Excel

Posted by hanyong Employee Nov 3, 2010

A couple of weeks ago, I've put up a new tutorial titled "Exporting PI Data to XML". As the title of the tutorial suggests, it is focused on exporting PI Data to XML format. If it is of your interest, you can access it in the vCampus Library, under "White Papers and Tutorials" -> "Miscellanous" -> "Exporting PI Data to XML".

 

One of the comments that I've got about the paper is "What about exporting AF data to XML?", which is the main intention of having this blog post.

 

3 methods of exporting PI data to XML format is covered in the tutorial:

  • programmatically through PI Web Services
  • using Microsoft SQL Server and SQL Server Integration Services (SSIS) and PI OLEDB Provider
  • using Excel and PI DataLink
  • The first two options are pretty straightforward. PI Web Services is able to read data from AF if a path to AF Server and the specific attribute is given. And we can always use PI OLEDB Enterprise in place of PI OLEDB for connection to AF in the SQL world.

     

    What I'll cover in this blog post is the steps to import AF Data into Excel. And what we will use is PI OLEDB Enterprise in Excel to get data from AF. Here's what we will need to start the work:

  • Microsoft Excel
  • PI OLEDB Enterprise
  • Step 1: Defining a Data Connection Source

    1. Go into the Data menu and import data from other sources.
      screen001.jpg

    2. Choose “Others/Advanced” for data source
      screen002.jpg

    3. Choose “PI OLEDB Enterprise 2010” as the OLE DB Provider
      screen003.jpg

    4. In "Data Link Properties", input your AF server name and other appropriate settings. In the example here, I've configured it to use Integrated Security
      screen004.jpgscreen005.jpg

    5. Select the AF Database you want to connect to. You probably will be joining the different tables exposed by PI OLEDB Enterprise, so we want to uncheck the option “Connect to a specific table”
      screen006.jpg

    6. Click on "Next" to enter information to save the configuration as a Data Connection (.odc) file, then "Finish". You might be prompted for a login at this time. If you select Windows Authentication, you can click on “OK” directly to proceed.

    At this point, you have defined a data connection to AF Server from Excel. The same data connection can be re-used for future, so you would not need to re-do them again. If you want to re-use the data connection, simply go to “Data” -> “Existing Connections”

     

    screen008.jpg

     

    Step 2: importing data using data connection to PI OLEDB Enterprise

    1. The next part would be to define what information to extract from the data source (in this case PI OLEDB Enterprise). Defining the data connection will transit into this part directly. And the 1st thing you would be prompted is to select a table
      screen009.jpg

    2. We can select any table here and click “OK” to continue. As mentioned earlier, you probably want to join different tables together. In the future steps, we will input the SQL query to extract data instead of simply importing from a single table.

      The next dialog box that you should see allows you to choose where and how you want to view the data in Excel. But before that, we want to go into “Properties” to change some configurations.

      screen010.jpg

    3. In the Connection Properties Dialog box, we can look at the “Definition” Tab. This is where we can change how we extract data from AF Server. The configuration that you should see: “Command type” would be “Table” and “Command text” would be the table that was specified earlier.
      screen011.jpg

    4. We want to change the “Command type” to “SQL” and input the SQL query as “Command text”
       screen012.jpg

    5. You can put in any query as long as it works. You probably want to first test out the query using client tools like PI SQL Commander.

      The query that I am using is as follows:
      SELECT eh1.Path, eh1.Name as "Plant", ea1.Name as "Attribute", a1.Time, a1.ValueDbl as "KPI"
      FROM [Demo].[Data].[Archive] a1
      INNER JOIN [Demo].[Asset].[ElementAttribute] ea1
      ON a1.ElementAttributeID = ea1.ID
      INNER JOIN [Demo].[Asset].[ElementHierarchy] eh1
      ON ea1.ElementID = eh1.ElementID
      WHERE eh1.Name LIKE 'Plant1'
      AND a1.Time BETWEEN DATE('29-Aug') AND DATE('*')
      ORDER BY a1.Time
      OPTION (IGNORE ERRORS, EMBED ERRORS)

      As you can see, I am joining 3 tables together to display the element path, element attribute and archive data from the attributes.

    6. We can click on “OK” to proceed, and you would be prompted the following dialog. Click “Yes” to continue. You should be back at the following dialog box, to choose the way to display the data, and where to put the data in Excel.

      The next dialog box that you should see allows you to choose where and how you want to view the data in Excel. But before that, we want to go into “Properties” to change some configurations.
      screen014.jpg

    7. Once you have made your selection and click “OK”, you should see the data being imported into Excel.
      screen015.jpg

    Conclusion

     

    With the AF data imported into Excel, you can use the information to fit your needs, creating a report, export to XML format like what is described in the tutorial, etc...

     

    This would be one of the methods to import AF data into Excel. There are other viable methods like:

  • PowerPivot and PI OLEDB Enterprise (for Excel 2010)
    You can take a look at webinar recording for "Personal BI with PI DataLink and Excel 2010" here
  • AF Builder add-in
    This is currently on Community Technology Preview (CTP), available for download in Download Center
  • Depending on your requirements, you can play around with these options as well.

     

    Acknowledgement

     

    Thanks to Jay for his comments, which leads to this blog post.

    Having fun with AF and dynamic programming

    I haven't been really active on vCampus lately due to time constraints. We are working on some pretty exciting projects here at Atos, but that takes it's toll on my vCampus activity. I thought it would be time to make use of my newly earned Blogging priviliges, and talk some geek

     

    Today, let's talk about dynamic programming with c# and .NET 4.0. For those of you who aren't using Visual Studio 2010, and if you have the chance, you should really switch. Besided having the awesome benefits of .NET 4.0, the UI has changed a lot, and has some really cool features you should check out.

     

    Allright, dynamic programming in C#. What's that about?

     

     
     public class DAFElement : DynamicObject
        {
            public AFElement EmbeddedElement { get; set; }

     

            public DAFElement(AFElement embeddedElement)
            {
                EmbeddedElement = embeddedElement;
            }

     

            public override bool TryGetMember(GetMemberBinder binder, out object result)
            {
                result = null;
                var name = binder.Name.Replace("_", " ");
                if (EmbeddedElement.Attributes.Contains(name))
                {
                    result = new DAFAttribute(EmbeddedElement.Attributes[name]);
                    return true;
                }
                if (EmbeddedElement.Elements.Contains(name))
                {
                    result = new DAFElement(EmbeddedElement.Elements[name]);
                    return true;
                }
             
                var prop = EmbeddedElement.GetType().GetProperty(name);
                if (prop != null)
                {
                    result = prop.GetValue(EmbeddedElement, null);
                    return true;
                }
               
                return false;
            } 
        }

    Filter Blog

    By date: By tag: