⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 overview.d

📁 YLP270的Windows CE5.0 bsp源码。
💻 D
字号:
/*
@doc DRIVERS

@topic PCMCIA Client Driver Operation |
It is possible for a PC card to have more than one function.  Because of this,
card services uses a socket number and a function number combination to identify
a particular function (also called a logical socket).  The card services design
allows function specific device drivers to be platform independent because it hides
the details of the target hardware behind a well-defined software interface.  The
socket services provider corresponds to a set of platform dependent functions.  The
PCMCIA card services driver provides the interface between a function specific device
driver and the system.

A client driver initiates involvement in the plug and play environment by calling
<f CardRegisterClient> and specifying a card event callback function.  When card events
occur, such as CE_CARD_INSERTION, the card services driver calls the client's callback
function, passing it the event type (card services will callback all clients when a
multifunction card is inserted).  The client driver then must determine if and how to 
respond.  In the card insertion case, the client must determine whether the inserted
card is one that it can control.  Card services provides several functions for reading
the card information structures (CIS) to facilitate the client's detection process, in
addition, the CE_CARD_INSERTION callback includes a pointer to the card's PNP identification
string in one of the parameters.  When a client determines that it wants to service a card,
it uses card services to map system memory and I/O space to the card's memory and I/O space.
Also, the client driver for an interrupt driven I/O card must specify an interrupt service
routine (ISR, actually another callback) using <f CardRequestIRQ>.  
Card services calls a client driver's ISR only when a real interrupt occurs on the card it
is controlling.  If there are multiple functions on a card, then the ISR will be called only
when an interrupt occurs on the requested socket/function pair.

          
@topic PCMCIA Callbacks |

PCMCIA client drivers are notified of PC card status changes via a callback function which is
specified in the call to <f CardRegisterClient>.

The callbacks that can be initiated by a hardware event are CE_BATTERY_DEAD, CE_BATTERY_LOW,
CE_CARD_LOCK, CE_CARD_UNLOCK, CE_CARD_READY, CE_CARD_INSERTION, CE_CARD_REMOVAL and
CE_WRITE_PROTECT.  These callbacks go to all clients.


The following callback events are software initiated and are sent to all client drivers: 
CE_EXCLUSIVE_REQUEST due to <f CardRequestExclusive>;
CE_CARD_INSERTION due to one of <f CardRequestExclusive>, <f CardReleaseExclusive> or <f CardRegisterClient>;
CE_CARD_REMOVAL due to either <f CardRequestExclusive> or <f CardReleaseExclusive>.

These software initiated callbacks are sent only to the requesting client:
CE_EXCLUSIVE_COMPLETE due to <f CardRequestExclusive>,
CE_REGISTRATION_COMPLETE due to <f CardRegisterClient>.


Some callbacks occur in multi-event sequences:
When a client calls <f CardRegisterClient>, a CE_CARD_INSERTION is sent to it for all
functions on the inserted cards followed by a CE_REGISTRATION_COMPLETE.

When a client calls <f CardRequestExclusive>, a CE_EXCLUSIVE_REQUEST is sent to all clients
and if all clients approve, then a CE_CARD_REMOVAL is sent to all and then a 
CE_CARD_INSERTION is sent to the requesting client and followed by a CE_EXCLUSIVE_COMPLETE.

*/

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -