-
5.6.2. Enable/Disable CF Slot
Function Description:
Enable/disable CF slot.
Function call:
BOOL IOC_EnablePCMCIA0(BOOL On);
Parameters(Input):
On:
BOOL
: CF slot status = TRUE : Enable
= FALSE : Disable
Return code:
TRUE = Success
FALSE = Unsupported
Example:
#include “ioc_ioctl.h”
…
DWORD dwStatus;
HANDLE gIOControlDriverHandle;
…
gIOControlDriverHandle = CreateFile(L”IOC1:”, GENERIC_READ |
GENERIC_WRITE, FILE_SHARE_READ | FILE_SHARE_WRITE,
NULL, OPEN_EXISTING, 0, 0);
If (gIOControlDriverHandle == INVALID_HANDLE_VALUE)
{
// IO device not found, function not supported,
// error process
}
…
…
GetPCMCIA0Status(&dwStatus);
if (dwStatus == 0)
{
IOC_EnablePCMCIA0(TRUE); //if CF disabled, enable it
}
else
{
IOC_EnablePCMCIA0(FALSE); //if CF enabled, disable it
}
CloseHandle(gIOControlDriverHandle);
…
Содержание MR650
Страница 1: ...MR650 Programming Manual V 1 12 1 16 2008 ...
Страница 7: ... 7 13 FUNCTION KEY SETTING ON REGISTRY 65 14 UPDATE NOTES 66 ...
Страница 16: ... it is for internal use send messages ...
Страница 33: ... Be aware to release handles when program ends ...