Create a Dashboard to View the Data
In this step, you'll use the Real Time Visualization section to build custom charts and graphs to easily monitor the virtual meter remotely.
To visualize our virtual meter's data stored at the Raw History section in AnythingDB, you will first need to create an App.
-
Click Access Control > Apps by following these
steps.
Note: The Application Client ID and Secret ID are required for configuring the Real time Visualization module. Be sure to capture and save this information.
Figure 1. - From the left menu, click Real Time Visualization > Workbooks.
- Select the desired folder. By default, a root folder with your user name is already present.
-
Click New Workbook.
- Name the Workbook and click Create.
-
Create a Data Table by clicking the + icon. Data tables define the queries and
source data repository definitions in order to retrieve data.
Figure 2. -
Under Data Table Settings, enter a title and click the check mark to save it.
Enter a description, if desired.
Figure 3. -
With Data Sources highlighted, under File/URL, select SmartWorks
IoT.
Figure 4. -
Enter the following:
- Client ID: from the app created in Step 1
- Client Secret: from the app created in Step 1
- Grant Type: type of app created in Step 1. Here we use client_credentials.
- Scope: Choose Data to retrieve the data stored at the Raw History section
- URL: to make the request. Use https://api.swx.altairone.com/spaces/YourSpaceID/data/?source%5B%5D=ThingUID
Figure 5. -
Click Generate Columns and make sure the JsonPath fields
are filled as follows:
Name JsonPath content.UD_DTYPE_KWH_ODM content.data.UD_DTYPE_KWH_ODM content.UD_DTYPE_KW_AVG content.data.UD_DTYPE_KW_AVG
Figure 6. -
Click the Transform Settings tab and enable Time Series
Analysis. Click Fetch and select
thing.Id.
Figure 7. -
Click Refresh Preview.
The columns are populated and the reqeusted data is displayed.
- Click Save.
- Click Back to return to the Edit Dashboard view.
-
On the blank canvas (right half section), sketch a simple square by clicking
and dragging on the blank interface.
This enables the Visualization menu.
Figure 8. -
Select the Visualization mode (from the ones available at the Combination or
Time Series Visualizations) and configure it using the Visualization
settings.
For example, choose Time Combination and configure it as follows by dragging and dropping the data elements to the different sections:
- Visuals:
- content.UD_DTYPE_KWH_ODM
- content.UD_DTYPE_KW_AV
Figure 9. - Visuals: