Windows Phone 8 SDK: Debugging your Application

Depending on whether your application targets WP7 or WP8 you’ll see different options in the devices dropdown. Since it is possible to run WP7 devices on both WP7 and WP8 devices you’ll see additional options for WP7 targeted applications (right image).

image_thumbimage_thumb1

In the same way that you should always test your application on both the emulator and a real device, for a WP7 application you should test on both the wp7 and wp8 emulators, and ideally both wp7 and wp8 devices. In fact with the new SDK the test matrix just got significantly larger as you need to also test the 720p emulator (I’m less worried about the WXGA emulator since in theory it should just scale up from WVGA – the only thing to watch is that images don’t pixelate).

If you didn’t already realise, the new emulator images are actual hyper-v virtual machines. This means that they will appear in Hyper-V Manager. Although, I wouldn’t recommend attempting to tweak the images via the manager!

image_thumb3

The Additional Tools window includes a Network tab, although in my case it’s a little confusing because there are four adapters. Whilst I haven’t been able to get Fiddler to work with the new emulators it does appear that lower level tools such as Wireshark can be used to monitor traffic – it’s useful to see what the IP address of the emulator is via the Network pane so that you can filter the traffic.

image_thumb5

In the Windows Phone 8 SDK there is another tool that can really assist with debugging applications and their behaviour when interrupted. The Tools menu contains a link to the Simulation Dashboard.

image_thumb8

The Simulation Dashboard (adjusts the currently selected emulator in the device dropdown) allows you to monitor the network speed and signal strength. It also lets you trigger the lock screen and a reminder.

image_thumb10

Being able to trigger a reminder will aid in debugging your application, or game, when it is partially obscured, rather than simply when the user navigates away from your application.

image_thumb7

Leave a comment