Tuning.Tune Method

Issues XML requests to the tuner and requests that non-critical Windows Media Center TV UI be suppressed.

Syntax

  public void Tune(
  string  xmlTune,
  bool  suppressUI
);

Parameters

xmlTune

System.String. An XML string that represents the new tune request.

suppressUI

System.Boolean. Indicates whether the system should suppress its non-critical TV user interface components. A value of false requests that the system not suppress these components and render these components as it would by default.

Return Value

This method does not return a value.

Remarks

This method queues an asynchronous XML-encoded request to the current tuner, to change some characteristic of its tuning qualities. Conceptually, this is used to change the channel. However, due to tuners having many technical details that indirectly relate channels to specific technical characteristics (such as frequency, transponder, or multicast address), the XML request may require a significant amount of detail.

The request is asynchronous in nature, and will be completed at some point after the initial call is made. The application should make use of the Tuning.PropertyChanged event and the Tuning.ChannelState property to determine when a queued asynchronous request has ceased processing.

A final component of this method allows the application to request that Windows Media Center begin suppressing non-critical portions of its TV graphical user interface (where critical should be perceived as things such as emergency access messages or window management controls).

The application developer should be aware that only a single tune request is allowed to be pending at a time, and attempts to queue a new request while one is already pending will generate a TuningInProgressException.

The Tuning.ChannelState property indicates whether a tune is in progress at any given time.

Unless you receive an exception, the tune request is assumed to succeed, although the time to complete the request is dependent on the tuner.

The schema for tuning can be found at in the Protected Broadcast Driver Architecture (PBDA) Specification, which is available on the Developing Protected Broadcast Drivers in Windows page on the Microsoft website.

The following excpetions are possible from this method:

Requirements

Reference: Microsoft.MediaCenter.ITVVM

Namespace: Microsoft.MediaCenter.TVVM

Assembly: Microsoft.MediaCenter.ITVVM.dll

Platform: Windows 7

See Also