Plug Finding (Windows CE 5.0)

Send Feedback

A plug is a difficult term to define in IEEE 1394, as it carries multiple meanings. A plug can be an external plug, that is, an input or output jack on a physical device. A plug could be an IEC-61883 unit serial bus plug, a conceptual endpoint for streaming communications. A plug could also be a conceptual internal source or destination for a particular subunit. When reading, be sure to note the context in which the word plug is mentioned. Microsoft® Windows® CE operating system (OS) support for IEEE 1394 currently does not support external plugs. The context in which you will find plug documentation here will be serial bus or subunit plugs. A serial bus plug is something global to the unit; a unit is usually equivalent to the physical device in question. A subunit plug is relative only to the subunit. Other subunits have no reference to it. This documentation usually refers to plugs when meaning serial bus plugs.

Before streaming data using AVC_STREAM, you must know which serial bus plug on the remote device you want to stream data to or from. Determining which plug to use is not always easy; AV/C has no mandatory scheme for managing plugs, and many camcorders always use plug 0, or broadcast. Currently, AVC_STREAM supports several plug management commands defined in the AV/C Digital Interface Command Set General Specification.

From a programming perspective, you to have an understanding of which subunit plug identifier that you want to connect to. These are subunit-specific definitions. If no documentation has been provided for determining these on a per-subunit basis, you might consider utilizing 0. Once you know the subunit plug identifier, you can attempt to locate a serial bus plug on the remote device that is associated with that subunit plug. The command IOCTL_STREAM_LOCATE_REMOTE_PLUG currently encapsulates the AV/C commands from the specification mentioned above. The different schemes for managing plugs have different requirements. Some require that once you have completed using a plug, you should free the resource. Others do not have this requirement. To accommodate all scenarios transparently, the developer should call IOCTL_STREAM_DEREFERENCE_REMOTE_PLUG when no longer connected to the plug and when completely finished with it. Depending on the mechanism used by IOCTL_STREAM_LOCATE_REMOTE_PLUG to find or connect to the plug, IOCTL_STREAM_DEREFERENCE_REMOTE_PLUG might or might not take action. From the perspective of the developer, this is unimportant as the plug resource freeing is transparent.

Once you have determined the serial bus plug number on the remote device, utilize IOCTL_STREAM_GET_REMOTE_PLUG_HANDLE to obtain the plug handle required by IOCTL_STREAM_START_RECV_SESSION or IOCTL_STREAM_START_XMIT_SESSION.

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.