Skip navigation
All Places > All Things PI - Ask, Discuss, Connect > PI Integrators > Blog

PI Integrators

3 posts

Are you using Esri's recently released Operations Dashboard with the new dashboard items? If so, you might be interested in how to integrate PI Vision into this new application.

 

The new Operations Dashboard supports HTML in some elements, and we can leverage that to embed PI Vision without a custom extension.

 

The simplest way to embed a PI Vision display into Operations Dashboard is to add a Rich Text element to the dashboard. This is a good option for displays that you do not need to update to reflect a change in feature selection, like a summary display.

1. In an opened dashboard with a map element already configured, highlight the Add + button in the top right corner to show the list of elements.

2. Click on the Rich Text item to add a configurable element to the dashboard.

3. Click the Source button to edit the HTML directly.

4. Type the following, but replace the value for src with the URL to a PI Vision display in your organization:

     <iframe height="400" id="MyFrame" name="MyFrame" runat="server" src="https://VisionServer/PIVision/#/Displays/10/Esri_States?hidetoolbar&hidetimebar" width="600"></iframe>

5. Click the Source button to exit the HTML editor and update the element preview. Then click the Done button in the bottom right corner to add the element to the dashboard. You should now see the PI Vision display.

PIVisionOpsDB1.png

 

 

If you would like to add a PI Vision display that you want to update when the feature context changes, add a List element instead of the Rich Text element. You can use the URLs provided by PI Integrator for Esri ArcGIS to link feature layers to AF elements in PI Vision displays. The Integrator provides both an ad-hoc URL and URLs to saved custom displays. (These are accessible in the Integrator website by navigating to the desired layer, then clicking on the Visualization tab.)

 

Example of an ad-hoc URL: https://IntegratorServer/api/v1/services/2017_opsdbagol/2017_opsdbagol/displayserver/0/adhoc?mapfeaturekey={name}

Example of a custom display URL: https://IntegratorServer/api/v1/services/2017_opsdbagol/2017_opsdbagol/displayserver/0/displays/1?mapfeaturekey={name}

 

These URLs can be used the same way as the HTML example provided above, just replace the src value. I've also added the PI Vision URL parameters to hide the tool bar and time bar in the following example.

1. In an opened dashboard with a map element already configured, highlight the Add + button in the top right corner to show the list of elements.

2. Click on the List item to add a configurable element to the dashboard.

3. On the Data tab, you might want to limit the Maximum Features Displayed to 1 so that you only see one copy of the display at a time.

4. On the List tab, click the Source button to edit the HTML directly.

4. Type the following, but replace the value for src with a PI Vision URL provided by your Integrator for one of the layers in the map element of the dashboard.

     <iframe height="400" id="MyFrame" name="MyFrame" runat="server" src="https://IntegratorServer/api/v1/services/2017_opsdbagol/2017_opsdbagol/displayserver/0/displays/1?mapfeaturekey={name}&hidetoolbar&hidetimebar" width="600"></iframe>

5. Click the Source button to exit the HTML editor and update the element preview. Then click the Done button in the bottom right corner to add the element to the dashboard. You should now see the PI Vision display.

 

You may see"Object reference not set to an instance of an object." but this resolves once the feature context is available to the List element and the URL is able to resolve to an AF element in the layer.

 

After configuring the List element, you can make the dashboard interactive by configuring an action to update that display context based on a selection in another element, like the map.

1. Hover over the top left hand corner of the Map element to show the menu, then click on Configure Actions .

2. For Source, select the desired layer from the dropdown.

3. Click Add Action and select Filter.

4. Click Add Target and select the List element just configured to show the PI Vision display.

5. Click Done to return to the dashboard.

6. To update the PI Vision display with the context of a specific feature, click on the feature in the map then click the selection tool .

7. The PI Vision display should then update to reflect the AF element data corresponding to the selected feature.

 

Note that the new Integrator hosted time-enabled feature layers available in PI Integrator for Esri ArcGIS 2017 are supported data sources in dashboards, but they cannot be used as an action's source in interactive dashboards.

This post was originally created to work for the Operations Dashboard 0.7 Beta. Please see the new post with updates for the released Operations Dashboard.

 

Are you using Esri's recently updated Operations Dashboard Beta with the new dashboard items? If so, you might be interested in how to integrate PI Vision into this new application.

 

The new Operations Dashboard supports HTML in some elements, and we can leverage that to embed PI Vision without a custom extension.

 

The simplest way to embed a PI Vision display into Operations Dashboard is to add a Rich Text element to the dashboard. This is a good option for displays that you do not need to update to reflect a change in feature selection, like a summary display.

1. In an opened dashboard with a map element already configured, highlight the Add + button in the top right corner to show the list of elements.

2. Click on the Rich Text item to add a configurable element to the dashboard.

3. Click the Source button to edit the HTML directly.

4. Type the following, but replace the value for src with the URL to a PI Vision display in your organization:

     <iframe height="400" id="MyFrame" name="MyFrame" runat="server" src="https://VisionServer/PIVision/#/Displays/10/Esri_States?hidetoolbar&hidetimebar" width="600"></iframe>

5. Click the Source button to exit the HTML editor and update the element preview. Then click the Done button in the bottom right corner to add the element to the dashboard. You should now see the PI Vision display.

PIVisionOpsDB1.png

With the emergence of IoT and the notion of connected cities, an increasing amount of city services are being connected to the internet. This includes transportation –based assets, such as public bike rental stations. We will outline how to map these stations (PI AF elements), and view any geographical trends which might emerge. Bike share stations are distributed around a city, and provide easy access to a public bike share system. Users can pick up a bike at one station and drop it off at any other station in the network. The bike station status is continuously updated with live metrics such as the number of bikes available at a station (for users to take out bikes) and the number of docks available (for users to return bikes).

 

This post is based on a summer internship project, undertaken at the OSIsoft Montreal office. For more details, check out "Monitoring Smart City Assets with the PI System"

 

For more information on how this data was collected and stored in the PI System, please have a look at these blog posts:

 

Why use the PI Integrator for ESRI ArcGIS?

The PI Integrator for ESRI ArcGIS allows us to geographically map all of our AF assets. It can then display all the static and dynamic attributes of these PI AF assets in real time. The physical location of our PI AF assets (public bike stations) is incredibly important, as the usage of any bike station will be heavily related to its location. Factors such as proximity to pedestrian malls and office buildings will cause an increase in usage. We could have looked at a station map and tried to manually work out which stations would be favored based on their location, which would have been a very tedious process. A much better way to go about this analysis would be to map our stations, and view our KPIs on a map. This allows us to easily see any geographical trends which might be present. 

 

How does the Integrator for ESRI ArcGIS work?

In a nutshell, the Integrator searches the AF archive for updated attributes, and then can send them to an ESRI online or local portal for mapping purposes. The PI AF database is crawled using the “ESRI Data Relay” which continuously searches for new updates in PI AF attributes. The Integrator setup is hosted on an IIS configuration webpage, where the user can set which PI AF elements and attributes to send through to a map layer. In order to map an element, it must have an attribute denoting its location - this may be an address or a longitude/latitude pair. The map layer, which now contains the location of our PI AF elements along with their attributes, can then be viewed in an ESRI product such as ESRI Online or ESRI operational dashboard.

 

Analyzing our data with the PI Integrator for ESRI ArcGIS

We started off by mapping our PI AF assets (Bike stations in Montreal) using the ESRI online portal. The examples below show how we can view our elements in a much more intuitive way, and combine secondary data sets such as the location of bike paths, subway stations and bike accidents.

 

A live, interactive version of the map is available here. Below are some of the individual analyses and displays we can generate:

 

Mapping Bike stations:

All of our PI AF assets (bike stations) are displayed on an ESRI online map. The PI Integrator for ESRI ArcGIS helps resolve the station's longitude/latitude position to a map layer (LEFT). We can change the marker size to display a KPI of interest, such as the total in/out traffic events in a four hour period (RIGHT).

 

 

Zooming in on an area of high use, we can take a look at station closer to Montreal's OSIsoft office. We can see all of our PI AF attributes displayed in real time, updated at an interval which we've specified (5 minutes).

 

 

We can further enrich this data by adding other map layers. For example, we see that bike stations with the most usage coincide with the location of bicycle paths (LEFT, in purple) and the location of subway stations (RIGHT)

 

System administrators might want to compare this year's live data with last year's historical data to see which stations are under-performing and which are exceeding last year's usage. In this case, we can plot last year's trips in red (LEFT) , and then overlay this year's live data in orange (RIGHT). We see that for the most part, stations this year were more popular than those last year.

 

 

Another dataset which city planners may be interested in is the location of bike accidents in Montreal. This would help point out any particularly dangerous intersections, and lead officials to investigate whether a bike dock should be placed in close proximity to them. Worryingly, there is much overlap between high use bike stations and intersections with a concentration of bike accidents.

 

 

Given that ESRI is a worldwide mapping application, we can easily move to a different city and view a bike station layer which was generated. For example, if we wanted to have a look at bike stations outside of OSIsoft’s Philadelphia office (1700 Market St.)

 

In addition to Philadelphia, we are gathering data from other bike sharing systems such as New York City’s CITIBike, San Francisco’s Bay Area Bike Share, Boston’s Hubway, and Toronto’s City Bike Share.  If you were to find yourself in Times Square, you could consult an ESRI map to see live PI AF attributes from New York’s public bike sharing system.

 

 

For those who are reading this in the Bay Area, we can also have a look at San Francisco’s Bay Area Bike Share.