epoc32/include/hcibase.h
author William Roberts <williamr@symbian.org>
Tue, 16 Mar 2010 16:12:26 +0000
branchSymbian2
changeset 2 2fe1408b6811
permissions -rw-r--r--
Final list of Symbian^2 public API header files
williamr@2
     1
// Copyright (c) 1999-2009 Nokia Corporation and/or its subsidiary(-ies).
williamr@2
     2
// All rights reserved.
williamr@2
     3
// This component and the accompanying materials are made available
williamr@2
     4
// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
williamr@2
     5
// which accompanies this distribution, and is available
williamr@2
     6
// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
williamr@2
     7
//
williamr@2
     8
// Initial Contributors:
williamr@2
     9
// Nokia Corporation - initial contribution.
williamr@2
    10
//
williamr@2
    11
// Contributors:
williamr@2
    12
//
williamr@2
    13
// Description:
williamr@2
    14
// This is the API that the bluetooth stack expects from the HCI layer.
williamr@2
    15
// It comprises an event notification interface and a command sending interface.
williamr@2
    16
// Implementations of the HCI must derive from CHCIBase.
williamr@2
    17
// 
williamr@2
    18
//
williamr@2
    19
williamr@2
    20
williamr@2
    21
williamr@2
    22
/**
williamr@2
    23
 @file
williamr@2
    24
 @publishedPartner
williamr@2
    25
 @released
williamr@2
    26
*/
williamr@2
    27
williamr@2
    28
#ifndef BT_HCIBASE_H_
williamr@2
    29
#define BT_HCIBASE_H_
williamr@2
    30
williamr@2
    31
#include <bttypes.h>
williamr@2
    32
#include <hcierrors.h>
williamr@2
    33
#include <hcitypes.h>
williamr@2
    34
#include <e32base.h>
williamr@2
    35
williamr@2
    36
#include <bluetooth/hci/hciopcodes.h>
williamr@2
    37
#include <bluetooth/hci/aclpacketconsts.h>
williamr@2
    38
#include <bluetooth/hci/hciconsts.h>
williamr@2
    39
#include <bluetooth/hci/basebandpacketconsts.h>
williamr@2
    40
williamr@2
    41
class CHCICommandFrame;
williamr@2
    42
class CHCIACLDataFrame;
williamr@2
    43
class CHCISCODataFrame;
williamr@2
    44
class CHCIBase;
williamr@2
    45
class MHCIEventObserver;
williamr@2
    46
class CESockIniData;
williamr@2
    47
williamr@2
    48
/** Factory for creating CHCIBase derived class.
williamr@2
    49
williamr@2
    50
To provide a new HCI implementation, re-implement this
williamr@2
    51
class in a DLL, which has a factory fucntion at oridnal 1
williamr@2
    52
which returns a TAny* to the instance of this factory.
williamr@2
    53
NewHCIL() will then be called on the factory to actually
williamr@2
    54
create the CHCIBase derived object.
williamr@2
    55
williamr@2
    56
@released
williamr@2
    57
@publishedPartner
williamr@2
    58
*/	
williamr@2
    59
NONSHARABLE_CLASS(CHCIFactory) : public CBase
williamr@2
    60
    {
williamr@2
    61
public: 
williamr@2
    62
	CHCIFactory();
williamr@2
    63
    virtual TVersion Version() const;
williamr@2
    64
    virtual CHCIBase* NewHCIL(MHCIEventObserver* aParent, CESockIniData* aIni=0);
williamr@2
    65
	virtual CHCICommandFrame* NewHCICommandFrameL(THCIOpcode aOpcode);
williamr@2
    66
	virtual CHCIACLDataFrame* NewHCIACLDataFrameL(TUint16 aSize);
williamr@2
    67
	virtual CHCISCODataFrame* NewHCISCODataFrameL(TUint8 aSize);
williamr@2
    68
	};
williamr@2
    69
williamr@2
    70
williamr@2
    71
/** Abstract HCI Interface class.
williamr@2
    72
 
williamr@2
    73
The Symbian Bluetooth stack uses this abstract class as the 
williamr@2
    74
polymorphic base through which it obtains host controller
williamr@2
    75
access. The actual implementation is dependent on the DLL
williamr@2
    76
loaded at run-time, as specified in the bt.bt.esk file.
williamr@2
    77
The concrete class derived from this should be returned
williamr@2
    78
by the CHCIFactory class, located through ordinal 1 in the
williamr@2
    79
polymorphic DLL.
williamr@2
    80
williamr@2
    81
@publishedPartner
williamr@2
    82
@released
williamr@2
    83
@see 
williamr@2
    84
CHCI for detailed description of the functions.
williamr@2
    85
MHCIEventObserver for the callback interface for events received over HCI.
williamr@2
    86
*/ 
williamr@2
    87
NONSHARABLE_CLASS(CHCIBase) : public CBase
williamr@2
    88
	{
williamr@2
    89
public:
williamr@2
    90
williamr@2
    91
	/** Writes command frame.
williamr@2
    92
williamr@2
    93
	 @param aFrame command frame to write
williamr@2
    94
	 @return KErrBcspWriteCommandDataFailed on failure, KErrNone otherwise
williamr@2
    95
	 @released
williamr@2
    96
	 @publishedPartner
williamr@2
    97
	 */
williamr@2
    98
	virtual TInt WriteCommand(const CHCICommandFrame& aFrame)=0;
williamr@2
    99
williamr@2
   100
	// HCI General exports
williamr@2
   101
	/** Sets option.
williamr@2
   102
williamr@2
   103
	 @param aName option to set
williamr@2
   104
	 @param aData option value
williamr@2
   105
	 @return System wide error code
williamr@2
   106
	 @released
williamr@2
   107
	 @publishedPartner
williamr@2
   108
	 */
williamr@2
   109
    virtual TInt SetOption(TUint aName,const TDesC8& aData)=0;
williamr@2
   110
williamr@2
   111
    /** Gets option.
williamr@2
   112
williamr@2
   113
	 @param aName option to set
williamr@2
   114
	 @param aData desriptor to be filled with option data
williamr@2
   115
	 @return System wide error code
williamr@2
   116
     @released
williamr@2
   117
     @publishedPartner
williamr@2
   118
     */
williamr@2
   119
    virtual TInt GetOption(TUint aName,TDes8& aData)=0;
williamr@2
   120
	
williamr@2
   121
	// HCI Data Calls
williamr@2
   122
    /** Formats ACL Data.
williamr@2
   123
williamr@2
   124
	 @param aFrame Reference to CHCIACLDataFrame which will be formatted with the data supplied in the other params
williamr@2
   125
	 @param aConnH Connection handle for this frame
williamr@2
   126
	 @param aFlags Flags to be set for this frame
williamr@2
   127
	 @param aData Data for this frame
williamr@2
   128
     @released
williamr@2
   129
     @publishedPartner
williamr@2
   130
     */
williamr@2
   131
    virtual void FormatACLData(CHCIACLDataFrame& aFrame, THCIConnHandle aConnH,TUint8 aFlags,const TDesC8& aData)=0;
williamr@2
   132
    
williamr@2
   133
	/** Formats SCO Data.
williamr@2
   134
williamr@2
   135
	 @param aFrame Reference to CHCISCODataFrame which will be formatted with the data supplied in the other params
williamr@2
   136
	 @param aConnH Connection handle for this frame
williamr@2
   137
	 @param aData Data for this frame
williamr@2
   138
     @released
williamr@2
   139
     @publishedPartner
williamr@2
   140
     */
williamr@2
   141
    virtual void FormatSCOData(CHCISCODataFrame& aFrame, THCIConnHandle aConnH, const TDesC8& aData)=0;
williamr@2
   142
williamr@2
   143
    /** Writes ACL Data.
williamr@2
   144
williamr@2
   145
	This forwards a write from link layer to host controller.  The descriptor in the frame is owned by the link layer.
williamr@2
   146
williamr@2
   147
	 @param aFrame the formatted ACL payload from the linkmanager
williamr@2
   148
	 @return System wide error code
williamr@2
   149
     @released
williamr@2
   150
     @publishedPartner
williamr@2
   151
     */
williamr@2
   152
	virtual TInt WriteACLData(const CHCIACLDataFrame& aFrame)=0;
williamr@2
   153
williamr@2
   154
	/** Writes SCO Data.
williamr@2
   155
williamr@2
   156
	This forwards a write from link layer to host controller.  The descriptor in the frame is owned by the link layer.
williamr@2
   157
	 
williamr@2
   158
	 @param aFrame the formatted SCO payload from the linkmanager
williamr@2
   159
	 @return System wide error code
williamr@2
   160
	 @released
williamr@2
   161
	 @publishedPartner
williamr@2
   162
	 */
williamr@2
   163
    virtual TInt WriteSCOData(const CHCISCODataFrame& aFrame)=0;
williamr@2
   164
williamr@2
   165
	// HCI Frame information commands
williamr@2
   166
    /** Gets frame connection handle
williamr@2
   167
williamr@2
   168
	 @param aFrame the frame to return the connection handle of
williamr@2
   169
	 @return the connection handle from aFrame
williamr@2
   170
     @released
williamr@2
   171
     @publishedPartner
williamr@2
   172
     */
williamr@2
   173
	virtual THCIConnHandle FrameConnectionHandle(const CHCIACLDataFrame& aFrame) const =0;
williamr@2
   174
williamr@2
   175
	/** Gets frame opcode.
williamr@2
   176
williamr@2
   177
	 @param aFrame the frame to return the opcode of
williamr@2
   178
	 @return the opcode of aFrame
williamr@2
   179
	 @released
williamr@2
   180
	 @publishedPartner
williamr@2
   181
	 */
williamr@2
   182
	virtual THCIOpcode FrameOpcode(const CHCICommandFrame& aFrame) const =0;
williamr@2
   183
	
williamr@2
   184
	// HCI Commands
williamr@2
   185
	/**	Commands the host controller to start looking for remote devices within range.
williamr@2
   186
  
williamr@2
   187
	 The HCI client should not issue a second  Inquiry() before the first has 
williamr@2
   188
	 completed, because the HC cannot cope with this and will return a 
williamr@2
   189
	 COMMAND_DISALLOWED error
williamr@2
   190
williamr@2
   191
	 @param aFrame The HCI frame to format
williamr@2
   192
	 @param aCode InquiryAccessCode (3 bytes)
williamr@2
   193
	 @param aLength InquiryLength N where N * 1.28s is the no. of seconds for inquiry
williamr@2
   194
	 @param aNumResponses Number of responses from inquiry before it is halted - default 0 is unlimited number of responses.
williamr@2
   195
	 @released
williamr@2
   196
	 @publishedPartner
williamr@2
   197
	 */
williamr@2
   198
    virtual void Inquiry(CHCICommandFrame& aFrame, const TUint aCode=KGIAC, const TUint8 aLength=10, const TUint8 aNumResponses=0)=0;
williamr@2
   199
williamr@2
   200
    /** Cancels an ongoing inquiry.
williamr@2
   201
williamr@2
   202
	 @param aFrame frame to apply any necessary formatting to for inquiry cancel.
williamr@2
   203
     @released
williamr@2
   204
     @publishedPartner
williamr@2
   205
     */
williamr@2
   206
    virtual void InquiryCancel(CHCICommandFrame& aFrame)=0;
williamr@2
   207
williamr@2
   208
    /** Commands the host controller to enter periodic enquiry mode
williamr@2
   209
williamr@2
   210
	 @param aFrame The HCI frame to format
williamr@2
   211
	 @param aMax MaxPeriodLength. The HC chooses a value between aMax and aMin. 
williamr@2
   212
	 @param aMin MinPeriodLength 
williamr@2
   213
	 @param aCode InquiryAccessCode (3 bytes)
williamr@2
   214
	 @param aLength InquiryLength (default N=2)
williamr@2
   215
	 @param aNumResponses Number of Responses (default=0)
williamr@2
   216
     @released
williamr@2
   217
     @publishedPartner
williamr@2
   218
     */
williamr@2
   219
	virtual void PeriodicInquiryMode(CHCICommandFrame& aFrame, TUint16 aMax,TUint16 aMin, const TUint aCode=0,const TUint8 aLength=2,const TUint8 aNumResponses=0)=0;
williamr@2
   220
williamr@2
   221
	/** Exits the periodic inquiry.
williamr@2
   222
williamr@2
   223
	 @param aFrame The HCI frame to format
williamr@2
   224
	 @released
williamr@2
   225
	 @publishedPartner
williamr@2
   226
	 */
williamr@2
   227
    virtual void ExitPeriodicInquiryMode(CHCICommandFrame& aFrame)=0;
williamr@2
   228
williamr@2
   229
	/**	Initiates connection to remote device using the specified baseband packet type.
williamr@2
   230
williamr@2
   231
	 @param aFrame The HCI frame to format
williamr@2
   232
	 @param aBdaddr remove device address
williamr@2
   233
	 @param aPacketType Packet Type
williamr@2
   234
	 @param aPageScanRepetitionMode pages scan repetition mode
williamr@2
   235
	 @param aPageScanMode page scan mode
williamr@2
   236
	 @param aClockOffset Offset between local and remote clock
williamr@2
   237
	 @param aAllowRoleSwitch Whether the remote device is allowed to role switch the local device
williamr@2
   238
	 @released
williamr@2
   239
	 @publishedPartner
williamr@2
   240
	 */
williamr@2
   241
    virtual void CreateConnection(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,
williamr@2
   242
					TUint16 aPacketType=KDM1Packet, TUint8 aPageScanRepetitionMode=0,
williamr@2
   243
					TUint8 aPageScanMode=0, TUint16 aClockOffset=0, TUint8 aAllowRoleSwitch=1)=0;
williamr@2
   244
williamr@2
   245
    /**	Add an SCO connection between the Host Controller and the remote device.
williamr@2
   246
williamr@2
   247
	 @param aFrame The HCI frame to format
williamr@2
   248
	 @param aConnHandle Connection handle
williamr@2
   249
	 @param aPacketType Packet Type
williamr@2
   250
     @released
williamr@2
   251
     @publishedPartner
williamr@2
   252
     */
williamr@2
   253
    virtual void AddSCOConnection(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle,TUint16 aPacketType)=0;
williamr@2
   254
williamr@2
   255
williamr@2
   256
williamr@2
   257
williamr@2
   258
williamr@2
   259
williamr@2
   260
williamr@2
   261
	/**
williamr@2
   262
	Adds a new or modifies an existing synchronous logical transport (SCO or eSCO)
williamr@2
   263
	@param aFrame The HCI frame to format	
williamr@2
   264
	@param aConnHandle Connection handle (2 bytes)
williamr@2
   265
	@param aTransmitBandwidth (4 bytes)
williamr@2
   266
	@param aReceiveBandwidth  (4 bytes)
williamr@2
   267
	@param aMaxLatency        (2 bytes)
williamr@2
   268
	@param aVoiceSettings     (2 bytes)
williamr@2
   269
	@param aRetransmissionEffort (1 bytes)	
williamr@2
   270
	@param aPacketType 		     (2 bytes)	
williamr@2
   271
	*/
williamr@2
   272
	virtual void SetupSynchronousConnectionCommand(CHCICommandFrame& aFrame, TUint16 aConnHandle,
williamr@2
   273
						TUint aTransmitBandwidth,	TUint aReceiveBandwidth, TUint16 aMaxLatency,
williamr@2
   274
						TUint16 aVoiceSettings,	TUint8  aRetransmissionEffort,
williamr@2
   275
						TUint16 aPacketType)=0;
williamr@2
   276
williamr@2
   277
	/**
williamr@2
   278
	Accepts an incoming connection request for an synchronous connection.
williamr@2
   279
	@param aFrame The HCI frame to format	
williamr@2
   280
	@param aBdaddr BDADDR (6 bytes)
williamr@2
   281
	@param aTransmitBandwidth (4 bytes)
williamr@2
   282
	@param aReceiveBandwidth  (4 bytes)
williamr@2
   283
	@param aMaxLatency        (2 bytes)
williamr@2
   284
	@param aContentFormat        (2 bytes)
williamr@2
   285
	@param aRetransmissionEffort (1 bytes)	
williamr@2
   286
	@param aPacketType           (2 bytes)
williamr@2
   287
	*/					
williamr@2
   288
	virtual void AcceptSynchronousConnectionRequestCommand(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,
williamr@2
   289
						TUint aTransmitBandwidth,	TUint aReceiveBandwidth, TUint16 aMaxLatency,
williamr@2
   290
						TUint16 aContentFormat, TUint8  aRetransmissionEffort, TUint16 aPacketType)=0;
williamr@2
   291
	/**
williamr@2
   292
	Rejects the synchronous connction from thre remote device (aBdaddr).
williamr@2
   293
williamr@2
   294
	@param aFrame The HCI frame to format
williamr@2
   295
	@param aBdaddr BDADDR
williamr@2
   296
	@param THCIErrorCode Reject reason
williamr@2
   297
	*/					
williamr@2
   298
	virtual void RejectSynchronousConnectionRequestCommand(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,THCIErrorCode aReason)=0;
williamr@2
   299
																	
williamr@2
   300
williamr@2
   301
williamr@2
   302
williamr@2
   303
williamr@2
   304
williamr@2
   305
williamr@2
   306
    /**	Accepts an incoming connection request.
williamr@2
   307
williamr@2
   308
	 @param aFrame The HCI frame to format
williamr@2
   309
	 @param aBdaddr bluetooth address of remote device
williamr@2
   310
	 @param aRole Role - 0x00=Master, 0x01=Slave.
williamr@2
   311
     @released
williamr@2
   312
     @publishedPartner
williamr@2
   313
     */
williamr@2
   314
    virtual void AcceptConnectionRequest(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,TUint8 aRole)=0;
williamr@2
   315
williamr@2
   316
    /**	Rejects the connection from the remote device.
williamr@2
   317
williamr@2
   318
	 @param aFrame The HCI frame to format
williamr@2
   319
	 @param aBdaddr Bluetooth address of remote device
williamr@2
   320
	 @param THCIErrorCode Reject reason
williamr@2
   321
     @released
williamr@2
   322
     @publishedPartner
williamr@2
   323
     */
williamr@2
   324
    virtual void RejectConnectionRequest(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,THCIErrorCode aReason)=0;
williamr@2
   325
williamr@2
   326
    /**	Replies to the remote host with the supplied link key.
williamr@2
   327
williamr@2
   328
	 @param aFrame The HCI frame to format
williamr@2
   329
	 @param aBdaddr bluetooth address of remote device
williamr@2
   330
	 @param aLinkKey Link key (16 bytes)
williamr@2
   331
     @released
williamr@2
   332
     @publishedPartner
williamr@2
   333
     */
williamr@2
   334
    virtual void LinkKeyRequestReply(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,const TDesC8& aLinkKey)=0;
williamr@2
   335
williamr@2
   336
    /**	Notifies the remote host that the link key was not accepted.
williamr@2
   337
williamr@2
   338
	 @param aFrame The HCI frame to format
williamr@2
   339
	 @param aBdaddr Bluetooth address of remote device
williamr@2
   340
     @released
williamr@2
   341
     @publishedPartner
williamr@2
   342
     */
williamr@2
   343
    virtual void LinkKeyRequestNegativeReply(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr)=0;
williamr@2
   344
williamr@2
   345
    /**	Returns to the remote host the requested PIN.
williamr@2
   346
williamr@2
   347
	 @param aFrame The HCI frame to format
williamr@2
   348
	 @param aBdaddr Bluetooth address of remote device
williamr@2
   349
	 @param aPIN PIN Code (up to 16 bytes)
williamr@2
   350
     @released
williamr@2
   351
     @publishedPartner
williamr@2
   352
     */
williamr@2
   353
    virtual void PINCodeRequestReply(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,const TDesC8& aPIN)=0; 
williamr@2
   354
williamr@2
   355
    /**	Notifies the remote host that the PIN code was rejected.
williamr@2
   356
williamr@2
   357
	 @param aFrame The HCI frame to format
williamr@2
   358
	 @param aBdaddr Bluetooth address of remote device
williamr@2
   359
     @released
williamr@2
   360
     @publishedPartner
williamr@2
   361
     */
williamr@2
   362
    virtual void PINCodeRequestNegativeReply(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr)=0; 
williamr@2
   363
williamr@2
   364
    /**	Disconnect the ACL or SCO connection corresponding to the supplied handle.
williamr@2
   365
williamr@2
   366
	 @param aFrame The HCI frame to format
williamr@2
   367
	 @param aConnHandle Handle of connection to disconnect
williamr@2
   368
	 @param aReason Reason for disconnection
williamr@2
   369
     @released
williamr@2
   370
     @publishedPartner
williamr@2
   371
     */
williamr@2
   372
	virtual void Disconnect(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle,THCIErrorCode aReason)=0;
williamr@2
   373
williamr@2
   374
	/**	Changes baseband packet type (e.g DH1, DM3 etc.).
williamr@2
   375
williamr@2
   376
	 @param aFrame The HCI frame to format
williamr@2
   377
	 @param aConnHandle Connection Handle
williamr@2
   378
	 @param aType Packet Type.  This should be one of the consts defined in hcibase.h e.g. KDM1Packet.
williamr@2
   379
	 @released
williamr@2
   380
	 @publishedPartner
williamr@2
   381
	 */
williamr@2
   382
	virtual void ChangeConnectionPacketType(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle,TUint16 aType)=0;
williamr@2
   383
williamr@2
   384
	/** Perform authenticaction request.	
williamr@2
   385
williamr@2
   386
	 @param aFrame The HCI frame to format
williamr@2
   387
	 @param aConnHandle Connection Handle
williamr@2
   388
	 @released
williamr@2
   389
	 @publishedPartner
williamr@2
   390
	 */
williamr@2
   391
    virtual void AuthenticationRequest(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
williamr@2
   392
williamr@2
   393
    /** Sets connection encryption
williamr@2
   394
williamr@2
   395
	 @param aFrame The HCI frame to format
williamr@2
   396
	 @param aConnHandle Connection Handle
williamr@2
   397
	 @param aEnable Enable flag ETrue=Enable link encryption, EFalse=Disable link encryption
williamr@2
   398
     @released
williamr@2
   399
     @publishedPartner
williamr@2
   400
     */
williamr@2
   401
    virtual void SetEncryptionEnable(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle,TBool aEnable)=0;
williamr@2
   402
williamr@2
   403
    /**	Notifies host of need to change connection key for the supplied connection handle.
williamr@2
   404
williamr@2
   405
	 @param aFrame The HCI frame to format
williamr@2
   406
	 @param aConnHandle Connection Handle
williamr@2
   407
     @released
williamr@2
   408
     @publishedPartner
williamr@2
   409
     */
williamr@2
   410
    virtual void ChangeConnectionLinkKey(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
williamr@2
   411
williamr@2
   412
    /**	Not used.
williamr@2
   413
williamr@2
   414
	 @param aFrame The HCI frame to format
williamr@2
   415
	 @param aKeyFlag Link Key Flag. Possible values are ETrue to use temporary link key or EFalse to  use regular link key
williamr@2
   416
     @released
williamr@2
   417
     @publishedPartner
williamr@2
   418
     */
williamr@2
   419
    virtual void MasterLinkKey(CHCICommandFrame& aFrame, TBool aKeyFlag)=0;
williamr@2
   420
williamr@2
   421
    /**	Retrieves the remote hosts advertised hardware/firmware features.
williamr@2
   422
williamr@2
   423
	 @param aFrame The HCI frame to format
williamr@2
   424
	 @param aConnHandle Connection Handle
williamr@2
   425
     @released
williamr@2
   426
     @publishedPartner
williamr@2
   427
     */
williamr@2
   428
    virtual void ReadRemoteSupportedFeatures(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
williamr@2
   429
williamr@2
   430
    /**	Retrieve remote hosts HW/Firmware revision information.
williamr@2
   431
williamr@2
   432
	 @param aFrame The HCI frame to format
williamr@2
   433
	 @param aConnHandle Connection Handle
williamr@2
   434
     @released
williamr@2
   435
     @publishedPartner
williamr@2
   436
     */
williamr@2
   437
    virtual void ReadRemoteVersionInfo(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
williamr@2
   438
williamr@2
   439
	/** Request on human redable name of remote host.
williamr@2
   440
williamr@2
   441
	 @param aFrame The HCI frame to format
williamr@2
   442
	 @param aBdaddr The bluetooth address of device on which we seek to find a name
williamr@2
   443
	 @param aPageScanRepetitionMode Page scan repetition mode
williamr@2
   444
	 @param aPageScanMode Page scan mode
williamr@2
   445
	 @param aClockOffset Offset of remote device clock from local device clock
williamr@2
   446
	 @released
williamr@2
   447
	 @publishedPartner
williamr@2
   448
	 */
williamr@2
   449
    virtual void RemoteNameRequest(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr, TUint8 aPageScanRepetitionMode=0,
williamr@2
   450
					TUint8 aPageScanMode=0, TBasebandTime aClockOffset=0)=0;
williamr@2
   451
williamr@2
   452
    /**	Retrieve offset of remote clock from local clock.
williamr@2
   453
williamr@2
   454
	 @param aFrame The HCI frame to format
williamr@2
   455
	 @param aConnHandle Connection Handle
williamr@2
   456
     @released
williamr@2
   457
     @publishedPartner
williamr@2
   458
     */
williamr@2
   459
    virtual void ReadClockOffset(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
williamr@2
   460
williamr@2
   461
	// HCI Link Policy Commands 
williamr@2
   462
    /**	Write local link policy settings
williamr@2
   463
williamr@2
   464
	 @param aFrame The HCI frame to format
williamr@2
   465
	 @param aConnHandle Connection Handle
williamr@2
   466
	 @param aSettings @see Bluetooth HCI specification
williamr@2
   467
     @released
williamr@2
   468
     @publishedPartner
williamr@2
   469
     */
williamr@2
   470
	virtual void WriteLinkPolicySettings(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle, TUint16 aSettings)=0;
williamr@2
   471
williamr@2
   472
	/**	Switch radio and host controller to Hold mode.
williamr@2
   473
williamr@2
   474
	 @param aFrame The HCI frame to format
williamr@2
   475
	 @param aConnHandle Connection Handle 
williamr@2
   476
	 @param aHoldMaxInterval Max Hold Interval N, where Time of Hold=N*0.625ms (1 baseband slot)
williamr@2
   477
	 @param aHoldMinInterval Min Hold interval N, as above (both up to 40.9 sec)
williamr@2
   478
	 @released
williamr@2
   479
	 @publishedPartner
williamr@2
   480
	 */
williamr@2
   481
    virtual void HoldMode(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle, TBasebandTime aHoldMaxInterval, 
williamr@2
   482
		TBasebandTime aHoldMinInterval)=0;
williamr@2
   483
williamr@2
   484
	/**	Switch radio and host controller to Sniff mode.
williamr@2
   485
williamr@2
   486
	 @param aFrame The HCI frame to format
williamr@2
   487
	 @param aConnHandle Connection Handle
williamr@2
   488
	 @param aSniffMaxInterval Max Sniff length (Max number of acceptable slots in a sniff period) N, where the interval (time between sniffs)=N*0.625ms (1 baseband slot)
williamr@2
   489
	 @param aSniffMinInterval Min Sniff interval , as above
williamr@2
   490
	 @param aAttemptSlots Sniff Attempt - the period the slave will listen after each sniff interval
williamr@2
   491
	 @param aTimeOutSlots Sniff Timeout - time listening for packets as long as some arrive
williamr@2
   492
	 @released
williamr@2
   493
	 @publishedPartner
williamr@2
   494
	 */
williamr@2
   495
    virtual void SniffMode(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle,TBasebandTime aSniffMaxInterval,TBasebandTime
williamr@2
   496
		aSniffMinInterval, TBasebandTime aAttempSlots, TBasebandTime aTimeOutSlots)=0;
williamr@2
   497
williamr@2
   498
	/**	Switch radio and host out of the Sniff mode.
williamr@2
   499
williamr@2
   500
	 @param aFrame The HCI frame to format
williamr@2
   501
	 @param aConnHandle Connection Handle
williamr@2
   502
	 @released
williamr@2
   503
	 @publishedPartner
williamr@2
   504
	 */
williamr@2
   505
    virtual void ExitSniffMode(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
williamr@2
   506
williamr@2
   507
	/**	Switch radio and host controller to the Park mode.
williamr@2
   508
williamr@2
   509
	 @param aFrame The HCI frame to format
williamr@2
   510
	 @param aConnHandle Connection Handle
williamr@2
   511
	 @param aBeaconMax Beacon Max Interval Length N where interval between beacons=N*0.625ms
williamr@2
   512
	 @param aBeaconMin Beacon Min Interval Length N where interval between beacons=N*0.625ms
williamr@2
   513
	 @released
williamr@2
   514
	 @publishedPartner
williamr@2
   515
	 */
williamr@2
   516
    virtual void ParkMode(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle, TBasebandTime aBeaconMaxInterval, 
williamr@2
   517
		TBasebandTime aBeaconMinInterval)=0;
williamr@2
   518
williamr@2
   519
    /**	Switch radio and host controller off the Park mode.
williamr@2
   520
williamr@2
   521
	 @param aFrame The HCI frame to format
williamr@2
   522
 	 @param aConnHandle Connection Handle
williamr@2
   523
     @released
williamr@2
   524
     @publishedPartner
williamr@2
   525
     */
williamr@2
   526
    virtual void ExitParkMode(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
williamr@2
   527
williamr@2
   528
	/**	Initiate role discovery for the supplied connection handle.
williamr@2
   529
williamr@2
   530
	 @param aFrame The HCI frame to format
williamr@2
   531
	 @param aConnHandle Connection Handle
williamr@2
   532
	 @released
williamr@2
   533
	 @publishedPartner
williamr@2
   534
	 */
williamr@2
   535
    virtual void RoleDiscovery(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
williamr@2
   536
williamr@2
   537
	/**	Switch current role (master / slave) for the physical link associated with the bluetooth device address provided.
williamr@2
   538
	
williamr@2
   539
	 @param aFrame The HCI frame to format
williamr@2
   540
	 @param aRole New role 
williamr@2
   541
	 @param aAddr Bluetooth device address of remote device 
williamr@2
   542
	 @released
williamr@2
   543
	 @publishedPartner
williamr@2
   544
	 */
williamr@2
   545
	virtual void SwitchRole(CHCICommandFrame& aFrame, TBTBasebandRole aRole, const TBTDevAddr& aAddr)=0;
williamr@2
   546
williamr@2
   547
williamr@2
   548
	// HCI Host Controller and Baseband Commands 
williamr@2
   549
	/**	Sets the mask for the reception or the filtering-out of HCI events from the host controller.
williamr@2
   550
williamr@2
   551
 	 @param aFrame The HCI frame to format
williamr@2
   552
	 @param aMask Event Mask
williamr@2
   553
	 @released
williamr@2
   554
	 @publishedPartner
williamr@2
   555
	 */
williamr@2
   556
    virtual void SetEventMask(CHCICommandFrame& aFrame, const THCIEventMask& aMask)=0;
williamr@2
   557
williamr@2
   558
    /**	Resets the Host Controller hardware state. 
williamr@2
   559
williamr@2
   560
	 @param aFrame The HCI frame to format
williamr@2
   561
     @released
williamr@2
   562
     @publishedPartner
williamr@2
   563
     */
williamr@2
   564
    virtual void Reset(CHCICommandFrame& aFrame)=0;
williamr@2
   565
williamr@2
   566
    /**	Set the filter mask for remotely initiated  events.
williamr@2
   567
williamr@2
   568
	 @param aFrame The HCI frame to format
williamr@2
   569
	 @param aData Denotes the filter 'category' and its particular properties as such its 'category'/type may be EClearAllFilters, EInquiryResultFilter or EConnectionSetupFilter. Then its condition type (aData.iConditionType) can be as defined in the spec
williamr@2
   570
     @released
williamr@2
   571
     @publishedPartner
williamr@2
   572
     */
williamr@2
   573
    virtual void SetEventFilter(CHCICommandFrame& aFrame, const THCIEventCondition& aData)=0;
williamr@2
   574
williamr@2
   575
    /**	Flush buffers corresponding to the supplied connection handle.
williamr@2
   576
williamr@2
   577
	 @param aFrame The HCI frame to format
williamr@2
   578
	 @param aConnHandle Connection Handle
williamr@2
   579
     @released
williamr@2
   580
     @publishedPartner
williamr@2
   581
     */
williamr@2
   582
    virtual void Flush(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
williamr@2
   583
williamr@2
   584
    /**	Creates a new unit key in the host controller.
williamr@2
   585
williamr@2
   586
	 @param aFrame The HCI frame to format
williamr@2
   587
     @released
williamr@2
   588
     @publishedPartner
williamr@2
   589
     */
williamr@2
   590
    virtual void CreateNewUnitKey(CHCICommandFrame& aFrame)=0;
williamr@2
   591
williamr@2
   592
    /**	Reads out from the host controller the stored link key for given device address
williamr@2
   593
williamr@2
   594
	 @param aFrame The HCI frame to format
williamr@2
   595
	 @param aBdaddr Bluetooth device address to read the link key for.
williamr@2
   596
	 @param aFlag Read all keys flag
williamr@2
   597
     @released
williamr@2
   598
     @publishedPartner
williamr@2
   599
     */
williamr@2
   600
    virtual void ReadStoredLinkKey(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,THCIReadAllKeysFlag aFlag)=0;
williamr@2
   601
williamr@2
   602
	/**	Writes a Link Key to the Host Controllers volatile storage memory.  You can write as many keys as you want to storage - this function just does one at a time.
williamr@2
   603
	
williamr@2
   604
	 @param aFrame The HCI frame to format
williamr@2
   605
	 @param aNumOfKeysToWrite Number of keys to write to storage
williamr@2
   606
	 @param aBdaddr Bluetooth device address for the associated link key
williamr@2
   607
	 @param aLinkKey The Link Key
williamr@2
   608
	 @released
williamr@2
   609
	 @publishedPartner
williamr@2
   610
	 */
williamr@2
   611
    virtual void WriteStoredLinkKey(CHCICommandFrame& aFrame, /*TUint8 aNumOfKeysToWrite,*/
williamr@2
   612
		const TBTDevAddr& aBdaddr,const TDesC8& aLinkKey)=0;
williamr@2
   613
williamr@2
   614
    /**	Delete the link key stored in the host controller's volatile storage.
williamr@2
   615
williamr@2
   616
	 @param aFrame The HCI frame to format
williamr@2
   617
	 @param aBdaddr Bluetooth device address associated with the link key to delete.
williamr@2
   618
	 @param aFlag Delete options flag
williamr@2
   619
     @released
williamr@2
   620
     @publishedPartner
williamr@2
   621
     */
williamr@2
   622
    virtual void DeleteStoredLinkKey(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,THCIDeleteAllKeysFlag aFlag)=0;
williamr@2
   623
williamr@2
   624
    /**	Sets the local Bluetooth device name.
williamr@2
   625
williamr@2
   626
	 @param aFrame The HCI frame to format
williamr@2
   627
	 @param aName Local device name (max 248 characters as defined in bluetooth specification).
williamr@2
   628
     @released
williamr@2
   629
     @publishedPartner
williamr@2
   630
     */
williamr@2
   631
    virtual void ChangeLocalName(CHCICommandFrame& aFrame, const TDesC8& aName)=0;
williamr@2
   632
williamr@2
   633
    /**	Reads out the stored local Bluetooth device name.
williamr@2
   634
	
williamr@2
   635
	 @param aFrame The HCI frame to format
williamr@2
   636
     @released
williamr@2
   637
     @publishedPartner
williamr@2
   638
     */
williamr@2
   639
	virtual void ReadLocalName(CHCICommandFrame& aFrame)=0;
williamr@2
   640
williamr@2
   641
	/**	Reads out of the Bluetooth device the connection accept timeout, for incoming connections.
williamr@2
   642
williamr@2
   643
	 @param aFrame The HCI frame to format
williamr@2
   644
	 @released
williamr@2
   645
	 @publishedPartner
williamr@2
   646
	 */
williamr@2
   647
    virtual void ReadConnectionAcceptTimeout(CHCICommandFrame& aFrame)=0;
williamr@2
   648
williamr@2
   649
    /**	Sets the connection accept timeout in the host controller.
williamr@2
   650
williamr@2
   651
	 @param aFrame The HCI frame to format
williamr@2
   652
	 @param aTimeout The connection timeout
williamr@2
   653
     @released
williamr@2
   654
     @publishedPartner
williamr@2
   655
     */
williamr@2
   656
    virtual void WriteConnectionAcceptTimeout(CHCICommandFrame& aFrame, TBasebandTime aTimeout)=0;
williamr@2
   657
    
williamr@2
   658
    /**	Commands the Bluetooth hardware to respond with its Page Timeout.
williamr@2
   659
	
williamr@2
   660
	 @param aFrame The HCI frame to format
williamr@2
   661
     @released
williamr@2
   662
     @publishedPartner
williamr@2
   663
     */
williamr@2
   664
	virtual void ReadPageTimeout(CHCICommandFrame& aFrame)=0;
williamr@2
   665
williamr@2
   666
	/**	Sets the page timeout in the host controller.
williamr@2
   667
williamr@2
   668
	 @param aFrame The HCI frame to format
williamr@2
   669
	 @param aTimeout Page Timeout.  This must be between KMaxPageTimeout and KMinPageTimeout.
williamr@2
   670
	 @released
williamr@2
   671
	 @publishedPartner
williamr@2
   672
	 */
williamr@2
   673
    virtual void WritePageTimeout(CHCICommandFrame& aFrame, TBasebandTime aTimeout)=0;
williamr@2
   674
williamr@2
   675
    /**	Read out of the host controller the scan options.
williamr@2
   676
	
williamr@2
   677
	 @param aFrame The HCI frame to format
williamr@2
   678
     @released
williamr@2
   679
     @publishedPartner
williamr@2
   680
     */
williamr@2
   681
    virtual void ReadScanEnable(CHCICommandFrame& aFrame)=0;
williamr@2
   682
williamr@2
   683
    /**	Sets the scan options on the host controller.
williamr@2
   684
williamr@2
   685
	 @param aFrame The HCI frame to format
williamr@2
   686
	 @param  aScanEnable Scan enable options
williamr@2
   687
     @released
williamr@2
   688
     @publishedPartner
williamr@2
   689
     */
williamr@2
   690
    virtual void WriteScanEnable(CHCICommandFrame& aFrame, THCIScanEnable aEnable=EInquiryAndPageScan)=0;
williamr@2
   691
	
williamr@2
   692
    /**	Read out of the host controller the number of supported inquiry access codes.
williamr@2
   693
williamr@2
   694
	 @param aFrame The HCI frame to format
williamr@2
   695
     @released
williamr@2
   696
     @publishedPartner
williamr@2
   697
     */
williamr@2
   698
	virtual void ReadNumberOfSupportedIAC(CHCICommandFrame& aFrame)=0;
williamr@2
   699
williamr@2
   700
	/**	Write to the host controller the lower address parts supplied.
williamr@2
   701
williamr@2
   702
	 @param aFrame The HCI frame to format
williamr@2
   703
	 @param aNumCurrentIAC The number of inquiry access code lower address parts being sent to the hardware
williamr@2
   704
	 @param aIAC_LAP The inquiry access code lower address parts - 3 bytes each: e.g: GIACLAP=0x9e8b33, LIACLAP=0x9e8b00
williamr@2
   705
	 @released
williamr@2
   706
	 @publishedPartner
williamr@2
   707
	 */
williamr@2
   708
    virtual void WriteCurrentIACLAP(CHCICommandFrame& aFrame, TUint8 aNumCurrentIAC, TUint aIAC_LAP[])=0;
williamr@2
   709
williamr@2
   710
    /**	Read out the inquiry access code lower address parts.
williamr@2
   711
	
williamr@2
   712
	 @param aFrame The HCI frame to format
williamr@2
   713
     @released
williamr@2
   714
     @publishedPartner
williamr@2
   715
     */
williamr@2
   716
	virtual void ReadCurrentIACLAP(CHCICommandFrame& aFrame)=0;
williamr@2
   717
williamr@2
   718
	/**	Read out from the host controller whether authentication is enabled.
williamr@2
   719
williamr@2
   720
	 @param aFrame The HCI frame to format
williamr@2
   721
	 @released
williamr@2
   722
	 @publishedPartner
williamr@2
   723
	 */
williamr@2
   724
    virtual void ReadAuthenticationEnable(CHCICommandFrame& aFrame)=0;
williamr@2
   725
williamr@2
   726
    /**	Set/Unset authentication.
williamr@2
   727
williamr@2
   728
	 @param aFrame The HCI frame to format
williamr@2
   729
	 @param aAuthEnable	Authentication Enable.  Possible values are EFalse for authentication disabled or ETrue for authentication enabled
williamr@2
   730
     @released
williamr@2
   731
     @publishedPartner
williamr@2
   732
     */
williamr@2
   733
    virtual void WriteAuthenticationEnable(CHCICommandFrame& aFrame, TBool aAuthEnable)=0;
williamr@2
   734
williamr@2
   735
    /**	Read out the encryption mode.
williamr@2
   736
williamr@2
   737
	 @param aFrame The HCI frame to format
williamr@2
   738
     @released
williamr@2
   739
     @publishedPartner
williamr@2
   740
     */
williamr@2
   741
    virtual void ReadEncryptionMode(CHCICommandFrame& aFrame)=0;
williamr@2
   742
williamr@2
   743
    /**	Set/unset the encryption.
williamr@2
   744
williamr@2
   745
	 @param aFrame The HCI frame to format
williamr@2
   746
	 @param aFlag Whether to enable encryption.	 Possible values are EFalse to disable encryption or ETrue to enable encryption.
williamr@2
   747
     @released
williamr@2
   748
     @publishedPartner
williamr@2
   749
     */
williamr@2
   750
    virtual void WriteEncryptionMode(CHCICommandFrame& aFrame, THCIEncryptModeFlag aFlag)=0;
williamr@2
   751
williamr@2
   752
    /**	Reads out the class of device of the local Bluetooth device.
williamr@2
   753
williamr@2
   754
	 @param aFrame The HCI frame to format
williamr@2
   755
     @released
williamr@2
   756
     @publishedPartner
williamr@2
   757
     */
williamr@2
   758
    virtual void ReadClassOfDevice(CHCICommandFrame& aFrame)=0;
williamr@2
   759
williamr@2
   760
    /**	Sets the local Bluetooth class of device.
williamr@2
   761
williamr@2
   762
	 @param aFrame The HCI frame to format
williamr@2
   763
	 @param aCoD Class Of Device
williamr@2
   764
     @released
williamr@2
   765
     @publishedPartner
williamr@2
   766
     */
williamr@2
   767
    virtual void WriteClassOfDevice(CHCICommandFrame& aFrame, TUint aCoD)=0;
williamr@2
   768
williamr@2
   769
    /**	Read the Bluetooth hardware voice settings.
williamr@2
   770
williamr@2
   771
	 @param aFrame The HCI frame to format
williamr@2
   772
     @released
williamr@2
   773
     @publishedPartner
williamr@2
   774
     */
williamr@2
   775
	virtual void ReadVoiceSetting(CHCICommandFrame& aFrame)=0;
williamr@2
   776
williamr@2
   777
	/**	Set the local Bluetooth device voice settings. 
williamr@2
   778
williamr@2
   779
	 @param aFrame The HCI frame to format
williamr@2
   780
	 @param aVoiceChannelSetting	Voice channel settings as defined by the HCI specification.
williamr@2
   781
	 @released
williamr@2
   782
	 @publishedPartner
williamr@2
   783
	 */
williamr@2
   784
	virtual void WriteVoiceSetting(CHCICommandFrame& aFrame, TInt16 aVoiceChannelSetting)=0;
williamr@2
   785
    
williamr@2
   786
	// HCI Informational Parameters Commands
williamr@2
   787
	/**	Retrieve local hardware/firmware revision info.
williamr@2
   788
williamr@2
   789
	 @param aFrame The HCI frame to format
williamr@2
   790
	 @released
williamr@2
   791
	 @publishedPartner
williamr@2
   792
	 */
williamr@2
   793
	virtual void ReadLocalVersionInformation(CHCICommandFrame& aFrame)=0;
williamr@2
   794
williamr@2
   795
	/**	Retrieve local hardware/firmware capabilities.
williamr@2
   796
williamr@2
   797
	 @param aFrame The HCI frame to format
williamr@2
   798
	 @released
williamr@2
   799
	 @publishedPartner
williamr@2
   800
	 */
williamr@2
   801
	virtual void ReadLocalSupportedFeatures(CHCICommandFrame& aFrame)=0;
williamr@2
   802
williamr@2
   803
	/**	Retrieve from the host controller its buffering capabilities.
williamr@2
   804
williamr@2
   805
	 @param aFrame The HCI frame to format
williamr@2
   806
	 @released
williamr@2
   807
	 @publishedPartner
williamr@2
   808
	 */
williamr@2
   809
    virtual void ReadBufferSize(CHCICommandFrame& aFrame)=0;  
williamr@2
   810
  
williamr@2
   811
    /**	Retrieve the hardware's intended country code (for security/encryption issues). 
williamr@2
   812
williamr@2
   813
	 @param aFrame The HCI frame to format
williamr@2
   814
     @released
williamr@2
   815
     @publishedPartner
williamr@2
   816
     */
williamr@2
   817
	virtual void ReadCountryCode(CHCICommandFrame& aFrame)=0;
williamr@2
   818
williamr@2
   819
	/**	Retrieve local Bluetooth device address.
williamr@2
   820
williamr@2
   821
	 @param aFrame The HCI frame to format
williamr@2
   822
	 @released
williamr@2
   823
	 @publishedPartner
williamr@2
   824
	 */
williamr@2
   825
    virtual void ReadBDADDR(CHCICommandFrame& aFrame)=0;
williamr@2
   826
	
williamr@2
   827
	// Host Controller to Host Data Flow Control
williamr@2
   828
    /**	Set/unset notification of delivery of packets, from the host controller to the host.
williamr@2
   829
williamr@2
   830
	 @param aFrame The HCI frame to format
williamr@2
   831
	 @param aFlowFlag Flow Control Enable flag
williamr@2
   832
     @released
williamr@2
   833
     @publishedPartner
williamr@2
   834
     */
williamr@2
   835
    virtual void SetHostControllerToHostFlowControl(CHCICommandFrame& aFrame, TBool aHC2HFlowFlag)=0;// may return KErrNoMemory
williamr@2
   836
williamr@2
   837
    /** Notification to host controller of the number of packets that the above 
williamr@2
   838
	 layers (L2CAP) have consumed.  HostNumberOfCompletedPackets command to be 
williamr@2
   839
	 issued by L2CAP.
williamr@2
   840
williamr@2
   841
	 @param aFrame The HCI frame to format
williamr@2
   842
	 @param aNumHandles	Number of connectionhandles
williamr@2
   843
	 @param aConnH Connection handle 
williamr@2
   844
	 @param aCompletedPacketsNo	Host num of completed packets
williamr@2
   845
     @released
williamr@2
   846
     @publishedPartner
williamr@2
   847
     */
williamr@2
   848
	virtual void HostNumberOfCompletedPackets(CHCICommandFrame& aFrame, TUint8 aNumHandles, THCIConnHandle aConnH[], TUint16 aCompletedPacketsNo[])=0;
williamr@2
   849
williamr@2
   850
	/**	Notifies the host controller of the hosts buffering capabilities.
williamr@2
   851
williamr@2
   852
	 @param aFrame The HCI frame to format
williamr@2
   853
	 @param aACLDataLength	Host's ACL Data Packet Length
williamr@2
   854
	 @param aSCODataLength	Host's SCO Data Packet Length   
williamr@2
   855
	 @param aTotalACLPackets Total Number of ACL Data Packets that the Host can handle
williamr@2
   856
	 @param aTotalSCOPackets Total Number of SCO Data Packets that the Host can handle
williamr@2
   857
	 @released
williamr@2
   858
	 @publishedPartner
williamr@2
   859
	 */
williamr@2
   860
	virtual void HostBufferSize(CHCICommandFrame& aFrame, TUint16 aACLDataLength,TUint8 aSCODataLength,
williamr@2
   861
        TUint16 aTotalACLPackets, TUint16 aTotalSCOPackets)=0;
williamr@2
   862
williamr@2
   863
	/** Writes link supervision timeout.
williamr@2
   864
williamr@2
   865
	 @param aFrame The HCI frame to format
williamr@2
   866
	 @param aConnH Connection handle
williamr@2
   867
	 @param aTimeout Timeout to write
williamr@2
   868
	 @released
williamr@2
   869
	 @publishedPartner
williamr@2
   870
	 */
williamr@2
   871
	virtual void WriteLinkSupervisionTimeout(CHCICommandFrame& aFrame, THCIConnHandle aConnH, TBasebandTime aTimeout)=0;
williamr@2
   872
williamr@2
   873
	/** This call allows for a raw HCI command frame to be written to the HC.
williamr@2
   874
williamr@2
   875
    This is intended for vendor specific commands for which the opcode 
williamr@2
   876
	field will be known to the HCI.
williamr@2
   877
williamr@2
   878
    These raw frames should be constructed by calling the HCI factory
williamr@2
   879
    function with the opcode constructed of the vendor debug opcode group field
williamr@2
   880
	and the particular OCF required.  This function should then be called with the
williamr@2
   881
    appropriately formatted parameters which shall be placed into the frame's
williamr@2
   882
    payload.  It should be noted that the client need NOT to be concerned
williamr@2
   883
    with the HCTL framing at all.
williamr@2
   884
williamr@2
   885
    The HCI will only then copy this frame to the host controller after putting 
williamr@2
   886
	it in an HCTL frame.
williamr@2
   887
williamr@2
   888
    Note that the client is responsible for policing the size of the descriptor
williamr@2
   889
    passed to this function.  The length should be: 0 <= n <= KHCIMaxCommandLength
williamr@2
   890
williamr@2
   891
     @param aFrame The HCI frame to format
williamr@2
   892
     @param aData The frame parameters   
williamr@2
   893
	 @released
williamr@2
   894
	 @publishedPartner
williamr@2
   895
	 */
williamr@2
   896
	virtual void WriteVendorRawFrameCommand(CHCICommandFrame& aFrame, const TDesC8& aData)=0;
williamr@2
   897
williamr@2
   898
williamr@2
   899
	// HCI Status Parameters Commands
williamr@2
   900
	// not here yet
williamr@2
   901
	
williamr@2
   902
	// HCI Testing Commands
williamr@2
   903
	// not here yet 
williamr@2
   904
	/** Used for testing.
williamr@2
   905
williamr@2
   906
	 @released
williamr@2
   907
	 @internalComponent
williamr@2
   908
	 */
williamr@2
   909
	virtual TAny *LogIndex() const=0;
williamr@2
   910
williamr@2
   911
	// methods to allow stack to query HCI about its features
williamr@2
   912
	/** Reads ACL reporting interval.
williamr@2
   913
williamr@2
   914
	 @return the ACL reporting interval.
williamr@2
   915
	 @released
williamr@2
   916
	 @publishedPartner
williamr@2
   917
	 */
williamr@2
   918
	virtual TUint16 ReadACLReportingInterval() = 0; // Some hardware only reports on the nth ACL data packet being sent
williamr@2
   919
	                                                // this is an opportunity for the HCI to supply a minimum value of n
williamr@2
   920
													// to the Link Manager
williamr@2
   921
williamr@2
   922
	/** Reads size of HCI framing overhead per frame.
williamr@2
   923
williamr@2
   924
	 @return size of HCI framing overhead per frame.
williamr@2
   925
	 @released
williamr@2
   926
	 @publishedPartner
williamr@2
   927
	 */
williamr@2
   928
	virtual TUint16 ReadACLFramingOverhead() = 0; // Size of HCI framing overhead per frame
williamr@2
   929
williamr@2
   930
	// Adaptive Frequency Hopping (AFH)
williamr@2
   931
	
williamr@2
   932
	/**	Notifies the host controller of channels that are known by the host to be bad or to be about to be bad.
williamr@2
   933
	
williamr@2
   934
	 This allows those channels to be avoided if Adaptive Frequency Hopping is active on a connection.
williamr@2
   935
	 
williamr@2
   936
	 @param aFrame The HCI frame to format
williamr@2
   937
	 @param aChannelClassification Bitwise representation of the bad channels
williamr@2
   938
	 @released
williamr@2
   939
	 @publishedPartner
williamr@2
   940
	 */
williamr@2
   941
    virtual void SetAFHHostChannelClassification(CHCICommandFrame& aFrame, const TDesC8& aChannelClassification)=0;
williamr@2
   942
williamr@2
   943
	/**	Retrieves the AFH channel map being used on the specified connection.
williamr@2
   944
	
williamr@2
   945
	 If we are master this will be the local AFH channel map. If we are slave it 
williamr@2
   946
	 will be the remote master's AFH channel map.
williamr@2
   947
	 
williamr@2
   948
	 @param aFrame The HCI frame to format
williamr@2
   949
	 @param aConnH Connection handle 
williamr@2
   950
	 @released
williamr@2
   951
	 @publishedPartner
williamr@2
   952
	*/
williamr@2
   953
	virtual void ReadAFHChannelMap(CHCICommandFrame& aFrame, THCIConnHandle aConnH)=0;
williamr@2
   954
williamr@2
   955
 	/**	Notifies the host controller whether or not it is required to keep checking for busy channels..
williamr@2
   956
	
williamr@2
   957
	 @param aFrame The HCI frame to format
williamr@2
   958
	 @param aEnable Check for busy channels if ETrue, otherwise don't
williamr@2
   959
	 @released
williamr@2
   960
	 @publishedPartner
williamr@2
   961
	 */
williamr@2
   962
    virtual void WriteAFHChannelAssessmentMode(CHCICommandFrame& aFrame, TBool aEnable)=0;
williamr@2
   963
williamr@2
   964
 	/**	Asks the host controller whether or not it is checking for busy channels..
williamr@2
   965
	
williamr@2
   966
	 @param aFrame The HCI frame to format
williamr@2
   967
	 @released
williamr@2
   968
	 @publishedPartner
williamr@2
   969
	 */
williamr@2
   970
    virtual void ReadAFHChannelAssessmentMode(CHCICommandFrame& aFrame)=0;
williamr@2
   971
williamr@2
   972
    /** HCI level Ioctl
williamr@2
   973
williamr@2
   974
	 @param aLevel			The Ioctl level
williamr@2
   975
	 @param aName			The Ioctl function number
williamr@2
   976
	 @param aOption			Data associated with this Ioctl
williamr@2
   977
	 @param aStackSAP		A pointer to the SAP, used to track Ioctls
williamr@2
   978
     @released
williamr@2
   979
     @publishedPartner
williamr@2
   980
     */
williamr@2
   981
	virtual void Ioctl(TUint aLevel,TUint aName, TDes8* aOption, TAny* aStackSAP) = 0;
williamr@2
   982
williamr@2
   983
    /** Cancel HCI level Ioctl
williamr@2
   984
williamr@2
   985
	 @param aLevel			The Ioctl level
williamr@2
   986
	 @param aName			The Ioctl function number
williamr@2
   987
	 @param aStackSAP		A pointer to the SAP, used to track Ioctls
williamr@2
   988
     @released
williamr@2
   989
     @publishedPartner
williamr@2
   990
     */
williamr@2
   991
	virtual void CancelIoctl(TUint aLevel,TUint aName, TAny* aStackSAP) = 0;
williamr@2
   992
	};
williamr@2
   993
williamr@2
   994
enum THCIErrorCode;
williamr@2
   995
williamr@2
   996
williamr@2
   997
williamr@2
   998
/** Event handler mixin that must be implemented by the client of HCI.
williamr@2
   999
williamr@2
  1000
A class that implements this interface must be passed into the
williamr@2
  1001
CHCIBase derived class on construction, and will be used by the HCI
williamr@2
  1002
class to notify the client of events received over the HCI interface.
williamr@2
  1003
williamr@2
  1004
@released
williamr@2
  1005
@publishedPartner
williamr@2
  1006
*/
williamr@2
  1007
class MHCIEventObserver
williamr@2
  1008
    {   
williamr@2
  1009
public:
williamr@2
  1010
	// Interfaces to allow HCI to notify LL
williamr@2
  1011
	/** This provides command credits.
williamr@2
  1012
williamr@2
  1013
	 @param aCredits Provided command credits.
williamr@2
  1014
	 @released
williamr@2
  1015
	 @publishedPartner
williamr@2
  1016
	 */
williamr@2
  1017
	virtual void SetCommandCredits(TUint16 aCredits)=0;
williamr@2
  1018
williamr@2
  1019
	/** Informs of the ACL MTU for this host.
williamr@2
  1020
williamr@2
  1021
	 @param aMTU Maximum size of ACL packet the host can send.
williamr@2
  1022
	 @released
williamr@2
  1023
	 @publishedPartner
williamr@2
  1024
	 */
williamr@2
  1025
	virtual void HCIMaximumACLPacketSize(TUint16 aMTU)=0;
williamr@2
  1026
williamr@2
  1027
	/** Called when transport channels have become free.
williamr@2
  1028
williamr@2
  1029
	 @param aChannel Channel that is free.
williamr@2
  1030
	 @released
williamr@2
  1031
	 @publishedPartner
williamr@2
  1032
	 */
williamr@2
  1033
	virtual void CanSend(THCITransportChannel aChannel = KHCITransportAllChannels)=0;
williamr@2
  1034
williamr@2
  1035
	// Events as per spec
williamr@2
  1036
	/** Called on an inquiry complete event.
williamr@2
  1037
williamr@2
  1038
	 @param aNumResponses Number of responses received from the inquiry.  This is zero if not supported or there is an error.
williamr@2
  1039
	 @param aErr HCI specific or system wide error code.
williamr@2
  1040
	 @released
williamr@2
  1041
	 @publishedPartner
williamr@2
  1042
	 */
williamr@2
  1043
    virtual void InquiryCompleteEvent(THCIErrorCode aErr, TUint8 aNumResponses)=0;
williamr@2
  1044
williamr@2
  1045
    /** Called on an inquiry result complete event.
williamr@2
  1046
williamr@2
  1047
	 @param aEntry TInquiryLogEntry containing results of inquiry.
williamr@2
  1048
     @param aErr HCI specific or system wide error code.
williamr@2
  1049
     @released
williamr@2
  1050
     @publishedPartner
williamr@2
  1051
     */
williamr@2
  1052
    virtual void InquiryResultCompleteEvent(THCIErrorCode aErr,const TInquiryLogEntry& aEntry)=0;
williamr@2
  1053
williamr@2
  1054
    /** Called on a connection complete event.
williamr@2
  1055
williamr@2
  1056
	 @param aConn Contains information about the completed connection.
williamr@2
  1057
     @param aErr HCI specific or system wide error code.
williamr@2
  1058
     @released
williamr@2
  1059
     @publishedPartner
williamr@2
  1060
     */
williamr@2
  1061
    virtual void ConnectionCompleteEvent(THCIErrorCode aErr, const TBTConnect &aConn)=0;
williamr@2
  1062
williamr@2
  1063
    /** Called on a connection request event.
williamr@2
  1064
williamr@2
  1065
	 @param aConn Information about the device requesting the connection.
williamr@2
  1066
     @released
williamr@2
  1067
     @publishedPartner
williamr@2
  1068
     */
williamr@2
  1069
    virtual void ConnectionRequestEvent(const TBTConnect &aConn)=0;
williamr@2
  1070
williamr@2
  1071
    /** Called on a disconnection complete event.
williamr@2
  1072
williamr@2
  1073
	 @param aConnH Connection handle
williamr@2
  1074
	 @param aReason Reason for disconnection.
williamr@2
  1075
     @param aErr HCI specific or system wide error code.
williamr@2
  1076
     @released
williamr@2
  1077
     @publishedPartner
williamr@2
  1078
     */
williamr@2
  1079
    virtual void DisconnectionCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH, THCIErrorCode aReason)=0;
williamr@2
  1080
williamr@2
  1081
    /** Called on an authentication complete event.
williamr@2
  1082
williamr@2
  1083
	 @param aConnH Connection handle
williamr@2
  1084
     @param aErr HCI specific or system wide error code.
williamr@2
  1085
     @released
williamr@2
  1086
     @publishedPartner
williamr@2
  1087
     */
williamr@2
  1088
    virtual void AuthenticationCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH)=0;
williamr@2
  1089
williamr@2
  1090
    /** Called on a remote name request complete event.
williamr@2
  1091
williamr@2
  1092
	 @param aBdaddr Bluetooth address of remote device
williamr@2
  1093
	 @param aBuf Name of remote device (max 248 bytes as defined by the bluetooth specification).
williamr@2
  1094
     @param aErr HCI specific or system wide error code.
williamr@2
  1095
     @released
williamr@2
  1096
     @publishedPartner
williamr@2
  1097
     */
williamr@2
  1098
    virtual void RemoteNameReqCompleteEvent(THCIErrorCode aErr, const TBTDevAddr& aBdaddr, const TDesC8& aBuf)=0;
williamr@2
  1099
williamr@2
  1100
    /** Called on encryption change event.
williamr@2
  1101
williamr@2
  1102
	 @param aConnH Connection handle
williamr@2
  1103
	 @param aEnable Whether encryption is enabled
williamr@2
  1104
     @param aErr HCI specific or system wide error code.
williamr@2
  1105
     @released
williamr@2
  1106
     @publishedPartner
williamr@2
  1107
     */
williamr@2
  1108
    virtual void EncryptionChangeEvent(THCIErrorCode aErr, THCIConnHandle aConnH,TBool aEnable)=0;
williamr@2
  1109
williamr@2
  1110
    /** Called on link key complete event.
williamr@2
  1111
williamr@2
  1112
	 @param Connection handle
williamr@2
  1113
     @param aErr HCI specific or system wide error code.
williamr@2
  1114
     @released
williamr@2
  1115
     @publishedPartner
williamr@2
  1116
     */
williamr@2
  1117
    virtual void ChangeLinkKeyCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH)=0;
williamr@2
  1118
williamr@2
  1119
    /** Called on master link key complete event.
williamr@2
  1120
williamr@2
  1121
	 @param aConnH Connection handle
williamr@2
  1122
	 @param aKeyFlag See bluetooth specification
williamr@2
  1123
     @param aErr HCI specific or system wide error code.
williamr@2
  1124
     @released
williamr@2
  1125
     @publishedPartner
williamr@2
  1126
     */
williamr@2
  1127
    virtual void MasterLinkKeyCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH,TBool aKeyFlag)=0;
williamr@2
  1128
williamr@2
  1129
    /** Called on read remote supported features complete event.
williamr@2
  1130
williamr@2
  1131
	 @param aConnH Connection handle
williamr@2
  1132
	 @param aBitMaskList LMP_Features Bit Mask List (8 bytes)
williamr@2
  1133
     @param aErr HCI specific or system wide error code.
williamr@2
  1134
     @released
williamr@2
  1135
     @publishedPartner
williamr@2
  1136
     */
williamr@2
  1137
    virtual void ReadRemoteSupportedFeaturesCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH, TUint64 aBitMaskList)=0;
williamr@2
  1138
    /**  Called  on read remote version info complete event.
williamr@2
  1139
williamr@2
  1140
	 @param aConnH Connection handle
williamr@2
  1141
	 @param aVer Information on remote hardware version
williamr@2
  1142
     @param aErr HCI specific or system wide error code.
williamr@2
  1143
     @released
williamr@2
  1144
     @publishedPartner
williamr@2
  1145
     */
williamr@2
  1146
	virtual void ReadRemoteVersionInfoCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH, const TBTDevRemoteHwVersion& aVer)=0;
williamr@2
  1147
williamr@2
  1148
    /** Called on QOS setup complete event.
williamr@2
  1149
     
williamr@2
  1150
     @param  aQOS QOS information.
williamr@2
  1151
     @param aErr HCI specific or system wide error code.
williamr@2
  1152
     @param aConnH Connection handle
williamr@2
  1153
     @released
williamr@2
  1154
     @publishedPartner
williamr@2
  1155
     */
williamr@2
  1156
	virtual void QOSSetupCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH, TBTQOS aQOS)=0;
williamr@2
  1157
williamr@2
  1158
    /**  Called on Command Complete Event.
williamr@2
  1159
williamr@2
  1160
     @param aErr HCI specific or system wide error code.
williamr@2
  1161
     @released
williamr@2
  1162
     @publishedPartner
williamr@2
  1163
     */
williamr@2
  1164
    virtual void CommandCompleteEvent(THCIErrorCode aErr,THCIOpcode aOpcode)=0;
williamr@2
  1165
williamr@2
  1166
    /** Called on command status event.
williamr@2
  1167
williamr@2
  1168
     @param aOpcode Opcode of the successfully completed event.
williamr@2
  1169
     @released
williamr@2
  1170
     @publishedPartner
williamr@2
  1171
     */
williamr@2
  1172
    virtual void CommandStatusEvent(THCIOpcode aOpcode)=0;
williamr@2
  1173
williamr@2
  1174
    /** Called on Hardware Error Event.
williamr@2
  1175
williamr@2
  1176
	 @param aHwCode Hardware code.
williamr@2
  1177
     @released
williamr@2
  1178
     @publishedPartner
williamr@2
  1179
     */
williamr@2
  1180
    virtual void HardwareErrorEvent(TUint8 aHwCode)=0;
williamr@2
  1181
williamr@2
  1182
    /** Called on Flush Occurred Event.
williamr@2
  1183
williamr@2
  1184
     @param aErr HCI specific or system wide error code.
williamr@2
  1185
     @param aConnH Connection handle
williamr@2
  1186
     @released
williamr@2
  1187
     @publishedPartner
williamr@2
  1188
     */
williamr@2
  1189
	virtual void FlushOccurredEvent(THCIErrorCode aErr, THCIConnHandle aConnH)=0;
williamr@2
  1190
williamr@2
  1191
    /** Called on Role Change Event.
williamr@2
  1192
williamr@2
  1193
	 @param aRole New role.
williamr@2
  1194
	 @param aBdaddr Bluetooth device address of remote device.
williamr@2
  1195
     @param aErr HCI specific or system wide error code.
williamr@2
  1196
     @released
williamr@2
  1197
     @publishedPartner
williamr@2
  1198
     */
williamr@2
  1199
    virtual void RoleChangeEvent(THCIErrorCode aErr, const TBTDevAddr& aBdaddr,TBTBasebandRole aRole)=0;
williamr@2
  1200
williamr@2
  1201
    /** Called on HCI Completed Packets event.
williamr@2
  1202
williamr@2
  1203
     @param aConnH Connection handle
williamr@2
  1204
	 @param aNumPacketsCompleted Number of packets completed.
williamr@2
  1205
     @released
williamr@2
  1206
     @publishedPartner
williamr@2
  1207
     */
williamr@2
  1208
    virtual void HCICompletedPackets(THCIConnHandle aConnH, TUint16 aNumPacketsCompleted)=0; //NumberCompletedPacketsEvent
williamr@2
  1209
williamr@2
  1210
    /** Called on Mode Change Event.
williamr@2
  1211
williamr@2
  1212
	 @param aMode Current mode.
williamr@2
  1213
	 @param aInterval Interval defined according to current mode (see bluetooth specification).
williamr@2
  1214
     @param aErr HCI specific or system wide error code.
williamr@2
  1215
     @param aConnH Connection handle
williamr@2
  1216
     @released
williamr@2
  1217
     @publishedPartner
williamr@2
  1218
     */
williamr@2
  1219
    virtual void ModeChangeEvent(THCIErrorCode aErr, THCIConnHandle aConnH, TBTLinkMode aMode, TUint16 aInterval)=0;
williamr@2
  1220
williamr@2
  1221
    /** Called on Return Link Keys Event.
williamr@2
  1222
williamr@2
  1223
	 @param aBdaddr Bluetooth device address of remote device.
williamr@2
  1224
	 @param aLinkKey Link key.
williamr@2
  1225
     @param aErr HCI specific or system wide error code.
williamr@2
  1226
     @released
williamr@2
  1227
     @publishedPartner
williamr@2
  1228
     */
williamr@2
  1229
    virtual void ReturnLinkKeysEvent(THCIErrorCode aErr, const TBTDevAddr& aBdaddr,const TBTLinkKey& aLinkKey)=0;
williamr@2
  1230
williamr@2
  1231
    /** Called on PIN Code Request Event.
williamr@2
  1232
williamr@2
  1233
	 @param aBdaddr Bluetooth device address
williamr@2
  1234
     @released
williamr@2
  1235
     @publishedPartner
williamr@2
  1236
     */
williamr@2
  1237
    virtual void PINCodeRequestEvent(const TBTDevAddr& aBdaddr)=0;
williamr@2
  1238
williamr@2
  1239
    /** Called on Link Key Request Event.
williamr@2
  1240
williamr@2
  1241
	 @param aBdaddr Bluetooth device address
williamr@2
  1242
     @released
williamr@2
  1243
     @publishedPartner
williamr@2
  1244
     */
williamr@2
  1245
    virtual void LinkKeyRequestEvent(const TBTDevAddr& aBdaddr)=0;
williamr@2
  1246
williamr@2
  1247
    /** Called on Link Key Notification Event.
williamr@2
  1248
williamr@2
  1249
	 @param aBdaddr Bluetooth device address.
williamr@2
  1250
	 @param aLinkKey Link key.
williamr@2
  1251
     @released
williamr@2
  1252
     @publishedPartner
williamr@2
  1253
     */
williamr@2
  1254
    virtual void LinkKeyNotificationEvent(const TBTDevAddr& aBdaddr,const TBTLinkKey& aLinkKey)=0;
williamr@2
  1255
williamr@2
  1256
    /** Called on Loopback Command Event.  Not currently supported.
williamr@2
  1257
williamr@2
  1258
     @released
williamr@2
  1259
     @internalTechnology
williamr@2
  1260
     */
williamr@2
  1261
	virtual void LoopbackCommandEvent()=0; //not supported yet
williamr@2
  1262
williamr@2
  1263
    /** Called on Data Buffer Overflow Event. 
williamr@2
  1264
williamr@2
  1265
	 @param aLinkType
williamr@2
  1266
     @released
williamr@2
  1267
     @publishedPartner
williamr@2
  1268
     */
williamr@2
  1269
	virtual void DataBufferOverflowEvent(TUint8 aLinkType)=0;
williamr@2
  1270
williamr@2
  1271
    /** Called on Max Slots Change Event.
williamr@2
  1272
williamr@2
  1273
	 @param aMaxSlots New value of max slots.
williamr@2
  1274
     @param aConnH Connection handle
williamr@2
  1275
     @released
williamr@2
  1276
     @publishedPartner
williamr@2
  1277
     */
williamr@2
  1278
	virtual void MaxSlotsChangeEvent(THCIConnHandle aConnH, TUint8 aMaxSlots)=0;
williamr@2
  1279
williamr@2
  1280
    /** Called on Read Clock Offset Result Event.
williamr@2
  1281
williamr@2
  1282
	 @param aClockOffset Clock offset.
williamr@2
  1283
     @param aErr HCI specific or system wide error code.
williamr@2
  1284
     @param aConnH Connection handle
williamr@2
  1285
     @released
williamr@2
  1286
     @publishedPartner
williamr@2
  1287
     */
williamr@2
  1288
	virtual void ReadClockOffsetResultEvent(THCIErrorCode aErr, THCIConnHandle aConnH, TBasebandTime aClockOffset)=0;
williamr@2
  1289
williamr@2
  1290
    /** Called on Connection Packet Type Changed Event.
williamr@2
  1291
williamr@2
  1292
	 @param aPacketType New packet type.
williamr@2
  1293
     @param aErr HCI specific or system wide error code.
williamr@2
  1294
     @param aConnH Connection handle
williamr@2
  1295
     @released
williamr@2
  1296
     @publishedPartner
williamr@2
  1297
     */
williamr@2
  1298
	virtual void ConnectionPacketTypeChangedEvent(THCIErrorCode aErr,
williamr@2
  1299
					THCIConnHandle aConnH, TUint16 aPacketType)=0;
williamr@2
  1300
williamr@2
  1301
    /** Called on QOS Violation Event.
williamr@2
  1302
williamr@2
  1303
     @param aConnH Connection handle
williamr@2
  1304
     @released
williamr@2
  1305
     @publishedPartner
williamr@2
  1306
     */
williamr@2
  1307
	virtual void QOSViolationEvent(THCIConnHandle aConnH)=0;
williamr@2
  1308
williamr@2
  1309
    /** Called on Page Scan Mode Change Event.
williamr@2
  1310
williamr@2
  1311
	 @param aBdaddr Bluetooth device address.
williamr@2
  1312
	 @param aPageScanMode New page scan mode
williamr@2
  1313
     @released
williamr@2
  1314
     @publishedPartner
williamr@2
  1315
     */
williamr@2
  1316
	virtual void PageScanModeChangeEvent(const TBTDevAddr& aBdaddr, TUint8 aPageScanMode)=0;
williamr@2
  1317
williamr@2
  1318
    /** Called on Page Scan Repetition Mode Change Event.
williamr@2
  1319
williamr@2
  1320
	 @param aBdaddr Bluetooth device address
williamr@2
  1321
	 @param aPageScanRepetitionMode New page scan repetition mode
williamr@2
  1322
     @released
williamr@2
  1323
     @publishedPartner
williamr@2
  1324
     */
williamr@2
  1325
	virtual void PageScanRepetitionModeChangeEvent(const TBTDevAddr& aBdaddr, TUint8 aPageScanRepetitionMode)=0;
williamr@2
  1326
williamr@2
  1327
    // data events
williamr@2
  1328
williamr@2
  1329
    /** Called on ACLDataReceivedEvent.
williamr@2
  1330
williamr@2
  1331
     @param aConnH Connection handle
williamr@2
  1332
	 @param aData Received data
williamr@2
  1333
	 @param aFlag See bluetooth specification
williamr@2
  1334
     @released
williamr@2
  1335
     @publishedPartner
williamr@2
  1336
     */
williamr@2
  1337
	virtual void ACLDataReceivedEvent(THCIConnHandle aConnH,TUint8 aFlag,const TDesC8& aData)=0;
williamr@2
  1338
williamr@2
  1339
    /** Called on SCO Data Received Event.
williamr@2
  1340
williamr@2
  1341
	 @param aData Recieved data.
williamr@2
  1342
     @param aConnH Connection handle
williamr@2
  1343
     @released
williamr@2
  1344
     @publishedPartner
williamr@2
  1345
     */
williamr@2
  1346
	virtual void SCODataReceivedEvent(THCIConnHandle aConnH, const TDesC8& aData)=0;
williamr@2
  1347
williamr@2
  1348
	// complete events
williamr@2
  1349
williamr@2
  1350
williamr@2
  1351
    /** Called on Reset Complete Event.
williamr@2
  1352
williamr@2
  1353
     @param aStatus HCI specific or system wide error code.
williamr@2
  1354
     @released
williamr@2
  1355
     @publishedPartner
williamr@2
  1356
     */
williamr@2
  1357
	virtual void ResetCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1358
williamr@2
  1359
    /** Called on Write Link Supervision Timeout Complete Event.
williamr@2
  1360
williamr@2
  1361
     @param aStatus HCI specific or system wide error code.
williamr@2
  1362
     @released
williamr@2
  1363
     @publishedPartner
williamr@2
  1364
     */
williamr@2
  1365
	virtual void WriteLinkSupervisionTimeoutCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1366
williamr@2
  1367
    /** Called on Link Key Request Reply Complete Event.
williamr@2
  1368
williamr@2
  1369
     @param aStatus HCI specific or system wide error code.
williamr@2
  1370
     @released
williamr@2
  1371
     @publishedPartner
williamr@2
  1372
     */
williamr@2
  1373
	virtual void LinkKeyRequestReplyCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1374
williamr@2
  1375
    /** Called on Link Key Request Reply Negative Complete Event.
williamr@2
  1376
williamr@2
  1377
     @param aStatus HCI specific or system wide error code.
williamr@2
  1378
     @released
williamr@2
  1379
     @publishedPartner
williamr@2
  1380
     */
williamr@2
  1381
    virtual void LinkKeyRequestReplyNegativeCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1382
williamr@2
  1383
    /** Called on PIN Code Request Reply Complete Event.
williamr@2
  1384
williamr@2
  1385
     @param aStatus HCI specific or system wide error code.
williamr@2
  1386
     @released
williamr@2
  1387
     @publishedPartner
williamr@2
  1388
     */
williamr@2
  1389
    virtual void PINCodeRequestReplyCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1390
williamr@2
  1391
    /** Called on PIN Code Request Reply Negative Complete Event.
williamr@2
  1392
williamr@2
  1393
     @param aStatus HCI specific or system wide error code.
williamr@2
  1394
     @released
williamr@2
  1395
     @publishedPartner
williamr@2
  1396
     */
williamr@2
  1397
    virtual void PINCodeRequestReplyNegativeCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1398
williamr@2
  1399
    /** Called on Inquiry Cancel Complete Event.
williamr@2
  1400
williamr@2
  1401
     @param aStatus HCI specific or system wide error code.
williamr@2
  1402
     @released
williamr@2
  1403
     @publishedPartner
williamr@2
  1404
     */
williamr@2
  1405
    virtual void InquiryCancelCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1406
williamr@2
  1407
    /** Called on Periodic Inquiry Mode Complete Event.
williamr@2
  1408
williamr@2
  1409
     @param aStatus HCI specific or system wide error code.
williamr@2
  1410
     @released
williamr@2
  1411
     @publishedPartner
williamr@2
  1412
     */
williamr@2
  1413
    virtual void PeriodicInquiryModeCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1414
williamr@2
  1415
    /** Called on Exit Periodic Inquiry Mode Complete Event.
williamr@2
  1416
williamr@2
  1417
     @param aStatus HCI specific or system wide error code.
williamr@2
  1418
     @released
williamr@2
  1419
     @publishedPartner
williamr@2
  1420
     */
williamr@2
  1421
    virtual void ExitPeriodicInquiryModeCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1422
williamr@2
  1423
    /** Called on Set Event Mask Complete Event.
williamr@2
  1424
williamr@2
  1425
     @param aStatus HCI specific or system wide error code.
williamr@2
  1426
     @released
williamr@2
  1427
     @publishedPartner
williamr@2
  1428
     */
williamr@2
  1429
    virtual void SetEventMaskCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1430
williamr@2
  1431
    /** Called on Set Event Filter Complete Event.
williamr@2
  1432
williamr@2
  1433
     @param aStatus HCI specific or system wide error code.
williamr@2
  1434
     @released
williamr@2
  1435
     @publishedPartner
williamr@2
  1436
     */
williamr@2
  1437
    virtual void SetEventFilterCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1438
williamr@2
  1439
    /** Called on Create New Unit Key Complete Event.
williamr@2
  1440
williamr@2
  1441
     @param aStatus HCI specific or system wide error code.
williamr@2
  1442
     @released
williamr@2
  1443
     @publishedPartner
williamr@2
  1444
     */
williamr@2
  1445
    virtual void CreateNewUnitKeyCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1446
williamr@2
  1447
    /** Called on Change Local Name Complete Event.
williamr@2
  1448
williamr@2
  1449
     @param aStatus HCI specific or system wide error code.
williamr@2
  1450
     @released
williamr@2
  1451
     @publishedPartner
williamr@2
  1452
     */
williamr@2
  1453
    virtual void ChangeLocalNameCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1454
williamr@2
  1455
    /** Called on Write Authentication Enable Complete Event.
williamr@2
  1456
williamr@2
  1457
     @param aStatus HCI specific or system wide error code.
williamr@2
  1458
     @released
williamr@2
  1459
     @publishedPartner
williamr@2
  1460
     */
williamr@2
  1461
    virtual void WriteAuthenticationEnableCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1462
williamr@2
  1463
    /** Called on Write Encryption Mode Complete Event.
williamr@2
  1464
williamr@2
  1465
     @param aStatus HCI specific or system wide error code.
williamr@2
  1466
     @released
williamr@2
  1467
     @publishedPartner
williamr@2
  1468
     */
williamr@2
  1469
    virtual void WriteEncryptionModeCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1470
williamr@2
  1471
    /** Called on Write Page Timeout Complete Event.
williamr@2
  1472
williamr@2
  1473
     @param aStatus HCI specific or system wide error code.
williamr@2
  1474
     @released
williamr@2
  1475
     @publishedPartner
williamr@2
  1476
     */
williamr@2
  1477
    virtual void WritePageTimeoutCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1478
williamr@2
  1479
    /** Called on Write Connection Accept Timeout Complete Event.
williamr@2
  1480
williamr@2
  1481
     @param aStatus HCI specific or system wide error code.
williamr@2
  1482
     @released
williamr@2
  1483
     @publishedPartner
williamr@2
  1484
     */
williamr@2
  1485
    virtual void WriteConnectionAcceptTimeoutCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1486
williamr@2
  1487
    /** Called on Write Class Of Device Complete Event.
williamr@2
  1488
williamr@2
  1489
     @param aStatus HCI specific or system wide error code.
williamr@2
  1490
     @released
williamr@2
  1491
     @publishedPartner
williamr@2
  1492
     */
williamr@2
  1493
    virtual void WriteClassOfDeviceCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1494
williamr@2
  1495
    /** Called on Write Voice Setting Complete Event.
williamr@2
  1496
williamr@2
  1497
     @param aStatus HCI specific or system wide error code.
williamr@2
  1498
     @released
williamr@2
  1499
     @publishedPartner
williamr@2
  1500
     */
williamr@2
  1501
	virtual void WriteVoiceSettingCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1502
williamr@2
  1503
    /** Called on Write Current IAC LAP Complete Event.
williamr@2
  1504
williamr@2
  1505
     @param aStatus HCI specific or system wide error code.
williamr@2
  1506
     @released
williamr@2
  1507
     @publishedPartner
williamr@2
  1508
     */
williamr@2
  1509
	virtual void WriteCurrentIACLAPCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1510
williamr@2
  1511
    /** Called on Set Host Controller To Host Flow Complete Event.
williamr@2
  1512
williamr@2
  1513
     @param aStatus HCI specific or system wide error code.
williamr@2
  1514
     @released
williamr@2
  1515
     @publishedPartner
williamr@2
  1516
     */
williamr@2
  1517
	virtual void SetHostControllerToHostFlowCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1518
williamr@2
  1519
    /** Called on Host Buffer Size Complete Event.
williamr@2
  1520
williamr@2
  1521
     @param aStatus HCI specific or system wide error code.
williamr@2
  1522
     @released
williamr@2
  1523
     @publishedPartner
williamr@2
  1524
     */
williamr@2
  1525
	virtual void HostBufferSizeCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1526
williamr@2
  1527
    /** Called on Host Number Of Completed Packets Complete Event.
williamr@2
  1528
williamr@2
  1529
     @param aStatus HCI specific or system wide error code.
williamr@2
  1530
     @released
williamr@2
  1531
     @publishedPartner
williamr@2
  1532
     */
williamr@2
  1533
	virtual void HostNumberOfCompletedPacketsCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1534
williamr@2
  1535
    /** Called on Write Scan Enable Complete Event.
williamr@2
  1536
williamr@2
  1537
     @param aStatus HCI specific or system wide error code.
williamr@2
  1538
     @released
williamr@2
  1539
     @publishedPartner
williamr@2
  1540
     */
williamr@2
  1541
	virtual void WriteScanEnableCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1542
williamr@2
  1543
    /** Called on Write Link Policy Settings Complete Event.
williamr@2
  1544
williamr@2
  1545
     @param aConnH Connection handle
williamr@2
  1546
     @param aStatus HCI specific or system wide error code.
williamr@2
  1547
     @released
williamr@2
  1548
     @publishedPartner
williamr@2
  1549
     */
williamr@2
  1550
	virtual void WriteLinkPolicySettingsCompleteEvent(THCIErrorCode aStatus, THCIConnHandle aConnH)=0;
williamr@2
  1551
williamr@2
  1552
	// results of local commands
williamr@2
  1553
williamr@2
  1554
williamr@2
  1555
    /** Called on Read Stored Link Key Result.
williamr@2
  1556
williamr@2
  1557
	 @param aNumKeysRead Number of keys read
williamr@2
  1558
	 @param aMaxNumKeys Max number of keys
williamr@2
  1559
     @param aErr HCI specific or system wide error code.
williamr@2
  1560
     @released
williamr@2
  1561
     @publishedPartner
williamr@2
  1562
     */
williamr@2
  1563
    virtual void ReadStoredLinkKeyResult(THCIErrorCode aErr,TUint16 aNumKeysRead,TUint16 aMaxNumKeys)=0;
williamr@2
  1564
williamr@2
  1565
    /** Called on Write Stored Link Key Result.
williamr@2
  1566
williamr@2
  1567
	 @param aNumKeysStored Number of keys stored
williamr@2
  1568
     @param aErr HCI specific or system wide error code.
williamr@2
  1569
     @released
williamr@2
  1570
     @publishedPartner
williamr@2
  1571
     */
williamr@2
  1572
    virtual void WriteStoredLinkKeyResult(THCIErrorCode aErr,TUint8 aNumKeysStored)=0;
williamr@2
  1573
williamr@2
  1574
    /** Called on Delete Stored Link Key Result.
williamr@2
  1575
williamr@2
  1576
	 @param aNumKeysDeleted Number of keys deleted
williamr@2
  1577
     @param aErr HCI specific or system wide error code.
williamr@2
  1578
     @released
williamr@2
  1579
     @publishedPartner
williamr@2
  1580
     */
williamr@2
  1581
    virtual void DeleteStoredLinkKeyResult(THCIErrorCode aErr,TUint8 aNumKeysDeleted)=0;
williamr@2
  1582
williamr@2
  1583
    /** Called on Read Scan Enable Result.
williamr@2
  1584
williamr@2
  1585
	 @param aEnable See bluetooth specification
williamr@2
  1586
     @param aErr HCI specific or system wide error code.
williamr@2
  1587
     @released
williamr@2
  1588
     @publishedPartner
williamr@2
  1589
     */
williamr@2
  1590
    virtual void ReadScanEnableResult(THCIErrorCode aErr,TUint8 aEnable)=0;
williamr@2
  1591
williamr@2
  1592
    /** Called on Read Authentication Enable Result.
williamr@2
  1593
williamr@2
  1594
	 @param aEnable See bluetooth specification
williamr@2
  1595
     @param aErr HCI specific or system wide error code.
williamr@2
  1596
     @released
williamr@2
  1597
     @publishedPartner
williamr@2
  1598
     */
williamr@2
  1599
    virtual void ReadAuthenticationEnableResult(THCIErrorCode aErr,TUint8 aEnable)=0;
williamr@2
  1600
williamr@2
  1601
    /** Called on Read Encryption Enable Result.
williamr@2
  1602
williamr@2
  1603
	 @param aEnable See bluetooth specification
williamr@2
  1604
     @param aErr HCI specific or system wide error code.
williamr@2
  1605
     @released
williamr@2
  1606
     @publishedPartner
williamr@2
  1607
     */
williamr@2
  1608
    virtual void ReadEncryptionEnableResult(THCIErrorCode aErr,THCIEncryptModeFlag aEnable)=0;
williamr@2
  1609
williamr@2
  1610
    /** Called on Read Bdaddr Result.
williamr@2
  1611
williamr@2
  1612
	 @param aBdaddr Bluetooth device address of remote device
williamr@2
  1613
     @param aErr HCI specific or system wide error code.
williamr@2
  1614
     @released
williamr@2
  1615
     @publishedPartner
williamr@2
  1616
     */
williamr@2
  1617
    virtual void ReadBdaddrResult(THCIErrorCode aErr,const TBTDevAddr& aBdaddr)=0;
williamr@2
  1618
williamr@2
  1619
    /** Called on Read Class Of Device Result.
williamr@2
  1620
williamr@2
  1621
	 @param aCoD Class of device of remote device
williamr@2
  1622
     @param aErr HCI specific or system wide error code.
williamr@2
  1623
     @released
williamr@2
  1624
     @publishedPartner
williamr@2
  1625
     */
williamr@2
  1626
    virtual void ReadClassOfDeviceResult(THCIErrorCode aErr,TUint aCoD)=0;
williamr@2
  1627
williamr@2
  1628
    /** Called on Read Voice Setting Result.
williamr@2
  1629
williamr@2
  1630
	 @param aVoiceChannelSetting Voice channel setting
williamr@2
  1631
     @param aErr HCI specific or system wide error code.
williamr@2
  1632
     @released
williamr@2
  1633
     @publishedPartner
williamr@2
  1634
     */
williamr@2
  1635
	virtual void ReadVoiceSettingResult(THCIErrorCode aErr,TUint16 aVoiceChannelSetting)=0;
williamr@2
  1636
williamr@2
  1637
    /** Called on Read Local Name Result.
williamr@2
  1638
williamr@2
  1639
	 @param aLocalName Local name
williamr@2
  1640
     @param aErr HCI specific or system wide error code.
williamr@2
  1641
     @released
williamr@2
  1642
     @publishedPartner
williamr@2
  1643
     */
williamr@2
  1644
	virtual void ReadLocalNameResult(THCIErrorCode aErr,const TDesC8& aLocalName)=0;
williamr@2
  1645
williamr@2
  1646
    /** Called on Read Timeout Result.
williamr@2
  1647
williamr@2
  1648
	 @param aType See bluetooth specification
williamr@2
  1649
	 @param aTimeout  See bluetooth specification
williamr@2
  1650
     @param aErr HCI specific or system wide error code.
williamr@2
  1651
     @released
williamr@2
  1652
     @publishedPartner
williamr@2
  1653
     */
williamr@2
  1654
    virtual void ReadTimeoutResult(THCIErrorCode aErr,THCITimeoutType aType,TBasebandTime aTimeout)=0;
williamr@2
  1655
williamr@2
  1656
    /** Called on Read Local Version Info Result.
williamr@2
  1657
williamr@2
  1658
	 @param aHCIVersion Version information of local device hardware
williamr@2
  1659
	 @param aLMPVersion Version information of local LMP
williamr@2
  1660
     @param aErr HCI specific or system wide error code.
williamr@2
  1661
     @released
williamr@2
  1662
     @publishedPartner
williamr@2
  1663
     */
williamr@2
  1664
	virtual void ReadLocalVersionInfoResult(THCIErrorCode aErr, TBTDevHCIVersion aHCIVersion, TBTDevLMPVersion aLMPVersion)=0;
williamr@2
  1665
williamr@2
  1666
    /** Called on Read Local Supported Features Result.
williamr@2
  1667
williamr@2
  1668
	 @param aBitMaskList See bluetooth specification
williamr@2
  1669
     @param aErr HCI specific or system wide error code.
williamr@2
  1670
     @released
williamr@2
  1671
     @publishedPartner
williamr@2
  1672
     */
williamr@2
  1673
	virtual void ReadLocalSupportedFeaturesResult(THCIErrorCode aErr, TUint64 aBitMaskList)=0;
williamr@2
  1674
    /** Called on Read Country Code Result.
williamr@2
  1675
williamr@2
  1676
	 @param aCountryCode Country code
williamr@2
  1677
     @param aErr HCI specific or system wide error code.
williamr@2
  1678
     @released
williamr@2
  1679
     @publishedPartner
williamr@2
  1680
     */
williamr@2
  1681
	virtual void ReadCountryCodeResult(THCIErrorCode aErr, TUint8 aCountryCode)=0;
williamr@2
  1682
williamr@2
  1683
    /** Called on Read Number Of Supported IAC Result.
williamr@2
  1684
williamr@2
  1685
	 @param aNumIACs  Number of IACs
williamr@2
  1686
     @param aErr HCI specific or system wide error code.
williamr@2
  1687
     @released
williamr@2
  1688
     @publishedPartner
williamr@2
  1689
     */
williamr@2
  1690
	virtual void ReadNumberOfSupportedIACResult(THCIErrorCode aErr, TUint8 aNumIACs)=0;
williamr@2
  1691
williamr@2
  1692
    /** Called on Read Discoverability Result.
williamr@2
  1693
williamr@2
  1694
	 @param aNumIACs The number of concurrent IACs on which scanning is/would take place
williamr@2
  1695
	 @param aIAC IAC_LAP array.
williamr@2
  1696
     @param aErr HCI specific or system wide error code.
williamr@2
  1697
     @released
williamr@2
  1698
     @publishedPartner
williamr@2
  1699
     */
williamr@2
  1700
	virtual void ReadDiscoverabilityResult(THCIErrorCode aErr, TUint8 aNumIACs, TUint aIAC[])=0;
williamr@2
  1701
williamr@2
  1702
    /** Called on Read Buffer Size Result.
williamr@2
  1703
williamr@2
  1704
	 @param aAclMaxLen Maximum length of each ACL packet
williamr@2
  1705
	 @param aScoMaxLen Maximum length of each SCO packet
williamr@2
  1706
	 @param aNoACL Total number of ACL data packets
williamr@2
  1707
	 @param aNoSCO Total number of SCO data packets
williamr@2
  1708
     @param aErr HCI specific or system wide error code.
williamr@2
  1709
     @released
williamr@2
  1710
     @publishedPartner
williamr@2
  1711
     */
williamr@2
  1712
    virtual void ReadBufferSizeResult(THCIErrorCode aErr,TUint16 aAclMaxLen,
williamr@2
  1713
			      TUint8 aScoMaxLen,TUint16 aNoACL,TUint16 aNoSCO)=0;
williamr@2
  1714
williamr@2
  1715
    /** Called on Read Role Discovery Result.
williamr@2
  1716
williamr@2
  1717
	 @param aRole Current role
williamr@2
  1718
     @param aStatus HCI specific or system wide error code.
williamr@2
  1719
     @released
williamr@2
  1720
     @publishedPartner
williamr@2
  1721
     */
williamr@2
  1722
	virtual void ReadRoleDiscoveryResult(THCIErrorCode aStatus, TBTBasebandRole aRole)=0;
williamr@2
  1723
williamr@2
  1724
    /** Called on Vendor Specific Debug Event.
williamr@2
  1725
	
williamr@2
  1726
	 @param aEventFrame The frame holds the event parameters and parameter length field
williamr@2
  1727
     @released
williamr@2
  1728
     @publishedPartner
williamr@2
  1729
     */
williamr@2
  1730
	virtual void VendorSpecificDebugEvent(TPtrC8 aEventFrame)=0;
williamr@2
  1731
williamr@2
  1732
	// Power off event
williamr@2
  1733
williamr@2
  1734
    /** Called on Handle Power Status Change.
williamr@2
  1735
williamr@2
  1736
	 @param aState New power state
williamr@2
  1737
     @released
williamr@2
  1738
     @publishedPartner
williamr@2
  1739
     */
williamr@2
  1740
	virtual void HandlePowerStatusChange(TBTPowerState aState)=0;
williamr@2
  1741
	
williamr@2
  1742
williamr@2
  1743
	// Results of Adaptive Frequency Hopping (AFH) commands
williamr@2
  1744
williamr@2
  1745
    /** Called in response to a SetAFHHostChannelClassification command.
williamr@2
  1746
williamr@2
  1747
	 @param aStatus The success or not of the SetAFHHostChannelClassification command
williamr@2
  1748
	 @see SetAFHHostChannelClassification
williamr@2
  1749
     @released
williamr@2
  1750
     @publishedPartner
williamr@2
  1751
     */
williamr@2
  1752
	virtual void SetAFHHostChannelClassificationCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1753
 
williamr@2
  1754
    /** Called in response to a ReadAFHChannelMap command.
williamr@2
  1755
williamr@2
  1756
	 @param aStatus The success or not of the ReadAFHChannelMap command
williamr@2
  1757
	 @param aConnH Connection handle
williamr@2
  1758
	 @param aAFHMode ETrue if AFH is enabled, EFalse if not
williamr@2
  1759
	 @param aAFHChannelMap The AFH channel map being used on the specified connection
williamr@2
  1760
	 @see ReadAFHChannelMap
williamr@2
  1761
     @released
williamr@2
  1762
     @publishedPartner
williamr@2
  1763
     */
williamr@2
  1764
	virtual void ReadAFHChannelMapCompleteEvent(THCIErrorCode aStatus, THCIConnHandle aConnH, TBool aAFHMode, const TDesC8& aAFHChannelMap)=0;
williamr@2
  1765
williamr@2
  1766
    /** Called in response to a WriteAFHChannelAssessmentMode command.
williamr@2
  1767
williamr@2
  1768
	 @param aStatus The success or not of the WriteAFHChannelAssessmentMode command
williamr@2
  1769
	 @see WriteAFHChannelAssessmentMode
williamr@2
  1770
     @released
williamr@2
  1771
     @publishedPartner
williamr@2
  1772
     */
williamr@2
  1773
	virtual void WriteAFHChannelAssessmentModeCompleteEvent(THCIErrorCode aStatus)=0;
williamr@2
  1774
williamr@2
  1775
    /** Called in response to a ReadAFHChannelAssessmentMode command.
williamr@2
  1776
williamr@2
  1777
	 @param aStatus The success or not of the ReadAFHChannelAssessmentMode command
williamr@2
  1778
	 @param aChannelAssessmentMode The host controller is checking for busy channels if ETrue, otherwise it is not
williamr@2
  1779
	 @see ReadAFHChannelAssessmentMode
williamr@2
  1780
     @released
williamr@2
  1781
     @publishedPartner
williamr@2
  1782
     */
williamr@2
  1783
	virtual void ReadAFHChannelAssessmentModeCompleteEvent(THCIErrorCode aStatus, TBool aChannelAssessmentMode)=0;
williamr@2
  1784
williamr@2
  1785
	
williamr@2
  1786
    /** Called in response to a Flush command.
williamr@2
  1787
williamr@2
  1788
	 @param aStatus The success or not of the Flush command
williamr@2
  1789
	 @param aConnH  The connection handle
williamr@2
  1790
     @released
williamr@2
  1791
     @publishedPartner
williamr@2
  1792
     */
williamr@2
  1793
	virtual void FlushCompleteEvent(THCIErrorCode aStatus, THCIConnHandle aConnH)=0;
williamr@2
  1794
williamr@2
  1795
williamr@2
  1796
    /** Called on a synchronous connection complete event.  
williamr@2
  1797
 	@param aStatus
williamr@2
  1798
    @param aConnH HCI connection handle
williamr@2
  1799
    @param aBdaddr BT device address
williamr@2
  1800
    @param aLinkType Link Type:SCO, Reserved or eSCO
williamr@2
  1801
    @param aTransmissionInterval Transmission Interval
williamr@2
  1802
    @param aRetransmissionWindow Retransmission Window
williamr@2
  1803
    @param aRxPacketLength Rx Packet Length
williamr@2
  1804
    @param aTxPacketLength Tx Packet Length
williamr@2
  1805
    @param aAirMode Air Mode: uLaw, ALaw, CVSD or Transparent data
williamr@2
  1806
    @released
williamr@2
  1807
    @publishedPartner
williamr@2
  1808
     */
williamr@2
  1809
    virtual void SynchronousConnectionCompleteEvent(const THCIErrorCode aErr,
williamr@2
  1810
    												const THCIConnHandle aConnH,
williamr@2
  1811
    												const TBTDevAddr& aBdaddr,
williamr@2
  1812
    												const TLinkType aLinkType,
williamr@2
  1813
    												const TUint8 aTransmissionInterval,
williamr@2
  1814
    												const TUint8 aRetransmissionWindow,
williamr@2
  1815
    												const TUint16 aRxPacketLength,
williamr@2
  1816
    												const TUint16 aTxPacketLength,
williamr@2
  1817
    												const TAirMode aAirMode)=0;
williamr@2
  1818
williamr@2
  1819
    /** Called on a synchronous connection changed event
williamr@2
  1820
 	@param aStatus
williamr@2
  1821
    @param aConnH HCI connection handle
williamr@2
  1822
    @param aTransmissionInterval Transmission Interval
williamr@2
  1823
    @param aRetransmissionWindow Retransmission Window
williamr@2
  1824
    @param aRxPacketLength Rx Packet Length
williamr@2
  1825
    @param aTxPacketLength Tx Packet Length
williamr@2
  1826
    @released
williamr@2
  1827
    @publishedPartner
williamr@2
  1828
     */
williamr@2
  1829
    virtual void SynchronousConnectionChangedEvent(const THCIErrorCode aErr,
williamr@2
  1830
    											   const THCIConnHandle aConnH,
williamr@2
  1831
   												   const TUint8 aTransmissionInterval,
williamr@2
  1832
   												   const TUint8 aRetransmissionWindow,
williamr@2
  1833
   												   const TUint16 aRxPacketLength,
williamr@2
  1834
   												   const TUint16 aTxPacketLength)=0;
williamr@2
  1835
    
williamr@2
  1836
  
williamr@2
  1837
williamr@2
  1838
    /** Called when an HCI level Ioctl completes.
williamr@2
  1839
williamr@2
  1840
	 @param aLevel			The Ioctl level
williamr@2
  1841
	 @param aName			The Ioctl function number
williamr@2
  1842
	 @param aOption			Data associated with this Ioctl
williamr@2
  1843
	 @param aErr			System-wide error code
williamr@2
  1844
	 @param aStackSAP		A pointer to the SAP, used to track Ioctls
williamr@2
  1845
     @released
williamr@2
  1846
     @publishedPartner
williamr@2
  1847
     */
williamr@2
  1848
	virtual void CompleteIoctl(TUint aLevel,TUint aName,TDes8* aOption,TInt aErr, TAny* aStackSAP)=0;
williamr@2
  1849
    };
williamr@2
  1850
	
williamr@2
  1851
williamr@2
  1852
/* 
williamr@2
  1853
 * Constants used for Symbian's RHCIDirectAccess test functionality
williamr@2
  1854
 */
williamr@2
  1855
williamr@2
  1856
	// Test Ioctls
williamr@2
  1857
	enum THCIDirectAccessTestIoctl
williamr@2
  1858
		{
williamr@2
  1859
		EHCIDirectAccessTestIoctlSetFlag1 = 0,
williamr@2
  1860
		EHCIDirectAccessTestIoctlSetFlag2,
williamr@2
  1861
		EHCIDirectAccessTestIoctlGetFlag1,
williamr@2
  1862
		EHCIDirectAccessTestIoctlGetFlag2,
williamr@2
  1863
		EHCIDirectAccessTestIoctlValidateFlag1,
williamr@2
  1864
		EHCIDirectAccessTestIoctlValidateFlag2,
williamr@2
  1865
		EHCIDirectAccessTestIoctlTimerFiveSeconds,
williamr@2
  1866
		EHCIDirectAccessTestIoctlTimerEightSeconds,
williamr@2
  1867
		EHCIDirectAccessTestIoctlTestDataPath,
williamr@2
  1868
		EHCIDirectAccessTestIoctlNotifyOnEventX,
williamr@2
  1869
		EHCIDirectAccessTestIoctlTriggerEventX,
williamr@2
  1870
		};
williamr@2
  1871
williamr@2
  1872
	// text strings for testing data path
williamr@2
  1873
	_LIT8(KHCIDirectAccessTestExpectedText, "ExpectedText");
williamr@2
  1874
	_LIT8(KHCIDirectAccessTestUnexpectedText, "UnexpectedText");
williamr@2
  1875
williamr@2
  1876
#endif