OPC UA Industrial Metaverse reference implementation leveraging Unity.
- A PC with at least 16 GB of memory and a modern graphics card with at least 6 GB of memory.
- An OpenXR-compatible Virtual Reality headset. Make sure you enable
developer mode
on your headset, if required. The solution has already been pre-configured for a Meta Quest headset. - An Azure subscription. If you don't have one, you can start with a free subscription from here.
- Download this repository to a directory of your choice from here.
- Obtain a license for Unity from here.
- Obtain a license for Cesium ion from here.
- Install the latest Unity Hub version from here.
- Install the latest Unity Editor version from here.
- Install the OpenXR plugin for Unity via Edit -> Project Settings in the Unity Editor.
- Install the Cesium for Unity plugin via the Unity Package Manager > My Registries and enter
Cesium
for the Name,https://unity.pkg.cesium.com
for the URL,com.cesium.unity
for the Scope and click Save. Then, select the Cesium for Unity package and click Install. - Install Visual Studio 2022 and the Visual Studio tools for Unity.
- Install any additional OpenXR package for Unity you may need for your particular VR headset.
- Install the Azure Industrial IoT Reference Solution from here.
- Run the OPC UA simulation as described here.
- Create an application registration for your ADX instance as described here. Copy the client secret to a safe place.
- In the C# file under the downloaded repository path /Assets/Scripts/SignalR/ADXService.cs, update the variables applicationClientId, adxInstanceURL, adxDatabaseName and tenantId with the data from your Azure Data Explorer instance, as well as from the new app registration you have just completed and from your Active Directory instance available in the Azure Portal.
- Open the Unity project through the Unity Hub. In the Unity Editor select the ADTConnection in the Hierarchy panel. In the Inspector panel, provide the client secret copied previously in the Url field.
- Select Cesium3DTileset in the Hierarchy panel and provide a Google Maps API key in the URL field in the form
https://tile.googleapis.com/v1/3dtiles/root.json?key=<your key>
. A Google Maps API key can be obtained from here. Please make sure you enable theAerial View API
and theMap Tiles API
in the Google Cloud Console. - Select the right platform for your Virtual Reality headset in Unity's
Build Settings
, select your headset inRun Device
, selectBuild And Run
and put on your headset.