RNDIS Concepts (Windows CE 5.0)

Send Feedback

RNDIS compliance places requirements on the communication channel and lower-layer drivers that are used to communicate between the host and the RNDIS device.

The following table provides a brief description of RNDIS requirements on the host.

RNDIS concept Description
Control Channel The control channel must be reliable and ensure sequenced delivery. It is used for all communication except for the transmission of network data packets. All required control messages, except REMOTE_NDIS_HALT_MSG and REMOTE_NDIS_INDICATE_STATUS_MSG, are request and response exchanges initiated by the host. The device must respond within the timeout period as specified for each bus.
Data Channel The data channel is used exclusively for the transmission of network data packets. It may consist of multiple sub channels as defined for the appropriate bus.
Initialization and Teardown The control and data channels are initialized and set up as specified for the appropriate bus. The host sends a REMOTE_NDIS_INITIALIZE_MSG message to the RNDIS device. The RNDIS device provides information about its type, supported medium, and version in the response message REMOTE_NDIS_INITIALIZE_CMPLT.
Either the host or the RNDIS device can tear down the communication channel through the REMOTE_NDIS_HALT_MSG message. All outstanding requests and packets are discarded on receipt of this message.
Halt At any time that the device is in the rndis-initialized or rndis-data-initialized state, the host computer may terminate the RNDIS functionality of the device by sending REMOTE_NDIS_HALT_MSG to the device.
Resetting the Communication Channel The communication channel is reset when an error, such as message timeout, occurs.
The host may initiate a reset at any time when the device is in the rndis-initialized state by sending the message REMOTE_NDIS_RESET_MSG to the device. The device must send a response message when it has completed the reset.
Flow Control The RNDIS device may need to exercise flow control to prevent the host from overflowing its data buffers with packets. Any flow control provisions or requirements are bus specific.
Numeric Byte Ordering All numeric values in RNDIS messages must be coded in little-endian format (least significant byte first).
NDIS Message Encapsulation There is no RNDIS specification for the way NDIS messages are encapsulated in native bus messages or primitives.

In the sense that any handles continue to be valid after a reset, any reset is a soft reset. The RNDIS device discards all outstanding requests and packets as part of the reset process. The remote device might reset a portion of its hardware, but keeps the communication channel intact.

If the RNDIS device performs a reboot, this event is equivalent to "Remove" followed by "Add" plug-and-play events. The host NDIS miniport driver will be halted and removed, and a new instance will be added and started. All bus-level and RNDIS initialization will be re-executed. A RNDIS device may reboot itself in the event of a critical device failure.

The following table shows the device states possible for RNDIS devices.

Device state Description
Rndis-uninitialized state Following bus-level initialization, the device is said to be in the rndis-uninitialized state.

If the device receives a REMOTE_NDIS_HALT_MSG, a bus-level disconnects, or a hard-reset at any time, it forces the device to the rndis-uninitialized state.

Rndis-initialized state After the device receives a REMOTE_NDIS_INITIALIZE_MSG and responds with a REMOTE_NDIS_INITIALIZE_CMPLT with a status of RNDIS_STATUS_SUCCESS, the device enters the rndis-initialized state.

If the device is in the rndis-data-initialized state when it receives a REMOTE_NDIS_SET_MSG specifying a zero filter value for OID_GEN_CURRENT_PACKET_FILTER, this event forces the device back to the rndis-initialized state.

Rndis-data-initialized state If the device receives a REMOTE_NDIS_SET_MSG that specifies a non-zero filter value for OID_GEN_CURRENT_PACKET_FILTER, the device enters the rndis-data-initialized state.

See Also

RNDIS Driver Implementation Guide

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.