Adaptation/GUID-67CFF27B-55AF-42AC-95AF-E71A7C54039E.dita
changeset 15 307f4279f433
equal deleted inserted replaced
14:578be2adaf3e 15:307f4279f433
       
     1 <?xml version="1.0" encoding="utf-8"?>
       
     2 <!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
       
     3 <!-- This component and the accompanying materials are made available under the terms of the License 
       
     4 "Eclipse Public License v1.0" which accompanies this distribution, 
       
     5 and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
       
     6 <!-- Initial Contributors:
       
     7     Nokia Corporation - initial contribution.
       
     8 Contributors: 
       
     9 -->
       
    10 <!DOCTYPE concept
       
    11   PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
       
    12 <concept id="GUID-67CFF27B-55AF-42AC-95AF-E71A7C54039E" xml:lang="en"><title>Sample
       
    13 Device Drivers</title><shortdesc>This document describes the steps and options for coding a device
       
    14 driver, and how to use APIs to access the services provided by the Symbian
       
    15 platform kernel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
       
    16 <p>Illustrations of the use of APIs are taken from a number of example device
       
    17 drivers. These are summarised below. All of the drivers implement support
       
    18 for serial communications over a UART. They are designed to show a number
       
    19 of different implementation techniques. </p>
       
    20 <table id="GUID-6AD1B279-724D-5EBD-9372-66400B8C9465">
       
    21 <tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
       
    22 <tbody>
       
    23 <row>
       
    24 <entry><p> <b>Name</b>  </p> </entry>
       
    25 <entry><p> <b>Key functionality</b>  </p> </entry>
       
    26 </row>
       
    27 <row>
       
    28 <entry><p> <filepath> exdriver_pio</filepath>  </p> </entry>
       
    29 <entry><p>Shows a simple driver running on a kernel DFC thread. It polls for
       
    30 data using a timer. </p> <p><xref href="GUID-1AFAD1C4-340B-4119-94A8-F50E9D8DA8E6.dita">Timers</xref> discusses
       
    31 timers in detail. </p> </entry>
       
    32 </row>
       
    33 <row>
       
    34 <entry><p> <filepath> exdriver_int</filepath>  </p> </entry>
       
    35 <entry><p>Illustrates the use of interrupts and asynchronous request handling. </p> <p><xref href="GUID-4DAC39E0-2EC2-40F7-9AEF-4FDA09F1A151.dita">Asynchronous Requests</xref> describes
       
    36 how to implement handling of asynchronous requests. </p> <p><xref href="GUID-8FA1B2B0-5842-4D5D-BD61-C2D79B56ADC6.dita">Interrupt
       
    37 Service Routine (ISR)</xref> describes how to write ISRs to handle interrupts
       
    38 from hardware devices. </p> </entry>
       
    39 </row>
       
    40 <row>
       
    41 <entry><p> <filepath> exdriver_dma</filepath>  </p> </entry>
       
    42 <entry><p>Illustrates the use of DMA (Direct Memory Access). </p> <p><xref href="GUID-D1F7D21F-BA9D-482C-9B58-7C53A680145A.dita">DMA</xref> describes how
       
    43 to use DMA for fast copying of data from memory to memory, and between memory
       
    44 and peripherals. </p> </entry>
       
    45 </row>
       
    46 <row>
       
    47 <entry><p> <filepath>exdriver_chnk</filepath>  </p> </entry>
       
    48 <entry><p>Illustrates shared chunks and synchronization in a multi-thread
       
    49 context. </p> <p><xref href="GUID-132349A6-9A5F-4866-A54D-F01B6F58ABDD.dita">Shared
       
    50 Chunks</xref> describes how to share data efficiently without the overhead
       
    51 of memory copy operations. </p> </entry>
       
    52 </row>
       
    53 <row>
       
    54 <entry><p> <filepath> exdriver_sync</filepath>  </p> </entry>
       
    55 <entry><p>Illustrates synchronous request handling, and the use of the <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref> base
       
    56 class for LDDs. </p> <p><xref href="GUID-CFE0A4EB-845C-43B6-A732-AA155AFD99D6.dita">User
       
    57 Requests and Synchronisation</xref> discusses the options for how LDDs can
       
    58 handle requests. </p> </entry>
       
    59 </row>
       
    60 </tbody>
       
    61 </tgroup>
       
    62 </table>
       
    63 <p>The source code for the example device drivers is delivered as part of
       
    64 the Symbian platform source code on kits, using the directory structure described
       
    65 previously in the <xref href="GUID-2ADB873A-1580-476A-9642-AB47D13D4A98.dita">Source
       
    66 Directory Structure</xref> section. </p>
       
    67 </conbody></concept>