UPnP AV Renderer Sample (Windows CE 5.0)

Send Feedback

The AV renderer sample, also known as the MediaRenderer sample, uses the AV Device API to implement a UPnP AV MediaRenderer device.

The implemented MediaRenderer uses the UPnP AV Framework and DirectShow functionality in Windows CE to output audio provided by a UPnP AV MediaServer device on your network.

The AV renderer sample is associated with a SYSGEN variable, so to include the AV renderer sample in your OS design, you just need to add the AV Renderer Sample Catalog item or define the SYSGEN_UPNP_AV_RENDERER Sysgen variable.

The files that implement the AV renderer sample are in %_WINCEROOT%\Public\DirectX\Oak\Samples\UPnP\MediaRenderer.

The AVTransport service's PrepareForConnection action is defined as optional in the UPnP AV DCP. The AV renderer sample implements PrepareForConnection, or does not, depending on the value of the CM_NO_PREPARE_FOR_CONNECTION preprocessor definition. If this constant is defined, the sample does not support PrepareForConnection; otherwise, the sample provides support for multiple connections. To see how this definition is used, examine ConnectionManager.cpp in the AV renderer sample's source directory.

Before using the AV renderer sample, ensure that the AV Renderer Sample Catalog item is part of your OS design.

To use the AV renderer sample

  1. Build, download, and run the run-time image to your target device.

    The renderer sample starts when the run-time image starts. However, it does not have a user interface. You can confirm the sample is running by examining the processes on the target device and confirming that mediarenderer.dll is loaded.

    Alternatively, if you use a UPnP or general-purpose network sniff utility, you can see the NOTIFY messages sent by the AV renderer sample when the run-time image starts.

  2. Ensure that a UPnP AV MediaServer device is running on your network and is sharing audio content.

    Note   Windows CE does not include a UPnP MediaServer sample. You can use another MediaServer implementation or implement your own using the same AV Device API used by the AV renderer sample.

  3. Using a UPnP control point, perform whatever steps are necessary to instruct the control point to send audio from the MediaServer device to the Windows CE-based MediaRenderer device.

    The target device outputs the audio.

Although a general-purpose UPnP control point application can control an AV MediaServer and AV MediaRenderer, the required action invocations can be complex. It may be easier to use a dedicated UPnP AV control point that understands specific AV actions and provides a dedicated AV-focused user interface.

Windows CE includes an AV control point sample. However, this sample does not demonstrate all of the functionality a more full-featured AV control point application could expose. For more information about the provided UPnP AV control point sample, see UPnP AV Control Point Sample.

See Also

UPnP Samples

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.