1.1 --- a/epoc32/include/hcibase.h Wed Mar 31 12:27:01 2010 +0100
1.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
1.3 @@ -1,1876 +0,0 @@
1.4 -// Copyright (c) 1999-2009 Nokia Corporation and/or its subsidiary(-ies).
1.5 -// All rights reserved.
1.6 -// This component and the accompanying materials are made available
1.7 -// 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
1.8 -// which accompanies this distribution, and is available
1.9 -// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
1.10 -//
1.11 -// Initial Contributors:
1.12 -// Nokia Corporation - initial contribution.
1.13 -//
1.14 -// Contributors:
1.15 -//
1.16 -// Description:
1.17 -// This is the API that the bluetooth stack expects from the HCI layer.
1.18 -// It comprises an event notification interface and a command sending interface.
1.19 -// Implementations of the HCI must derive from CHCIBase.
1.20 -//
1.21 -//
1.22 -
1.23 -
1.24 -
1.25 -/**
1.26 - @file
1.27 - @publishedPartner
1.28 - @released
1.29 -*/
1.30 -
1.31 -#ifndef BT_HCIBASE_H_
1.32 -#define BT_HCIBASE_H_
1.33 -
1.34 -#include <bttypes.h>
1.35 -#include <hcierrors.h>
1.36 -#include <hcitypes.h>
1.37 -#include <e32base.h>
1.38 -
1.39 -#include <bluetooth/hci/hciopcodes.h>
1.40 -#include <bluetooth/hci/aclpacketconsts.h>
1.41 -#include <bluetooth/hci/hciconsts.h>
1.42 -#include <bluetooth/hci/basebandpacketconsts.h>
1.43 -
1.44 -class CHCICommandFrame;
1.45 -class CHCIACLDataFrame;
1.46 -class CHCISCODataFrame;
1.47 -class CHCIBase;
1.48 -class MHCIEventObserver;
1.49 -class CESockIniData;
1.50 -
1.51 -/** Factory for creating CHCIBase derived class.
1.52 -
1.53 -To provide a new HCI implementation, re-implement this
1.54 -class in a DLL, which has a factory fucntion at oridnal 1
1.55 -which returns a TAny* to the instance of this factory.
1.56 -NewHCIL() will then be called on the factory to actually
1.57 -create the CHCIBase derived object.
1.58 -
1.59 -@released
1.60 -@publishedPartner
1.61 -*/
1.62 -NONSHARABLE_CLASS(CHCIFactory) : public CBase
1.63 - {
1.64 -public:
1.65 - CHCIFactory();
1.66 - virtual TVersion Version() const;
1.67 - virtual CHCIBase* NewHCIL(MHCIEventObserver* aParent, CESockIniData* aIni=0);
1.68 - virtual CHCICommandFrame* NewHCICommandFrameL(THCIOpcode aOpcode);
1.69 - virtual CHCIACLDataFrame* NewHCIACLDataFrameL(TUint16 aSize);
1.70 - virtual CHCISCODataFrame* NewHCISCODataFrameL(TUint8 aSize);
1.71 - };
1.72 -
1.73 -
1.74 -/** Abstract HCI Interface class.
1.75 -
1.76 -The Symbian Bluetooth stack uses this abstract class as the
1.77 -polymorphic base through which it obtains host controller
1.78 -access. The actual implementation is dependent on the DLL
1.79 -loaded at run-time, as specified in the bt.bt.esk file.
1.80 -The concrete class derived from this should be returned
1.81 -by the CHCIFactory class, located through ordinal 1 in the
1.82 -polymorphic DLL.
1.83 -
1.84 -@publishedPartner
1.85 -@released
1.86 -@see
1.87 -CHCI for detailed description of the functions.
1.88 -MHCIEventObserver for the callback interface for events received over HCI.
1.89 -*/
1.90 -NONSHARABLE_CLASS(CHCIBase) : public CBase
1.91 - {
1.92 -public:
1.93 -
1.94 - /** Writes command frame.
1.95 -
1.96 - @param aFrame command frame to write
1.97 - @return KErrBcspWriteCommandDataFailed on failure, KErrNone otherwise
1.98 - @released
1.99 - @publishedPartner
1.100 - */
1.101 - virtual TInt WriteCommand(const CHCICommandFrame& aFrame)=0;
1.102 -
1.103 - // HCI General exports
1.104 - /** Sets option.
1.105 -
1.106 - @param aName option to set
1.107 - @param aData option value
1.108 - @return System wide error code
1.109 - @released
1.110 - @publishedPartner
1.111 - */
1.112 - virtual TInt SetOption(TUint aName,const TDesC8& aData)=0;
1.113 -
1.114 - /** Gets option.
1.115 -
1.116 - @param aName option to set
1.117 - @param aData desriptor to be filled with option data
1.118 - @return System wide error code
1.119 - @released
1.120 - @publishedPartner
1.121 - */
1.122 - virtual TInt GetOption(TUint aName,TDes8& aData)=0;
1.123 -
1.124 - // HCI Data Calls
1.125 - /** Formats ACL Data.
1.126 -
1.127 - @param aFrame Reference to CHCIACLDataFrame which will be formatted with the data supplied in the other params
1.128 - @param aConnH Connection handle for this frame
1.129 - @param aFlags Flags to be set for this frame
1.130 - @param aData Data for this frame
1.131 - @released
1.132 - @publishedPartner
1.133 - */
1.134 - virtual void FormatACLData(CHCIACLDataFrame& aFrame, THCIConnHandle aConnH,TUint8 aFlags,const TDesC8& aData)=0;
1.135 -
1.136 - /** Formats SCO Data.
1.137 -
1.138 - @param aFrame Reference to CHCISCODataFrame which will be formatted with the data supplied in the other params
1.139 - @param aConnH Connection handle for this frame
1.140 - @param aData Data for this frame
1.141 - @released
1.142 - @publishedPartner
1.143 - */
1.144 - virtual void FormatSCOData(CHCISCODataFrame& aFrame, THCIConnHandle aConnH, const TDesC8& aData)=0;
1.145 -
1.146 - /** Writes ACL Data.
1.147 -
1.148 - This forwards a write from link layer to host controller. The descriptor in the frame is owned by the link layer.
1.149 -
1.150 - @param aFrame the formatted ACL payload from the linkmanager
1.151 - @return System wide error code
1.152 - @released
1.153 - @publishedPartner
1.154 - */
1.155 - virtual TInt WriteACLData(const CHCIACLDataFrame& aFrame)=0;
1.156 -
1.157 - /** Writes SCO Data.
1.158 -
1.159 - This forwards a write from link layer to host controller. The descriptor in the frame is owned by the link layer.
1.160 -
1.161 - @param aFrame the formatted SCO payload from the linkmanager
1.162 - @return System wide error code
1.163 - @released
1.164 - @publishedPartner
1.165 - */
1.166 - virtual TInt WriteSCOData(const CHCISCODataFrame& aFrame)=0;
1.167 -
1.168 - // HCI Frame information commands
1.169 - /** Gets frame connection handle
1.170 -
1.171 - @param aFrame the frame to return the connection handle of
1.172 - @return the connection handle from aFrame
1.173 - @released
1.174 - @publishedPartner
1.175 - */
1.176 - virtual THCIConnHandle FrameConnectionHandle(const CHCIACLDataFrame& aFrame) const =0;
1.177 -
1.178 - /** Gets frame opcode.
1.179 -
1.180 - @param aFrame the frame to return the opcode of
1.181 - @return the opcode of aFrame
1.182 - @released
1.183 - @publishedPartner
1.184 - */
1.185 - virtual THCIOpcode FrameOpcode(const CHCICommandFrame& aFrame) const =0;
1.186 -
1.187 - // HCI Commands
1.188 - /** Commands the host controller to start looking for remote devices within range.
1.189 -
1.190 - The HCI client should not issue a second Inquiry() before the first has
1.191 - completed, because the HC cannot cope with this and will return a
1.192 - COMMAND_DISALLOWED error
1.193 -
1.194 - @param aFrame The HCI frame to format
1.195 - @param aCode InquiryAccessCode (3 bytes)
1.196 - @param aLength InquiryLength N where N * 1.28s is the no. of seconds for inquiry
1.197 - @param aNumResponses Number of responses from inquiry before it is halted - default 0 is unlimited number of responses.
1.198 - @released
1.199 - @publishedPartner
1.200 - */
1.201 - virtual void Inquiry(CHCICommandFrame& aFrame, const TUint aCode=KGIAC, const TUint8 aLength=10, const TUint8 aNumResponses=0)=0;
1.202 -
1.203 - /** Cancels an ongoing inquiry.
1.204 -
1.205 - @param aFrame frame to apply any necessary formatting to for inquiry cancel.
1.206 - @released
1.207 - @publishedPartner
1.208 - */
1.209 - virtual void InquiryCancel(CHCICommandFrame& aFrame)=0;
1.210 -
1.211 - /** Commands the host controller to enter periodic enquiry mode
1.212 -
1.213 - @param aFrame The HCI frame to format
1.214 - @param aMax MaxPeriodLength. The HC chooses a value between aMax and aMin.
1.215 - @param aMin MinPeriodLength
1.216 - @param aCode InquiryAccessCode (3 bytes)
1.217 - @param aLength InquiryLength (default N=2)
1.218 - @param aNumResponses Number of Responses (default=0)
1.219 - @released
1.220 - @publishedPartner
1.221 - */
1.222 - virtual void PeriodicInquiryMode(CHCICommandFrame& aFrame, TUint16 aMax,TUint16 aMin, const TUint aCode=0,const TUint8 aLength=2,const TUint8 aNumResponses=0)=0;
1.223 -
1.224 - /** Exits the periodic inquiry.
1.225 -
1.226 - @param aFrame The HCI frame to format
1.227 - @released
1.228 - @publishedPartner
1.229 - */
1.230 - virtual void ExitPeriodicInquiryMode(CHCICommandFrame& aFrame)=0;
1.231 -
1.232 - /** Initiates connection to remote device using the specified baseband packet type.
1.233 -
1.234 - @param aFrame The HCI frame to format
1.235 - @param aBdaddr remove device address
1.236 - @param aPacketType Packet Type
1.237 - @param aPageScanRepetitionMode pages scan repetition mode
1.238 - @param aPageScanMode page scan mode
1.239 - @param aClockOffset Offset between local and remote clock
1.240 - @param aAllowRoleSwitch Whether the remote device is allowed to role switch the local device
1.241 - @released
1.242 - @publishedPartner
1.243 - */
1.244 - virtual void CreateConnection(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,
1.245 - TUint16 aPacketType=KDM1Packet, TUint8 aPageScanRepetitionMode=0,
1.246 - TUint8 aPageScanMode=0, TUint16 aClockOffset=0, TUint8 aAllowRoleSwitch=1)=0;
1.247 -
1.248 - /** Add an SCO connection between the Host Controller and the remote device.
1.249 -
1.250 - @param aFrame The HCI frame to format
1.251 - @param aConnHandle Connection handle
1.252 - @param aPacketType Packet Type
1.253 - @released
1.254 - @publishedPartner
1.255 - */
1.256 - virtual void AddSCOConnection(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle,TUint16 aPacketType)=0;
1.257 -
1.258 -
1.259 -
1.260 -
1.261 -
1.262 -
1.263 -
1.264 - /**
1.265 - Adds a new or modifies an existing synchronous logical transport (SCO or eSCO)
1.266 - @param aFrame The HCI frame to format
1.267 - @param aConnHandle Connection handle (2 bytes)
1.268 - @param aTransmitBandwidth (4 bytes)
1.269 - @param aReceiveBandwidth (4 bytes)
1.270 - @param aMaxLatency (2 bytes)
1.271 - @param aVoiceSettings (2 bytes)
1.272 - @param aRetransmissionEffort (1 bytes)
1.273 - @param aPacketType (2 bytes)
1.274 - */
1.275 - virtual void SetupSynchronousConnectionCommand(CHCICommandFrame& aFrame, TUint16 aConnHandle,
1.276 - TUint aTransmitBandwidth, TUint aReceiveBandwidth, TUint16 aMaxLatency,
1.277 - TUint16 aVoiceSettings, TUint8 aRetransmissionEffort,
1.278 - TUint16 aPacketType)=0;
1.279 -
1.280 - /**
1.281 - Accepts an incoming connection request for an synchronous connection.
1.282 - @param aFrame The HCI frame to format
1.283 - @param aBdaddr BDADDR (6 bytes)
1.284 - @param aTransmitBandwidth (4 bytes)
1.285 - @param aReceiveBandwidth (4 bytes)
1.286 - @param aMaxLatency (2 bytes)
1.287 - @param aContentFormat (2 bytes)
1.288 - @param aRetransmissionEffort (1 bytes)
1.289 - @param aPacketType (2 bytes)
1.290 - */
1.291 - virtual void AcceptSynchronousConnectionRequestCommand(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,
1.292 - TUint aTransmitBandwidth, TUint aReceiveBandwidth, TUint16 aMaxLatency,
1.293 - TUint16 aContentFormat, TUint8 aRetransmissionEffort, TUint16 aPacketType)=0;
1.294 - /**
1.295 - Rejects the synchronous connction from thre remote device (aBdaddr).
1.296 -
1.297 - @param aFrame The HCI frame to format
1.298 - @param aBdaddr BDADDR
1.299 - @param THCIErrorCode Reject reason
1.300 - */
1.301 - virtual void RejectSynchronousConnectionRequestCommand(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,THCIErrorCode aReason)=0;
1.302 -
1.303 -
1.304 -
1.305 -
1.306 -
1.307 -
1.308 -
1.309 - /** Accepts an incoming connection request.
1.310 -
1.311 - @param aFrame The HCI frame to format
1.312 - @param aBdaddr bluetooth address of remote device
1.313 - @param aRole Role - 0x00=Master, 0x01=Slave.
1.314 - @released
1.315 - @publishedPartner
1.316 - */
1.317 - virtual void AcceptConnectionRequest(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,TUint8 aRole)=0;
1.318 -
1.319 - /** Rejects the connection from the remote device.
1.320 -
1.321 - @param aFrame The HCI frame to format
1.322 - @param aBdaddr Bluetooth address of remote device
1.323 - @param THCIErrorCode Reject reason
1.324 - @released
1.325 - @publishedPartner
1.326 - */
1.327 - virtual void RejectConnectionRequest(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,THCIErrorCode aReason)=0;
1.328 -
1.329 - /** Replies to the remote host with the supplied link key.
1.330 -
1.331 - @param aFrame The HCI frame to format
1.332 - @param aBdaddr bluetooth address of remote device
1.333 - @param aLinkKey Link key (16 bytes)
1.334 - @released
1.335 - @publishedPartner
1.336 - */
1.337 - virtual void LinkKeyRequestReply(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,const TDesC8& aLinkKey)=0;
1.338 -
1.339 - /** Notifies the remote host that the link key was not accepted.
1.340 -
1.341 - @param aFrame The HCI frame to format
1.342 - @param aBdaddr Bluetooth address of remote device
1.343 - @released
1.344 - @publishedPartner
1.345 - */
1.346 - virtual void LinkKeyRequestNegativeReply(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr)=0;
1.347 -
1.348 - /** Returns to the remote host the requested PIN.
1.349 -
1.350 - @param aFrame The HCI frame to format
1.351 - @param aBdaddr Bluetooth address of remote device
1.352 - @param aPIN PIN Code (up to 16 bytes)
1.353 - @released
1.354 - @publishedPartner
1.355 - */
1.356 - virtual void PINCodeRequestReply(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,const TDesC8& aPIN)=0;
1.357 -
1.358 - /** Notifies the remote host that the PIN code was rejected.
1.359 -
1.360 - @param aFrame The HCI frame to format
1.361 - @param aBdaddr Bluetooth address of remote device
1.362 - @released
1.363 - @publishedPartner
1.364 - */
1.365 - virtual void PINCodeRequestNegativeReply(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr)=0;
1.366 -
1.367 - /** Disconnect the ACL or SCO connection corresponding to the supplied handle.
1.368 -
1.369 - @param aFrame The HCI frame to format
1.370 - @param aConnHandle Handle of connection to disconnect
1.371 - @param aReason Reason for disconnection
1.372 - @released
1.373 - @publishedPartner
1.374 - */
1.375 - virtual void Disconnect(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle,THCIErrorCode aReason)=0;
1.376 -
1.377 - /** Changes baseband packet type (e.g DH1, DM3 etc.).
1.378 -
1.379 - @param aFrame The HCI frame to format
1.380 - @param aConnHandle Connection Handle
1.381 - @param aType Packet Type. This should be one of the consts defined in hcibase.h e.g. KDM1Packet.
1.382 - @released
1.383 - @publishedPartner
1.384 - */
1.385 - virtual void ChangeConnectionPacketType(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle,TUint16 aType)=0;
1.386 -
1.387 - /** Perform authenticaction request.
1.388 -
1.389 - @param aFrame The HCI frame to format
1.390 - @param aConnHandle Connection Handle
1.391 - @released
1.392 - @publishedPartner
1.393 - */
1.394 - virtual void AuthenticationRequest(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
1.395 -
1.396 - /** Sets connection encryption
1.397 -
1.398 - @param aFrame The HCI frame to format
1.399 - @param aConnHandle Connection Handle
1.400 - @param aEnable Enable flag ETrue=Enable link encryption, EFalse=Disable link encryption
1.401 - @released
1.402 - @publishedPartner
1.403 - */
1.404 - virtual void SetEncryptionEnable(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle,TBool aEnable)=0;
1.405 -
1.406 - /** Notifies host of need to change connection key for the supplied connection handle.
1.407 -
1.408 - @param aFrame The HCI frame to format
1.409 - @param aConnHandle Connection Handle
1.410 - @released
1.411 - @publishedPartner
1.412 - */
1.413 - virtual void ChangeConnectionLinkKey(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
1.414 -
1.415 - /** Not used.
1.416 -
1.417 - @param aFrame The HCI frame to format
1.418 - @param aKeyFlag Link Key Flag. Possible values are ETrue to use temporary link key or EFalse to use regular link key
1.419 - @released
1.420 - @publishedPartner
1.421 - */
1.422 - virtual void MasterLinkKey(CHCICommandFrame& aFrame, TBool aKeyFlag)=0;
1.423 -
1.424 - /** Retrieves the remote hosts advertised hardware/firmware features.
1.425 -
1.426 - @param aFrame The HCI frame to format
1.427 - @param aConnHandle Connection Handle
1.428 - @released
1.429 - @publishedPartner
1.430 - */
1.431 - virtual void ReadRemoteSupportedFeatures(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
1.432 -
1.433 - /** Retrieve remote hosts HW/Firmware revision information.
1.434 -
1.435 - @param aFrame The HCI frame to format
1.436 - @param aConnHandle Connection Handle
1.437 - @released
1.438 - @publishedPartner
1.439 - */
1.440 - virtual void ReadRemoteVersionInfo(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
1.441 -
1.442 - /** Request on human redable name of remote host.
1.443 -
1.444 - @param aFrame The HCI frame to format
1.445 - @param aBdaddr The bluetooth address of device on which we seek to find a name
1.446 - @param aPageScanRepetitionMode Page scan repetition mode
1.447 - @param aPageScanMode Page scan mode
1.448 - @param aClockOffset Offset of remote device clock from local device clock
1.449 - @released
1.450 - @publishedPartner
1.451 - */
1.452 - virtual void RemoteNameRequest(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr, TUint8 aPageScanRepetitionMode=0,
1.453 - TUint8 aPageScanMode=0, TBasebandTime aClockOffset=0)=0;
1.454 -
1.455 - /** Retrieve offset of remote clock from local clock.
1.456 -
1.457 - @param aFrame The HCI frame to format
1.458 - @param aConnHandle Connection Handle
1.459 - @released
1.460 - @publishedPartner
1.461 - */
1.462 - virtual void ReadClockOffset(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
1.463 -
1.464 - // HCI Link Policy Commands
1.465 - /** Write local link policy settings
1.466 -
1.467 - @param aFrame The HCI frame to format
1.468 - @param aConnHandle Connection Handle
1.469 - @param aSettings @see Bluetooth HCI specification
1.470 - @released
1.471 - @publishedPartner
1.472 - */
1.473 - virtual void WriteLinkPolicySettings(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle, TUint16 aSettings)=0;
1.474 -
1.475 - /** Switch radio and host controller to Hold mode.
1.476 -
1.477 - @param aFrame The HCI frame to format
1.478 - @param aConnHandle Connection Handle
1.479 - @param aHoldMaxInterval Max Hold Interval N, where Time of Hold=N*0.625ms (1 baseband slot)
1.480 - @param aHoldMinInterval Min Hold interval N, as above (both up to 40.9 sec)
1.481 - @released
1.482 - @publishedPartner
1.483 - */
1.484 - virtual void HoldMode(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle, TBasebandTime aHoldMaxInterval,
1.485 - TBasebandTime aHoldMinInterval)=0;
1.486 -
1.487 - /** Switch radio and host controller to Sniff mode.
1.488 -
1.489 - @param aFrame The HCI frame to format
1.490 - @param aConnHandle Connection Handle
1.491 - @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)
1.492 - @param aSniffMinInterval Min Sniff interval , as above
1.493 - @param aAttemptSlots Sniff Attempt - the period the slave will listen after each sniff interval
1.494 - @param aTimeOutSlots Sniff Timeout - time listening for packets as long as some arrive
1.495 - @released
1.496 - @publishedPartner
1.497 - */
1.498 - virtual void SniffMode(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle,TBasebandTime aSniffMaxInterval,TBasebandTime
1.499 - aSniffMinInterval, TBasebandTime aAttempSlots, TBasebandTime aTimeOutSlots)=0;
1.500 -
1.501 - /** Switch radio and host out of the Sniff mode.
1.502 -
1.503 - @param aFrame The HCI frame to format
1.504 - @param aConnHandle Connection Handle
1.505 - @released
1.506 - @publishedPartner
1.507 - */
1.508 - virtual void ExitSniffMode(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
1.509 -
1.510 - /** Switch radio and host controller to the Park mode.
1.511 -
1.512 - @param aFrame The HCI frame to format
1.513 - @param aConnHandle Connection Handle
1.514 - @param aBeaconMax Beacon Max Interval Length N where interval between beacons=N*0.625ms
1.515 - @param aBeaconMin Beacon Min Interval Length N where interval between beacons=N*0.625ms
1.516 - @released
1.517 - @publishedPartner
1.518 - */
1.519 - virtual void ParkMode(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle, TBasebandTime aBeaconMaxInterval,
1.520 - TBasebandTime aBeaconMinInterval)=0;
1.521 -
1.522 - /** Switch radio and host controller off the Park mode.
1.523 -
1.524 - @param aFrame The HCI frame to format
1.525 - @param aConnHandle Connection Handle
1.526 - @released
1.527 - @publishedPartner
1.528 - */
1.529 - virtual void ExitParkMode(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
1.530 -
1.531 - /** Initiate role discovery for the supplied connection handle.
1.532 -
1.533 - @param aFrame The HCI frame to format
1.534 - @param aConnHandle Connection Handle
1.535 - @released
1.536 - @publishedPartner
1.537 - */
1.538 - virtual void RoleDiscovery(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
1.539 -
1.540 - /** Switch current role (master / slave) for the physical link associated with the bluetooth device address provided.
1.541 -
1.542 - @param aFrame The HCI frame to format
1.543 - @param aRole New role
1.544 - @param aAddr Bluetooth device address of remote device
1.545 - @released
1.546 - @publishedPartner
1.547 - */
1.548 - virtual void SwitchRole(CHCICommandFrame& aFrame, TBTBasebandRole aRole, const TBTDevAddr& aAddr)=0;
1.549 -
1.550 -
1.551 - // HCI Host Controller and Baseband Commands
1.552 - /** Sets the mask for the reception or the filtering-out of HCI events from the host controller.
1.553 -
1.554 - @param aFrame The HCI frame to format
1.555 - @param aMask Event Mask
1.556 - @released
1.557 - @publishedPartner
1.558 - */
1.559 - virtual void SetEventMask(CHCICommandFrame& aFrame, const THCIEventMask& aMask)=0;
1.560 -
1.561 - /** Resets the Host Controller hardware state.
1.562 -
1.563 - @param aFrame The HCI frame to format
1.564 - @released
1.565 - @publishedPartner
1.566 - */
1.567 - virtual void Reset(CHCICommandFrame& aFrame)=0;
1.568 -
1.569 - /** Set the filter mask for remotely initiated events.
1.570 -
1.571 - @param aFrame The HCI frame to format
1.572 - @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
1.573 - @released
1.574 - @publishedPartner
1.575 - */
1.576 - virtual void SetEventFilter(CHCICommandFrame& aFrame, const THCIEventCondition& aData)=0;
1.577 -
1.578 - /** Flush buffers corresponding to the supplied connection handle.
1.579 -
1.580 - @param aFrame The HCI frame to format
1.581 - @param aConnHandle Connection Handle
1.582 - @released
1.583 - @publishedPartner
1.584 - */
1.585 - virtual void Flush(CHCICommandFrame& aFrame, THCIConnHandle aConnHandle)=0;
1.586 -
1.587 - /** Creates a new unit key in the host controller.
1.588 -
1.589 - @param aFrame The HCI frame to format
1.590 - @released
1.591 - @publishedPartner
1.592 - */
1.593 - virtual void CreateNewUnitKey(CHCICommandFrame& aFrame)=0;
1.594 -
1.595 - /** Reads out from the host controller the stored link key for given device address
1.596 -
1.597 - @param aFrame The HCI frame to format
1.598 - @param aBdaddr Bluetooth device address to read the link key for.
1.599 - @param aFlag Read all keys flag
1.600 - @released
1.601 - @publishedPartner
1.602 - */
1.603 - virtual void ReadStoredLinkKey(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,THCIReadAllKeysFlag aFlag)=0;
1.604 -
1.605 - /** 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.
1.606 -
1.607 - @param aFrame The HCI frame to format
1.608 - @param aNumOfKeysToWrite Number of keys to write to storage
1.609 - @param aBdaddr Bluetooth device address for the associated link key
1.610 - @param aLinkKey The Link Key
1.611 - @released
1.612 - @publishedPartner
1.613 - */
1.614 - virtual void WriteStoredLinkKey(CHCICommandFrame& aFrame, /*TUint8 aNumOfKeysToWrite,*/
1.615 - const TBTDevAddr& aBdaddr,const TDesC8& aLinkKey)=0;
1.616 -
1.617 - /** Delete the link key stored in the host controller's volatile storage.
1.618 -
1.619 - @param aFrame The HCI frame to format
1.620 - @param aBdaddr Bluetooth device address associated with the link key to delete.
1.621 - @param aFlag Delete options flag
1.622 - @released
1.623 - @publishedPartner
1.624 - */
1.625 - virtual void DeleteStoredLinkKey(CHCICommandFrame& aFrame, const TBTDevAddr& aBdaddr,THCIDeleteAllKeysFlag aFlag)=0;
1.626 -
1.627 - /** Sets the local Bluetooth device name.
1.628 -
1.629 - @param aFrame The HCI frame to format
1.630 - @param aName Local device name (max 248 characters as defined in bluetooth specification).
1.631 - @released
1.632 - @publishedPartner
1.633 - */
1.634 - virtual void ChangeLocalName(CHCICommandFrame& aFrame, const TDesC8& aName)=0;
1.635 -
1.636 - /** Reads out the stored local Bluetooth device name.
1.637 -
1.638 - @param aFrame The HCI frame to format
1.639 - @released
1.640 - @publishedPartner
1.641 - */
1.642 - virtual void ReadLocalName(CHCICommandFrame& aFrame)=0;
1.643 -
1.644 - /** Reads out of the Bluetooth device the connection accept timeout, for incoming connections.
1.645 -
1.646 - @param aFrame The HCI frame to format
1.647 - @released
1.648 - @publishedPartner
1.649 - */
1.650 - virtual void ReadConnectionAcceptTimeout(CHCICommandFrame& aFrame)=0;
1.651 -
1.652 - /** Sets the connection accept timeout in the host controller.
1.653 -
1.654 - @param aFrame The HCI frame to format
1.655 - @param aTimeout The connection timeout
1.656 - @released
1.657 - @publishedPartner
1.658 - */
1.659 - virtual void WriteConnectionAcceptTimeout(CHCICommandFrame& aFrame, TBasebandTime aTimeout)=0;
1.660 -
1.661 - /** Commands the Bluetooth hardware to respond with its Page Timeout.
1.662 -
1.663 - @param aFrame The HCI frame to format
1.664 - @released
1.665 - @publishedPartner
1.666 - */
1.667 - virtual void ReadPageTimeout(CHCICommandFrame& aFrame)=0;
1.668 -
1.669 - /** Sets the page timeout in the host controller.
1.670 -
1.671 - @param aFrame The HCI frame to format
1.672 - @param aTimeout Page Timeout. This must be between KMaxPageTimeout and KMinPageTimeout.
1.673 - @released
1.674 - @publishedPartner
1.675 - */
1.676 - virtual void WritePageTimeout(CHCICommandFrame& aFrame, TBasebandTime aTimeout)=0;
1.677 -
1.678 - /** Read out of the host controller the scan options.
1.679 -
1.680 - @param aFrame The HCI frame to format
1.681 - @released
1.682 - @publishedPartner
1.683 - */
1.684 - virtual void ReadScanEnable(CHCICommandFrame& aFrame)=0;
1.685 -
1.686 - /** Sets the scan options on the host controller.
1.687 -
1.688 - @param aFrame The HCI frame to format
1.689 - @param aScanEnable Scan enable options
1.690 - @released
1.691 - @publishedPartner
1.692 - */
1.693 - virtual void WriteScanEnable(CHCICommandFrame& aFrame, THCIScanEnable aEnable=EInquiryAndPageScan)=0;
1.694 -
1.695 - /** Read out of the host controller the number of supported inquiry access codes.
1.696 -
1.697 - @param aFrame The HCI frame to format
1.698 - @released
1.699 - @publishedPartner
1.700 - */
1.701 - virtual void ReadNumberOfSupportedIAC(CHCICommandFrame& aFrame)=0;
1.702 -
1.703 - /** Write to the host controller the lower address parts supplied.
1.704 -
1.705 - @param aFrame The HCI frame to format
1.706 - @param aNumCurrentIAC The number of inquiry access code lower address parts being sent to the hardware
1.707 - @param aIAC_LAP The inquiry access code lower address parts - 3 bytes each: e.g: GIACLAP=0x9e8b33, LIACLAP=0x9e8b00
1.708 - @released
1.709 - @publishedPartner
1.710 - */
1.711 - virtual void WriteCurrentIACLAP(CHCICommandFrame& aFrame, TUint8 aNumCurrentIAC, TUint aIAC_LAP[])=0;
1.712 -
1.713 - /** Read out the inquiry access code lower address parts.
1.714 -
1.715 - @param aFrame The HCI frame to format
1.716 - @released
1.717 - @publishedPartner
1.718 - */
1.719 - virtual void ReadCurrentIACLAP(CHCICommandFrame& aFrame)=0;
1.720 -
1.721 - /** Read out from the host controller whether authentication is enabled.
1.722 -
1.723 - @param aFrame The HCI frame to format
1.724 - @released
1.725 - @publishedPartner
1.726 - */
1.727 - virtual void ReadAuthenticationEnable(CHCICommandFrame& aFrame)=0;
1.728 -
1.729 - /** Set/Unset authentication.
1.730 -
1.731 - @param aFrame The HCI frame to format
1.732 - @param aAuthEnable Authentication Enable. Possible values are EFalse for authentication disabled or ETrue for authentication enabled
1.733 - @released
1.734 - @publishedPartner
1.735 - */
1.736 - virtual void WriteAuthenticationEnable(CHCICommandFrame& aFrame, TBool aAuthEnable)=0;
1.737 -
1.738 - /** Read out the encryption mode.
1.739 -
1.740 - @param aFrame The HCI frame to format
1.741 - @released
1.742 - @publishedPartner
1.743 - */
1.744 - virtual void ReadEncryptionMode(CHCICommandFrame& aFrame)=0;
1.745 -
1.746 - /** Set/unset the encryption.
1.747 -
1.748 - @param aFrame The HCI frame to format
1.749 - @param aFlag Whether to enable encryption. Possible values are EFalse to disable encryption or ETrue to enable encryption.
1.750 - @released
1.751 - @publishedPartner
1.752 - */
1.753 - virtual void WriteEncryptionMode(CHCICommandFrame& aFrame, THCIEncryptModeFlag aFlag)=0;
1.754 -
1.755 - /** Reads out the class of device of the local Bluetooth device.
1.756 -
1.757 - @param aFrame The HCI frame to format
1.758 - @released
1.759 - @publishedPartner
1.760 - */
1.761 - virtual void ReadClassOfDevice(CHCICommandFrame& aFrame)=0;
1.762 -
1.763 - /** Sets the local Bluetooth class of device.
1.764 -
1.765 - @param aFrame The HCI frame to format
1.766 - @param aCoD Class Of Device
1.767 - @released
1.768 - @publishedPartner
1.769 - */
1.770 - virtual void WriteClassOfDevice(CHCICommandFrame& aFrame, TUint aCoD)=0;
1.771 -
1.772 - /** Read the Bluetooth hardware voice settings.
1.773 -
1.774 - @param aFrame The HCI frame to format
1.775 - @released
1.776 - @publishedPartner
1.777 - */
1.778 - virtual void ReadVoiceSetting(CHCICommandFrame& aFrame)=0;
1.779 -
1.780 - /** Set the local Bluetooth device voice settings.
1.781 -
1.782 - @param aFrame The HCI frame to format
1.783 - @param aVoiceChannelSetting Voice channel settings as defined by the HCI specification.
1.784 - @released
1.785 - @publishedPartner
1.786 - */
1.787 - virtual void WriteVoiceSetting(CHCICommandFrame& aFrame, TInt16 aVoiceChannelSetting)=0;
1.788 -
1.789 - // HCI Informational Parameters Commands
1.790 - /** Retrieve local hardware/firmware revision info.
1.791 -
1.792 - @param aFrame The HCI frame to format
1.793 - @released
1.794 - @publishedPartner
1.795 - */
1.796 - virtual void ReadLocalVersionInformation(CHCICommandFrame& aFrame)=0;
1.797 -
1.798 - /** Retrieve local hardware/firmware capabilities.
1.799 -
1.800 - @param aFrame The HCI frame to format
1.801 - @released
1.802 - @publishedPartner
1.803 - */
1.804 - virtual void ReadLocalSupportedFeatures(CHCICommandFrame& aFrame)=0;
1.805 -
1.806 - /** Retrieve from the host controller its buffering capabilities.
1.807 -
1.808 - @param aFrame The HCI frame to format
1.809 - @released
1.810 - @publishedPartner
1.811 - */
1.812 - virtual void ReadBufferSize(CHCICommandFrame& aFrame)=0;
1.813 -
1.814 - /** Retrieve the hardware's intended country code (for security/encryption issues).
1.815 -
1.816 - @param aFrame The HCI frame to format
1.817 - @released
1.818 - @publishedPartner
1.819 - */
1.820 - virtual void ReadCountryCode(CHCICommandFrame& aFrame)=0;
1.821 -
1.822 - /** Retrieve local Bluetooth device address.
1.823 -
1.824 - @param aFrame The HCI frame to format
1.825 - @released
1.826 - @publishedPartner
1.827 - */
1.828 - virtual void ReadBDADDR(CHCICommandFrame& aFrame)=0;
1.829 -
1.830 - // Host Controller to Host Data Flow Control
1.831 - /** Set/unset notification of delivery of packets, from the host controller to the host.
1.832 -
1.833 - @param aFrame The HCI frame to format
1.834 - @param aFlowFlag Flow Control Enable flag
1.835 - @released
1.836 - @publishedPartner
1.837 - */
1.838 - virtual void SetHostControllerToHostFlowControl(CHCICommandFrame& aFrame, TBool aHC2HFlowFlag)=0;// may return KErrNoMemory
1.839 -
1.840 - /** Notification to host controller of the number of packets that the above
1.841 - layers (L2CAP) have consumed. HostNumberOfCompletedPackets command to be
1.842 - issued by L2CAP.
1.843 -
1.844 - @param aFrame The HCI frame to format
1.845 - @param aNumHandles Number of connectionhandles
1.846 - @param aConnH Connection handle
1.847 - @param aCompletedPacketsNo Host num of completed packets
1.848 - @released
1.849 - @publishedPartner
1.850 - */
1.851 - virtual void HostNumberOfCompletedPackets(CHCICommandFrame& aFrame, TUint8 aNumHandles, THCIConnHandle aConnH[], TUint16 aCompletedPacketsNo[])=0;
1.852 -
1.853 - /** Notifies the host controller of the hosts buffering capabilities.
1.854 -
1.855 - @param aFrame The HCI frame to format
1.856 - @param aACLDataLength Host's ACL Data Packet Length
1.857 - @param aSCODataLength Host's SCO Data Packet Length
1.858 - @param aTotalACLPackets Total Number of ACL Data Packets that the Host can handle
1.859 - @param aTotalSCOPackets Total Number of SCO Data Packets that the Host can handle
1.860 - @released
1.861 - @publishedPartner
1.862 - */
1.863 - virtual void HostBufferSize(CHCICommandFrame& aFrame, TUint16 aACLDataLength,TUint8 aSCODataLength,
1.864 - TUint16 aTotalACLPackets, TUint16 aTotalSCOPackets)=0;
1.865 -
1.866 - /** Writes link supervision timeout.
1.867 -
1.868 - @param aFrame The HCI frame to format
1.869 - @param aConnH Connection handle
1.870 - @param aTimeout Timeout to write
1.871 - @released
1.872 - @publishedPartner
1.873 - */
1.874 - virtual void WriteLinkSupervisionTimeout(CHCICommandFrame& aFrame, THCIConnHandle aConnH, TBasebandTime aTimeout)=0;
1.875 -
1.876 - /** This call allows for a raw HCI command frame to be written to the HC.
1.877 -
1.878 - This is intended for vendor specific commands for which the opcode
1.879 - field will be known to the HCI.
1.880 -
1.881 - These raw frames should be constructed by calling the HCI factory
1.882 - function with the opcode constructed of the vendor debug opcode group field
1.883 - and the particular OCF required. This function should then be called with the
1.884 - appropriately formatted parameters which shall be placed into the frame's
1.885 - payload. It should be noted that the client need NOT to be concerned
1.886 - with the HCTL framing at all.
1.887 -
1.888 - The HCI will only then copy this frame to the host controller after putting
1.889 - it in an HCTL frame.
1.890 -
1.891 - Note that the client is responsible for policing the size of the descriptor
1.892 - passed to this function. The length should be: 0 <= n <= KHCIMaxCommandLength
1.893 -
1.894 - @param aFrame The HCI frame to format
1.895 - @param aData The frame parameters
1.896 - @released
1.897 - @publishedPartner
1.898 - */
1.899 - virtual void WriteVendorRawFrameCommand(CHCICommandFrame& aFrame, const TDesC8& aData)=0;
1.900 -
1.901 -
1.902 - // HCI Status Parameters Commands
1.903 - // not here yet
1.904 -
1.905 - // HCI Testing Commands
1.906 - // not here yet
1.907 - /** Used for testing.
1.908 -
1.909 - @released
1.910 - @internalComponent
1.911 - */
1.912 - virtual TAny *LogIndex() const=0;
1.913 -
1.914 - // methods to allow stack to query HCI about its features
1.915 - /** Reads ACL reporting interval.
1.916 -
1.917 - @return the ACL reporting interval.
1.918 - @released
1.919 - @publishedPartner
1.920 - */
1.921 - virtual TUint16 ReadACLReportingInterval() = 0; // Some hardware only reports on the nth ACL data packet being sent
1.922 - // this is an opportunity for the HCI to supply a minimum value of n
1.923 - // to the Link Manager
1.924 -
1.925 - /** Reads size of HCI framing overhead per frame.
1.926 -
1.927 - @return size of HCI framing overhead per frame.
1.928 - @released
1.929 - @publishedPartner
1.930 - */
1.931 - virtual TUint16 ReadACLFramingOverhead() = 0; // Size of HCI framing overhead per frame
1.932 -
1.933 - // Adaptive Frequency Hopping (AFH)
1.934 -
1.935 - /** Notifies the host controller of channels that are known by the host to be bad or to be about to be bad.
1.936 -
1.937 - This allows those channels to be avoided if Adaptive Frequency Hopping is active on a connection.
1.938 -
1.939 - @param aFrame The HCI frame to format
1.940 - @param aChannelClassification Bitwise representation of the bad channels
1.941 - @released
1.942 - @publishedPartner
1.943 - */
1.944 - virtual void SetAFHHostChannelClassification(CHCICommandFrame& aFrame, const TDesC8& aChannelClassification)=0;
1.945 -
1.946 - /** Retrieves the AFH channel map being used on the specified connection.
1.947 -
1.948 - If we are master this will be the local AFH channel map. If we are slave it
1.949 - will be the remote master's AFH channel map.
1.950 -
1.951 - @param aFrame The HCI frame to format
1.952 - @param aConnH Connection handle
1.953 - @released
1.954 - @publishedPartner
1.955 - */
1.956 - virtual void ReadAFHChannelMap(CHCICommandFrame& aFrame, THCIConnHandle aConnH)=0;
1.957 -
1.958 - /** Notifies the host controller whether or not it is required to keep checking for busy channels..
1.959 -
1.960 - @param aFrame The HCI frame to format
1.961 - @param aEnable Check for busy channels if ETrue, otherwise don't
1.962 - @released
1.963 - @publishedPartner
1.964 - */
1.965 - virtual void WriteAFHChannelAssessmentMode(CHCICommandFrame& aFrame, TBool aEnable)=0;
1.966 -
1.967 - /** Asks the host controller whether or not it is checking for busy channels..
1.968 -
1.969 - @param aFrame The HCI frame to format
1.970 - @released
1.971 - @publishedPartner
1.972 - */
1.973 - virtual void ReadAFHChannelAssessmentMode(CHCICommandFrame& aFrame)=0;
1.974 -
1.975 - /** HCI level Ioctl
1.976 -
1.977 - @param aLevel The Ioctl level
1.978 - @param aName The Ioctl function number
1.979 - @param aOption Data associated with this Ioctl
1.980 - @param aStackSAP A pointer to the SAP, used to track Ioctls
1.981 - @released
1.982 - @publishedPartner
1.983 - */
1.984 - virtual void Ioctl(TUint aLevel,TUint aName, TDes8* aOption, TAny* aStackSAP) = 0;
1.985 -
1.986 - /** Cancel HCI level Ioctl
1.987 -
1.988 - @param aLevel The Ioctl level
1.989 - @param aName The Ioctl function number
1.990 - @param aStackSAP A pointer to the SAP, used to track Ioctls
1.991 - @released
1.992 - @publishedPartner
1.993 - */
1.994 - virtual void CancelIoctl(TUint aLevel,TUint aName, TAny* aStackSAP) = 0;
1.995 - };
1.996 -
1.997 -enum THCIErrorCode;
1.998 -
1.999 -
1.1000 -
1.1001 -/** Event handler mixin that must be implemented by the client of HCI.
1.1002 -
1.1003 -A class that implements this interface must be passed into the
1.1004 -CHCIBase derived class on construction, and will be used by the HCI
1.1005 -class to notify the client of events received over the HCI interface.
1.1006 -
1.1007 -@released
1.1008 -@publishedPartner
1.1009 -*/
1.1010 -class MHCIEventObserver
1.1011 - {
1.1012 -public:
1.1013 - // Interfaces to allow HCI to notify LL
1.1014 - /** This provides command credits.
1.1015 -
1.1016 - @param aCredits Provided command credits.
1.1017 - @released
1.1018 - @publishedPartner
1.1019 - */
1.1020 - virtual void SetCommandCredits(TUint16 aCredits)=0;
1.1021 -
1.1022 - /** Informs of the ACL MTU for this host.
1.1023 -
1.1024 - @param aMTU Maximum size of ACL packet the host can send.
1.1025 - @released
1.1026 - @publishedPartner
1.1027 - */
1.1028 - virtual void HCIMaximumACLPacketSize(TUint16 aMTU)=0;
1.1029 -
1.1030 - /** Called when transport channels have become free.
1.1031 -
1.1032 - @param aChannel Channel that is free.
1.1033 - @released
1.1034 - @publishedPartner
1.1035 - */
1.1036 - virtual void CanSend(THCITransportChannel aChannel = KHCITransportAllChannels)=0;
1.1037 -
1.1038 - // Events as per spec
1.1039 - /** Called on an inquiry complete event.
1.1040 -
1.1041 - @param aNumResponses Number of responses received from the inquiry. This is zero if not supported or there is an error.
1.1042 - @param aErr HCI specific or system wide error code.
1.1043 - @released
1.1044 - @publishedPartner
1.1045 - */
1.1046 - virtual void InquiryCompleteEvent(THCIErrorCode aErr, TUint8 aNumResponses)=0;
1.1047 -
1.1048 - /** Called on an inquiry result complete event.
1.1049 -
1.1050 - @param aEntry TInquiryLogEntry containing results of inquiry.
1.1051 - @param aErr HCI specific or system wide error code.
1.1052 - @released
1.1053 - @publishedPartner
1.1054 - */
1.1055 - virtual void InquiryResultCompleteEvent(THCIErrorCode aErr,const TInquiryLogEntry& aEntry)=0;
1.1056 -
1.1057 - /** Called on a connection complete event.
1.1058 -
1.1059 - @param aConn Contains information about the completed connection.
1.1060 - @param aErr HCI specific or system wide error code.
1.1061 - @released
1.1062 - @publishedPartner
1.1063 - */
1.1064 - virtual void ConnectionCompleteEvent(THCIErrorCode aErr, const TBTConnect &aConn)=0;
1.1065 -
1.1066 - /** Called on a connection request event.
1.1067 -
1.1068 - @param aConn Information about the device requesting the connection.
1.1069 - @released
1.1070 - @publishedPartner
1.1071 - */
1.1072 - virtual void ConnectionRequestEvent(const TBTConnect &aConn)=0;
1.1073 -
1.1074 - /** Called on a disconnection complete event.
1.1075 -
1.1076 - @param aConnH Connection handle
1.1077 - @param aReason Reason for disconnection.
1.1078 - @param aErr HCI specific or system wide error code.
1.1079 - @released
1.1080 - @publishedPartner
1.1081 - */
1.1082 - virtual void DisconnectionCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH, THCIErrorCode aReason)=0;
1.1083 -
1.1084 - /** Called on an authentication complete event.
1.1085 -
1.1086 - @param aConnH Connection handle
1.1087 - @param aErr HCI specific or system wide error code.
1.1088 - @released
1.1089 - @publishedPartner
1.1090 - */
1.1091 - virtual void AuthenticationCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH)=0;
1.1092 -
1.1093 - /** Called on a remote name request complete event.
1.1094 -
1.1095 - @param aBdaddr Bluetooth address of remote device
1.1096 - @param aBuf Name of remote device (max 248 bytes as defined by the bluetooth specification).
1.1097 - @param aErr HCI specific or system wide error code.
1.1098 - @released
1.1099 - @publishedPartner
1.1100 - */
1.1101 - virtual void RemoteNameReqCompleteEvent(THCIErrorCode aErr, const TBTDevAddr& aBdaddr, const TDesC8& aBuf)=0;
1.1102 -
1.1103 - /** Called on encryption change event.
1.1104 -
1.1105 - @param aConnH Connection handle
1.1106 - @param aEnable Whether encryption is enabled
1.1107 - @param aErr HCI specific or system wide error code.
1.1108 - @released
1.1109 - @publishedPartner
1.1110 - */
1.1111 - virtual void EncryptionChangeEvent(THCIErrorCode aErr, THCIConnHandle aConnH,TBool aEnable)=0;
1.1112 -
1.1113 - /** Called on link key complete event.
1.1114 -
1.1115 - @param Connection handle
1.1116 - @param aErr HCI specific or system wide error code.
1.1117 - @released
1.1118 - @publishedPartner
1.1119 - */
1.1120 - virtual void ChangeLinkKeyCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH)=0;
1.1121 -
1.1122 - /** Called on master link key complete event.
1.1123 -
1.1124 - @param aConnH Connection handle
1.1125 - @param aKeyFlag See bluetooth specification
1.1126 - @param aErr HCI specific or system wide error code.
1.1127 - @released
1.1128 - @publishedPartner
1.1129 - */
1.1130 - virtual void MasterLinkKeyCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH,TBool aKeyFlag)=0;
1.1131 -
1.1132 - /** Called on read remote supported features complete event.
1.1133 -
1.1134 - @param aConnH Connection handle
1.1135 - @param aBitMaskList LMP_Features Bit Mask List (8 bytes)
1.1136 - @param aErr HCI specific or system wide error code.
1.1137 - @released
1.1138 - @publishedPartner
1.1139 - */
1.1140 - virtual void ReadRemoteSupportedFeaturesCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH, TUint64 aBitMaskList)=0;
1.1141 - /** Called on read remote version info complete event.
1.1142 -
1.1143 - @param aConnH Connection handle
1.1144 - @param aVer Information on remote hardware version
1.1145 - @param aErr HCI specific or system wide error code.
1.1146 - @released
1.1147 - @publishedPartner
1.1148 - */
1.1149 - virtual void ReadRemoteVersionInfoCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH, const TBTDevRemoteHwVersion& aVer)=0;
1.1150 -
1.1151 - /** Called on QOS setup complete event.
1.1152 -
1.1153 - @param aQOS QOS information.
1.1154 - @param aErr HCI specific or system wide error code.
1.1155 - @param aConnH Connection handle
1.1156 - @released
1.1157 - @publishedPartner
1.1158 - */
1.1159 - virtual void QOSSetupCompleteEvent(THCIErrorCode aErr, THCIConnHandle aConnH, TBTQOS aQOS)=0;
1.1160 -
1.1161 - /** Called on Command Complete Event.
1.1162 -
1.1163 - @param aErr HCI specific or system wide error code.
1.1164 - @released
1.1165 - @publishedPartner
1.1166 - */
1.1167 - virtual void CommandCompleteEvent(THCIErrorCode aErr,THCIOpcode aOpcode)=0;
1.1168 -
1.1169 - /** Called on command status event.
1.1170 -
1.1171 - @param aOpcode Opcode of the successfully completed event.
1.1172 - @released
1.1173 - @publishedPartner
1.1174 - */
1.1175 - virtual void CommandStatusEvent(THCIOpcode aOpcode)=0;
1.1176 -
1.1177 - /** Called on Hardware Error Event.
1.1178 -
1.1179 - @param aHwCode Hardware code.
1.1180 - @released
1.1181 - @publishedPartner
1.1182 - */
1.1183 - virtual void HardwareErrorEvent(TUint8 aHwCode)=0;
1.1184 -
1.1185 - /** Called on Flush Occurred Event.
1.1186 -
1.1187 - @param aErr HCI specific or system wide error code.
1.1188 - @param aConnH Connection handle
1.1189 - @released
1.1190 - @publishedPartner
1.1191 - */
1.1192 - virtual void FlushOccurredEvent(THCIErrorCode aErr, THCIConnHandle aConnH)=0;
1.1193 -
1.1194 - /** Called on Role Change Event.
1.1195 -
1.1196 - @param aRole New role.
1.1197 - @param aBdaddr Bluetooth device address of remote device.
1.1198 - @param aErr HCI specific or system wide error code.
1.1199 - @released
1.1200 - @publishedPartner
1.1201 - */
1.1202 - virtual void RoleChangeEvent(THCIErrorCode aErr, const TBTDevAddr& aBdaddr,TBTBasebandRole aRole)=0;
1.1203 -
1.1204 - /** Called on HCI Completed Packets event.
1.1205 -
1.1206 - @param aConnH Connection handle
1.1207 - @param aNumPacketsCompleted Number of packets completed.
1.1208 - @released
1.1209 - @publishedPartner
1.1210 - */
1.1211 - virtual void HCICompletedPackets(THCIConnHandle aConnH, TUint16 aNumPacketsCompleted)=0; //NumberCompletedPacketsEvent
1.1212 -
1.1213 - /** Called on Mode Change Event.
1.1214 -
1.1215 - @param aMode Current mode.
1.1216 - @param aInterval Interval defined according to current mode (see bluetooth specification).
1.1217 - @param aErr HCI specific or system wide error code.
1.1218 - @param aConnH Connection handle
1.1219 - @released
1.1220 - @publishedPartner
1.1221 - */
1.1222 - virtual void ModeChangeEvent(THCIErrorCode aErr, THCIConnHandle aConnH, TBTLinkMode aMode, TUint16 aInterval)=0;
1.1223 -
1.1224 - /** Called on Return Link Keys Event.
1.1225 -
1.1226 - @param aBdaddr Bluetooth device address of remote device.
1.1227 - @param aLinkKey Link key.
1.1228 - @param aErr HCI specific or system wide error code.
1.1229 - @released
1.1230 - @publishedPartner
1.1231 - */
1.1232 - virtual void ReturnLinkKeysEvent(THCIErrorCode aErr, const TBTDevAddr& aBdaddr,const TBTLinkKey& aLinkKey)=0;
1.1233 -
1.1234 - /** Called on PIN Code Request Event.
1.1235 -
1.1236 - @param aBdaddr Bluetooth device address
1.1237 - @released
1.1238 - @publishedPartner
1.1239 - */
1.1240 - virtual void PINCodeRequestEvent(const TBTDevAddr& aBdaddr)=0;
1.1241 -
1.1242 - /** Called on Link Key Request Event.
1.1243 -
1.1244 - @param aBdaddr Bluetooth device address
1.1245 - @released
1.1246 - @publishedPartner
1.1247 - */
1.1248 - virtual void LinkKeyRequestEvent(const TBTDevAddr& aBdaddr)=0;
1.1249 -
1.1250 - /** Called on Link Key Notification Event.
1.1251 -
1.1252 - @param aBdaddr Bluetooth device address.
1.1253 - @param aLinkKey Link key.
1.1254 - @released
1.1255 - @publishedPartner
1.1256 - */
1.1257 - virtual void LinkKeyNotificationEvent(const TBTDevAddr& aBdaddr,const TBTLinkKey& aLinkKey)=0;
1.1258 -
1.1259 - /** Called on Loopback Command Event. Not currently supported.
1.1260 -
1.1261 - @released
1.1262 - @internalTechnology
1.1263 - */
1.1264 - virtual void LoopbackCommandEvent()=0; //not supported yet
1.1265 -
1.1266 - /** Called on Data Buffer Overflow Event.
1.1267 -
1.1268 - @param aLinkType
1.1269 - @released
1.1270 - @publishedPartner
1.1271 - */
1.1272 - virtual void DataBufferOverflowEvent(TUint8 aLinkType)=0;
1.1273 -
1.1274 - /** Called on Max Slots Change Event.
1.1275 -
1.1276 - @param aMaxSlots New value of max slots.
1.1277 - @param aConnH Connection handle
1.1278 - @released
1.1279 - @publishedPartner
1.1280 - */
1.1281 - virtual void MaxSlotsChangeEvent(THCIConnHandle aConnH, TUint8 aMaxSlots)=0;
1.1282 -
1.1283 - /** Called on Read Clock Offset Result Event.
1.1284 -
1.1285 - @param aClockOffset Clock offset.
1.1286 - @param aErr HCI specific or system wide error code.
1.1287 - @param aConnH Connection handle
1.1288 - @released
1.1289 - @publishedPartner
1.1290 - */
1.1291 - virtual void ReadClockOffsetResultEvent(THCIErrorCode aErr, THCIConnHandle aConnH, TBasebandTime aClockOffset)=0;
1.1292 -
1.1293 - /** Called on Connection Packet Type Changed Event.
1.1294 -
1.1295 - @param aPacketType New packet type.
1.1296 - @param aErr HCI specific or system wide error code.
1.1297 - @param aConnH Connection handle
1.1298 - @released
1.1299 - @publishedPartner
1.1300 - */
1.1301 - virtual void ConnectionPacketTypeChangedEvent(THCIErrorCode aErr,
1.1302 - THCIConnHandle aConnH, TUint16 aPacketType)=0;
1.1303 -
1.1304 - /** Called on QOS Violation Event.
1.1305 -
1.1306 - @param aConnH Connection handle
1.1307 - @released
1.1308 - @publishedPartner
1.1309 - */
1.1310 - virtual void QOSViolationEvent(THCIConnHandle aConnH)=0;
1.1311 -
1.1312 - /** Called on Page Scan Mode Change Event.
1.1313 -
1.1314 - @param aBdaddr Bluetooth device address.
1.1315 - @param aPageScanMode New page scan mode
1.1316 - @released
1.1317 - @publishedPartner
1.1318 - */
1.1319 - virtual void PageScanModeChangeEvent(const TBTDevAddr& aBdaddr, TUint8 aPageScanMode)=0;
1.1320 -
1.1321 - /** Called on Page Scan Repetition Mode Change Event.
1.1322 -
1.1323 - @param aBdaddr Bluetooth device address
1.1324 - @param aPageScanRepetitionMode New page scan repetition mode
1.1325 - @released
1.1326 - @publishedPartner
1.1327 - */
1.1328 - virtual void PageScanRepetitionModeChangeEvent(const TBTDevAddr& aBdaddr, TUint8 aPageScanRepetitionMode)=0;
1.1329 -
1.1330 - // data events
1.1331 -
1.1332 - /** Called on ACLDataReceivedEvent.
1.1333 -
1.1334 - @param aConnH Connection handle
1.1335 - @param aData Received data
1.1336 - @param aFlag See bluetooth specification
1.1337 - @released
1.1338 - @publishedPartner
1.1339 - */
1.1340 - virtual void ACLDataReceivedEvent(THCIConnHandle aConnH,TUint8 aFlag,const TDesC8& aData)=0;
1.1341 -
1.1342 - /** Called on SCO Data Received Event.
1.1343 -
1.1344 - @param aData Recieved data.
1.1345 - @param aConnH Connection handle
1.1346 - @released
1.1347 - @publishedPartner
1.1348 - */
1.1349 - virtual void SCODataReceivedEvent(THCIConnHandle aConnH, const TDesC8& aData)=0;
1.1350 -
1.1351 - // complete events
1.1352 -
1.1353 -
1.1354 - /** Called on Reset Complete Event.
1.1355 -
1.1356 - @param aStatus HCI specific or system wide error code.
1.1357 - @released
1.1358 - @publishedPartner
1.1359 - */
1.1360 - virtual void ResetCompleteEvent(THCIErrorCode aStatus)=0;
1.1361 -
1.1362 - /** Called on Write Link Supervision Timeout Complete Event.
1.1363 -
1.1364 - @param aStatus HCI specific or system wide error code.
1.1365 - @released
1.1366 - @publishedPartner
1.1367 - */
1.1368 - virtual void WriteLinkSupervisionTimeoutCompleteEvent(THCIErrorCode aStatus)=0;
1.1369 -
1.1370 - /** Called on Link Key Request Reply Complete Event.
1.1371 -
1.1372 - @param aStatus HCI specific or system wide error code.
1.1373 - @released
1.1374 - @publishedPartner
1.1375 - */
1.1376 - virtual void LinkKeyRequestReplyCompleteEvent(THCIErrorCode aStatus)=0;
1.1377 -
1.1378 - /** Called on Link Key Request Reply Negative Complete Event.
1.1379 -
1.1380 - @param aStatus HCI specific or system wide error code.
1.1381 - @released
1.1382 - @publishedPartner
1.1383 - */
1.1384 - virtual void LinkKeyRequestReplyNegativeCompleteEvent(THCIErrorCode aStatus)=0;
1.1385 -
1.1386 - /** Called on PIN Code Request Reply Complete Event.
1.1387 -
1.1388 - @param aStatus HCI specific or system wide error code.
1.1389 - @released
1.1390 - @publishedPartner
1.1391 - */
1.1392 - virtual void PINCodeRequestReplyCompleteEvent(THCIErrorCode aStatus)=0;
1.1393 -
1.1394 - /** Called on PIN Code Request Reply Negative Complete Event.
1.1395 -
1.1396 - @param aStatus HCI specific or system wide error code.
1.1397 - @released
1.1398 - @publishedPartner
1.1399 - */
1.1400 - virtual void PINCodeRequestReplyNegativeCompleteEvent(THCIErrorCode aStatus)=0;
1.1401 -
1.1402 - /** Called on Inquiry Cancel Complete Event.
1.1403 -
1.1404 - @param aStatus HCI specific or system wide error code.
1.1405 - @released
1.1406 - @publishedPartner
1.1407 - */
1.1408 - virtual void InquiryCancelCompleteEvent(THCIErrorCode aStatus)=0;
1.1409 -
1.1410 - /** Called on Periodic Inquiry Mode Complete Event.
1.1411 -
1.1412 - @param aStatus HCI specific or system wide error code.
1.1413 - @released
1.1414 - @publishedPartner
1.1415 - */
1.1416 - virtual void PeriodicInquiryModeCompleteEvent(THCIErrorCode aStatus)=0;
1.1417 -
1.1418 - /** Called on Exit Periodic Inquiry Mode Complete Event.
1.1419 -
1.1420 - @param aStatus HCI specific or system wide error code.
1.1421 - @released
1.1422 - @publishedPartner
1.1423 - */
1.1424 - virtual void ExitPeriodicInquiryModeCompleteEvent(THCIErrorCode aStatus)=0;
1.1425 -
1.1426 - /** Called on Set Event Mask Complete Event.
1.1427 -
1.1428 - @param aStatus HCI specific or system wide error code.
1.1429 - @released
1.1430 - @publishedPartner
1.1431 - */
1.1432 - virtual void SetEventMaskCompleteEvent(THCIErrorCode aStatus)=0;
1.1433 -
1.1434 - /** Called on Set Event Filter Complete Event.
1.1435 -
1.1436 - @param aStatus HCI specific or system wide error code.
1.1437 - @released
1.1438 - @publishedPartner
1.1439 - */
1.1440 - virtual void SetEventFilterCompleteEvent(THCIErrorCode aStatus)=0;
1.1441 -
1.1442 - /** Called on Create New Unit Key Complete Event.
1.1443 -
1.1444 - @param aStatus HCI specific or system wide error code.
1.1445 - @released
1.1446 - @publishedPartner
1.1447 - */
1.1448 - virtual void CreateNewUnitKeyCompleteEvent(THCIErrorCode aStatus)=0;
1.1449 -
1.1450 - /** Called on Change Local Name Complete Event.
1.1451 -
1.1452 - @param aStatus HCI specific or system wide error code.
1.1453 - @released
1.1454 - @publishedPartner
1.1455 - */
1.1456 - virtual void ChangeLocalNameCompleteEvent(THCIErrorCode aStatus)=0;
1.1457 -
1.1458 - /** Called on Write Authentication Enable Complete Event.
1.1459 -
1.1460 - @param aStatus HCI specific or system wide error code.
1.1461 - @released
1.1462 - @publishedPartner
1.1463 - */
1.1464 - virtual void WriteAuthenticationEnableCompleteEvent(THCIErrorCode aStatus)=0;
1.1465 -
1.1466 - /** Called on Write Encryption Mode Complete Event.
1.1467 -
1.1468 - @param aStatus HCI specific or system wide error code.
1.1469 - @released
1.1470 - @publishedPartner
1.1471 - */
1.1472 - virtual void WriteEncryptionModeCompleteEvent(THCIErrorCode aStatus)=0;
1.1473 -
1.1474 - /** Called on Write Page Timeout Complete Event.
1.1475 -
1.1476 - @param aStatus HCI specific or system wide error code.
1.1477 - @released
1.1478 - @publishedPartner
1.1479 - */
1.1480 - virtual void WritePageTimeoutCompleteEvent(THCIErrorCode aStatus)=0;
1.1481 -
1.1482 - /** Called on Write Connection Accept Timeout Complete Event.
1.1483 -
1.1484 - @param aStatus HCI specific or system wide error code.
1.1485 - @released
1.1486 - @publishedPartner
1.1487 - */
1.1488 - virtual void WriteConnectionAcceptTimeoutCompleteEvent(THCIErrorCode aStatus)=0;
1.1489 -
1.1490 - /** Called on Write Class Of Device Complete Event.
1.1491 -
1.1492 - @param aStatus HCI specific or system wide error code.
1.1493 - @released
1.1494 - @publishedPartner
1.1495 - */
1.1496 - virtual void WriteClassOfDeviceCompleteEvent(THCIErrorCode aStatus)=0;
1.1497 -
1.1498 - /** Called on Write Voice Setting Complete Event.
1.1499 -
1.1500 - @param aStatus HCI specific or system wide error code.
1.1501 - @released
1.1502 - @publishedPartner
1.1503 - */
1.1504 - virtual void WriteVoiceSettingCompleteEvent(THCIErrorCode aStatus)=0;
1.1505 -
1.1506 - /** Called on Write Current IAC LAP Complete Event.
1.1507 -
1.1508 - @param aStatus HCI specific or system wide error code.
1.1509 - @released
1.1510 - @publishedPartner
1.1511 - */
1.1512 - virtual void WriteCurrentIACLAPCompleteEvent(THCIErrorCode aStatus)=0;
1.1513 -
1.1514 - /** Called on Set Host Controller To Host Flow Complete Event.
1.1515 -
1.1516 - @param aStatus HCI specific or system wide error code.
1.1517 - @released
1.1518 - @publishedPartner
1.1519 - */
1.1520 - virtual void SetHostControllerToHostFlowCompleteEvent(THCIErrorCode aStatus)=0;
1.1521 -
1.1522 - /** Called on Host Buffer Size Complete Event.
1.1523 -
1.1524 - @param aStatus HCI specific or system wide error code.
1.1525 - @released
1.1526 - @publishedPartner
1.1527 - */
1.1528 - virtual void HostBufferSizeCompleteEvent(THCIErrorCode aStatus)=0;
1.1529 -
1.1530 - /** Called on Host Number Of Completed Packets Complete Event.
1.1531 -
1.1532 - @param aStatus HCI specific or system wide error code.
1.1533 - @released
1.1534 - @publishedPartner
1.1535 - */
1.1536 - virtual void HostNumberOfCompletedPacketsCompleteEvent(THCIErrorCode aStatus)=0;
1.1537 -
1.1538 - /** Called on Write Scan Enable Complete Event.
1.1539 -
1.1540 - @param aStatus HCI specific or system wide error code.
1.1541 - @released
1.1542 - @publishedPartner
1.1543 - */
1.1544 - virtual void WriteScanEnableCompleteEvent(THCIErrorCode aStatus)=0;
1.1545 -
1.1546 - /** Called on Write Link Policy Settings Complete Event.
1.1547 -
1.1548 - @param aConnH Connection handle
1.1549 - @param aStatus HCI specific or system wide error code.
1.1550 - @released
1.1551 - @publishedPartner
1.1552 - */
1.1553 - virtual void WriteLinkPolicySettingsCompleteEvent(THCIErrorCode aStatus, THCIConnHandle aConnH)=0;
1.1554 -
1.1555 - // results of local commands
1.1556 -
1.1557 -
1.1558 - /** Called on Read Stored Link Key Result.
1.1559 -
1.1560 - @param aNumKeysRead Number of keys read
1.1561 - @param aMaxNumKeys Max number of keys
1.1562 - @param aErr HCI specific or system wide error code.
1.1563 - @released
1.1564 - @publishedPartner
1.1565 - */
1.1566 - virtual void ReadStoredLinkKeyResult(THCIErrorCode aErr,TUint16 aNumKeysRead,TUint16 aMaxNumKeys)=0;
1.1567 -
1.1568 - /** Called on Write Stored Link Key Result.
1.1569 -
1.1570 - @param aNumKeysStored Number of keys stored
1.1571 - @param aErr HCI specific or system wide error code.
1.1572 - @released
1.1573 - @publishedPartner
1.1574 - */
1.1575 - virtual void WriteStoredLinkKeyResult(THCIErrorCode aErr,TUint8 aNumKeysStored)=0;
1.1576 -
1.1577 - /** Called on Delete Stored Link Key Result.
1.1578 -
1.1579 - @param aNumKeysDeleted Number of keys deleted
1.1580 - @param aErr HCI specific or system wide error code.
1.1581 - @released
1.1582 - @publishedPartner
1.1583 - */
1.1584 - virtual void DeleteStoredLinkKeyResult(THCIErrorCode aErr,TUint8 aNumKeysDeleted)=0;
1.1585 -
1.1586 - /** Called on Read Scan Enable Result.
1.1587 -
1.1588 - @param aEnable See bluetooth specification
1.1589 - @param aErr HCI specific or system wide error code.
1.1590 - @released
1.1591 - @publishedPartner
1.1592 - */
1.1593 - virtual void ReadScanEnableResult(THCIErrorCode aErr,TUint8 aEnable)=0;
1.1594 -
1.1595 - /** Called on Read Authentication Enable Result.
1.1596 -
1.1597 - @param aEnable See bluetooth specification
1.1598 - @param aErr HCI specific or system wide error code.
1.1599 - @released
1.1600 - @publishedPartner
1.1601 - */
1.1602 - virtual void ReadAuthenticationEnableResult(THCIErrorCode aErr,TUint8 aEnable)=0;
1.1603 -
1.1604 - /** Called on Read Encryption Enable Result.
1.1605 -
1.1606 - @param aEnable See bluetooth specification
1.1607 - @param aErr HCI specific or system wide error code.
1.1608 - @released
1.1609 - @publishedPartner
1.1610 - */
1.1611 - virtual void ReadEncryptionEnableResult(THCIErrorCode aErr,THCIEncryptModeFlag aEnable)=0;
1.1612 -
1.1613 - /** Called on Read Bdaddr Result.
1.1614 -
1.1615 - @param aBdaddr Bluetooth device address of remote device
1.1616 - @param aErr HCI specific or system wide error code.
1.1617 - @released
1.1618 - @publishedPartner
1.1619 - */
1.1620 - virtual void ReadBdaddrResult(THCIErrorCode aErr,const TBTDevAddr& aBdaddr)=0;
1.1621 -
1.1622 - /** Called on Read Class Of Device Result.
1.1623 -
1.1624 - @param aCoD Class of device of remote device
1.1625 - @param aErr HCI specific or system wide error code.
1.1626 - @released
1.1627 - @publishedPartner
1.1628 - */
1.1629 - virtual void ReadClassOfDeviceResult(THCIErrorCode aErr,TUint aCoD)=0;
1.1630 -
1.1631 - /** Called on Read Voice Setting Result.
1.1632 -
1.1633 - @param aVoiceChannelSetting Voice channel setting
1.1634 - @param aErr HCI specific or system wide error code.
1.1635 - @released
1.1636 - @publishedPartner
1.1637 - */
1.1638 - virtual void ReadVoiceSettingResult(THCIErrorCode aErr,TUint16 aVoiceChannelSetting)=0;
1.1639 -
1.1640 - /** Called on Read Local Name Result.
1.1641 -
1.1642 - @param aLocalName Local name
1.1643 - @param aErr HCI specific or system wide error code.
1.1644 - @released
1.1645 - @publishedPartner
1.1646 - */
1.1647 - virtual void ReadLocalNameResult(THCIErrorCode aErr,const TDesC8& aLocalName)=0;
1.1648 -
1.1649 - /** Called on Read Timeout Result.
1.1650 -
1.1651 - @param aType See bluetooth specification
1.1652 - @param aTimeout See bluetooth specification
1.1653 - @param aErr HCI specific or system wide error code.
1.1654 - @released
1.1655 - @publishedPartner
1.1656 - */
1.1657 - virtual void ReadTimeoutResult(THCIErrorCode aErr,THCITimeoutType aType,TBasebandTime aTimeout)=0;
1.1658 -
1.1659 - /** Called on Read Local Version Info Result.
1.1660 -
1.1661 - @param aHCIVersion Version information of local device hardware
1.1662 - @param aLMPVersion Version information of local LMP
1.1663 - @param aErr HCI specific or system wide error code.
1.1664 - @released
1.1665 - @publishedPartner
1.1666 - */
1.1667 - virtual void ReadLocalVersionInfoResult(THCIErrorCode aErr, TBTDevHCIVersion aHCIVersion, TBTDevLMPVersion aLMPVersion)=0;
1.1668 -
1.1669 - /** Called on Read Local Supported Features Result.
1.1670 -
1.1671 - @param aBitMaskList See bluetooth specification
1.1672 - @param aErr HCI specific or system wide error code.
1.1673 - @released
1.1674 - @publishedPartner
1.1675 - */
1.1676 - virtual void ReadLocalSupportedFeaturesResult(THCIErrorCode aErr, TUint64 aBitMaskList)=0;
1.1677 - /** Called on Read Country Code Result.
1.1678 -
1.1679 - @param aCountryCode Country code
1.1680 - @param aErr HCI specific or system wide error code.
1.1681 - @released
1.1682 - @publishedPartner
1.1683 - */
1.1684 - virtual void ReadCountryCodeResult(THCIErrorCode aErr, TUint8 aCountryCode)=0;
1.1685 -
1.1686 - /** Called on Read Number Of Supported IAC Result.
1.1687 -
1.1688 - @param aNumIACs Number of IACs
1.1689 - @param aErr HCI specific or system wide error code.
1.1690 - @released
1.1691 - @publishedPartner
1.1692 - */
1.1693 - virtual void ReadNumberOfSupportedIACResult(THCIErrorCode aErr, TUint8 aNumIACs)=0;
1.1694 -
1.1695 - /** Called on Read Discoverability Result.
1.1696 -
1.1697 - @param aNumIACs The number of concurrent IACs on which scanning is/would take place
1.1698 - @param aIAC IAC_LAP array.
1.1699 - @param aErr HCI specific or system wide error code.
1.1700 - @released
1.1701 - @publishedPartner
1.1702 - */
1.1703 - virtual void ReadDiscoverabilityResult(THCIErrorCode aErr, TUint8 aNumIACs, TUint aIAC[])=0;
1.1704 -
1.1705 - /** Called on Read Buffer Size Result.
1.1706 -
1.1707 - @param aAclMaxLen Maximum length of each ACL packet
1.1708 - @param aScoMaxLen Maximum length of each SCO packet
1.1709 - @param aNoACL Total number of ACL data packets
1.1710 - @param aNoSCO Total number of SCO data packets
1.1711 - @param aErr HCI specific or system wide error code.
1.1712 - @released
1.1713 - @publishedPartner
1.1714 - */
1.1715 - virtual void ReadBufferSizeResult(THCIErrorCode aErr,TUint16 aAclMaxLen,
1.1716 - TUint8 aScoMaxLen,TUint16 aNoACL,TUint16 aNoSCO)=0;
1.1717 -
1.1718 - /** Called on Read Role Discovery Result.
1.1719 -
1.1720 - @param aRole Current role
1.1721 - @param aStatus HCI specific or system wide error code.
1.1722 - @released
1.1723 - @publishedPartner
1.1724 - */
1.1725 - virtual void ReadRoleDiscoveryResult(THCIErrorCode aStatus, TBTBasebandRole aRole)=0;
1.1726 -
1.1727 - /** Called on Vendor Specific Debug Event.
1.1728 -
1.1729 - @param aEventFrame The frame holds the event parameters and parameter length field
1.1730 - @released
1.1731 - @publishedPartner
1.1732 - */
1.1733 - virtual void VendorSpecificDebugEvent(TPtrC8 aEventFrame)=0;
1.1734 -
1.1735 - // Power off event
1.1736 -
1.1737 - /** Called on Handle Power Status Change.
1.1738 -
1.1739 - @param aState New power state
1.1740 - @released
1.1741 - @publishedPartner
1.1742 - */
1.1743 - virtual void HandlePowerStatusChange(TBTPowerState aState)=0;
1.1744 -
1.1745 -
1.1746 - // Results of Adaptive Frequency Hopping (AFH) commands
1.1747 -
1.1748 - /** Called in response to a SetAFHHostChannelClassification command.
1.1749 -
1.1750 - @param aStatus The success or not of the SetAFHHostChannelClassification command
1.1751 - @see SetAFHHostChannelClassification
1.1752 - @released
1.1753 - @publishedPartner
1.1754 - */
1.1755 - virtual void SetAFHHostChannelClassificationCompleteEvent(THCIErrorCode aStatus)=0;
1.1756 -
1.1757 - /** Called in response to a ReadAFHChannelMap command.
1.1758 -
1.1759 - @param aStatus The success or not of the ReadAFHChannelMap command
1.1760 - @param aConnH Connection handle
1.1761 - @param aAFHMode ETrue if AFH is enabled, EFalse if not
1.1762 - @param aAFHChannelMap The AFH channel map being used on the specified connection
1.1763 - @see ReadAFHChannelMap
1.1764 - @released
1.1765 - @publishedPartner
1.1766 - */
1.1767 - virtual void ReadAFHChannelMapCompleteEvent(THCIErrorCode aStatus, THCIConnHandle aConnH, TBool aAFHMode, const TDesC8& aAFHChannelMap)=0;
1.1768 -
1.1769 - /** Called in response to a WriteAFHChannelAssessmentMode command.
1.1770 -
1.1771 - @param aStatus The success or not of the WriteAFHChannelAssessmentMode command
1.1772 - @see WriteAFHChannelAssessmentMode
1.1773 - @released
1.1774 - @publishedPartner
1.1775 - */
1.1776 - virtual void WriteAFHChannelAssessmentModeCompleteEvent(THCIErrorCode aStatus)=0;
1.1777 -
1.1778 - /** Called in response to a ReadAFHChannelAssessmentMode command.
1.1779 -
1.1780 - @param aStatus The success or not of the ReadAFHChannelAssessmentMode command
1.1781 - @param aChannelAssessmentMode The host controller is checking for busy channels if ETrue, otherwise it is not
1.1782 - @see ReadAFHChannelAssessmentMode
1.1783 - @released
1.1784 - @publishedPartner
1.1785 - */
1.1786 - virtual void ReadAFHChannelAssessmentModeCompleteEvent(THCIErrorCode aStatus, TBool aChannelAssessmentMode)=0;
1.1787 -
1.1788 -
1.1789 - /** Called in response to a Flush command.
1.1790 -
1.1791 - @param aStatus The success or not of the Flush command
1.1792 - @param aConnH The connection handle
1.1793 - @released
1.1794 - @publishedPartner
1.1795 - */
1.1796 - virtual void FlushCompleteEvent(THCIErrorCode aStatus, THCIConnHandle aConnH)=0;
1.1797 -
1.1798 -
1.1799 - /** Called on a synchronous connection complete event.
1.1800 - @param aStatus
1.1801 - @param aConnH HCI connection handle
1.1802 - @param aBdaddr BT device address
1.1803 - @param aLinkType Link Type:SCO, Reserved or eSCO
1.1804 - @param aTransmissionInterval Transmission Interval
1.1805 - @param aRetransmissionWindow Retransmission Window
1.1806 - @param aRxPacketLength Rx Packet Length
1.1807 - @param aTxPacketLength Tx Packet Length
1.1808 - @param aAirMode Air Mode: uLaw, ALaw, CVSD or Transparent data
1.1809 - @released
1.1810 - @publishedPartner
1.1811 - */
1.1812 - virtual void SynchronousConnectionCompleteEvent(const THCIErrorCode aErr,
1.1813 - const THCIConnHandle aConnH,
1.1814 - const TBTDevAddr& aBdaddr,
1.1815 - const TLinkType aLinkType,
1.1816 - const TUint8 aTransmissionInterval,
1.1817 - const TUint8 aRetransmissionWindow,
1.1818 - const TUint16 aRxPacketLength,
1.1819 - const TUint16 aTxPacketLength,
1.1820 - const TAirMode aAirMode)=0;
1.1821 -
1.1822 - /** Called on a synchronous connection changed event
1.1823 - @param aStatus
1.1824 - @param aConnH HCI connection handle
1.1825 - @param aTransmissionInterval Transmission Interval
1.1826 - @param aRetransmissionWindow Retransmission Window
1.1827 - @param aRxPacketLength Rx Packet Length
1.1828 - @param aTxPacketLength Tx Packet Length
1.1829 - @released
1.1830 - @publishedPartner
1.1831 - */
1.1832 - virtual void SynchronousConnectionChangedEvent(const THCIErrorCode aErr,
1.1833 - const THCIConnHandle aConnH,
1.1834 - const TUint8 aTransmissionInterval,
1.1835 - const TUint8 aRetransmissionWindow,
1.1836 - const TUint16 aRxPacketLength,
1.1837 - const TUint16 aTxPacketLength)=0;
1.1838 -
1.1839 -
1.1840 -
1.1841 - /** Called when an HCI level Ioctl completes.
1.1842 -
1.1843 - @param aLevel The Ioctl level
1.1844 - @param aName The Ioctl function number
1.1845 - @param aOption Data associated with this Ioctl
1.1846 - @param aErr System-wide error code
1.1847 - @param aStackSAP A pointer to the SAP, used to track Ioctls
1.1848 - @released
1.1849 - @publishedPartner
1.1850 - */
1.1851 - virtual void CompleteIoctl(TUint aLevel,TUint aName,TDes8* aOption,TInt aErr, TAny* aStackSAP)=0;
1.1852 - };
1.1853 -
1.1854 -
1.1855 -/*
1.1856 - * Constants used for Symbian's RHCIDirectAccess test functionality
1.1857 - */
1.1858 -
1.1859 - // Test Ioctls
1.1860 - enum THCIDirectAccessTestIoctl
1.1861 - {
1.1862 - EHCIDirectAccessTestIoctlSetFlag1 = 0,
1.1863 - EHCIDirectAccessTestIoctlSetFlag2,
1.1864 - EHCIDirectAccessTestIoctlGetFlag1,
1.1865 - EHCIDirectAccessTestIoctlGetFlag2,
1.1866 - EHCIDirectAccessTestIoctlValidateFlag1,
1.1867 - EHCIDirectAccessTestIoctlValidateFlag2,
1.1868 - EHCIDirectAccessTestIoctlTimerFiveSeconds,
1.1869 - EHCIDirectAccessTestIoctlTimerEightSeconds,
1.1870 - EHCIDirectAccessTestIoctlTestDataPath,
1.1871 - EHCIDirectAccessTestIoctlNotifyOnEventX,
1.1872 - EHCIDirectAccessTestIoctlTriggerEventX,
1.1873 - };
1.1874 -
1.1875 - // text strings for testing data path
1.1876 - _LIT8(KHCIDirectAccessTestExpectedText, "ExpectedText");
1.1877 - _LIT8(KHCIDirectAccessTestUnexpectedText, "UnexpectedText");
1.1878 -
1.1879 -#endif