Performance Counters
Counters are used to provide information about how well an operating system, application, service, or driver is performing. You can use the counter data to determine system bottlenecks and modify the system's or application's performance. The operating system, network, and devices provide counter data that an application can use to create a graphical view of how well the system is performing.
The Microsoft Surface platform provides three types of performance counters: Vision System, Client, and System Control Module.
For more information about performance counters, see Performance Counters and Performance Counters in the .NET Framework on the MSDN Web site.
Microsoft Surface Vision System
The Vision System category provides counters to monitor the Microsoft Surface Vision System.
| Counter | Description |
|---|---|
|
Frame rate |
The Vision System processing rate, in number of frames per second. |
Microsoft Surface Client
The Client category provides counters to monitor the Microsoft Surface input system.
| Counter | Description |
|---|---|
|
Vision System - processing time |
The average time to deliver a contact event from the Vision System, in milliseconds. |
|
Core - contact processing time |
The average time to deliver a contact event from the Core layer, in milliseconds. |
|
Core - total contact count |
The total number of contacts since the application started. |
|
Core - number of contacts |
The current number of contacts over all windows for a given process. |
|
Core - contact event rate |
The number of ContactAdded, ContactRemoved, and ContactChanged events per second at the Core layer. |
|
Core - frame rate |
The number of FrameReceived events per second at the Core layer. |
|
Presentation - contact processing time |
The average time to deliver a contact event from the Presentation layer, in milliseconds. |
|
Presentation - contact event rate |
The number of ContactDown, ContactUp, and ContactChanged events per second at the Presentation layer. |
|
Presentation - grouping event rate |
The number of ContactChanged events batched together per second at the Presentation layer. |
|
Presentation - event queue length |
The number of pending events at the Presentation layer. |
Microsoft Surface System Control Module
The System Control Module category provides counters to monitor the system control module (SCM).
| Counter | Description |
|---|---|
|
Lamp Temperature |
The lamp temperature, in degrees Celsius. |
|
OSTAR Temperature |
The OSTAR infrared direct illumination system temperature, in degrees Celsius. |
|
Computer Temperature |
The computer temperature, in degrees Celsius. |
|
DMD Temperature |
The digital micromirror device (DMD) temperature, in degrees Celsius. |
|
Lamp Fan Speed |
The lamp fan speed, in revolutions per minute. |
|
OSTAR Fan Speed |
The OSTAR fan speed, in revolutions per minute. |
|
Computer Fan Speed |
The computer fan speed, in revolutions per minute. |
|
DMD Fan Speed |
The Digital Micromirror Device (DMD) fan speed, in revolutions per minute. |
Monitoring Surface Performance Counters
You can use the Microsoft Windows Reliability and Performance Monitor (PerfMon) to monitor Microsoft Surface performance counters, but first you must add them to Performance Monitor.
To add Surface performance counters to Performance Monitor
-
Click Start, enter perfmon.exe, and then press ENTER.
-
In the left pane, under Monitoring Tools, click Performance Monitor.
-
In the toolbar within the right pane, click the Add button (
). -
Under Available counters, scroll through the list until you see Microsoft Surface Client, Microsoft Surface System Control Module, and Microsoft Surface Vision System.
-
Expand the node that you are interested in, select the counter that you want to add, and then click Add.
-
Add any more counters that you want, and then click OK.
The counters are tracked in the chart in the right pane. Below the chart, you can select a specific counter to view its values and other information about it.
Troubleshooting by Using Performance Counters
The following table describes scenarios that show how you can use performance counters to troubleshoot Microsoft Surface-related performance issues in a Microsoft Surface application.
| Scenario | Solution |
|---|---|
|
A Microsoft Surface application does not receive any Contact events. |
If the counter is 0, the Vision System is not running or the Vision System does not see any contacts. Make sure that the SurfaceInput.exe process is running. |
|
Panning in SurfaceScrollViewer is not smooth. |
If (1) is low, the system is busy, and the Vision System does not have enough resources to process contacts. This situation typically occurs because of high CPU utilization on the system. Look for processes that load CPU. If (2) is much lower than (1) and if (3) is large, the application UI thread is busy, and you should change the application to offload some processing to a different thread or reduce the computation load altogether. This situation might also occur because the application is inefficiently using WPF. |
|
When you are panning a SurfaceScrollViewer control, the IsScrolling property randomly switches between true and false. |
If the counter value increases while a contact moves across the Microsoft Surface screen, the Vision System cannot track it and treats it as a new contact with a new ID. Most likely, the panning velocity is too high for the Vision System to track it. |
|
You want to know the latency between touching the Microsoft Surface screen and when your application receives notification of a new contact. |
These counters reflect the elapsed time between a driver receiving data and the corresponding contact event that is raised to the application. |
Client performance counters are counted per process based on process name. If there are multiple processes with the same name that are running at the same time, the performance counters reflect data only from the first process.