天嵌二次封装库使用手册  V1.0
sco.h
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 /*
3  *
4  * BlueZ - Bluetooth protocol stack for Linux
5  *
6  * Copyright (C) 2002-2003 Maxim Krasnyansky <maxk@qualcomm.com>
7  * Copyright (C) 2002-2010 Marcel Holtmann <marcel@holtmann.org>
8  *
9  *
10  */
11 
12 #ifndef __SCO_H
13 #define __SCO_H
14 
15 #ifdef __cplusplus
16 extern "C" {
17 #endif
18 
19 /* SCO defaults */
20 #define SCO_DEFAULT_MTU 500
21 #define SCO_DEFAULT_FLUSH_TO 0xFFFF
22 
23 #define SCO_CONN_TIMEOUT (HZ * 40)
24 #define SCO_DISCONN_TIMEOUT (HZ * 2)
25 #define SCO_CONN_IDLE_TIMEOUT (HZ * 60)
26 
27 /* SCO socket address */
28 struct sockaddr_sco {
29  sa_family_t sco_family;
30  bdaddr_t sco_bdaddr;
31 };
32 
33 /* set/get sockopt defines */
34 #define SCO_OPTIONS 0x01
35 struct sco_options {
36  uint16_t mtu;
37 };
38 
39 #define SCO_CONNINFO 0x02
40 struct sco_conninfo {
41  uint16_t hci_handle;
42  uint8_t dev_class[3];
43 };
44 
45 #ifdef __cplusplus
46 }
47 #endif
48 
49 #endif /* __SCO_H */
Definition: sco.h:35
Definition: sco.h:28
Definition: sco.h:40