--- a/GAPE/gape_chipset_api.h Mon Dec 14 17:31:38 2009 +0000
+++ b/GAPE/gape_chipset_api.h Wed Dec 16 17:41:52 2009 +0000
@@ -1,18 +1,34 @@
/*
- gptimer_chipset_api.h
+Nokia/Devices/R&D/SD/SSS
+CONFIDENTIAL
+Deliverable software
+
+
- Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
- All rights reserved.
+ GAPE_CHIPSET_API.H
+ --------------------------------
+
+ SW Include Document - Symbian OS
+
+
+
+Document identification and location in Synergy/CM
- This program and the accompanying materials are made available
- under the terms of the Eclipse Public License v1.0 which accompanies
- this distribution, and is available at
- http://www.eclipse.org/legal/epl-v10.html
+Database: ...
- Initial Contributors:
- Nokia Corporation - initial contribution.
+Object (this information is substituted by Synergy/CM):
+ %name: %
+ %cvtype: %
+ %instance: %
+ %version: %
+ %date_modified: %
- Contributors:
+Copyright (c) Nokia. This material, including documentation and any related
+computer programs, is protected by copyright controlled by Nokia.
+All rights are reserved. Copying, including reproducing, storing, adapting or
+translating, any or all of this material requires the prior written consent
+of Nokia. This material also contains confidential information, which may not
+be disclosed to others without the prior written consent of Nokia.
*/
/** @file
@@ -29,83 +45,9 @@
// Include files
#include <kern_priv.h>
-
+#include <gape_descriptors.h>
// Constants
-
-/* The list of the descriptor names what the array can hold */
-_LIT8( KTvOut, "TvOut" );
-_LIT8( KKeypad, "Keypad" );
-_LIT8( KNand, "Nand" );
-_LIT8( KPrimaryDisplay, "PriDisp" );
-_LIT8( KSecondaryDisplay, "SecDisp" );
-_LIT8( KSecurity, "Security" );
-_LIT8( KUsbExt, "UsbExtension" );
-_LIT8( KUsbDriver, "UsbDriver" );
-_LIT8( KDigitiser, "Digitiser" );
-_LIT8( KMmc, "Mmc" );
-_LIT8( KSd, "Sd" );
-_LIT8( KHdd, "Hdd" );
-_LIT8( KCustom, "Custom" );
-_LIT8( KJoystick, "Joystick" );
-_LIT8( KLight, "Light" );
-_LIT8( KSwitch, "Switch" );
-_LIT8( KQwerty, "Qwerty" );
-_LIT8( KPanicScreen, "PanicScreen" );
-_LIT8( KBootFigure0, "BootFigure0" );
-_LIT8( KBootFigure1, "BootFigure1" );
-_LIT8( KThermalSensor, "ThermalSensor" );
-_LIT8( KCameraHWA, "CameraHWA" );
-_LIT8( KCameraDriver, "CameraDriver" );
-_LIT8( KDisplayDriver, "DisplayDriver" );
-_LIT8( KPowerModel, "PowerController" );
-_LIT8( KTwistDriver, "TwistDriver" );
-_LIT8( KCameraStaticData, "CameraStaticData" );
-_LIT8( KAccelerometer, "Accelerometer" );
-_LIT8( KExpander, "KeypadExpander" );
-_LIT8( KPowerTouareg, "PowerTouareg" );
-_LIT8( KKernelDataTransferApiUsb, "UsbDataIf" );
-_LIT8( KNaviScroll, "NaviScroll" );
-_LIT8( KTouchIC, "TouchIC" );
-
-/** Array for pointers (for registered descriptors) */
-const TDesC8* const KPtrArray[] =
- {
- &KTvOut,
- &KKeypad,
- &KNand,
- &KPrimaryDisplay,
- &KSecondaryDisplay,
- &KSecurity,
- &KUsbExt,
- &KUsbDriver,
- &KDigitiser,
- &KMmc,
- &KSd,
- &KHdd,
- &KCustom,
- &KJoystick,
- &KLight,
- &KSwitch,
- &KQwerty,
- &KPanicScreen,
- &KBootFigure0,
- &KBootFigure1,
- &KThermalSensor,
- &KCameraHWA,
- &KCameraDriver,
- &KDisplayDriver,
- &KPowerModel,
- &KCameraStaticData,
- &KAccelerometer,
- &KExpander,
- &KPowerTouareg,
- &KKernelDataTransferApiUsb,
- &KNaviScroll,
- &KTouchIC
- };
-
-/** Maximum number of items in an array */
-const TUint KPtrArraySize = ( sizeof( KPtrArray ) / sizeof( KPtrArray[0] ) );
+// defined in gape_descriptors.h
// Macros
@@ -133,45 +75,32 @@
new instances of this class.
@return GApe* An instance to GApe class
+ @pre Pre-condition: do not call from an ISR
*/
static GApe* Instance();
/**
Save pointer to internal array e.g.
- @code
- TInt ret = GApe::SetPtr( KTvOut, this );
- if ( ret != KErrNone )
- {
- // Error handling...
- }
- @endcode
-
@param aName Name used for registering pointer
@param aPtr Pointer to be saved
@return KErrNone, if successful. KErrAlreadyExists, if the pointer
is already registered. KErrNotFound, if the 'aName' is not
a valid name.
+ @pre Pre-condition: Call in any context
*/
IMPORT_C static TInt SetPtr(const TDesC8& aName, TAny* const aPtr);
/**
Get pointer from internal array e.g.
- @code
- DTvOut* tvout = static_cast<DTvOut*>( GApe::GetPtr( KTvOut ) );
- if ( tvout )
- {
- // Usage...
- }
- @endcode
-
@param aName Name of the registered pointer
@return Pointer to requested item. May also return NULL, which
indicates that the pointer is not registered or the name
is not valid.
+ @pre Pre-condition: Call in any context
*/
IMPORT_C static TAny* GetPtr(const TDesC8& aName);