wlan_plat/wlan_hw_initialization_data_api/inc/wlanhwinitinterface.h
changeset 0 c40eb8fe8501
equal deleted inserted replaced
-1:000000000000 0:c40eb8fe8501
       
     1 /*
       
     2 * Copyright (c) 2002-2006 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Defines the abstract interface for HW specific initialization
       
    15 *
       
    16 */
       
    17 
       
    18 /*
       
    19 * %version: 6 %
       
    20 */
       
    21 
       
    22 #ifndef WLANHWINITINTERFACE_H
       
    23 #define WLANHWINITINTERFACE_H
       
    24 
       
    25 #include <e32base.h>
       
    26 
       
    27 /**
       
    28 * Length of the MAC address.
       
    29 */
       
    30 const TUint8 KMacAddrLength = 6;
       
    31 
       
    32 /**
       
    33 * Structure for storing a MAC address.
       
    34 */
       
    35 struct TMacAddr
       
    36     {
       
    37     /** the MAC address */
       
    38     TUint8 iMacAddress[KMacAddrLength];
       
    39     };
       
    40 
       
    41 /**
       
    42  * This is the abstract base class used for HW specific initialization.
       
    43  *
       
    44  * @since Series 60 3.1
       
    45  */
       
    46 class MWlanHwInitInterface
       
    47     {
       
    48     public:  // Constructors and destructor
       
    49 
       
    50         // New functions
       
    51 
       
    52         /**
       
    53          * Get pointer to hardware specific initialization data.
       
    54          * @since Series 60 3.1
       
    55          * @param aInitData Pointer to initialization data, NULL if none.
       
    56          * @param aInitLength Length of initialization data.
       
    57          * @param aFwData Pointer to firmware data, NULL if none.
       
    58          * @param aFwLength Length of firmware data.
       
    59          */
       
    60         virtual void GetHwInitData(
       
    61             const TUint8** aInitData,
       
    62             TUint& aInitLength,
       
    63             const TUint8** aFwData,
       
    64             TUint& aFwLength ) = 0;
       
    65 
       
    66         /**
       
    67          * Get device MAC address.
       
    68          * @since Series 60 3.1
       
    69          * @param aMacAddress MAC address of the device.
       
    70          * @return A Symbian error code.
       
    71          * @note If a special MAC address 00:00:00:00:00:00 is returned,
       
    72          * the WLAN engine assumes the device to be a variant without
       
    73          * WLAN support and will not start the up.
       
    74          */
       
    75         virtual TInt GetMacAddress(
       
    76             TMacAddr& aMacAddress ) = 0;
       
    77 
       
    78         /**
       
    79          * Methods for production testing.
       
    80          */
       
    81 
       
    82         /**
       
    83          * Get pointer to hardware specific initialization data for production testing.
       
    84          * @since Series 60 3.1
       
    85          * @param aInitData Pointer to initialization data, NULL if none.
       
    86          * @param aInitLength Length of initialization data.
       
    87          * @param aFwData Pointer to firmware data, NULL if none.
       
    88          * @param aFwLength Length of firmware data.
       
    89          */
       
    90         virtual void GetHwTestInitData(
       
    91             const TUint8** aInitData,
       
    92             TUint& aInitLength,
       
    93             const TUint8** aFwData,
       
    94             TUint& aFwLength ) = 0;
       
    95 
       
    96         /**
       
    97          * Get hardware specific production testing data.
       
    98          * @since Series 60 3.1
       
    99          * @param aId Id of the parameter to read.
       
   100          * @param aData Buffer for read data.
       
   101          * @return A Symbian error code.
       
   102          */
       
   103         virtual TInt GetHwTestData(
       
   104             TUint aId,
       
   105             TDes8& aData ) = 0;
       
   106 
       
   107         /**
       
   108          * Set hardware specific production testing data.
       
   109          * @since Series 60 3.1
       
   110          * @param aId Id of the parameter to store.
       
   111          * @param aData Data to be stored.
       
   112          * @return A Symbian error code.
       
   113          */
       
   114         virtual TInt SetHwTestData(
       
   115             TUint aId,
       
   116             TDesC8& aData ) = 0;
       
   117     };
       
   118 
       
   119 #endif // WLANHWINITINTERFACE_H