HoloLens

From Smartana Wiki
Jump to: navigation, search

Create a HoloLens app.

A "Hello World" text and a cube will augment reality using the HoloLens.

Prerequisites: Unity, Visual Studio(14GB; Community, enable: Tools (1.4); Windows 10 SDK (10.0.10586)), Hololens and at least Windows 8 (note: you could run a W10 VM in W7)[status 10/2/2017];

  • Project
    • Start Unity >> New project
    • Project name: Hello HoloLens World; Location: C:\Users\myUserName\Google Drive; Enable Unity Analytics: Off
    • Edit >> Project Settings >> Quality >> (Default, WinStore)=Fastest
  • The Scene
    • Camera: Position=(0,0,0); Clear Flags: Solid Color; Background: black; Clipping Planes: Near: 0.85
    • GameObject >> 3D Object >> 3D Text: Name: myMessage; Text="Hello World"; Position=(-1,0.3,2.5); Scale=(.25,.25,.25); Color=red
    • GameObject >> 3D Object >> Cube; Position=(0,-.1,2); Scale=(.25,.25,.25)
    • Save Scenes as: HelloWorld
  • Building
    • File >> Build Settings >> Add Open Scene
    • select: Windows Store (install missing file if required)
    • SDK: Universal 10;Target device: HoloLens; Unity C# Project: tick
    • Player Settings >> Inspector >> Other Settings >> Virtual Reality Supported: tick
    • Build >> right-click and add new folder: App and select this folder
  • HoloLens
    • Bloom gesture >> Settings >> Update >> For developers: enable Developer Mode
    • Settings >> Network >> Advanced options >> IP: 192.168.1.36 (this will vary; you will need this later)
    • Settings >> Update >> For developers >> Pair devices >> 123456 ("this will vary")
  • Visual Studio (VS) [back to your computer, ensure "Use developer features" settings are set to Developer mode]
    • Open the App in VS
    • right-click Package.appxmanifest and select View Code
    • replace: TargetDeviceFamily Name="Windows.Universal" with "Windows.Holographic"
    • change: Develop to Master; ARM to x86; Local Machine to Remote Machine
    • IP: 192.168.1.36
    • Debug >> Start Without Debugging
    • enter the PIN code
    • Note: the App will start immediately and the text and cube location cannot be changed. The App will be available via "Bloom" (TODO location relative to app position)

External Links

HoloLens-Hello-World, Microsoft Holographic documentation, Getting started