Historically, just as in the “old days” with Windows Mobile and Pocket PC before it, Microsoft has made a handy emulator available as part of the SDK that is freely downloadable and installable.
An emulator is not just useful for developers anymore, but also for a corporate enterprise administrator it could be handy for testing applications, configurations or infrastructure. But especially if there is no physical Windows Phone 8 device handy, you could jumpstart the platform understanding and even support for it.
In this posting I will give a overview, good reference points and tips to utilize the Windows Phone 8 emulator.
The Windows Phone SDK 8.0 has the following basic requirements:
– Windows 8, running 64-bit. A 32-bit system is not supported.
– 4Gb RAM minimum
– 6.5Gb of disk space
For the Windows Phone 8 emulator these additional requirements also apply:
– Windows 8 Professional or Enterprise Edition
– Hardware virtualization
– Second Level Address Translation (SLAT)
– DHCP, so the virtual machine can get a IP address on the local network
A great handy small 3rd party utility to detect if you have the necessary SLAT support is located here: http://slatstatuscheck.codeplex.com/
On older equipment you may find that you have basic virtualization support, but lack the SLAT or other features.
To properly understand and enable the virtualization settings I recommend to look at these helpful pages:
– Technet: Hyper-V: How to Fix BIOS Errors Enabling Hyper-V
– How to enable Hyper-V for the Windows Phone Emulator
– (WP8) Emulator (XDE) Troubleshooting Tips
Installation is pretty straight forward and simple. Please go here,http://www.microsoft.com/visualstudio, and download the “Visual Studio Express 2012 for Windows Phone” version. It will require approximately a whopping 6.5Gb of disk space, but provides a cost free option with all the basics. You will need to register for free and obtain a product key for long term use. Only takes 2-seconds with your existing Microsoft Live ID and will be e-mailed to you.
To utilize the Windows Phone Emulator 8.0 the machine and CPU you are installing on must support hardware virtualization.
If the virtualization support is available and properly enabled before you start the installation, it will automatically install all the necessary Hyper-V components if not already installed.
Some simple steps on how to start and use the emulator without having to be a developer.
1. Run the Microsoft Visual Studio Express 2012 for Windows Phone by tapping the tile:
2. Create a new project by selecting “New Project”:
3. In the New Project dialog window leave the default “Windows Phone App” and click OK.
4. Leave the target version as “Windows Phone OS 8.0”, and click OK.
5. The new project will now be created..
6. Once completed the Visual Studio Express will display the empty project source code. Ignore the code windows, and please notice the “Emulator WVGA” button in the upper left of the screen:
The dropdown shows several different emulator resolutions present (you don’t have to select a new selection):
Information on the resolution options:
|Resolution||Aspect Ratio||Scaled resolution|
|WVGA||480 x 800||15:9||480 x 800|
|WXGA||768 x 1280||15:9||480 x 800|
|720p||720 x 1280||16:9||480 x 853|
7. Once you execute the Emulator, it will build/compile the source code and start up the emulator, load and execute the Project code. In our case, it should come up with a empty page as shown. Please click on the Windows button.
8. As on a physical device, after pressing the Windows button it should display the home screen with the tiles:
If you have DHCP running on your local network, the emulator should have access to the same network and Internet if available. As in this quick test in Internet Explorer shows:
The toolbar next to the emulator has several nifty features which can be useful when utilizing the emulator.
= Close emulator and shut it down
= Minimize the emulator window. Retrieve it from the taskbar.
= Flip emulator display left and right, as you would a physical device
= Fit to screen. It will expand or shrink the emulator display to fit the screen size.
= Zoom. You can expand or shrink the emulator display.
= Open the Additional Tools window (see below)
= Drag the emulator display
The Additional Tools window has additional functionality for setting Accelerometer and Location data for the emulator. It also has functionality to take screenshots and view network information.
These keyboard shortcuts substitute the physical buttons on a Windows Phone device and may make it easier to demonstrate various aspects.
F1 = Back arrow button. Escape key can also be used.
F2 = Windows Start button
F3 = Search button
F6 = Camera button that is pressed halfway
F7 = Camera button that is fully pressed
F9 = Volume up
F10 = Volume down
F12 = Lock device/Power button. Press it twice to see the lock screen.
PAGE DOWN = When text box is highlight, moves visual keyboard down, and you can use your physical keyboard for input
PAGE UP = When text box is highlight, moves visual keyboard up.
PAUSE/BREAK = Toggle keyboard
Hope this helps any efforts to setup and use the Windows Phone 8 emulator. Here are some additional links that may be helpful.
Additional troubleshooting information can be found here: Troubleshooting the Windows Phone 8 Emulator