Kinect for Windows SDK Programming Guide
上QQ阅读APP看书,第一时间看更新

Installing Kinect for Windows SDK

Before running the installation, make sure of the following:

  • You have uninstalled all the previous versions of Kinect for Windows SDK
  • The Kinect sensor is not plugged into the USB port on the computer
  • There are no Visual Studio instances currently running

Start the installer, which will display the start screen as End User License Agreement. You need to read and accept this agreement to proceed with the installation. The following screenshot shows the license agreement:

Installing Kinect for Windows SDK

Accept the agreement by selecting the checkbox and clicking on the Install option, which will do the rest of the job automatically.

Note

Before the installation, your computer may pop out the User Access Control (UAC ) dialog, to get a confirmation from you that you are authorizing the installer to make changes in your computer.

Once the installation is over, you will be notified along with an option for installing the Developer Toolkit, as shown in the next screenshot:

Installing Kinect for Windows SDK

Tip

Is it mandatory to uninstall the previous version of SDK before we install the new one?

The upgrade will happen without any hassles if your current version is a non-Beta version. As a standard procedure, it is always recommended to uninstall the older SDK prior to installing the newer one, if your current version is a Beta version.

Installing the Developer Toolkit

If you didn't downloaded the Developer Toolkit installer earlier, you can click on the Download the Developer Toolkit option of the SDK setup wizard (refer to the previous screenshot); this will first download and then install the Developer Toolkit setup. If you have already downloaded the setup, you can close the current window and execute the standalone Toolkit installer. The installation process for Developer Toolkit is similar to the process for the SDK installer.

Components installed by the SDK and the Developer Toolkit

The Kinect for Windows SDK and Kinect for Windows Developer Toolkit install the drivers, assemblies, samples, and the documentation. To check which components are installed, you can navigate to the Install and Uninstall Programs section of Control Panel and search for Kinect. The following screenshot shows the list of components that are installed with the SDK and Toolkit installer:

Components installed by the SDK and the Developer Toolkit

Note

The default location for the SDK and Toolkit installation is %ProgramFiles%/Microsoft SDKs/Kinect.

Kinect management service

The Kinect for Windows SDK also installs Kinect Management, which is a Windows service that runs in the background while your PC communicates with the device. This service is responsible for the following tasks:

  • Listening to the Kinect device for any status changes
  • Interacting with the COM Server for any native support
  • Managing the Kinect audio components by interacting with Windows audio drivers

You can view this service by launching Services by navigating to Control Panel | Administrative Tools, or by typing Services.msc in the Run command.

Tip

Is it necessary to install the Kinect SDK to end users' systems?

The answer is No. When you install the Kinect for Windows SDK, it creates a Redist directory containing an installer that is designed to be deployed with Kinect applications, which install the runtime and drivers. This is the path where you can find the setup file after the SDK is installed:

%ProgramFiles%/\Microsoft SDKs\Kinect\v1.6\Redist\KinectRuntime-v1.6-Setup.exe

This can be used with your application deployment package, which will install only the runtime and necessary drivers.

Connecting the sensor with the system

Now that we have installed the SDK, we can plug the Kinect device into your PC. The very first time you plug the device into your system, you will notice the LED indicator of the Kinect sensor turning solid red and the system will start installing the drivers automatically.

Note

The default location of the driver is %Program Files%\Microsoft Kinect Drivers\Drivers.

The drivers will be loaded only after the installation of SDK is complete and it's a one-time job. This process also checks for the latest Windows updates on USB Drivers, so it is good to be connected to the Internet if you don't have the latest updates of Windows.

The check marks in the dialog box shown in the next screenshot indicate successful driver software installation:

Connecting the sensor with the system

When the drivers have finished loading and are loaded properly, the LED light on your Kinect sensor will turn solid green. This indicates that the device is functioning properly and can communicate with the PC as well.

Verifying the installed drivers

This is typically a troubleshooting procedure in case you encounter any problems. Also, the verification procedure will help you to understand how the device drivers are installed within your system. In order to verify that the drivers are installed correctly, open Control Panel and select Device Manager; then look for the Kinect for Windows node. You will find the Kinect for Windows Device option listed as shown in the next screenshot:

Verifying the installed drivers

Not able to view all the device components

At some point of time, it may happen that you are able to view only the Kinect for Windows Device node (refer to the following screenshot). At this point of time, it looks as if the device is ready. However, a careful examination reveals a small hitch. Let's see whether you can figure it out or not! The Kinect device LED is on and Device Manager has also detected the device, which is absolutely fine, but we are still missing something here. The device is connected to the PC using the USB port, and the system prompt shows the device installed successfully—then where is the problem?

Not able to view all the device components

The default USB port that is plugged into the system doesn't have the power capabilities required by the camera, sensor, and motor. At this point, if you plug it into an external power supplier and turn the power on, you will find all the driver nodes in Device Manager loaded automatically.

Note

This is one of the most common mistakes made by the developers. While working with Kinect SDK, make sure your Kinect device is connected with the computer using the USB port, and the external power adapter is plugged in and turned on.

The next picture shows the Kinect sensor with USB connector and power adapter, and how they have been used:

Not able to view all the device components

With the aid of the external power supply, the system will start searching for Windows updates for the USB components. Once everything is installed properly, the system will prompt you as shown in the next screenshot:

Not able to view all the device components

All the check marks in the screenshot indicate that the corresponding components are ready to be used and the same components are also reflected in Device Manager.

Note

The messages prompting for the loading of drivers, and the prompts for the installation displaying during the loading of drivers, may vary depending upon the operating system you are using. You might also not receive any of them if the drivers are being loaded in the background.

Detecting the loaded drivers in Device Manager

Navigate to Control Panel | Device Manager, look for the Kinect for Windows node, and you will find the list of components detected. Refer to the next screenshot:

Detecting the loaded drivers in Device Manager

The Kinect for Windows Audio Array Control option indicates the driver for the Kinect audio system whereas the Kinect for Windows Camera option controls the camera sensor. The Kinect for Windows Security Control option is used to check whether the device being used is a genuine Microsoft Kinect for Windows or not. In addition to appearing under the Kinect for Windows node, the Kinect for Windows USB Audio option should also appear under the Sound, Video and Game Controllers node, as shown in the next screenshot:

Detecting the loaded drivers in Device Manager

Once the Kinect sensor is connected, you can identify the Kinect microphone like any other microphone connected to your PC in the Audio Device Manager section. Look at the next screenshot:

Detecting the loaded drivers in Device Manager