CardRequestWindow (Windows Embedded CE 6.0)
1/6/2010
This function allocates a window within system memory used to access PC Card memory or I/O space. The window must be mapped by the CardMapWindow function before the window can access the PC Card.
Syntax
CARD_WINDOW_HANDLE CardRequestWindow(
CARD_CLIENT_HANDLE hCardClient,
PCARD_WINDOW_PARMS pCardWinParms
);
Parameters
- hCardClient
[in] Client handle obtained from the CardRegisterClient function.
- pCardWinParms
[in] Pointer to a CARD_WINDOW_PARMS structure.
Return Value
A driver handle indicates success. NULL indicates failure, and GetLastError returns one of the following values:
- CERR_BAD_ARGS
Indicates that the pointer specified for pCardWinParms is not valid.
- CERR_BAD_HANDLE
Indicates that hCardClient is not a valid client.
- CERR_BAD_SOCKET
Indicates that the socket identifier specified for the hSocket member for CARD_WINDOW_PARMS is not valid or that no PC Card is inserted.
- CERR_OUT_OF_RESOURCE
Indicates that card services is unable to allocate memory to track the memory window or that the system has no windows available that match the requested window attributes.
Remarks
This function allocates a memory or an I/O window, according to the values specified in CARD_WINDOW_PARMS. You can use the returned handle for subsequent calls to the CardMapWindow and CardModifyWindow functions.
Requirements
Header | cardsv2.h |
Library | Pcc_serv.dll |
Windows Embedded CE | Windows CE 1.0 and later |
See Also
Reference
PC Card Driver Functions
CardMapWindow
CardModifyWindow
CardReleaseWindow
CARD_WINDOW_PARMS