* Fwd: Help with LE Create Connection
[not found] <CAGuV3hPxvhDbsO1TZLcQwtQuAWrm5TqQrH=zG3UrFsvjfZOeFA@mail.gmail.com>
@ 2018-04-21 2:01 ` Fulko Hew
2018-04-23 17:02 ` Marcel Holtmann
0 siblings, 1 reply; 2+ messages in thread
From: Fulko Hew @ 2018-04-21 2:01 UTC (permalink / raw)
To: linux-bluetooth
I'm doing my first Bluetooth app, and I have a specific question and a
general question:
1/ Where can I find documentation on the BlueZ API?
I've searched and haven't found anything yet.
2/ I've captured a trace of an existing conversation off of my Android phone,
and I'm trying to re-create it via my own app using BlueZ.
I've gotten to the point of trying to do an LE Create Connection
via hci_le_create_conn()
and my first stumbling block is the value of the 'peer address type'.
From my investigation, I need to use the 'public' address type
which according to
the spec, and Wireshark is a value of 0x00, but bluetooth.h defines
'public' as 0x01
(as per the following extract). Can anyone explain it to me?
#define BDADDR_BREDR 0x00
#define BDADDR_LE_PUBLIC 0x01
#define BDADDR_LE_RANDOM 0x02
TIA
Fulko
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Help with LE Create Connection
2018-04-21 2:01 ` Fwd: Help with LE Create Connection Fulko Hew
@ 2018-04-23 17:02 ` Marcel Holtmann
0 siblings, 0 replies; 2+ messages in thread
From: Marcel Holtmann @ 2018-04-23 17:02 UTC (permalink / raw)
To: Fulko Hew; +Cc: linux-bluetooth
Hi Fulko,
> I'm doing my first Bluetooth app, and I have a specific question and a
> general question:
>
> 1/ Where can I find documentation on the BlueZ API?
> I've searched and haven't found anything yet.
>
> 2/ I've captured a trace of an existing conversation off of my Android phone,
> and I'm trying to re-create it via my own app using BlueZ.
> I've gotten to the point of trying to do an LE Create Connection
> via hci_le_create_conn()
> and my first stumbling block is the value of the 'peer address type'.
> From my investigation, I need to use the 'public' address type
> which according to
> the spec, and Wireshark is a value of 0x00, but bluetooth.h defines
> 'public' as 0x01
> (as per the following extract). Can anyone explain it to me?
>
> #define BDADDR_BREDR 0x00
> #define BDADDR_LE_PUBLIC 0x01
> #define BDADDR_LE_RANDOM 0x02
why not use the bluetoothd D-Bus GATT APIs for your application. It will create all needed connections. Manually doing HCI is the wrong approach since that is owned by the kernel.
Regards
Marcel
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-04-23 17:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <CAGuV3hPxvhDbsO1TZLcQwtQuAWrm5TqQrH=zG3UrFsvjfZOeFA@mail.gmail.com>
2018-04-21 2:01 ` Fwd: Help with LE Create Connection Fulko Hew
2018-04-23 17:02 ` Marcel Holtmann
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.