Tested with 
https://code.qt.io/cgit/qt/qtwebengine-chromium.git/tree/chromium/device/bluetooth/bluetooth_low_energy_defs_win.h?id=2d71c20d894b2d19ecbbd6b54901eb00e130253d
From c445be63e7e977c969581426057f3ba40c0a5e0a Mon Sep 17 00:00:00 2001
From: Biswapriyo Nath <nathbap...@gmail.com>
Date: Mon, 21 Aug 2023 20:21:45 +0530
Subject: [PATCH 2/2] headers: Add bluetoothleapis.h

Signed-off-by: Biswapriyo Nath <nathbap...@gmail.com>
---
 mingw-w64-headers/include/bluetoothleapis.h | 43 +++++++++++++++++++++
 1 file changed, 43 insertions(+)
 create mode 100644 mingw-w64-headers/include/bluetoothleapis.h

diff --git a/mingw-w64-headers/include/bluetoothleapis.h 
b/mingw-w64-headers/include/bluetoothleapis.h
new file mode 100644
index 0000000..d85e85e
--- /dev/null
+++ b/mingw-w64-headers/include/bluetoothleapis.h
@@ -0,0 +1,43 @@
+/**
+ * This file has no copyright assigned and is placed in the Public Domain.
+ * This file is part of the mingw-w64 runtime package.
+ * No warranty is given; refer to the file DISCLAIMER.PD within this package.
+ */
+
+#ifndef __BLUETOOTHLEAPIS_H__
+#define __BLUETOOTHLEAPIS_H__
+
+#include <winapifamily.h>
+#include <bthledef.h>
+
+#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
+
+#ifdef __cplusplus
+extern "C"{
+#endif
+
+#if NTDDI_VERSION >= NTDDI_WIN8
+
+HRESULT WINAPI BluetoothGATTGetServices(HANDLE hDevice, USHORT 
ServicesBufferCount, PBTH_LE_GATT_SERVICE ServicesBuffer, USHORT 
*ServicesBufferActual, ULONG Flags);
+HRESULT WINAPI BluetoothGATTGetIncludedServices(HANDLE hDevice, 
PBTH_LE_GATT_SERVICE ParentService, USHORT IncludedServicesBufferCount, 
PBTH_LE_GATT_SERVICE IncludedServicesBuffer, USHORT 
*IncludedServicesBufferActual, ULONG Flags);
+HRESULT WINAPI BluetoothGATTGetCharacteristics(HANDLE hDevice, 
PBTH_LE_GATT_SERVICE Service, USHORT CharacteristicsBufferCount, 
PBTH_LE_GATT_CHARACTERISTIC CharacteristicsBuffer, USHORT 
*CharacteristicsBufferActual, ULONG Flags);
+HRESULT WINAPI BluetoothGATTGetDescriptors(HANDLE hDevice, 
PBTH_LE_GATT_CHARACTERISTIC Characteristic, USHORT DescriptorsBufferCount, 
PBTH_LE_GATT_DESCRIPTOR DescriptorsBuffer, USHORT *DescriptorsBufferActual, 
ULONG Flags);
+HRESULT WINAPI BluetoothGATTGetCharacteristicValue(HANDLE hDevice, 
PBTH_LE_GATT_CHARACTERISTIC Characteristic, ULONG CharacteristicValueDataSize, 
PBTH_LE_GATT_CHARACTERISTIC_VALUE CharacteristicValue, USHORT 
*CharacteristicValueSizeRequired, ULONG Flags);
+HRESULT WINAPI BluetoothGATTGetDescriptorValue(HANDLE hDevice, 
PBTH_LE_GATT_DESCRIPTOR Descriptor, ULONG DescriptorValueDataSize, 
PBTH_LE_GATT_DESCRIPTOR_VALUE DescriptorValue, USHORT 
*DescriptorValueSizeRequired, ULONG Flags);
+HRESULT WINAPI BluetoothGATTBeginReliableWrite(HANDLE hDevice, 
PBTH_LE_GATT_RELIABLE_WRITE_CONTEXT ReliableWriteContext, ULONG Flags);
+HRESULT WINAPI BluetoothGATTSetCharacteristicValue(HANDLE hDevice, 
PBTH_LE_GATT_CHARACTERISTIC Characteristic, PBTH_LE_GATT_CHARACTERISTIC_VALUE 
CharacteristicValue, BTH_LE_GATT_RELIABLE_WRITE_CONTEXT ReliableWriteContext, 
ULONG Flags);
+HRESULT WINAPI BluetoothGATTEndReliableWrite(HANDLE hDevice, 
BTH_LE_GATT_RELIABLE_WRITE_CONTEXT ReliableWriteContext, ULONG Flags);
+HRESULT WINAPI BluetoothGATTAbortReliableWrite(HANDLE hDevice, 
BTH_LE_GATT_RELIABLE_WRITE_CONTEXT ReliableWriteContext, ULONG Flags);
+HRESULT WINAPI BluetoothGATTSetDescriptorValue(HANDLE hDevice, 
PBTH_LE_GATT_DESCRIPTOR Descriptor, PBTH_LE_GATT_DESCRIPTOR_VALUE 
DescriptorValue, ULONG Flags);
+HRESULT WINAPI BluetoothGATTRegisterEvent(HANDLE hService, 
BTH_LE_GATT_EVENT_TYPE EventType, PVOID EventParameterIn, 
PFNBLUETOOTH_GATT_EVENT_CALLBACK Callback, PVOID CallbackContext, 
BLUETOOTH_GATT_EVENT_HANDLE *pEventHandle, ULONG Flags);
+HRESULT WINAPI BluetoothGATTUnregisterEvent(BLUETOOTH_GATT_EVENT_HANDLE 
EventHandle, ULONG Flags);
+
+#endif /* NTDDI_WIN8 */
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */
+
+#endif /* __BLUETOOTHLEAPIS_H__ */
-- 
2.41.0

_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to