4 * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
6 * Contact: Hocheol Seo <hocheol.seo@samsung.com>
7 * Girishashok Joshi <girish.joshi@samsung.com>
8 * Chanyeol Park <chanyeol.park@samsung.com>
10 * Licensed under the Apache License, Version 2.0 (the "License");
11 * you may not use this file except in compliance with the License.
12 * You may obtain a copy of the License at
14 * http://www.apache.org/licenses/LICENSE-2.0
16 * Unless required by applicable law or agreed to in writing, software
17 * distributed under the License is distributed on an "AS IS" BASIS,
18 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19 * See the License for the specific language governing permissions and
20 * limitations under the License.
25 #ifndef _BT_SERVICE_DEVICE_H_
26 #define _BT_SERVICE_DEVICE_H_
29 #include <sys/types.h>
30 #include "bluetooth-api.h"
36 int _bt_bond_device(int request_id,
37 bluetooth_device_address_t *device_address,
38 unsigned short conn_type, GArray **out_param1);
40 int _bt_cancel_bonding(void);
42 int _bt_passkey_reply(const char *passkey, gboolean authentication_reply);
44 int _bt_passkey_confirmation_reply(gboolean confirmation_reply);
46 int _bt_unbond_device(int request_id,
47 bluetooth_device_address_t *device_address,
50 int _bt_cancel_search_device(void);
52 int _bt_search_device(int request_id,
53 bluetooth_device_address_t *device_address);
55 int _bt_set_alias(bluetooth_device_address_t *device_address,
58 int _bt_set_authorization(bluetooth_device_address_t *device_address,
61 int _bt_is_gatt_connected(bluetooth_device_address_t *device_address,
62 gboolean *is_connected);
64 int _bt_is_device_connected(bluetooth_device_address_t *device_address,
65 int connection_type, gboolean *is_connected);
67 int _bt_get_connected_link(bluetooth_device_address_t *device_address,
68 bluetooth_connected_link_t *connected);
70 int _bt_set_pin_code(bluetooth_device_address_t *device_address,
71 bluetooth_device_pin_code_t *pin_code);
73 int _bt_unset_pin_code(bluetooth_device_address_t *device_address);
75 int _bt_get_device_pin_code(const char *address, char *pin_code);
77 gboolean _bt_is_device_creating(void);
79 void _bt_set_autopair_status_in_bonding_info(gboolean is_autopair);
81 bt_remote_dev_info_t *_bt_get_remote_device_info(char *address);
83 char *_bt_get_bonded_device_name(char *address);
85 gboolean _bt_is_bonding_device_address(const char *address);
87 int _bt_connect_le_device(int request_id,
88 const bluetooth_device_address_t *bd_addr,
89 gboolean auto_connect);
91 int _bt_disconnect_le_device(int request_id,
92 const bluetooth_device_address_t *bd_addr);
94 int _bt_le_conn_update(unsigned char *device_address,
95 guint16 interval_min, guint16 interval_max,
96 guint16 latency, guint16 time_out);
98 int _bt_get_le_connection_parameter(bluetooth_le_connection_mode_t mode,
99 bluetooth_le_connection_param_t *param);
101 int _bt_connect_profile(char *address, char *uuid,
102 void *cb, gpointer func_data);
104 int _bt_disconnect_profile(char *address, char *uuid,
105 void *cb, gpointer func_data);
106 int _bt_connect_le_ipsp_device(const bluetooth_device_address_t *bd_addr);
108 int _bt_disconnect_le_ipsp_device(const bluetooth_device_address_t *bd_addr);
113 #endif /* __cplusplus */
114 #endif /*_BT_SERVICE_ADAPTER_H_*/