QBluetoothDeviceInfo Class
The QBluetoothDeviceInfo class stores information about the Bluetooth device. More...
| Header: | #include <QBluetoothDeviceInfo> |
| qmake: | QT += bluetooth |
Public Types
| enum | CoreConfiguration { UnknownCoreConfiguration, BaseRateCoreConfiguration, BaseRateAndLowEnergyCoreConfiguration, LowEnergyCoreConfiguration } |
| flags | CoreConfigurations |
| enum class | Field { None, RSSI, ManufacturerData, ServiceData, All } |
| flags | Fields |
| enum | MajorDeviceClass { MiscellaneousDevice, ComputerDevice, PhoneDevice, NetworkDevice, AudioVideoDevice, …, UncategorizedDevice } |
| enum | MinorAudioVideoClass { UncategorizedAudioVideoDevice, WearableHeadsetDevice, HandsFreeDevice, Microphone, Loudspeaker, …, GamingDevice } |
| enum | MinorComputerClass { UncategorizedComputer, DesktopComputer, ServerComputer, LaptopComputer, HandheldClamShellComputer, …, WearableComputer } |
| enum | MinorHealthClass { UncategorizedHealthDevice, HealthBloodPressureMonitor, HealthThermometer, HealthWeightScale, HealthGlucoseMeter, …, HealthStepCounter } |
| enum | MinorImagingClass { UncategorizedImagingDevice, ImageDisplay, ImageCamera, ImageScanner, ImagePrinter } |
| enum | MinorMiscellaneousClass { UncategorizedMiscellaneous } |
| enum | MinorNetworkClass { NetworkFullService, NetworkLoadFactorOne, NetworkLoadFactorTwo, NetworkLoadFactorThree, NetworkLoadFactorFour, …, NetworkNoService } |
| enum | MinorPeripheralClass { UncategorizedPeripheral, KeyboardPeripheral, PointingDevicePeripheral, KeyboardWithPointingDevicePeripheral, JoystickPeripheral, …, CardReaderPeripheral } |
| enum | MinorPhoneClass { UncategorizedPhone, CellularPhone, CordlessPhone, SmartPhone, WiredModemOrVoiceGatewayPhone, CommonIsdnAccessPhone } |
| enum | MinorToyClass { UncategorizedToy, ToyRobot, ToyVehicle, ToyDoll, ToyController, ToyGame } |
| enum | MinorWearableClass { UncategorizedWearableDevice, WearableWristWatch, WearablePager, WearableJacket, WearableHelmet, WearableGlasses } |
| enum | ServiceClass { NoService, PositioningService, NetworkingService, RenderingService, CapturingService, …, AllServices } |
| flags | ServiceClasses |
Public Functions
| QBluetoothDeviceInfo() | |
| QBluetoothDeviceInfo(const QBluetoothAddress &address, const QString &name, quint32 classOfDevice) | |
| QBluetoothDeviceInfo(const QBluetoothUuid &uuid, const QString &name, quint32 classOfDevice) | |
| QBluetoothDeviceInfo(const QBluetoothDeviceInfo &other) | |
| ~QBluetoothDeviceInfo() | |
| QBluetoothAddress | address() const |
| QBluetoothDeviceInfo::CoreConfigurations | coreConfigurations() const |
| QBluetoothUuid | deviceUuid() const |
| bool | isCached() const |
| bool | isValid() const |
| QBluetoothDeviceInfo::MajorDeviceClass | majorDeviceClass() const |
| QMultiHash<quint16, QByteArray> | manufacturerData() const |
| QByteArray | manufacturerData(quint16 manufacturerId) const |
| QList<quint16> | manufacturerIds() const |
| quint8 | minorDeviceClass() const |
| QString | name() const |
| qint16 | rssi() const |
| QBluetoothDeviceInfo::ServiceClasses | serviceClasses() const |
(since 6.3) QMultiHash<QBluetoothUuid, QByteArray> | serviceData() const |
(since 6.3) QByteArray | serviceData(const QBluetoothUuid &serviceId) const |
(since 6.3) QList<QBluetoothUuid> | serviceIds() const |
(since 6.0) QList<QBluetoothUuid> | serviceUuids() const |
| void | setCached(bool cached) |
| void | setCoreConfigurations(QBluetoothDeviceInfo::CoreConfigurations coreConfigs) |
| void | setDeviceUuid(const QBluetoothUuid &uuid) |
| bool | setManufacturerData(quint16 manufacturerId, const QByteArray &data) |
(since 6.2) void | setName(const QString &name) |
| void | setRssi(qint16 signal) |
(since 6.3) bool | setServiceData(const QBluetoothUuid &serviceId, const QByteArray &data) |
| void | setServiceUuids(const QList<QBluetoothUuid> &uuids) |
| QBluetoothDeviceInfo & | operator=(const QBluetoothDeviceInfo &other) |
Related Non-Members
| bool | operator!=(const QBluetoothDeviceInfo &a, const QBluetoothDeviceInfo &b) |
| bool | operator==(const QBluetoothDeviceInfo &a, const QBluetoothDeviceInfo &b) |
Detailed Description
QBluetoothDeviceInfo provides information about a Bluetooth device's name, address and class of device.
Member Type Documentation
enum QBluetoothDeviceInfo::CoreConfiguration
flags QBluetoothDeviceInfo::CoreConfigurations
This enum describes the configuration of the device.
| Constant | Value | Description |
|---|---|---|
QBluetoothDeviceInfo::UnknownCoreConfiguration | 0x0 | The type of the Bluetooth device cannot be determined. |
QBluetoothDeviceInfo::BaseRateCoreConfiguration | 0x02 | The device is a standard Bluetooth device. |
QBluetoothDeviceInfo::BaseRateAndLowEnergyCoreConfiguration | 0x03 | The device is a Bluetooth Smart device with support for standard and Low Energy device. |
QBluetoothDeviceInfo::LowEnergyCoreConfiguration | 0x01 | The device is a Bluetooth Low Energy device. |
The CoreConfigurations type is a typedef for QFlags<CoreConfiguration>. It stores an OR combination of CoreConfiguration values.
enum class QBluetoothDeviceInfo::Field
flags QBluetoothDeviceInfo::Fields
This enum is used in conjuntion with the QBluetoothDeviceDiscoveryAgent::deviceUpdated() signal and indicates the field that changed.
| Constant | Value | Description |
|---|---|---|
QBluetoothDeviceInfo::Field::None | 0x0000 | None of the values changed. |
QBluetoothDeviceInfo::Field::RSSI | 0x0001 | The rssi() value of the device changed. |
QBluetoothDeviceInfo::Field::ManufacturerData | 0x0002 | The manufacturerData() field changed |
QBluetoothDeviceInfo::Field::ServiceData | 0x0004 | The serviceData() field changed |
QBluetoothDeviceInfo::Field::All | 0x7fff | Matches every possible field. |
The Fields type is a typedef for QFlags<Field>. It stores an OR combination of Field values.
enum QBluetoothDeviceInfo::MajorDeviceClass
This enum describes a Bluetooth device's major device class.
| Constant | Value | Description |
|---|---|---|
QBluetoothDeviceInfo::MiscellaneousDevice | 0 | A miscellaneous device. |
QBluetoothDeviceInfo::ComputerDevice | 1 | A computer device or PDA. |
QBluetoothDeviceInfo::PhoneDevice | 2 | A telephone device. |
QBluetoothDeviceInfo::NetworkDevice | 3 | A device that provides access to a local area network (since Qt 5.13). |
QBluetoothDeviceInfo::AudioVideoDevice | 4 | A device capable of playback or capture of audio and/or video. |
QBluetoothDeviceInfo::PeripheralDevice | 5 | A peripheral device such as a keyboard, mouse, and so on. |
QBluetoothDeviceInfo::ImagingDevice | 6 | An imaging device such as a display, printer, scanner or camera. |
QBluetoothDeviceInfo::WearableDevice | 7 | A wearable device such as a watch or pager. |
QBluetoothDeviceInfo::ToyDevice | 8 | A toy. |
QBluetoothDeviceInfo::HealthDevice | 9 | A health reated device such as heart rate or temperature monitor. |
QBluetoothDeviceInfo::UncategorizedDevice | 31 | A device that does not fit into any of the other device classes. |
enum QBluetoothDeviceInfo::MinorAudioVideoClass
This enum describes the minor device classes for audio/video devices.
| Constant | Value | Description |
|---|---|---|
QBluetoothDeviceInfo::UncategorizedAudioVideoDevice | 0 | An uncategorized audio/video device. |
QBluetoothDeviceInfo::WearableHeadsetDevice | 1 | A wearable headset device. |
QBluetoothDeviceInfo::HandsFreeDevice | 2 | A handsfree device. |
QBluetoothDeviceInfo::Microphone | 4 | A microphone. |
QBluetoothDeviceInfo::Loudspeaker | 5 | A loudspeaker. |
QBluetoothDeviceInfo::Headphones | 6 | Headphones. |
QBluetoothDeviceInfo::PortableAudioDevice | 7 | A portable audio device. |
QBluetoothDeviceInfo::CarAudio | 8 | A car audio device. |
QBluetoothDeviceInfo::SetTopBox | 9 | A settop box. |
QBluetoothDeviceInfo::HiFiAudioDevice | 10 | A HiFi audio device. |
QBluetoothDeviceInfo::Vcr | 11 | A video cassette recorder. |
QBluetoothDeviceInfo::VideoCamera | 12 | A video camera. |
QBluetoothDeviceInfo::Camcorder | 13 | A video camera. |
QBluetoothDeviceInfo::VideoMonitor | 14 | A video monitor. |
QBluetoothDeviceInfo::VideoDisplayAndLoudspeaker | 15 | A video display with built-in loudspeaker. |
QBluetoothDeviceInfo::VideoConferencing | 16 | A video conferencing device. |
QBluetoothDeviceInfo::GamingDevice | 18 | A gaming device. |
enum QBluetoothDeviceInfo::MinorComputerClass
This enum describes the minor device classes for computer devices.
| Constant | Value | Description |
|---|---|---|
QBluetoothDeviceInfo::UncategorizedComputer | 0 | An uncategorized computer device. |
QBluetoothDeviceInfo::DesktopComputer | 1 | A desktop computer. |
QBluetoothDeviceInfo::ServerComputer | 2 | A server computer. |
QBluetoothDeviceInfo::LaptopComputer | 3 | A laptop computer. |
QBluetoothDeviceInfo::HandheldClamShellComputer | 4 | A clamshell handheld computer or PDA. |
QBluetoothDeviceInfo::HandheldComputer | 5 | A handheld computer or PDA. |
QBluetoothDeviceInfo::WearableComputer | 6 | A wearable computer. |
enum QBluetoothDeviceInfo::MinorHealthClass
This enum describes the minor device classes for health devices.
| Constant | Value | Description |
|---|---|---|
QBluetoothDeviceInfo::UncategorizedHealthDevice | 0 | An uncategorized health device. |
QBluetoothDeviceInfo::HealthBloodPressureMonitor | 0x1 | A blood pressure monitor. |
QBluetoothDeviceInfo::HealthThermometer | 0x2 | A Thermometer. |
QBluetoothDeviceInfo::HealthWeightScale | 0x3 | A scale. |
QBluetoothDeviceInfo::HealthGlucoseMeter | 0x4 | A glucose meter. |
QBluetoothDeviceInfo::HealthPulseOximeter | 0x5 | A blood oxygen saturation meter. |
QBluetoothDeviceInfo::HealthDataDisplay | 0x7 | A data display. |
QBluetoothDeviceInfo::HealthStepCounter | 0x8 | A pedometer. |
enum QBluetoothDeviceInfo::MinorImagingClass
This enum describes the minor device classes for imaging devices.
| Constant | Value | Description |
|---|---|---|
QBluetoothDeviceInfo::UncategorizedImagingDevice | 0 | An uncategorized imaging device. |
QBluetoothDeviceInfo::ImageDisplay | 0x04 | A device capable of displaying images. |
QBluetoothDeviceInfo::ImageCamera | 0x08 | A camera. |
QBluetoothDeviceInfo::ImageScanner | 0x10 | An image scanner. |
QBluetoothDeviceInfo::ImagePrinter | 0x20 | A printer. |
enum QBluetoothDeviceInfo::MinorMiscellaneousClass
This enum describes the minor device classes for miscellaneous Bluetooth devices.
| Constant | Value | Description |
|---|---|---|
QBluetoothDeviceInfo::UncategorizedMiscellaneous | 0 | An uncategorized miscellaneous device. |
enum QBluetoothDeviceInfo::MinorNetworkClass
This enum describes the minor device classes for local area network access devices. Local area network access devices use the minor device class to specify the current network utilization.
| Constant | Value | Description |
|---|---|---|
QBluetoothDeviceInfo::NetworkFullService | 0x00 | 100% of the total bandwidth is available. |
QBluetoothDeviceInfo::NetworkLoadFactorOne | 0x08 | 0 - 17% of the total bandwidth is currently being used. |
QBluetoothDeviceInfo::NetworkLoadFactorTwo | 0x10 | 17 - 33% of the total bandwidth is currently being used. |
QBluetoothDeviceInfo::NetworkLoadFactorThree | 0x18 | 33 - 50% of the total bandwidth is currently being used. |
QBluetoothDeviceInfo::NetworkLoadFactorFour | 0x20 | 50 - 67% of the total bandwidth is currently being used. |
QBluetoothDeviceInfo::NetworkLoadFactorFive | 0x28 | 67 - 83% of the total bandwidth is currently being used. |
QBluetoothDeviceInfo::NetworkLoadFactorSix | 0x30 | 83 - 99% of the total bandwidth is currently being used. |
QBluetoothDeviceInfo::NetworkNoService | 0x38 | No network service available. |
enum QBluetoothDeviceInfo::MinorPeripheralClass
This enum describes the minor device classes for peripheral devices.
| Constant | Value | Description |
|---|---|---|
QBluetoothDeviceInfo::UncategorizedPeripheral | 0 | An uncategorized peripheral device. |
QBluetoothDeviceInfo::KeyboardPeripheral | 0x10 | A keyboard. |
QBluetoothDeviceInfo::PointingDevicePeripheral | 0x20 | A pointing device, for example a mouse. |
QBluetoothDeviceInfo::KeyboardWithPointingDevicePeripheral | 0x30 | A keyboard with built-in pointing device. |
QBluetoothDeviceInfo::JoystickPeripheral | 0x01 | A joystick. |
QBluetoothDeviceInfo::GamepadPeripheral | 0x02 | A game pad. |
QBluetoothDeviceInfo::RemoteControlPeripheral | 0x03 | A remote control. |
QBluetoothDeviceIn |