xref: /btstack/port/qt-h4/README.md (revision 01f72e3df45a7cedc261ee0c559b7ee1149f5d69)
1# BTstack Port for QT with H4 Bluetooth Controller
2
3Uses libusb Library on macOS and Linux and WinUSB on Windows.
4Windows is supported with the MinGW Kit.
5
6Windows with MSVC or Embedded (bare metal) platforms not supported yet.
7
8## Configuration
9
10Most Bluetooth Bluetooth Controllers connected via UART/H4 require some special configuration, e.g. to set the UART baud rate, and/or require firmware patches during startup. In this port, we've tried to do most of these automatically based on information gathered from the Bluetooth Controller. Here's some Controller specific details:
11
12## TI CC256x
13The CC2564x needs the correct init script to start up. The Makfile already has entries for most silicon revisions:
14
15- CC2560:  bluetooth_init_cc2564_2.14.c
16- CC2564B: bluetooth_init_cc2564B_1.8_BT_Spec_4.1.c
17- CC2564C: bluetooth_init_cc2564C_1.5.c
18
19Please pick the correct one. The main.c verifies that the correct script is loaded, but the init script is linked to the executable.
20
21## Broadcom BCM/CYW 43430
22
23The correct firmware file needs to be provided in the current working directory. The Makefile downloads the one for the BCM43430 e.g. found on later Raspberry Pi editions. Please see the separate port/raspi, too.
24
25## Compilation
26
27On all platforms, you'll need Qt Python 3 installed.
28On macOS/Linux [libusb-1.0](http://libusb.info) or higher is required, too.
29
30When everything is ready, you can open the provided CMakelists.txt project in Qt Creator and run any of the provided examples.
31See Qt documentation on how to compile on the command line or with other IDEs
32
33
34## Running the examples
35
36BTstack's HCI USB transport will try to find a suitable Bluetooth module and use it.
37
38On start, BTstack will try to find a suitable Bluetooth module. It will also print the path to the packet log as well as the USB path.
39
40	$ ./le_counter
41	Packet Log: /tmp/hci_dump.pklg
42	BTstack counter 0001
43	USB Path: 06
44	BTstack up and running on 00:1A:7D:DA:71:13.
45
46