C# Class LitDev.LDBlueTooth

Afficher le fichier Open project: litdev1/LitDev

Méthodes publiques

Méthode Description
Connect ( ) : Primitive

Advanced feature. Connect an external device and service to the bluetooth USB stick. You must first Initialise, then set the device, service and encoding.

GetDevices ( ) : Primitive

Get a list of discovered bluetooth devices.

GetEncodings ( ) : Primitive

Advanced feature. Get a list of available encodings.

GetServices ( ) : Primitive

Advanced feature. Get a list of available service protocols.

Initialise ( ) : Primitive

Initialise a bluetooth USB stick and detect discoverable external devices. As devices come into or out of range the devices list is updated.

ReceiveData ( ) : Primitive

Advanced feature. Receive (fetch) data from a bluetooth device. The device must be Initialised and Connected. The encoding should also be set.

ReceiveFile ( Primitive fileName ) : Primitive

Receive (fetch) a file from an attached external bluetooth device. You must first Initialise, then set the device.

SendData ( Primitive data ) : Primitive

Advanced feature. Send data to a bluetooth device. The device must be Initialised and Connected. The encoding should also be set.

SendFile ( Primitive fileName ) : Primitive

Send a file to an attached external bluetooth device. You must first Initialise, then set the device.

initialise ( ) : bool

Private Methods

Méthode Description
GetBluetoothDeviceInfo ( string name ) : BluetoothDeviceInfo
GetBluetoothServiceItem ( string name ) : BluetoothServiceItem
inRangeEvent ( object sender, BluetoothWin32RadioInRangeEventArgs e ) : void
outOfRangeEvent ( object sender, BluetoothWin32RadioOutOfRangeEventArgs e ) : void
setDevices ( ) : void
setServices ( ) : void

Method Details

Connect() public static méthode

Advanced feature. Connect an external device and service to the bluetooth USB stick. You must first Initialise, then set the device, service and encoding.
public static Connect ( ) : Primitive
Résultat Primitive

GetDevices() public static méthode

Get a list of discovered bluetooth devices.
public static GetDevices ( ) : Primitive
Résultat Primitive

GetEncodings() public static méthode

Advanced feature. Get a list of available encodings.
public static GetEncodings ( ) : Primitive
Résultat Primitive

GetServices() public static méthode

Advanced feature. Get a list of available service protocols.
public static GetServices ( ) : Primitive
Résultat Primitive

Initialise() public static méthode

Initialise a bluetooth USB stick and detect discoverable external devices. As devices come into or out of range the devices list is updated.
public static Initialise ( ) : Primitive
Résultat Primitive

ReceiveData() public static méthode

Advanced feature. Receive (fetch) data from a bluetooth device. The device must be Initialised and Connected. The encoding should also be set.
public static ReceiveData ( ) : Primitive
Résultat Primitive

ReceiveFile() public static méthode

Receive (fetch) a file from an attached external bluetooth device. You must first Initialise, then set the device.
public static ReceiveFile ( Primitive fileName ) : Primitive
fileName Primitive The location to save the received file.
Résultat Primitive

SendData() public static méthode

Advanced feature. Send data to a bluetooth device. The device must be Initialised and Connected. The encoding should also be set.
public static SendData ( Primitive data ) : Primitive
data Primitive A string of characters to send.
Résultat Primitive

SendFile() public static méthode

Send a file to an attached external bluetooth device. You must first Initialise, then set the device.
public static SendFile ( Primitive fileName ) : Primitive
fileName Primitive The file to send.
Résultat Primitive

initialise() public static méthode

public static initialise ( ) : bool
Résultat bool