holounity – how to deployment unity apps across hololens platform

Heutzutage, The configuration tutorial for Hololens is generally with Visual Studio 2015. However, there may exist bunch of problems while using newest software. After spending whole afternoon, I finally made it with newest version.

Table of Contents

Requirement

###Win 10 (64 bit)
Using Windows 10 Pro system is highly recommended.
###Visual Studio 2017
You need to mark on UWP && Win10 SDK while installing VS 2017.

Here is a list of my Visual Studio Installer.
###Unity 2018.3.5f1
It’s okay if you use a higher version of unity since the only thing you should do is to install the Metro Support for Editor for you need to release your apps to UWP platform except PC platform.

You can check the corresponding packages with your own Unity version here.

Installation

###PC
Your PC should enable Hyper-V as well as Developer mode.

###Hololens
Developer mode. If you want to debug your Unity apps instantly, you shall install HoloGraphics Remoting player.

Configuration

Now you have all your stuff done. It’s time to configue your Unity.

Suppose you have a project named “HoloTest”.

First, we need to open Build Settings(File -> Build Settings).

Swith your building platform to Universal Windows Platform.

  • Target Device: Any Device -> Hololens
  • Visual Studio Version: Latest installed -> Visual Studio 2017
  • Build configuration: Release -> Debug

Don’t worry if you can’t tick off Unity C# Projects for it related an important setting later.

Then, open Player Settings.

Find Configuration in Other Setttings and change Scripting Backend from IL2CPP(which is usually used in IOS platform) to .NET.

Check Virtual Reality Supported in XR Settings.

Finally, return to Build Settings and tick off Unity C# Project.

Build & Deployment

Click Build, create a new folder named “Apps”(or whatever you like).

Then, go to that folder, and open “HoloTest.sln” in Visual Studio 2017.

Change Debug to Release, ARM to x86, and Local Computer to Device.

Link your Hololens with USB or Wi-Fi, you shall configure your Hololens with “http://127.0.0.1:10080” if you first use it.

Return to Visual Studio 2017, clicking Run without debugging.

There would pop a PIN window after a while. Input the PIN shown in Developer Mode in Hololens.

After that, the project you made in Unity can be deployment in Hololens Successfully.