3 * BlueZ - Bluetooth protocol stack for Linux
5 * Copyright (C) 2011-2012 Intel Corporation
6 * Copyright (C) 2004-2010 Marcel Holtmann <marcel@holtmann.org>
9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Lesser General Public
11 * License as published by the Free Software Foundation; either
12 * version 2.1 of the License, or (at your option) any later version.
14 * This library is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 * Lesser General Public License for more details.
19 * You should have received a copy of the GNU Lesser General Public
20 * License along with this library; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
30 struct bt_phy *bt_phy_new(void);
32 struct bt_phy *bt_phy_ref(struct bt_phy *phy);
33 void bt_phy_unref(struct bt_phy *phy);
35 bool bt_phy_send(struct bt_phy *phy, uint16_t type,
36 const void *data, size_t size);
37 bool bt_phy_send_vector(struct bt_phy *phy, uint16_t type,
38 const void *data1, size_t size1,
39 const void *data2, size_t size2,
40 const void *data3, size_t size3);
42 typedef void (*bt_phy_callback_func_t)(uint16_t type, const void *data,
43 size_t size, void *user_data);
45 bool bt_phy_register(struct bt_phy *phy, bt_phy_callback_func_t callback,
48 #define BT_PHY_PKT_NULL 0x0000
50 #define BT_PHY_PKT_ADV 0x0001
51 struct bt_phy_pkt_adv {
59 } __attribute__ ((packed));
61 #define BT_PHY_PKT_CONN 0x0002
62 struct bt_phy_pkt_conn {
70 } __attribute__ ((packed));