So you're attending a hackathon and you want to build for HoloLens? Awesome! We've got you covered with this step by step guide for working with Microsoft HoloLens at a hackathon.
Event wifi can be spotty, so you'll be best off if you download all of the necessary tools ahead of time. The full toolset will run best on Windows 10.
You will need:
- Visual Studio 2015 with Update 3
- The Windows 10 SDK
- Unity 5.5 or later
Optionally, you will need:
- The HoloLens Emulator to test your applications on (Requires Win 10)
You should go to the HoloLens Developer Site to get the most up-to-date versions of each of the above tools. Using outdated versions of the tools may result in unexpected issues whem you build or deploy your apps.
If you do not have a Windows PC or laptop to develop on, you may have luck with one of the following options:
- Installing a Windows Partition on your machine through a tool like Bootcamp.
- Setting up a Windows 10 Virtual Machine
If you have a chance to walk through a few sample projects for HoloLens, you will be well-prepared for building your first Holographic application. Understanding how Gaze, Gesture, and Voice - the three main principles of HoloLens input - work will help you design your apps.
Check out some awesome things people are building
See things from a developer perspective
You should also bookmark the HoloLens Developer main site and the Holographic Academy site, both of which will contain useful information about getting your own holographic applications up and running.
When it's time to program your application, the best way to get started with your app will probably be a clean Unity project. You'll also likely want to grab the HoloTookKit-Unity package from GitHub to use in your project.
-
Double check that you have Unity 5.5 or greater.
-
Download the HoloToolKit-Unity project as a zip folder from GitHub.
-
Open up the HoloToolKit-Unity-master project in the Unity HoloLens Technical Preview. You should see two folders under your assets: HoloToolkit and HoloToolkit-Examples.
-
Select the HoloToolkit folder and right click to find 'Export Package'
-
Save your exported package somewhere you'll remember it and name it 'HoloToolkit'
-
In Unity, go to File > New Project to create your hackathon project folder. Save this somewhere you have access to, such as your Desktop or Documents folders.
-
In your Assets folder, right-click and Import Custom Package
-
Find your Holotoolkit.unityplugin file that you just imported and select it to import it into your new project.
Next step: build some holograms!
When you have your project working in the emulator and you're ready to test on a device, you will need to do the following steps to connect and deploy to each device you are testing with:
-
Make sure that your computer and your HoloLens are both on the same WiFi network.
-
In Visual Studio, set your deployment target to 'Release', the architecture to 'x86', and the deployment player to 'Remote Machine'
-
On the HoloLens, make sure that the developer settings are enabled to allow project applications to run (Settings > Developer)
-
In the Settings > Network tab on the HoloLens, air tap on "Advanced Settings" and note your device IP Address
-
Launch your application in Visual Studio. The first time you set up a device, you will be prompted for the IP Address. Enter the HoloLens IP Address.
-
Once your device is connected, you will be promped in Visual Studio for a PIN. You can find this back in Settings > Developer > Pair. Once you enter the code and the device pairs to the computer, your application will begin deployment.
Unity projects with 3D assets can be really large, so you should set up your source control on your project for the following:
-
Include a Unity .gitignore to your git configuration
-
Set up Git Large File Storage to track your .scene files and models that are larger than 50.0MB
-
When holding the HoloLens, take care to hold it by the arms of the device, not the band or the visor. You can clean off the front of the device with a dry screen cleaning cloth.
-
Keep the device charging while not in use so that you don't have to worry about a low battery during testing
-
Rest the device flat (upside-down from how you'd wear it on your head) when it isn't in use. Ideally, it should rest in the case, too.
-
The HoloLens App will allow you manage your device from your computer. You'll also be able to turn on remote capture to see the holograms as someone uses your app.
