»
Symbian OS v9.3 »
Symbian OS reference »
C++ component reference »
Bluetooth BLUETOOTH_USER »
CBluetoothPhysicalLinks
Location:
bt_sock.h
Link against: bluetooth.lib
Class CBluetoothPhysicalLinks
class CBluetoothPhysicalLinks : public CBase;
Description
This is used to enumerate members of piconet, and attach and remove members thereof
It may also be used for non-service dependent reads and writes.
Derivation
CBase
- Base class for all classes to be instantiated on the heap
CBluetoothPhysicalLinks
- This is used to enumerate members of piconet, and attach and remove members thereof
Members
Defined in CBluetoothPhysicalLinks
:
Broadcast()
, CancelCreateConnection()
, CreateConnection()
, Disconnect()
, DisconnectAll()
, Enumerate()
, NewL()
, NewLC()
, ReadRaw()
, ~CBluetoothPhysicalLinks()
Inherited from CBase
:
Delete()
,
Extension_()
,
operator new()
Construction and destruction
static IMPORT_C CBluetoothPhysicalLinks *NewL(MBluetoothPhysicalLinksNotifier &aNotifier, RSocketServ &aServer);
Pre-Condition
A session on the socket server has been started.
Description
Constructor
Opens a Bluetooth socket.
Parameters
Return value
Leave codes
No |
memory, or error on opening socket
|
|
static IMPORT_C CBluetoothPhysicalLinks *NewLC(MBluetoothPhysicalLinksNotifier &aNotifier, RSocketServ &aServer);
Pre-Condition
A session on the socket server has been started.
Description
Constructor
Opens a Bluetooth socket.
Parameters
Return value
Leave codes
No |
memory, or error on opening socket
|
|
~CBluetoothPhysicalLinks()
IMPORT_C ~CBluetoothPhysicalLinks();
Description
Destructor
IMPORT_C TInt CreateConnection(const TBTDevAddr &aDevAddr);
Description
Bring in a new member to the piconet
This can be useful for preparing for a logical link (service socket). Firstly if the local device has not bonded with the
specified remote device, then this function can be used to allow the bonding procedure can take place in advance. Secondly
if a CBluetoothSocket
call is made to create a logical link within an internally specified time of this CreateConnection function being called,
then that link will come up much faster since the physical link will already be in place. Unless this connection is taken
up by a logical link (or a synchronous link) within that internally specified time then it will be closed.
This function can also be used to create a physical link ready for the setting up of a synchronous link (e.g. voice link).
Parameters
const TBTDevAddr &aDevAddr |
Bluetooth address specifying remote device (new member of piconet)
|
|
Return value
IMPORT_C void CancelCreateConnection();
Description
Cancel bringing in a new member to the piconet
Capability: |
NetworkControl |
|
IMPORT_C TInt Disconnect(const TBTDevAddr &aDevAddr);
Description
Disconnect a single member of piconet
Parameters
const TBTDevAddr &aDevAddr |
Bluetooth address specifying remote device (member of piconet)
|
|
Return value
Capability: |
NetworkControl |
|
IMPORT_C TInt DisconnectAll();
Description
Disconnect all members of piconet
Return value
Capability: |
NetworkControl |
|
IMPORT_C TInt Broadcast(const TDesC8 &aData);
Description
Write (raw) broadcast data
Raw broadcast data is data that is not directed to any specified service.
Parameters
const TDesC8 &aData |
Contains data to be broadcast.
|
|
Return value
Capability: |
NetworkControl |
|
IMPORT_C TInt ReadRaw(TDes8 &aData);
Description
Receive (raw) broadcast data
Raw broadcast data is data that is not directed to any specified service.
Parameters
TDes8 &aData |
Contains data received.
|
|
Return value
IMPORT_C TInt Enumerate(RBTDevAddrArray &aBTDevAddrArray, TUint aMaxNumber);
Description
Enumerate connected members of the piconet
Parameters
RBTDevAddrArray &aBTDevAddrArray |
Bluetooth device address array to be filled with bluetooth addresses of connected members of the piconet.
|
TUint aMaxNumber |
Upper limit on number of members to be returned.
|
|
Return value