-
Notifications
You must be signed in to change notification settings - Fork 29
/
bluetooth.h
40 lines (32 loc) · 1.43 KB
/
bluetooth.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
/*
* bluetooth.h
*
* This file is part of the QtSixA, the Sixaxis Joystick Manager
* Copyright 2008-10 Filipe Coelho <[email protected]>
*
* QtSixA can be redistributed and/or modified under the terms of the GNU General
* Public License (Version 2), as published by the Free Software Foundation.
* A copy of the license is included in the QtSixA source code, or can be found
* online at www.gnu.org/licenses.
*
* QtSixA is distributed in the hope that it will be useful, but WITHOUT ANY
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
* A PARTICULAR PURPOSE. See the GNU General Public License for more details.
*
*/
#ifndef BLUETOOTH_H
#define BLUETOOTH_H
#include <bluetooth/bluetooth.h>
#include <bluetooth/l2cap.h>
#define L2CAP_PSM_HIDP_CTRL 0x11
#define L2CAP_PSM_HIDP_INTR 0x13
void do_search(int ctl, bdaddr_t *bdaddr, int debug);
void do_connect(int ctl, bdaddr_t *src, bdaddr_t *dst, int debug);
int l2cap_listen(const bdaddr_t *bdaddr, unsigned short psm, int lm, int backlog);
void l2cap_accept(int ctl, int csk, int isk, int debug, int legacy);
int l2cap_connect(bdaddr_t *src, bdaddr_t *dst, unsigned short psm);
void hid_server(int ctl, int csk, int isk, int debug, int legacy);
int create_device(int ctl, int csk, int isk);
int get_sdp_device_info(const bdaddr_t *src, const bdaddr_t *dst, struct hidp_connadd_req *req);
void epox_endian_quirk(unsigned char *data, int size);
#endif // BLUETOOTH_H