Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
NDISUIO Implementation

NDISUIO Implementation (Windows CE 5.0)

Windows CE 5.0
Send Feedback

NDISUIO is implemented as an NDIS protocol driver. As a protocol driver, NDISUIO is NDIS-aware, and can directly open an NDIS miniport driver to send requests, set, and query information. NDISUIO provides an interface between a user-mode application and NDIS using DeviceIoControl.

Applications load NDISUIO from a DriverEntry routine. The application calls to CreateFile to generate a file handle, then associates the file handle with the target network device by sending IOCTL_NDISUIO_OPEN_DEVICE from DeviceIoControl. The application uses one file handle for each device that it communicates with.

The following shows how to call CreateFile to obtain a handle to the device.

hAdapter = CreateFile(
     NDISUIO_DEVICE_NAME,
     GENERIC_READ | GENERIC_WRITE,
     FILE_SHARE_READ | FILE_SHARE_WRITE,
     NULL,
     OPEN_EXISTING,
     FILE_ATTRIBUTE_NORMAL | FILE_FLAG_OVERLAPPED,
     INVALID_HANDLE_VALUE);

The following function call shows the use of IOCTL_NDISUIO_OPEN_DEVICE to create a binding with an NE20001 network device using the handle obtained from CreateFile.

DeviceIoControl(
hAdapter, 
     IOCTL_NDISUIO_OPEN_DEVICE,
TEXT("NE20001"),
wcslen(TEXT("NE20001")) * sizeof(TCHAR),
NULL,
0,
&dwReturnedBytes,
NULL);

The following list shows the operations NDISUIO does using the file object:

  • Read and write operations
  • Send or query NDIS OIDs
  • Receive bind and unbind notifications

See Also

NDIS User-mode I/O Driver | NDISUIO Operations | Simultaneous Access for Multiple Applications | NDISUIO Driver Registration | NDISUIO Binding and Unbinding


Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.


Show:
© 2015 Microsoft