2 * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the License);
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an AS IS BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
18 #ifndef __TIZEN_NETWORK_BLUETOOTH_INTERNAL_H__
19 #define __TIZEN_NETWORK_BLUETOOTH_INTERNAL_H__
22 #include "bluetooth_type.h"
23 #include "bluetooth_type_internal.h"
25 #ifndef TIZEN_DEPRECATED_API
26 #define TIZEN_DEPRECATED_API __attribute__((__visibility__("default"), deprecated))
32 #endif /* __cplusplus */
35 * @file bluetooth_internal.h
40 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
41 * @brief Enables the local Bluetooth adapter, asynchronously.
42 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
44 * @privilege %http://tizen.org/privilege/bluetooth.admin
46 * @details This function enables Bluetooth protocol stack and hardware.
48 * @return 0 on success, otherwise a negative error value.
49 * @retval #BT_ERROR_NONE Successful
50 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
51 * @retval #BT_ERROR_ALREADY_DONE Already enabled
52 * @retval #BT_ERROR_NOW_IN_PROGRESS Operation now in progress
53 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
54 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
56 * @pre Bluetooth service must be initialized with bt_initialize().
57 * @pre The state of local Bluetooth must be #BT_ADAPTER_DISABLED
58 * @post This function invokes bt_adapter_state_changed_cb().
60 * @see bt_initialize()
61 * @see bt_adapter_get_state()
62 * @see bt_adapter_set_state_changed_cb()
63 * @see bt_adapter_unset_state_changed_cb()
64 * @see bt_adapter_state_changed_cb()
67 int bt_adapter_enable(void);
71 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
72 * @brief Synchronously provides details about bluetooth usage
75 * @privilege %http://tizen.org/privilege/bluetooth.admin
77 * @details This function provides details such as session start time, session end time as well as total scan time and total connected time in a session
79 * @remarks An pointer of type bt_battery_info_s must be passed as argument which will contain the relevant information as the function returns.
81 * @return 0 on success, otherwise a negative error value.
82 * @retval #BT_ERROR_NONE Successful
83 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
84 * @retval #BT_ERROR_NOT_ENABLED Not enabled
85 * @retval #BT_ERROR_NOW_IN_PROGRESS Operation now in progress
86 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
87 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
89 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED
93 int bt_adapter_read_battery_info(bt_battery_info_s *data);
97 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
98 * @brief Disables the local Bluetooth adapter, asynchronously.
99 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
100 * @privlevel platform
101 * @privilege %http://tizen.org/privilege/bluetooth.admin
103 * @details This function disables Bluetooth protocol stack and hardware.
105 * @remarks You should disable Bluetooth adapter, which is helpful for saving power.
107 * @return 0 on success, otherwise a negative error value.
108 * @retval #BT_ERROR_NONE Successful
109 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
110 * @retval #BT_ERROR_NOT_ENABLED Not enabled
111 * @retval #BT_ERROR_NOW_IN_PROGRESS Operation now in progress
112 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
113 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
115 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED
116 * @post This function invokes bt_adapter_state_changed_cb().
118 * @see bt_adapter_get_state()
119 * @see bt_adapter_state_changed_cb()
120 * @see bt_adapter_set_state_changed_cb()
121 * @see bt_adapter_unset_state_changed_cb ()
124 int bt_adapter_disable(void);
127 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
128 * @brief Initializes and activates battery monitor
131 * @param[in] callback Address of callback function
132 * @param[in] user_data user
134 * @pre This function will initialize and activate the battery monitor feature.
135 * It sets a callback function that will be called when bluetooth adapter
138 * @see *bt_adapter_disable_battery_cb
140 int bt_adapter_init_battery_monitor(bt_adapter_disable_battery_cb callback,
144 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
145 * @brief Deinitializes and disables battery monitor.
148 * @pre This function will disable the battery monitor feature
149 * and unset the related callback function
151 * @see bt_adapter_init_battery_monitor
152 * @see *bt_adapter_disable_battery_cb
154 int bt_adapter_deinit_battery_monitor();
158 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
159 * @brief Recover the local Bluetooth adapter, asynchronously.
160 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
161 * @privlevel platform
162 * @privilege %http://tizen.org/privilege/bluetooth.admin
164 * @details This function does recovery logic, disables Bluetooth protocol stack and hardware, then enables after a few seconds.
166 * @return 0 on success, otherwise a negative error value.
167 * @retval #BT_ERROR_NONE Successful
168 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
169 * @retval #BT_ERROR_NOT_ENABLED Not enabled
170 * @retval #BT_ERROR_NOW_IN_PROGRESS Operation now in progress
171 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
172 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
174 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED
175 * @post This function invokes bt_adapter_state_changed_cb().
177 * @see bt_adapter_get_state()
178 * @see bt_adapter_state_changed_cb()
179 * @see bt_adapter_set_state_changed_cb()
180 * @see bt_adapter_unset_state_changed_cb ()
183 int bt_adapter_recover(void);
186 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE
187 * @brief A2DP source/sink role is switched using this API
189 * @param[in] Role for A2DP
190 * @return @c 0 on success,
191 * otherwise a negative error value
192 * @retval #BT_ERROR_NONE Successful
193 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
194 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
195 * @retval #BT_ERROR_OPERATION_FAILED Internal Error
196 * @pre The Bluetooth service must be initialized with bt_initialize().
197 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
198 * @see bt_initialize()
199 * @see bt_audio_initialize()
201 int bt_audio_select_role(bt_audio_role_e role);
204 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE
205 * @brief Absolute Volume of the remote headset is set using this API
207 * @param[in] The absolute volume of the remote headset (0 ~ 150)
208 * @return @c 0 on success,
209 * otherwise a negative error value
210 * @retval #BT_ERROR_NONE Successful
211 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
212 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
213 * @retval #BT_ERROR_NOT_ENABLED Not enabled
214 * @retval #BT_ERROR_OPERATION_FAILED Internal Error
215 * @pre The Bluetooth service must be initialized with bt_initialize().
216 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
217 * @see bt_initialize()
218 * @see bt_audio_initialize()
220 int bt_audio_set_absolute_volume(unsigned int volume);
223 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE
224 * @brief Get Absolute Volume of the remote headset using this API
226 * @param[out] The absolute volume of the remote headset (0 ~ 150)
227 * @return @c 0 on success,
228 * otherwise a negative error value
229 * @retval #BT_ERROR_NONE Successful
230 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
231 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
232 * @retval #BT_ERROR_NOT_ENABLED Not enabled
233 * @retval #BT_ERROR_OPERATION_FAILED Internal Error
234 * @pre The Bluetooth service must be initialized with bt_initialize().
235 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
236 * @see bt_initialize()
237 * @see bt_audio_initialize()
239 int bt_audio_get_absolute_volume(unsigned int *volume);
242 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE
243 * @brief Registers a callback function that will be invoked when the volume is changed.
245 * @param[in] callback The callback function to register
246 * @param[in] user_data The user data to be passed to the callback function
247 * @return 0 on success, otherwise a negative error value.
248 * @retval #BT_ERROR_NONE Successful
249 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
250 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
251 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
252 * @pre The Bluetooth service must be initialized with bt_initialize().
253 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
254 * @see bt_initialize()
255 * @see bt_audio_initialize()
257 int bt_audio_set_absolute_volume_changed_cb(bt_audio_absolute_volume_changed_cb callback, void *user_data);
260 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE
261 * @brief Unregisters a callback function that will be invoked when the volume is changed.
263 * @return 0 on success, otherwise a negative error value.
264 * @retval #BT_ERROR_NONE Successful
265 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
266 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
268 * @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize().
269 * @pre The Bluetooth service must be initialized with bt_initialize().
270 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
271 * @see bt_initialize()
272 * @see bt_audio_initialize()
274 int bt_audio_unset_absolute_volume_changed_cb(void);
277 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE
278 * @brief Get Absolute Volume Control status using this API
280 * @param[out] Activated infomation
281 * @return @c 0 on success,
282 * otherwise a negative error value
283 * @retval #BT_ERROR_NONE Successful
284 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
285 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
286 * @retval #BT_ERROR_OPERATION_FAILED Internal Error
287 * @pre The Bluetooth service must be initialized with bt_initialize().
288 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
289 * @see bt_initialize()
290 * @see bt_audio_initialize()
292 int bt_audio_is_avc_activated(bool *activated);
295 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE
296 * @brief Registers a callback function that will be invoked when the absolute volume control status is changed.
298 * @param[in] callback The callback function to register
299 * @param[in] user_data The user data to be passed to the callback function
300 * @return 0 on success, otherwise a negative error value.
301 * @retval #BT_ERROR_NONE Successful
302 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
303 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
304 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
305 * @pre The Bluetooth service must be initialized with bt_initialize().
306 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
307 * @see bt_initialize()
308 * @see bt_audio_initialize()
310 int bt_audio_set_avc_status_changed_cb(bt_audio_avc_status_changed_cb callback, void *user_data);
313 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE
314 * @brief Unregisters a callback function that will be invoked when the absolute volume control status is changed.
316 * @return 0 on success, otherwise a negative error value.
317 * @retval #BT_ERROR_NONE Successful
318 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
319 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
320 * @pre The Bluetooth service must be initialized with bt_initialize().
321 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
322 * @see bt_initialize()
323 * @see bt_audio_initialize()
325 int bt_audio_unset_avc_status_changed_cb(void);
329 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
330 * @brief Reset the local Bluetooth adapter, synchronously.
331 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
332 * @privlevel platform
333 * @privilege %http://tizen.org/privilege/bluetooth.admin
335 * @details This function resets Bluetooth protocol and values.
337 * @return 0 on success, otherwise a negative error value.
338 * @retval #BT_ERROR_NONE Successful
339 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
340 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
341 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
342 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
344 * @pre Bluetooth service must be initialized with bt_initialize().
345 * @post bt_adapter_state_changed_cb() will be invoked if The state of local Bluetooth was #BT_ADAPTER_ENABLED.
347 * @see bt_initialize()
348 * @see bt_adapter_get_state()
349 * @see bt_adapter_set_state_changed_cb()
350 * @see bt_adapter_unset_state_changed_cb()
351 * @see bt_adapter_state_changed_cb()
354 int bt_adapter_reset(void);
358 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
359 * @brief Gets the version of local Bluetooth adapter.
360 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
361 * @remarks The @a local_version must be released with free() by you.
363 * @param[out] local_version The version of local Bluetooth adapter
365 * @return 0 on success, otherwise a negative error value.
366 * @retval #BT_ERROR_NONE Successful
367 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
368 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
369 * @retval #BT_ERROR_NOT_ENABLED Not enabled
370 * @retval #BT_ERROR_OUT_OF_MEMORY Out of memory
371 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
372 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
374 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
376 int bt_adapter_get_version(char **local_version);
380 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
381 * @brief Gets the information regarding local Bluetooth adapter.
382 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
383 * @remarks The @a all parameters must be released with free() by you.
385 * @param[out] chipset Chipset name of local Bluetooth adapter
386 * @param[out] firmware Firmware info. of local Bluetooth adapter
387 * @param[out] stack_version Bluetooth stack version
388 * @param[out] profiles The profile list of local Bluetooth adapter
390 * @return 0 on success, otherwise a negative error value.
391 * @retval #BT_ERROR_NONE Successful
392 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
393 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
394 * @retval #BT_ERROR_NOT_ENABLED Not enabled
395 * @retval #BT_ERROR_OUT_OF_MEMORY Out of memory
396 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
397 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
399 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
401 int bt_adapter_get_local_info(char **chipset, char **firmware, char **stack_version, char **profiles);
405 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
406 * @brief Sets the visibility mode.
407 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
408 * @privlevel platform
409 * @privilege %http://tizen.org/privilege/bluetooth.admin
411 * @remarks #BT_ADAPTER_VISIBILITY_MODE_LIMITED_DISCOVERABLE will change to #BT_ADAPTER_VISIBILITY_MODE_NON_DISCOVERABLE
412 * after the given @a duration goes.
414 * @param[in] discoverable_mode The Bluetooth visibility mode to set
415 * @param[in] duration The duration until the visibility mode is changed to #BT_ADAPTER_VISIBILITY_MODE_NON_DISCOVERABLE (in seconds).
416 * @a duration is used only for #BT_ADAPTER_VISIBILITY_MODE_LIMITED_DISCOVERABLE mode.
418 * @return 0 on success, otherwise a negative error value.
419 * @retval #BT_ERROR_NONE Successful
420 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
421 * @retval #BT_ERROR_NOT_ENABLED Not enabled
422 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
423 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
424 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
425 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
427 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
428 * @post bt_adapter_visibility_mode_changed_cb() will be invoked if this function returns #BT_ERROR_NONE.
430 * @see bt_adapter_get_visibility()
431 * @see bt_adapter_visibility_mode_changed_cb()
432 * @see bt_adapter_set_visibility_mode_changed_cb()
433 * @see bt_adapter_unset_visibility_mode_changed_cb()
435 int bt_adapter_set_visibility(bt_adapter_visibility_mode_e discoverable_mode, int duration);
438 * @deprecated Deprecated since 5.5
439 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
440 * @brief Registers a callback function that will be invoked when remote device requests authentication.
441 * @return 0 on success, otherwise a negative error value.
442 * @retval #BT_ERROR_NONE Successful
443 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
444 * @pre The Bluetooth service must be initialized by bt_initialize().
445 * @param[in] callback callback function to be set when a request is received.
446 * @param[in] user_data data from application which will be provided in callback.
447 * @retval #BT_ERROR_NONE Successful
448 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
449 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
450 * @see bt_initialize()
451 * @see bt_adapter_set_authentication_req_cb()
453 int bt_adapter_set_authentication_req_cb(bt_adapter_authentication_req_cb callback, void *user_data);
457 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
458 * @brief Registers a callback with a incoming parameter to describe direction of pairing request that will be invoked when remote device requests authentication.
459 * @return 0 on success, otherwise a negative error value.
460 * @retval #BT_ERROR_NONE Successful
461 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
462 * @pre The Bluetooth service must be initialized by bt_initialize().
463 * @param[in] callback callback function to be set when a request is received.
464 * @param[in] user_data data from application which will be provided in callback.
465 * @retval #BT_ERROR_NONE Successful
466 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
467 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
468 * @see bt_initialize()
469 * @see bt_adapter_authentication_request_cb()
472 int bt_adapter_set_authentication_request_cb(bt_adapter_authentication_request_cb callback, void *user_data);
475 * @deprecated Deprecated since 5.5
476 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
477 * @brief Unregisters a callback function that will be invoked when remote device requests authentication.
478 * @return 0 on success, otherwise a negative error value.
479 * @retval #BT_ERROR_NONE Successful
480 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
481 * @pre The Bluetooth service must be initialized by bt_initialize().
482 * @see bt_initialize()
483 * @see bt_adapter_set_authentication_req_cb()
485 int bt_adapter_unset_authentication_req_cb(void);
489 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
490 * @brief Unregisters a callback function with incoming parameter that will be invoked when remote device requests authentication.
491 * @return 0 on success, otherwise a negative error value.
492 * @retval #BT_ERROR_NONE Successful
493 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
494 * @pre The Bluetooth service must be initialized by bt_initialize().
495 * @see bt_initialize()
496 * @see bt_adapter_set_authentication_request_cb()
499 int bt_adapter_unset_authentication_request_cb(void);
503 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
504 * @brief API to reply with PIN or PASSKEY with authentication type - TRUE or FALSE.
505 * @remarks This function can be called by application when remote device requests PIN or PASSKEY from
507 * @param[in] passkey The passkey to be provided by application when remote devices requests for it.
508 * @param[in] authentication_reply This indicates whether application wants to accept or cancel the on-going pairing
509 * @pre This function can only be called when application receieves authentication event (BT_AUTH_PIN_REQUEST)
510 * from remote device.
511 * @see bt_adapter_set_authentication_req_cb()
513 int bt_adapter_passkey_reply(char *passkey, bool authentication_reply);
516 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
517 * @brief API to reply to the PASSKEY confirmation for on-going pairing with remote device.
518 * @remarks This function can be called by application, when local adapter wants PASSKEY confirmation from user.
519 * @param[in] confirmation_reply This indicates whether application wants to accepts or cancels the on-going pairing
520 * confirmation_reply : TRUE will indicate that Application has confirmed the PASSKEY
521 * confirmation_reply : FALSE will indicate that Application has failed to confirm the PASSKEY. In this situation
522 * the pairing will be failed.
523 * @pre This function can only be called when application receives authentication event (BT_AUTH_PASSKEY_CONFIRM_REQUEST)
524 * from remote device.
525 * @see bt_adapter_set_authentication_req_cb()
527 int bt_adapter_passkey_confirmation_reply(bool confirmation_reply);
531 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
532 * @brief Registers a callback function to be invoked when the connectable state changes.
533 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
535 * @param[in] callback The callback function to register
536 * @param[in] user_data The user data to be passed to the callback function
538 * @return 0 on success, otherwise a negative error value.
539 * @retval #BT_ERROR_NONE Successful
540 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
541 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
542 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
544 * @pre The Bluetooth service must be initialized with bt_initialize().
545 * @post bt_adapter_connectable_changed_cb() will be invoked.
547 * @see bt_initialize()
548 * @see bt_adapter_connectable_changed_cb()
549 * @see bt_adapter_unset_connectable_changed_cb()
551 int bt_adapter_set_connectable_changed_cb(bt_adapter_connectable_changed_cb callback, void *user_data);
555 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
556 * @brief Unregisters the callback function.
557 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
559 * @return 0 on success, otherwise a negative error value.
560 * @retval #BT_ERROR_NONE Successful
561 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
562 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
564 * @pre The Bluetooth service must be initialized with bt_initialize().
566 * @see bt_initialize()
567 * @see bt_adapter_set_connectable_changed_cb()
569 int bt_adapter_unset_connectable_changed_cb(void);
573 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
574 * @brief Gets the connectable state of local Bluetooth adapter.
575 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
577 * @remarks When connectable state is false, no device can connect to this device and visibility mode cannot be changed.
579 * @param[out] connectable The connectable state of local Bluetooth adapter
581 * @return 0 on success, otherwise a negative error value.
582 * @retval #BT_ERROR_NONE Successful
583 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
584 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
585 * @retval #BT_ERROR_NOT_ENABLED Not enabled
586 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
587 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
589 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
591 * @see bt_adapter_set_connectable()
593 int bt_adapter_get_connectable(bool *connectable);
597 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
598 * @brief Sets the connectable state of local Bluetooth adapter.
599 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
600 * @privlevel platform
601 * @privilege %http://tizen.org/privilege/bluetooth.admin
603 * @remarks When connectable state is false, no device can connect to this device and visibility mode cannot be changed.
605 * @param[in] connectable The connectable state to set
607 * @return 0 on success, otherwise a negative error value.
608 * @retval #BT_ERROR_NONE Successful
609 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
610 * @retval #BT_ERROR_NOT_ENABLED Not enabled
611 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
612 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
613 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
615 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
616 * @post bt_adapter_connectable_changed_cb() will be invoked if this function returns #BT_ERROR_NONE.
618 * @see bt_adapter_get_connectable()
619 * @see bt_adapter_connectable_changed_cb()
620 * @see bt_adapter_set_connectable_changed_cb()
621 * @see bt_adapter_unset_connectable_changed_cb()
623 int bt_adapter_set_connectable(bool connectable);
627 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
628 * @brief Sets the manufacturer data of local Bluetooth adapter.
630 * @privlevel platform
631 * @privilege %http://tizen.org/privilege/bluetooth.admin
633 * @param[in] data The manufacturer specific data of the Bluetooth device.
634 * @param[in] len The length of @a data.Maximaum length is 240 bytes.
636 * @return 0 on success, otherwise a negative error value.
637 * @retval #BT_ERROR_NONE Successful
638 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
639 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
640 * @retval #BT_ERROR_NOT_ENABLED Not enabled
641 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
642 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
643 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
645 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
646 * @post bt_adapter_manufacturer_data_changed_cb() will be invoked
647 * if this function returns #BT_ERROR_NONE.
649 * @see bt_adapter_manufacturer_data_changed_cb
650 * @see bt_adapter_set_manufacturer_data_changed_cb()
651 * @see bt_adapter_unset_manufacturer_data_changed_cb()
653 int bt_adapter_set_manufacturer_data(char *data, int len);
656 * @brief Checks scan filter feature is supported or not.
657 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
659 * @param[out] is_supported The Scan Filter feature support: (@c true = supported , @c false = not supported)
661 * @return 0 on success, otherwise a negative error value.
662 * @retval #BT_ERROR_NONE Successful
663 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
664 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
665 * @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled
666 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
667 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
669 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
671 int bt_adapter_le_is_scan_filter_supported(bool *is_supported);
675 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
676 * @brief Parse the samsung specific manufacturer data of discovered device.
678 * @remarks bt_adapter_free_manufacturer_data should be invoked
679 * to free the memory associated with parsed data
681 * @param[in] manufacturer_data The manufacturer specific data of the discovered Bluetooth device.
682 * @param[in] len length of the received manufacturer data
683 * @param[out] data Parsed manufacturer data
685 * @return 0 on success, otherwise a negative error value.
686 * @retval #BT_ERROR_NONE Successful
687 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
688 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
689 * @retval #BT_ERROR_NOT_ENABLED Not enabled
691 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
693 * @see bt_adapter_free_manufacturer_data()
695 int bt_adapter_parse_manufacturer_data(bt_manufacturer_data *data,
696 char *manufacturer_data, int manufacturer_data_len);
700 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
701 * @brief Free the memory associated with parsed manufacturer data
703 * @param[in] data parsed manufactrer data
705 * @return 0 on success, otherwise a negative error value.
706 * @retval #BT_ERROR_NONE Successful
707 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
710 * @see bt_adapter_parse_manufacturer_data()
712 int bt_adapter_free_manufacturer_data(bt_manufacturer_data *data);
716 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
717 * @brief Registers a callback function to be invoked
718 * when the manufacturer data of Bluetooth adapter changes.
721 * @param[in] callback The callback function to invoke
722 * @param[in] user_data The user data to be passed to the callback function
724 * @return 0 on success, otherwise a negative error value.
725 * @retval #BT_ERROR_NONE Successful
726 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
727 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
728 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
730 * @pre The Bluetooth service must be initialized with bt_initialize().
731 * @post bt_adapter_manufacturer_data_changed_cb() will be invoked.
733 * @see bt_initialize()
734 * @see bt_adapter_unset_manufacturer_data_changed_cb()
736 int bt_adapter_set_manufacturer_data_changed_cb(
737 bt_adapter_manufacturer_data_changed_cb callback,
742 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
743 * @brief Unregisters the callback function.
746 * @return 0 on success, otherwise a negative error value.
747 * @retval #BT_ERROR_NONE Successful
748 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
749 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
751 * @pre The Bluetooth service must be initialized with bt_initialize().
753 * @see bt_initialize()
754 * @see bt_adapter_set_manufacturer_data_changed_cb()
756 int bt_adapter_unset_manufacturer_data_changed_cb(void);
760 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
761 * @brief Enables the local Bluetooth le adapter, asynchronously.
762 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
763 * @privlevel platform
764 * @privilege %http://tizen.org/privilege/bluetooth.admin
766 * @details This function enables Bluetooth protocol stack and hardware.
768 * @return 0 on success, otherwise a negative error value.
769 * @retval #BT_ERROR_NONE Successful
770 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
771 * @retval #BT_ERROR_ALREADY_DONE Already enabled
772 * @retval #BT_ERROR_NOW_IN_PROGRESS Operation now in progress
773 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
774 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
776 * @pre Bluetooth service must be initialized with bt_initialize().
777 * @post This function invokes bt_adapter_le_state_changed_cb().
779 * @see bt_initialize()
780 * @see bt_adapter_le_get_state()
781 * @see bt_adapter_le_set_state_changed_cb()
782 * @see bt_adapter_le_unset_state_changed_cb()
783 * @see bt_adapter_le_state_changed_cb()
786 int bt_adapter_le_enable(void);
790 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
791 * @brief Disables the local Bluetooth le adapter, asynchronously.
792 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
793 * @privlevel platform
794 * @privilege %http://tizen.org/privilege/bluetooth.admin
796 * @details This function disables Bluetooth le protocol stack and hardware.
800 * @return 0 on success, otherwise a negative error value.
801 * @retval #BT_ERROR_NONE Successful
802 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
803 * @retval #BT_ERROR_NOT_ENABLED Not enabled
804 * @retval #BT_ERROR_NOW_IN_PROGRESS Operation now in progress
805 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
806 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
808 * @pre The state of local Bluetooth must be #BT_ADAPTER_LE_ENABLED
809 * @post This function invokes bt_adapter_le_state_changed_cb().
811 * @see bt_adapter_le_get_state()
812 * @see bt_adapter_le_state_changed_cb()
813 * @see bt_adapter_le_set_state_changed_cb()
814 * @see bt_adapter_le_unset_state_changed_cb ()
817 int bt_adapter_le_disable(void);
821 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
822 * @brief Gets the current state of local Bluetooth adapter.
823 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
825 * @param[out] adapter_le_state The current adapter le state
827 * @return 0 on success, otherwise a negative error value.
828 * @retval #BT_ERROR_NONE Successful
829 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
830 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
831 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
833 * @pre Bluetooth service must be initialized with bt_initialize().
835 * @see bt_initialize()
837 int bt_adapter_le_get_state(bt_adapter_le_state_e *adapter_le_state);
841 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
842 * @brief Registers a callback function to be invoked when the Bluetooth adapter le state changes.
843 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
845 * @param[in] callback The callback function to invoke
846 * @param[in] user_data The user data to be passed to the callback function
848 * @return 0 on success, otherwise a negative error value.
849 * @retval #BT_ERROR_NONE Successful
850 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
851 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
852 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
854 * @pre The Bluetooth service must be initialized with bt_initialize().
855 * @post bt_adapter_le_state_changed_cb() will be invoked.
857 * @see bt_initialize()
858 * @see bt_adapter_le_state_changed_cb()
859 * @see bt_adapter_le_unset_state_changed_cb()
861 int bt_adapter_le_set_state_changed_cb(bt_adapter_le_state_changed_cb callback, void *user_data);
865 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
866 * @brief Unregisters the callback function.
867 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
869 * @return 0 on success, otherwise a negative error value.
870 * @retval #BT_ERROR_NONE Successful
871 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
872 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
874 * @pre The Bluetooth service must be initialized with bt_initialize().
876 * @see bt_initialize()
877 * @see bt_adapter_le_set_state_changed_cb()
879 int bt_adapter_le_unset_state_changed_cb(void);
882 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
883 * @brief Sets Bluetooth LE scan type
885 * @privlevel platform
886 * @privilege %http://tizen.org/privilege/bluetooth.admin
887 * @param[in] scan_type The scan type
889 * @return 0 on success, otherwise a negative error value.
890 * @retval #BT_ERROR_NONE Successful
891 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
892 * @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled
893 * @retval #BT_ERROR_INVALID_PARAMETER Parameter is invalid
894 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
895 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
896 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
897 * @pre The Bluetooth service must be initialized with bt_initialize().
899 int bt_adapter_le_set_scan_type(bt_adapter_le_scan_type_e scan_type);
903 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
904 * @brief add address to whitelist for accepting scanning request.
905 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
906 * @privlevel platform
907 * @privilege %http://tizen.org/privilege/bluetooth.admin
909 * @remarks If the adress is in the whitelist then other LE devices are able to
910 * search this device. Before calling this API, make sure that the adapter is
911 * enabled. There is no callback event for this API.
913 * @param[in] address The other device's address
914 * @param[in] address_type The other device's address type
916 * @return 0 on success, otherwise a negative error value.
917 * @retval #BT_ERROR_NONE Successful
918 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
919 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
920 * @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled
921 * @retval #BT_ERROR_RESOURCE_BUSY Device or resource busy
922 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
923 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
924 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
926 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
928 * @see bt_adapter_le_start_advertising_new()
929 * @see bt_adapter_le_stop_advertising()
931 int bt_adapter_le_add_white_list(const char *address, bt_device_address_type_e address_type);
935 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
936 * @brief remove address from the whitelist for not accepting scanning request.
937 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
938 * @privlevel platform
939 * @privilege %http://tizen.org/privilege/bluetooth.admin
941 * @remarks If the adress is in the whitelist then other LE devices are able to
942 * search this device. Before calling this API, make sure that the adapter is
943 * enabled. There is no callback event for this API.
945 * @param[in] address The other device's address
946 * @param[in] address_type The other device's address type
948 * @return 0 on success, otherwise a negative error value.
949 * @retval #BT_ERROR_NONE Successful
950 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
951 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
952 * @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled
953 * @retval #BT_ERROR_RESOURCE_BUSY Device or resource busy
954 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
955 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
956 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
958 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
960 * @see bt_adapter_le_start_advertising_new()
961 * @see bt_adapter_le_stop_advertising()
963 int bt_adapter_le_remove_white_list(const char *address, bt_device_address_type_e address_type);
967 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
968 * @brief Sets the Privacy feature state of local Bluetooth adapter.
969 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
970 * @privlevel platform
971 * @privilege %http://tizen.org/privilege/bluetooth.admin
973 * @param[in] enable_privacy The privacy feature to set/unset.
975 * @return 0 on success, otherwise a negative error value.
976 * @retval #BT_ERROR_NONE Successful
977 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
978 * @retval #BT_ERROR_NOT_ENABLED Not enabled
979 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
980 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
981 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
983 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
984 * @pre The state of local Bluetooth must be #BT_ADAPTER_LE_ENABLED.
987 int bt_adapter_le_enable_privacy(bool enable_privacy);
990 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
991 * @brief Gets the Confirmation and Random value, synchronously.
993 * @privlevel platform
994 * @privilege %http://tizen.org/privilege/bluetooth.admin
996 * @remarks The @a local_address, confirmation and random must be released using free()
998 * @param[out] local_address Local device address
999 * @param[out] address_type Local device address type
1000 * @param[out] confirmation The confirmation value
1001 * @param[out] random The random value
1002 * @param[out] confirmation_len The length of @a confirmation
1003 * @param[out] random_len The length of @a random
1004 * @return 0 on success, otherwise a negative error value.
1005 * @retval #BT_ERROR_NONE Successful
1006 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1007 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1008 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1009 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1010 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1011 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1013 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
1014 * @pre The Bluetooth service must be initialized with bt_initialize().
1015 * @see bt_initialize()
1017 int bt_adapter_le_get_local_oob_ext_data(char **local_address, bt_device_address_type_e *address_type,
1018 unsigned char **confirmation, unsigned char **random,
1019 int *confirmation_len, int *random_len);
1022 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
1023 * @brief Sets the Hash and Randomizer value, synchronously for LE OOB pairing.
1025 * @privlevel platform
1026 * @privilege %http://tizen.org/privilege/bluetooth.admin
1028 * @param[in] remote_address Remote device address
1029 * @param[in] address_type Remote device address type
1030 * @param[in] hash256 The P-256 hash value received via OOB from remote device
1031 * @param[in] randomizer256 The P-256 randomizer value received via OOB from remote device
1032 * @param[in] hash256_len The length of @a hash256
1033 * @param[in] randomizer256_len The length of @a randomizer256
1034 * @return 0 on success, otherwise a negative error value.
1035 * @retval #BT_ERROR_NONE Successful
1036 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1037 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1038 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1039 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1040 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1041 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1043 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
1044 * @pre The Bluetooth service must be initialized with bt_initialize().
1045 * @see bt_initialize()
1047 int bt_adapter_le_set_remote_oob_ext_data(const char *remote_address,
1048 bt_device_address_type_e address_type,
1049 const unsigned char *hash256, const unsigned char *randomizer256,
1050 int hash256_len, int randomizer256_len);
1053 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
1054 * @brief Set advertising filter policy to use white list
1057 * @privilege %http://tizen.org/privilege/bluetooth
1059 * @param[in] advertiser The handle of advertiser
1060 * @param[in] filter_policy The filter policy of advertising
1062 * @return 0 on success, otherwise a negative error value.
1063 * @retval #BT_ERROR_NONE Successful
1064 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1065 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1066 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1067 * @retval #BT_ERROR_NOW_IN_PROGRESS Operation is now in progress
1068 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1069 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1071 * @pre The Bluetooth service must be initialized with bt_initialize().
1073 * @see bt_adapter_le_start_advertising_new()
1075 int bt_adapter_le_set_advertising_filter_policy(bt_advertiser_h advertiser, bt_adapter_le_advertising_filter_policy_e filter_policy);
1079 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
1080 * @brief Set advertise Tx power level to control the transmission power level for the advertising
1082 * @privlevel platform
1083 * @privilege %http://tizen.org/privilege/bluetooth.admin
1085 * @param[in] advertiser The handle of advertiser
1086 * @param[in] tx_power_level Transmission power level of advertising. The valid range is [-127 ~ 1]
1087 * Recommended values are bt_adapter_le_advertising_tx_power_level_e
1089 * @return 0 on success, otherwise a negative error value.
1090 * @retval #BT_ERROR_NONE Successful
1091 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1092 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1093 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1094 * @retval #BT_ERROR_NOW_IN_PROGRESS Operation is now in progress
1095 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1096 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1098 * @pre The Bluetooth service must be initialized with bt_initialize().
1100 * @see bt_adapter_le_start_advertising_new()
1101 * @see bt_adapter_le_advertising_tx_power_level_e
1103 int bt_adapter_le_set_advertising_custom_tx_power_level(bt_advertiser_h advertiser, int tx_power_level);
1107 * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE
1108 * @brief Retrieves the address of the devices connected with the specific profile.
1111 * @param[in] profile_uuid The UUID of profile service uuid of the connected device
1112 * @param[in] callback The callback function to invoke
1113 * @param[in] user_data The user data passed from the foreach function
1115 * @return 0 on success, otherwise a negative error value.
1116 * @retval #BT_ERROR_NONE Successful
1117 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1118 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1119 * @retval #BT_ERROR_OUT_OF_MEMORY Out of memory
1120 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1121 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED There is no connected device
1122 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1123 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1125 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
1126 * @post This function invokes bt_adapter_profile_connected_devices_cb().
1128 * @see bt_adapter_profile_connected_devices_cb()
1130 int bt_adapter_foreach_profile_connected_devices(const char *profile_uuid,
1131 bt_adapter_profile_connected_devices_cb callback, void *user_data);
1135 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1136 * @brief Disconnects a remote Bluetooth device.
1138 * @privlevel platform
1139 * @privilege %http://tizen.org/privilege/bluetooth.admin
1141 * @param[in] remote_address The address of the remote Bluetooth device
1143 * @return 0 on success, otherwise a negative error value.
1144 * @retval #BT_ERROR_NONE Successful
1145 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1146 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1147 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1148 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1149 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1150 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1152 * @see bt_device_set_connection_state_changed_cb()
1154 int bt_device_disconnect(const char *remote_address);
1158 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1159 * @brief Gets a connection state
1160 * @since_tizen @if WEARABLE @else 2.4 @endif
1162 * @param[in] remote_address The address of the remote Bluetooth device
1163 * @param[in] link_type The link type to get a connection state
1164 * @param[out] connected The connection state
1166 * @return 0 on success, otherwise a negative error value.
1167 * @retval #BT_ERROR_NONE Successful
1168 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1169 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1170 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1171 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1173 int bt_device_get_connection_state(const char *remote_address, bt_device_connection_link_type_e link_type, bool *connected);
1177 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1178 * @brief Creates a bond with a remote Bluetooth device, asynchronously.
1179 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1180 * @privlevel platform
1181 * @privilege %http://tizen.org/privilege/bluetooth.admin
1183 * @remarks A bond can be destroyed by bt_device_destroy_bond().\n
1184 * The bonding request can be cancelled by bt_device_cancel_bonding().
1186 * @param[in] remote_address The address of the remote Bluetooth device with which the bond should be created
1187 * @param[in] conn_type The connection type(LE or BREDR) to create bond with remote device
1189 * @return 0 on success, otherwise a negative error value.
1190 * @retval #BT_ERROR_NONE Successful
1191 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1192 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1193 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1194 * @retval #BT_ERROR_RESOURCE_BUSY Device or resource busy
1195 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1196 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1197 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1199 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
1200 * @pre The remote device must be discoverable with bt_adapter_start_device_discovery().
1201 * @post This function invokes bt_device_bond_created_cb().
1203 * @see bt_adapter_start_device_discovery()
1204 * @see bt_device_create_bond()
1205 * @see bt_device_bond_created_cb()
1206 * @see bt_device_cancel_bonding()
1207 * @see bt_device_destroy_bond()
1208 * @see bt_device_set_bond_created_cb()
1209 * @see bt_device_unset_bond_created_cb()
1211 int bt_device_create_bond_by_type(const char *remote_address,
1212 bt_device_connection_link_type_e conn_type);
1216 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1217 * @brief Cancels service search process.
1218 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1219 * @privlevel platform
1220 * @privilege %http://tizen.org/privilege/bluetooth.admin
1222 * @return 0 on success, otherwise a negative error value.
1223 * @retval #BT_ERROR_NONE Successful
1224 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1225 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1226 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_BONDED Remote device not bonded
1227 * @retval #BT_ERROR_NOT_IN_PROGRESS Operation not in progress
1228 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1229 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1230 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1232 * @pre The service search must be in progress by bt_device_start_service_search().
1234 * @see bt_device_start_service_search()
1235 * @see bt_device_service_searched_cb()
1236 * @see bt_device_set_service_searched_cb()
1237 * @see bt_device_unset_service_searched_cb()
1239 int bt_device_cancel_service_search(void);
1243 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1244 * @brief Gets a connection state
1245 * @since_tizen @if WEARABLE 2.4 @endif
1247 * @param[in] remote_address The address of the remote Bluetooth device
1248 * @param[in] link_type The link type to get a connection state
1249 * @param[out] connected The connection state
1251 * @return 0 on success, otherwise a negative error value.
1252 * @retval #BT_ERROR_NONE Successful
1253 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1254 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1255 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1256 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1258 int bt_device_get_connection_state(const char *remote_address, bt_device_connection_link_type_e link_type, bool *connected);
1262 * @deprecated Deprecated since 4.0. Use bt_device_set_profile_trusted instead.
1263 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1264 * @brief Sets a profile restricted connection for a device
1266 * @privlevel platform
1267 * @privilege %http://tizen.org/privilege/bluetooth.admin
1269 * @return 0 on success, otherwise a negative error value.
1270 * @retval #BT_ERROR_NONE Successful
1271 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1272 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1273 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_BONDED Remote device not bonded
1274 * @retval #BT_ERROR_NOT_IN_PROGRESS Operation not in progress
1275 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1276 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1277 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1279 int bt_device_set_profile_restricted(const char *device_address, bt_restricted_profile_t profile, bool restricted);
1283 * @deprecated Deprecated since 4.0. Use bt_device_get_profile_trusted instead.
1284 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1285 * @brief Gets a profile restricted connection for a device
1288 * @return 0 on success, otherwise a negative error value.
1289 * @retval #BT_ERROR_NONE Successful
1290 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1291 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1292 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_BONDED Remote device not bonded
1293 * @retval #BT_ERROR_NOT_IN_PROGRESS Operation not in progress
1294 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1295 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1296 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1298 int bt_device_get_profile_restricted(const char *device_address, bt_restricted_profile_t profile, int *restricted);
1302 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1303 * @brief Set a profile trusted or untrusted for a device.
1305 * @privlevel platform
1306 * @privilege %http://tizen.org/privilege/bluetooth.admin
1307 * @return 0 on success, otherwise a negative error value.
1308 * @retval #BT_ERROR_NONE Successful
1309 * @retval #BT_ERROR_INTERNAL Internal Error
1310 * @retval #BT_ERROR_NOT_INITIALIZED Not supported
1311 * @retval #BT_ERROR_INVALID_PARAMETER Invalid Parameter
1312 * @retval #BT_ERROR_NOT_ENABLED Invalid Parameter
1314 int bt_device_set_profile_trusted(const char *device_address, bt_trusted_profile_t profile, bool trust);
1318 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1319 * @brief Gets a profile is trusted or untrusted for a device.
1321 * @return 0 on success, otherwise a negative error value.
1322 * @retval #BT_ERROR_NONE Successful
1323 * @retval #BT_ERROR_INTERNAL Internal Error
1324 * @retval #BT_ERROR_NOT_INITIALIZED Not supported
1325 * @retval #BT_ERROR_NOT_ENABLED Invalid Parameter
1326 * @retval #BT_ERROR_INVALID_PARAMETER Invalid Parameter
1328 int bt_device_get_profile_trusted(const char *device_address, bt_trusted_profile_t profile, int *trust);
1332 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1333 * @brief Registers a callback function to be invoked when Trusted Profiles are changed.
1335 * @return 0 on success, otherwise a negative error value.
1336 * @retval #BT_ERROR_NONE Successful
1337 * @retval #BT_ERROR_NOT_INITIALIZED Not supported
1338 * @retval #BT_ERROR_INVALID_PARAMETER Invalid Parameter
1340 int bt_device_set_trusted_profile_cb(bt_device_trusted_profiles_cb callback, void *user_data);
1344 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1345 * @brief Unregisters the callback function registered with bt_device_set_trusted_profile_cb().
1347 * @return 0 on success, otherwise a negative error value.
1348 * @retval #BT_ERROR_NONE Successful
1349 * @retval #BT_ERROR_NOT_INITIALIZED Not supported
1351 int bt_device_unset_trusted_profile_cb(void);
1354 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1355 * @brief Gets the ID address of the remote device
1358 * @remarks The id_address must be released with free() by you.
1360 * @param[in] remote_rpa The Resolvable private address of the remote device
1361 * @param[out] id_address The Identity address of the remote device
1363 * @return 0 on success, otherwise a negative error value.
1364 * @retval #BT_ERROR_NONE Successful
1365 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1366 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1367 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1368 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1369 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1370 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1372 int bt_device_get_id_address(const char *remote_rpa, char **id_address);
1376 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1377 * @brief Gets the rssi value when link loss occurs.
1380 * @remarks This function should be called in bt_device_connection_state_changed_cb()
1381 * when the device is disconnected
1383 * @param[out] rssi Link loss rssi
1384 * @retval #BT_ERROR_NONE Successful
1385 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1387 * @see bt_device_set_connection_state_changed_cb()
1388 * @see bt_device_connection_state_changed_cb()
1390 int bt_device_get_link_loss_rssi(int *rssi);
1393 * @deprecated Deprecated since 4.0. Use bt_gatt_client_request_att_mtu_change instead.
1394 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1395 * @brief Request to change ATT MTU value
1397 * @privlevel platform
1398 * @privilege %http://tizen.org/privilege/bluetooth.admin
1400 * @param[in] remote_address The address of the remote Bluetooth device
1401 * @param[in] mtu New MTU value to be changed
1403 * @return 0 on success, otherwise a negative error value.
1404 * @retval #BT_ERROR_NONE Successful
1405 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1406 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1407 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1408 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1409 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1410 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1412 int bt_device_request_att_mtu(const char *remote_address, unsigned int mtu) TIZEN_DEPRECATED_API;
1415 * @deprecated Deprecated since 4.0. Use bt_gatt_client_get_att_mtu instead.
1416 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1417 * @brief Gets the ATT MTU value set for a connection
1419 * @privlevel platform
1420 * @privilege %http://tizen.org/privilege/bluetooth.admin
1422 * @param[in] remote_address The address of the remote Bluetooth device
1423 * @param[ot] mtu MTU value set for a connection
1425 * @return 0 on success, otherwise a negative error value.
1426 * @retval #BT_ERROR_NONE Successful
1427 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1428 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1429 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1430 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1431 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1432 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1434 int bt_device_get_att_mtu(const char *remote_address, unsigned int *mtu) TIZEN_DEPRECATED_API;
1437 * @deprecated Deprecated since 4.0. Use bt_gatt_client_set_att_mtu_changed_cb instead.
1438 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1439 * @brief Registers a callback function to be invoked when the ATT MTU is changed.
1441 * @param[in] callback The callback function to register
1442 * @param[in] user_data The user data to be passed to the callback function
1443 * @return 0 on success, otherwise a negative error value.
1444 * @retval #BT_ERROR_NONE Successful
1445 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1446 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1447 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1449 * @pre The Bluetooth service must be initialized with bt_initialize().
1450 * @post bt_device_connection_state_changed_cb() will be invoked.
1451 * @see bt_initialize()
1452 * @see bt_device_unset_att_mtu_changed_cb()
1454 int bt_device_set_att_mtu_changed_cb(bt_device_att_mtu_changed_cb callback, void *user_data) TIZEN_DEPRECATED_API;
1457 * @deprecated Deprecated since 4.0. Use bt_gatt_client_unset_att_mtu_changed_cb instead.
1458 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
1459 * @brief Unregisters the callback function to be invoked when the ATT MTU is changed.
1461 * @return 0 on success, otherwise a negative error value.
1462 * @retval #BT_ERROR_NONE Successful
1463 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1464 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1466 * @pre The Bluetooth service must be initialized with bt_initialize().
1467 * @see bt_initialize()
1468 * @see bt_device_set_att_mtu_changed_cb()
1470 int bt_device_unset_att_mtu_changed_cb(void) TIZEN_DEPRECATED_API;
1474 * @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE
1475 * @brief Registers a rfcomm server socket with a specific UUID. Activation by dbus is possible when the profile is connected.
1477 * @privlevel platform
1478 * @privilege %http://tizen.org/privilege/bluetooth.admin
1480 * @remarks A socket can be destroyed by bt_socket_destroy_rfcomm_ex().
1481 * Application should call this API to receive a connection event when launched again by dbus.
1483 * @param[in] uuid The UUID of service to provide
1484 * @param[in] bus_name bus_name of the application which is provided in service file.
1485 * @param[in] object_path dbus of the application
1486 * @return 0 on success, otherwise a negative error value.
1488 * @retval #BT_ERROR_NONE Successful
1489 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1490 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1491 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1492 * @retval #BT_ERROR_NOW_IN_PROGRESS Already registered
1493 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1494 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1495 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1497 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
1499 * @see bt_socket_listen_and_accept_rfcomm_ex()
1500 * @see bt_socket_destroy_rfcomm_ex()
1502 int bt_socket_create_rfcomm_ex(const char *uuid, const char *bus_name, const char *object_path);
1506 * @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE
1507 * @brief Removes the rfcomm server socket which was created using bt_socket_create_rfcomm_ex().
1509 * @privlevel platform
1510 * @privilege %http://tizen.org/privilege/bluetooth.admin
1511 * @remarks If callback function bt_socket_connection_state_changed_cb() is set and the remote Bluetooth device is connected,
1512 * then bt_socket_connection_state_changed_cb() will be called when this function is finished successfully.
1514 * @param[in] uuid The UUID (which was created using bt_socket_create_rfcomm()) to destroy
1515 * @return 0 on success, otherwise a negative error value.
1516 * @retval #BT_ERROR_NONE Successful
1517 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1518 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1519 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1520 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1521 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1522 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1524 * @pre The socket must be created with bt_socket_create_rfcomm_ex().
1525 * @post If callback function bt_socket_connection_state_changed_cb() is set and the remote Bluetooth device is connected,
1526 * then bt_socket_connection_state_changed_cb() will be called.
1527 * @see bt_socket_create_rfcomm_ex()
1528 * @see bt_socket_connection_state_changed_cb()
1529 * @see bt_socket_set_connection_state_changed_cb()
1530 * @see bt_socket_unset_connection_state_changed_cb()
1532 int bt_socket_destroy_rfcomm_ex(const char *uuid);
1536 * @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE
1537 * @brief Starts listening on passed rfcomm socket and accepts connection requests. Activation by dbus is possible when the profile is connected.
1539 * @privlevel platform
1540 * @privilege %http://tizen.org/privilege/bluetooth.admin
1541 * @details Pop-up is shown automatically when a RFCOMM connection is requested.
1542 * bt_socket_connection_state_changed_cb() will be called with
1543 * #BT_SOCKET_CONNECTED if you click "yes" and connection is finished successfully.
1544 * @param[in] uuid The UUID of service to provide
1545 * @param[in] max_pending_connections The maximum number of pending connections
1546 * @param[in] bus_name bus_name of the application which is provided in service file.
1547 * @param[in] object_path dbus of the application
1548 * @return 0 on success, otherwise a negative error value.
1549 * @retval #BT_ERROR_NONE Successful
1550 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1551 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1552 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1553 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1554 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1555 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1557 * @pre The socket must be created with bt_socket_create_rfcomm_ex().
1558 * @post If callback function bt_socket_connection_state_changed_cb() is set,
1559 * then bt_socket_connection_state_changed_cb() will be called when the remote Bluetooth device is connected.
1560 * @see bt_socket_create_rfcomm_ex()
1561 * @see bt_socket_connection_state_changed_cb()
1562 * @see bt_socket_set_connection_state_changed_cb()
1563 * @see bt_socket_unset_connection_state_changed_cb()
1565 int bt_socket_listen_and_accept_rfcomm_ex(const char *uuid, int max_pending_connections, const char* bus_name, const char *object_path);
1569 * @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE
1570 * @brief Starts listening on passed rfcomm socket.
1571 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1572 * @privlevel platform
1573 * @privilege %http://tizen.org/privilege/bluetooth.admin
1574 * @details bt_socket_connection_requested_cb() will be called when a RFCOMM connection is requested.
1576 * @param[in] socket_fd The file descriptor socket on which start to listen
1577 * @param[in] max_pending_connections The number of pending connections
1579 * @return 0 on success, otherwise a negative error value.
1580 * @retval #BT_ERROR_NONE Successful
1581 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1582 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1583 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1584 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1585 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1586 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1588 * @pre The socket must be created with bt_socket_create_rfcomm().
1589 * @post This function invokes bt_socket_connection_state_changed_cb().
1591 * @see bt_socket_create_rfcomm()
1592 * @see bt_socket_set_connection_requested_cb()
1593 * @see bt_socket_unset_connection_requested_cb()
1594 * @see bt_socket_connection_requested_cb()
1596 int bt_socket_listen(int socket_fd, int max_pending_connections);
1600 * @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE
1601 * @brief Accepts a connection request.
1602 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1603 * @privlevel platform
1604 * @privilege %http://tizen.org/privilege/bluetooth.admin
1605 * @param[in] requested_socket_fd The file descriptor of socket on which a connection is requested
1606 * @return 0 on success, otherwise a negative error value.
1607 * @retval #BT_ERROR_NONE Successful
1608 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1609 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1610 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1611 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1612 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1613 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1615 * @pre The connection is requested by bt_socket_connection_requested_cb().
1616 * @see bt_socket_create_rfcomm()
1617 * @see bt_socket_connection_requested_cb()
1618 * @see bt_socket_listen()
1619 * @see bt_socket_reject()
1621 int bt_socket_accept(int requested_socket_fd);
1625 * @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE
1626 * @brief Rejects a connection request.
1627 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1628 * @privlevel platform
1629 * @privilege %http://tizen.org/privilege/bluetooth.admin
1630 * @param[in] socket_fd The file descriptor of socket on which a connection is requested
1631 * @return 0 on success, otherwise a negative error value.
1632 * @retval #BT_ERROR_NONE Successful
1633 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1634 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1635 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1636 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1637 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1638 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1640 * @pre The connection is requested by bt_socket_connection_requested_cb().
1641 * @see bt_socket_create_rfcomm()
1642 * @see bt_socket_connection_requested_cb()
1643 * @see bt_socket_listen()
1644 * @see bt_socket_accept()
1646 int bt_socket_reject(int socket_fd);
1650 * @ingroup CAPI_NETWORK_BLUETOOTH_OPP_SERVER_MODULE
1651 * @brief Initializes the Bluetooth OPP server requested by bt_opp_server_push_requested_cb().
1652 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1653 * @details The popup appears when an OPP connection is requested from a remote device.
1654 * If you accept the request, then connection will be established and bt_opp_server_push_requested_cb() will be called.
1655 * At that time, you can call either bt_opp_server_accept() or bt_opp_server_reject().
1656 * @remarks This function must be called to start Bluetooth OPP server. You must free all resources of the Bluetooth service
1657 * by calling bt_opp_server_deinitialize() if Bluetooth OPP service is no longer needed.
1658 * @param[in] destination The destination path
1659 * @param[in] push_requested_cb The callback called when a push is requested
1660 * @param[in] user_data The user data to be passed to the callback function
1661 * @return 0 on success, otherwise a negative error value.
1662 * @retval #BT_ERROR_NONE Successful
1663 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1664 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1665 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1666 * @retval #BT_ERROR_RESOURCE_BUSY Device or resource busy
1667 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1668 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1670 * @see bt_opp_server_push_requested_cb()
1671 * @see bt_opp_server_deinitialize()
1672 * @see bt_opp_server_accept()
1673 * @see bt_opp_server_reject()
1675 int bt_opp_server_initialize(const char *destination, bt_opp_server_push_requested_cb push_requested_cb, void *user_data);
1679 * @ingroup CAPI_NETWORK_BLUETOOTH_OPP_MODULE
1680 * @brief Gets the percentage progress for ongoing transfers.
1683 * @param[in] transfer_type Transfer Type: (@c BLUETOOTH_TRANSFER_INBOUND = receiving , @c BLUETOOTH_TRANSFER_OUTBOUND = sending)
1684 * @param[in] transfer_id Transfer ID
1685 * @param[out] progress Percentage Progress
1686 * @retval #BT_ERROR_NONE Successful
1687 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1688 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1690 int bt_opp_get_transfer_progress(bt_opp_transfer_type_t transfer_type,
1691 int transfer_id, unsigned char *progress);
1695 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1696 * @brief Notifies the call event to the remote bluetooth device.
1697 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1698 * @privlevel platform
1699 * @privilege %http://tizen.org/privilege/bluetooth.admin
1700 * @remarks Before notifying #BT_AG_CALL_EVENT_ANSWERED or #BT_AG_CALL_EVENT_DIALING, you should open SCO(Synchronous Connection Oriented link)
1701 * if Bluetooth Hands-Free need SCO connection.
1702 * @param[in] event The call event
1703 * @param[in] call_id The call ID
1704 * @param[in] phone_number The phone number. You must set this value in case of #BT_AG_CALL_EVENT_DIALING and #BT_AG_CALL_EVENT_INCOMING.
1705 * In other cases, this value can be NULL.
1706 * @return 0 on success, otherwise a negative error value.
1707 * @retval #BT_ERROR_NONE Successful
1708 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1709 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1710 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1711 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
1712 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1713 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1715 * @pre The Bluetooth audio device must be connected with bt_audio_connect().
1716 * @see bt_audio_connect()
1718 int bt_ag_notify_call_event(bt_ag_call_event_e event, unsigned int call_id, const char *phone_number);
1722 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1723 * @brief Notifies the call list to the remote bluetooth device.
1724 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1725 * @privlevel platform
1726 * @privilege %http://tizen.org/privilege/bluetooth.admin
1727 * @param[in] list The call list
1728 * @return 0 on success, otherwise a negative error value.
1729 * @retval #BT_ERROR_NONE Successful
1730 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1731 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1732 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1733 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
1734 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1735 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1736 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1738 * @pre The Bluetooth audio device must be connected with bt_audio_connect().
1739 * @see bt_audio_connect()
1741 int bt_ag_notify_call_list(bt_call_list_h list);
1745 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1746 * @brief Notifies the state of voice recognition.
1747 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1748 * @privlevel platform
1749 * @privilege %http://tizen.org/privilege/bluetooth.admin
1750 * @param[in] state The state of voice recognition: (@c true = enabled, @c false = disabled)
1751 * @return 0 on success, otherwise a negative error value.
1752 * @retval #BT_ERROR_NONE Successful
1753 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1754 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1755 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1756 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
1757 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
1758 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
1759 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1761 * @pre The Bluetooth audio device must be connected with bt_audio_connect().
1762 * @see bt_audio_connect()
1764 int bt_ag_notify_voice_recognition_state(bool state);
1768 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1769 * @brief Registers a callback function that will be invoked when a call handling event happened from Hands-Free.
1770 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1771 * @param[in] callback The callback function to register
1772 * @param[in] user_data The user data to be passed to the callback function
1773 * @return 0 on success, otherwise a negative error value.
1774 * @retval #BT_ERROR_NONE Successful
1775 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1776 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1777 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1779 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
1780 * @see bt_audio_initialize()
1781 * @see bt_ag_call_handling_event_cb()
1782 * @see bt_ag_unset_call_handling_event_cb()
1784 int bt_ag_set_call_handling_event_cb(bt_ag_call_handling_event_cb callback, void *user_data);
1788 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1789 * @brief Unregisters a callback function that will be invoked when a call handling event happened from Hands-Free.
1790 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1791 * @return 0 on success, otherwise a negative error value.
1792 * @retval #BT_ERROR_NONE Successful
1793 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1794 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1796 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
1797 * @see bt_audio_initialize()
1798 * @see bt_ag_call_handling_event_cb()
1799 * @see bt_ag_set_call_handling_event_cb()
1801 int bt_ag_unset_call_handling_event_cb(void);
1805 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1806 * @brief Registers a callback function that will be invoked when a multi call handling event happened from Hands-Free.
1807 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1808 * @param[in] callback The callback function to register
1809 * @param[in] user_data The user data to be passed to the callback function
1810 * @return 0 on success, otherwise a negative error value.
1811 * @retval #BT_ERROR_NONE Successful
1812 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1813 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1814 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1816 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
1817 * @see bt_audio_initialize()
1818 * @see bt_ag_multi_call_handling_event_cb()
1819 * @see bt_ag_unset_multi_call_handling_event_cb()
1821 int bt_ag_set_multi_call_handling_event_cb(bt_ag_multi_call_handling_event_cb callback, void *user_data);
1825 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1826 * @brief Unregisters a callback function that will be invoked when a multi call handling event happened from Hands-Free.
1827 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1828 * @return 0 on success, otherwise a negative error value.
1829 * @retval #BT_ERROR_NONE Successful
1830 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1831 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1833 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
1834 * @see bt_audio_initialize()
1835 * @see bt_ag_multi_call_handling_event_cb()
1836 * @see bt_ag_set_multi_call_handling_event_cb()
1838 int bt_ag_unset_multi_call_handling_event_cb(void);
1842 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1843 * @brief Registers a callback function that will be invoked when a DTMF(Dual Tone Multi Frequency) is transmitted from Hands-Free.
1844 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1845 * @param[in] callback The callback function to register
1846 * @param[in] user_data The user data to be passed to the callback function
1847 * @return 0 on success, otherwise a negative error value.
1848 * @retval #BT_ERROR_NONE Successful
1849 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1850 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1851 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1853 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
1854 * @see bt_audio_initialize()
1855 * @see bt_ag_dtmf_transmitted_cb()
1856 * @see bt_ag_unset_dtmf_transmitted_cb()
1858 int bt_ag_set_dtmf_transmitted_cb(bt_ag_dtmf_transmitted_cb callback, void *user_data);
1862 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1863 * @brief Unregisters a callback function that will be invoked when a DTMF(Dual Tone Multi Frequency) is transmitted from Hands-Free.
1864 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1865 * @return 0 on success, otherwise a negative error value.
1866 * @retval #BT_ERROR_NONE Successful
1867 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1868 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1870 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
1871 * @see bt_audio_initialize()
1872 * @see bt_ag_dtmf_transmitted_cb()
1873 * @see bt_ag_set_dtmf_transmitted_cb()
1875 int bt_ag_unset_dtmf_transmitted_cb(void);
1879 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1880 * @brief Checks whether the remoted device enables NREC(Noise Reduction and Echo Canceling) or not.
1881 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1882 * @param[out] enabled The NREC status: (@c true = enabled, @c false = not enabled)
1883 * @return 0 on success, otherwise a negative error value.
1884 * @retval #BT_ERROR_NONE Successful
1885 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1886 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1887 * @retval #BT_ERROR_NOT_ENABLED Not enabled
1888 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
1889 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1891 * @pre The remote device is connected by bt_audio_connect() with #BT_AUDIO_PROFILE_TYPE_HSP_HFP service.
1892 * @see bt_audio_connect()
1894 int bt_ag_is_nrec_enabled(bool *enabled);
1898 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_CALL_MODULE
1899 * @brief Creates a handle of call list.
1900 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1901 * @param[out] list The handle of call list
1902 * @return 0 on success, otherwise a negative error value.
1903 * @retval #BT_ERROR_NONE Successful
1904 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1905 * @retval #BT_ERROR_OUT_OF_MEMORY Out of memory
1906 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1908 * @see bt_call_list_destroy()
1910 int bt_call_list_create(bt_call_list_h *list);
1914 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_CALL_MODULE
1915 * @brief Destroys the handle of call list.
1916 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1917 * @param[in] list The handle of call list
1918 * @return 0 on success, otherwise a negative error value.
1919 * @retval #BT_ERROR_NONE Successful
1920 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1921 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1923 * @see bt_call_list_create()
1925 int bt_call_list_destroy(bt_call_list_h list);
1929 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_CALL_MODULE
1930 * @brief Resets the handle of call list.
1931 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1932 * @param[in] list The handle of call list
1933 * @return 0 on success, otherwise a negative error value.
1934 * @retval #BT_ERROR_NONE Successful
1935 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1936 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1938 * @see bt_call_list_create()
1940 int bt_call_list_reset(bt_call_list_h list);
1944 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_CALL_MODULE
1945 * @brief Adds a call to the handle of call list.
1946 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
1947 * @param[in] list The handle of call list
1948 * @param[in] call_id The call ID
1949 * @param[in] state The state of audio gate call
1950 * @param[in] phone_number The phone number. You must set this value in case of #BT_AG_CALL_EVENT_DIALING and #BT_AG_CALL_EVENT_INCOMING.
1951 * @return 0 on success, otherwise a negative error value.
1952 * @retval #BT_ERROR_NONE Successful
1953 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1954 * @retval #BT_ERROR_OUT_OF_MEMORY Out of memory
1955 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1957 * @see bt_call_list_create()
1959 int bt_call_list_add(bt_call_list_h list, unsigned int call_id, bt_ag_call_state_e state, const char *phone_number);
1962 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1963 * @brief Registers a callback function that will be invoked when a XSATvendor AT command is transmitted from Hands-Free.
1964 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
1965 * @param[in] callback The callback function to register
1966 * @param[in] user_data The user data to be passed to the callback function
1967 * @return 0 on success, otherwise a negative error value.
1968 * @retval #BT_ERROR_NONE Successful
1969 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1970 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
1971 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1972 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
1973 * @see bt_audio_initialize()
1974 * @see bt_ag_vendor_cmd_cb()
1975 * @see bt_ag_unset_vendor_cmd_cb()
1977 int bt_ag_set_vendor_cmd_cb(bt_ag_vendor_cmd_cb callback, void *user_data);
1980 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1981 * @brief Unregisters a callback function that will be invoked when a XSATvendor AT command is transmitted from Hands-Free
1982 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
1983 * @return 0 on success, otherwise a negative error value.
1984 * @retval #BT_ERROR_NONE Successful
1985 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
1986 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
1987 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
1988 * @see bt_audio_initialize()
1989 * @see bt_ag_vendor_cmd_cb()
1990 * @see bt_ag_set_vendor_cmd_cb()
1992 int bt_ag_unset_vendor_cmd_cb(void);
1995 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
1996 * @brief Checks whether the remoted device is wbs (Wide Band Speech) mode or not.
1997 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
1998 * @param[out] wbs_mode The wbs status: (@c true = wide band speech, @c false = narrow band speech)
1999 * @return 0 on success, otherwise a negative error value.
2000 * @retval #BT_ERROR_NONE Successful
2001 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2002 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2003 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2004 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
2005 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2006 * @pre The remote device is connected by bt_audio_connect() with #BT_AUDIO_PROFILE_TYPE_HSP_HFP service.
2007 * @see bt_audio_connect()
2009 int bt_ag_is_wbs_mode(bool *wbs_mode);
2012 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
2013 * @brief Gets the HF(Hands-Free) profile connected status for AG role.
2015 * @param[out] connected the connected status: (@c true = connected , @c false = not connected )
2016 * @return 0 on success, otherwise a negative error value.
2017 * @retval #BT_ERROR_NONE Successful
2018 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2019 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2020 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2021 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
2022 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2023 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
2025 int bt_ag_is_connected(bool *connected);
2028 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_AG_MODULE
2029 * @brief Switch between the connected headsets for AG role.
2032 * @return 0 on success, otherwise a negative error value.
2033 * @retval #BT_ERROR_NONE Successful
2034 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2035 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2036 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2037 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
2038 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2039 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Not connected
2040 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
2042 int bt_ag_switch_headset(const char *remote_addr);
2045 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_A2DP_MODULE
2046 * @brief Sets copy protection. streaming application that needs to have the copy protection for the streaming data, shall invoke this API.
2047 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
2048 * @privlevel platform
2049 * @privilege %http://tizen.org/privilege/bluetooth.admin
2050 * @param[in] status - TRUE/FALSE
2051 * @return 0 on success, otherwise negative error value.
2052 * @retval #BT_ERROR_NONE Successful
2053 * @retval #BT_ERROR_OPERATION_FAILED on failure
2054 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
2055 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2057 int bt_a2dp_set_content_protection(bool status);
2061 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE
2062 * @brief Sends a command to the target device.
2064 * @privlevel platform
2065 * @privilege %http://tizen.org/privilege/bluetooth.admin
2066 * @param[in] cmd The commands, one of: Play, Pause, Next, Rewind.
2067 * @param[in] remote_address The address of the remote Bluetooth device
2068 * @return 0 on success, otherwise a negative error value.
2069 * @retval #BT_ERROR_NONE Successful
2070 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2071 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2072 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2073 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
2074 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
2075 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
2076 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2077 * @pre The Bluetooth audio service must be initialized with bt_avrcp_control_initialize().
2078 * @see bt_avrcp_control_initialize()
2079 * @see bt_avrcp_control_connect()
2081 int bt_avrcp_control_send_player_command_to(bt_avrcp_player_command_e cmd, char *remote_address);
2086 * @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE
2087 * @brief Gets the specification name from the UUID
2090 * @remarks @a name must be released with free() by you.
2092 * @param[in] uuid The UUID
2093 * @param[out] name The specification name which defined from www.bluetooth.org
2094 * @return 0 on success, otherwise a negative error value.
2095 * @retval #BT_ERROR_NONE Successful
2096 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2097 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2099 * @see bt_gatt_get_uuid()
2101 int bt_gatt_get_uuid_specification_name(const char *uuid, char **name);
2104 * @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE
2105 * @brief Updates the permissions which a characteristic or descriptor's GATT handle has.
2108 * @param[in] gatt_handle The handle of a characteristic or descriptor
2109 * @param[in] permissions The permissions to be updated
2110 * @return 0 on success, otherwise a negative error value
2111 * @retval #BT_ERROR_NONE Successful
2112 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2113 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2115 * @see bt_gatt_characteristic_create()
2116 * @see bt_gatt_descriptor_create()
2117 * @see bt_gatt_permission_e
2119 int bt_gatt_set_permissions(bt_gatt_h gatt_handle, int permissions);
2122 * @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE
2123 * @brief Updates the properties which a characteristic's GATT handle has.
2126 * @param[in] characteristic The characteristic's GATT handle
2127 * @param[in] properties The properties to be updated
2128 * @return 0 on success, otherwise a negative error value
2129 * @retval #BT_ERROR_NONE Successful
2130 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2131 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2133 * @see bt_gatt_property_e
2135 int bt_gatt_characteristic_set_properties(bt_gatt_h characteristic, int properties);
2138 * @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE
2139 * @brief Destroys the GATT handle
2142 * @param[in] gatt_handle The handle of service, characteristic or descriptor
2143 * @return 0 on success, otherwise a negative error value
2144 * @retval #BT_ERROR_NONE Successful
2145 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2146 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2148 * @see bt_gatt_service_create()
2149 * @see bt_gatt_characteristic_create()
2150 * @see bt_gatt_descriptor_create()
2152 int bt_gatt_destroy(bt_gatt_h gatt_handle);
2155 * @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE
2156 * @brief Registers a callback function to be invoked when the ATT MTU is changed.
2158 * @param[in] server The created GATT server's handle
2159 * @param[in] callback The callback function to register
2160 * @param[in] user_data The user data to be passed to the callback function
2161 * @return 0 on success, otherwise a negative error value.
2162 * @retval #BT_ERROR_NONE Successful
2163 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2164 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2165 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2167 * @pre The Bluetooth service must be initialized with bt_initialize().
2168 * @post bt_device_connection_state_changed_cb() will be invoked.
2169 * @see bt_initialize()
2170 * @see bt_gatt_server_initialize()
2171 * @see bt_gatt_server_create()
2172 * @see bt_gatt_server_unset_att_mtu_changed_cb()
2174 int bt_gatt_server_set_att_mtu_changed_cb(bt_gatt_server_h server, bt_gatt_server_att_mtu_changed_cb callback, void *user_data);
2177 * @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE
2178 * @brief Unregisters the callback function to be invoked when the ATT MTU is changed.
2180 * @param[in] server The created GATT server's handle
2181 * @return 0 on success, otherwise a negative error value.
2182 * @retval #BT_ERROR_NONE Successful
2183 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2184 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2186 * @pre The Bluetooth service must be initialized with bt_initialize().
2187 * @see bt_initialize()
2188 * @see bt_gatt_server_set_att_mtu_changed_cb()
2190 int bt_gatt_server_unset_att_mtu_changed_cb(bt_gatt_server_h server);
2193 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE
2194 * @brief Registers a callback function that will be invoked when the A2DP Source connection state is changed.
2195 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
2196 * @param[in] callback The callback function to register
2197 * @param[in] user_data The user data to be passed to the callback function
2198 * @return 0 on success, otherwise a negative error value.
2199 * @retval #BT_ERROR_NONE Successful
2200 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2201 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2202 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2204 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
2205 * @see bt_audio_initialize()
2206 * @see bt_audio_connection_state_changed_cb()
2208 int bt_a2dp_source_audio_set_connection_state_changed_cb(bt_audio_connection_state_changed_cb callback, void *user_data);
2211 * @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE
2212 * @brief Unregisters a callback function that will be invoked when the A2DP Source connection state is changed.
2213 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
2214 * @return 0 on success, otherwise a negative error value.
2215 * @retval #BT_ERROR_NONE Successful
2216 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2217 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2219 * @pre The Bluetooth audio service must be initialized with bt_audio_initialize().
2220 * @see bt_audio_initialize()
2221 * @see bt_audio_connection_state_changed_cb()
2222 * @see bt_audio_set_connection_state_changed_cb()
2224 int bt_a2dp_source_audio_unset_connection_state_changed_cb(void);
2228 * @ingroup CAPI_NETWORK_BLUETOOTH_PAN_NAP_MODULE
2229 * @brief Activates the NAP(Network Access Point).
2230 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2232 * @privilege %http://tizen.org/privilege/bluetooth
2233 * @return 0 on success, otherwise a negative error value.
2234 * @retval #BT_ERROR_NONE Successful
2235 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2236 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2237 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
2238 * @retval #BT_ERROR_ALREADY_DONE Operation is already done
2239 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
2240 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2242 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED
2243 * @see bt_nap_deactivate()
2245 int bt_nap_activate(void);
2249 * @ingroup CAPI_NETWORK_BLUETOOTH_PAN_NAP_MODULE
2250 * @brief Deactivates the NAP(Network Access Point).
2251 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2253 * @privilege %http://tizen.org/privilege/bluetooth
2254 * @return 0 on success, otherwise a negative error value.
2255 * @retval #BT_ERROR_NONE Successful
2256 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2257 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2258 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
2259 * @retval #BT_ERROR_ALREADY_DONE Operation is already done
2260 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
2261 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2263 * @pre The Bluetooth NAP service must be activated with bt_nap_activate().
2264 * @see bt_nap_activate()
2266 int bt_nap_deactivate(void);
2270 * @ingroup CAPI_NETWORK_BLUETOOTH_PAN_NAP_MODULE
2271 * @brief Disconnects the all PANUs(Personal Area Networking User) which are connected to you.
2272 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2274 * @privilege %http://tizen.org/privilege/bluetooth
2275 * @return 0 on success, otherwise a negative error value.
2276 * @retval #BT_ERROR_NONE Successful
2277 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2278 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2279 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
2280 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
2281 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2283 * @pre The Bluetooth NAP service must be activated with bt_nap_activate().
2284 * @see bt_nap_activate()
2286 int bt_nap_disconnect_all(void);
2290 * @ingroup CAPI_NETWORK_BLUETOOTH_PAN_NAP_MODULE
2291 * @brief Disconnects the specified PANU(Personal Area Networking User) which is connected to you.
2292 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2294 * @privilege %http://tizen.org/privilege/bluetooth
2295 * @param[in] remote_address The remote address
2296 * @return 0 on success, otherwise a negative error value.
2297 * @retval #BT_ERROR_NONE Successful
2298 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2299 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2300 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
2301 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
2302 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2304 * @pre The Bluetooth NAP service must be activated with bt_nap_activate().
2305 * @see bt_nap_activate()
2307 int bt_nap_disconnect(const char *remote_address);
2311 * @ingroup CAPI_NETWORK_BLUETOOTH_PAN_NAP_MODULE
2312 * @brief Registers a callback function that will be invoked when the connection state changes.
2313 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2314 * @param[in] callback The callback function to register
2315 * @param[in] user_data The user data to be passed to the callback function
2316 * @return 0 on success, otherwise a negative error value.
2317 * @retval #BT_ERROR_NONE Successful
2318 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2319 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2320 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2322 * @pre The Bluetooth service must be initialized with bt_initialize().
2323 * @post bt_nap_connection_state_changed_cb() will be invoked.
2324 * @see bt_initialize()
2325 * @see bt_nap_connection_state_changed_cb()
2326 * @see bt_nap_unset_connection_state_changed_cb()
2328 int bt_nap_set_connection_state_changed_cb(bt_nap_connection_state_changed_cb callback, void *user_data);
2332 * @ingroup CAPI_NETWORK_BLUETOOTH_PAN_NAP_MODULE
2333 * @brief Unregisters a callback function that will be invoked when the connection state changes.
2334 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2335 * @return 0 on success, otherwise a negative error value.
2336 * @retval #BT_ERROR_NONE Successful
2337 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2338 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2340 * @pre The Bluetooth service must be initialized with bt_initialize().
2341 * @post bt_nap_connection_state_changed_cb() will be invoked.
2342 * @see bt_initialize()
2343 * @see bt_nap_connection_state_changed_cb()
2344 * @see bt_nap_set_connection_state_changed_cb()
2346 int bt_nap_unset_connection_state_changed_cb(void);
2350 * @ingroup CAPI_NETWORK_BLUETOOTH_PAN_PANU_MODULE
2351 * @brief Registers a callback function that will be invoked when the connection state changes.
2352 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2353 * @param[in] callback The callback function to register
2354 * @param[in] user_data The user data to be passed to the callback function
2355 * @return 0 on success, otherwise a negative error value.
2356 * @retval #BT_ERROR_NONE Successful
2357 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2358 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2359 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2361 * @pre The Bluetooth service must be initialized with bt_initialize().
2362 * @post bt_nap_connection_state_changed_cb() will be invoked.
2363 * @see bt_initialize()
2364 * @see bt_panu_connection_state_changed_cb()
2365 * @see bt_panu_unset_connection_state_changed_cb()
2367 int bt_panu_set_connection_state_changed_cb(bt_panu_connection_state_changed_cb callback, void *user_data);
2371 * @ingroup CAPI_NETWORK_BLUETOOTH_PAN_PANU_MODULE
2372 * @brief Unregisters a callback function that will be invoked when the connection state changes.
2373 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2374 * @return 0 on success, otherwise a negative error value.
2375 * @retval #BT_ERROR_NONE Successful
2376 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2377 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2379 * @pre The Bluetooth service must be initialized with bt_initialize().
2380 * @post bt_nap_connection_state_changed_cb() will be invoked.
2381 * @see bt_initialize()
2382 * @see bt_panu_connection_state_changed_cb()
2383 * @see bt_panu_set_connection_state_changed_cb()
2385 int bt_panu_unset_connection_state_changed_cb(void);
2389 * @ingroup CAPI_NETWORK_BLUETOOTH_PAN_PANU_MODULE
2390 * @brief Connects the remote device with the PAN(Personal Area Networking) service, asynchronously.
2391 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2393 * @privilege %http://tizen.org/privilege/bluetooth
2394 * @param[in] remote_address The remote address
2395 * @param[in] type The type of PAN service
2396 * @return 0 on success, otherwise a negative error value.
2397 * @retval #BT_ERROR_NONE Successful
2398 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2399 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2400 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2401 * @retval #BT_ERROR_OUT_OF_MEMORY Out of memory
2402 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
2403 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
2404 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2406 * @pre The local device must be bonded with the remote device by bt_device_create_bond().
2407 * @post bt_panu_connection_state_changed_cb() will be invoked.
2408 * @see bt_panu_disconnect()
2409 * @see bt_panu_connection_state_changed_cb()
2411 int bt_panu_connect(const char *remote_address, bt_panu_service_type_e type);
2415 * @ingroup CAPI_NETWORK_BLUETOOTH_PAN_PANU_MODULE
2416 * @brief Disconnects the remote device with the PAN(Personal Area Networking) service, asynchronously.
2417 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2419 * @privilege %http://tizen.org/privilege/bluetooth
2420 * @param[in] remote_address The remote address
2421 * @return 0 on success, otherwise a negative error value.
2422 * @retval #BT_ERROR_NONE Successful
2423 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2424 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2425 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2426 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
2427 * @retval #BT_ERROR_OUT_OF_MEMORY Out of memory
2428 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
2429 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
2430 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2432 * @pre The remote device must be connected by bt_panu_connect().
2433 * @post bt_panu_connection_state_changed_cb() will be invoked.
2434 * @see bt_panu_connect()
2435 * @see bt_panu_connection_state_changed_cb()
2437 int bt_panu_disconnect(const char *remote_address);
2441 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
2442 * @brief update LE connection.
2443 * @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif
2444 * @privlevel platform
2445 * @privilege %http://tizen.org/privilege/bluetooth.admin
2446 * @return 0 on success, otherwise a negative error value.
2447 * @retval #BT_ERROR_NONE Successful
2448 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2449 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
2450 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2452 * @pre The Bluetooth service must be initialized by bt_initialize().
2453 * @pre The remote device must be connected with bt_gatt_connect().
2455 int bt_device_le_conn_update(const char *device_address,
2456 const bt_le_conn_update_s *parameters);
2460 * @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE
2461 * @brief Gets the is_alias_set property of a bonded device.
2464 * @param[in] remote_address The address of remote device
2465 * @param[out] is_alias_set The is_alias_set property of device
2467 * @return 0 on success, otherwise a negative error value.
2468 * @retval #BT_ERROR_NONE Successful
2469 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
2470 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
2471 * @retval #BT_ERROR_OUT_OF_MEMORY Out of memory
2472 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2473 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
2475 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
2477 int bt_adapter_get_bonded_device_is_alias_set(const char *remote_address, gboolean *is_alias_set);
2480 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2481 * @brief Sets Restriction for BT mode(BT allowed or not).
2483 * @privlevel platform
2484 * @privilege %http://tizen.org/privilege/bluetooth.admin
2486 * @param[in] value - BT Allow value.
2487 * BT_DPM_ERROR = -1, < bluetooth allowance error
2488 * BT_DPM_BT_ALLOWED, < bluetooth allowance allowed
2489 * BT_DPM_HANDSFREE_ONLY, < bluetooth allowance handsfree only
2490 * BT_DPM_BT_RESTRICTED, < bluetooth allowance restricted
2491 * @retval #BT_ERROR_NONE Successful
2492 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2493 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2494 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2495 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2498 * @see bt_dpm_get_allow_bluetooth_mode()
2500 int bt_dpm_set_allow_bluetooth_mode(bt_dpm_allow_e value);
2503 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2504 * @brief Reads Restriction for BT mode(BT allowed or not).
2506 * @privlevel platform
2507 * @privilege %http://tizen.org/privilege/bluetooth.admin
2510 * @param[out] value - BT Allow value.
2511 * BT_DPM_ERROR = -1, < bluetooth allowance error
2512 * BT_DPM_BT_ALLOWED, < bluetooth allowance allowed
2513 * BT_DPM_HANDSFREE_ONLY, < bluetooth allowance handsfree only
2514 * BT_DPM_BT_RESTRICTED, < bluetooth allowance restricted
2515 * @retval #BT_ERROR_NONE Successful
2516 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2517 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2518 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2519 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2522 * @see bt_dpm_set_allow_bluetooth_mode()
2524 int bt_dpm_get_allow_bluetooth_mode(bt_dpm_allow_e *value);
2527 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2528 * @brief Sets the Restriction for device.
2530 * @privlevel platform
2531 * @privilege %http://tizen.org/privilege/bluetooth.admin
2533 * @param[in] value - State value.
2534 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
2535 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
2536 * @retval #BT_ERROR_NONE Successful
2537 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2538 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2539 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2540 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2542 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2543 * @see bt_dpm_get_allow_bluetooth_mode()
2545 int bt_dpm_activate_device_restriction(bt_dpm_status_e value);
2548 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2549 * @brief Reads the Restriction for device.
2551 * @privlevel platform
2552 * @privilege %http://tizen.org/privilege/bluetooth.admin
2554 * @param[out] value - State value.
2555 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
2556 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
2557 * @retval #BT_ERROR_NONE Successful
2558 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2559 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2560 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2561 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2563 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2564 * @see bt_dpm_get_allow_bluetooth_mode()
2566 int bt_dpm_is_device_restriction_active(bt_dpm_status_e *value);
2569 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2570 * @brief Sets the Restriction for uuid.
2572 * @privlevel platform
2573 * @privilege %http://tizen.org/privilege/bluetooth.admin
2575 * @param[in] value - State value.
2576 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
2577 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
2578 * @retval #BT_ERROR_NONE Successful
2579 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2580 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2581 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2582 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2584 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2585 * @see bt_dpm_get_allow_bluetooth_mode()
2587 int bt_dpm_activate_uuid_restriction(bt_dpm_status_e value);
2590 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2591 * @brief Reads the Restriction for uuid.
2593 * @privlevel platform
2594 * @privilege %http://tizen.org/privilege/bluetooth.admin
2596 * @param[out] value - State value.
2597 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
2598 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
2599 * @retval #BT_ERROR_NONE Successful
2600 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2601 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2602 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2603 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2605 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2606 * @see bt_dpm_get_allow_bluetooth_mode()
2608 int bt_dpm_is_uuid_restriction_active(bt_dpm_status_e *value);
2611 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2612 * @brief Adds the device to blacklist.
2614 * @privlevel platform
2615 * @privilege %http://tizen.org/privilege/bluetooth.admin
2617 * @param[in] device_address - Device address
2618 * @retval #BT_ERROR_NONE Successful
2619 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2620 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2621 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2622 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2624 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2625 * @see bt_dpm_get_allow_bluetooth_mode()
2627 int bt_dpm_add_devices_to_blacklist(const char *device_address);
2630 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2631 * @brief Adds the device to whitelist.
2633 * @privlevel platform
2634 * @privilege %http://tizen.org/privilege/bluetooth.admin
2636 * @param[in] device_address - Device address
2637 * @retval #BT_ERROR_NONE Successful
2638 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2639 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2640 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2641 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2643 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2644 * @see bt_dpm_get_allow_bluetooth_mode()
2646 int bt_dpm_add_devices_to_whitelist(const char *device_address);
2649 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2650 * @brief Adds the uuids to blacklist.
2652 * @privlevel platform
2653 * @privilege %http://tizen.org/privilege/bluetooth.admin
2655 * @param[in] service_uuids - profile or custom service uuids
2656 * @retval #BT_ERROR_NONE Successful
2657 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2658 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2659 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2660 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2662 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2663 * @see bt_dpm_get_allow_bluetooth_mode()
2665 int bt_dpm_add_uuids_to_blacklist(const char *service_uuid);
2668 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2669 * @brief Adds the uuid to whitelist.
2671 * @privlevel platform
2672 * @privilege %http://tizen.org/privilege/bluetooth.admin
2674 * @param[in] service_uuids - profile or custom service uuids
2675 * @retval #BT_ERROR_NONE Successful
2676 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2677 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2678 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2679 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2681 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2682 * @see bt_dpm_get_allow_bluetooth_mode()
2684 int bt_dpm_add_uuids_to_whitelist(const char *service_uuid);
2687 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2688 * @brief Clears the device from blacklist.
2690 * @privlevel platform
2691 * @privilege %http://tizen.org/privilege/bluetooth.admin
2694 * @retval #BT_ERROR_NONE Successful
2695 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2696 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2697 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2698 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2700 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2701 * @see bt_dpm_get_allow_bluetooth_mode()
2703 int bt_dpm_clear_devices_from_blacklist(void);
2706 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2707 * @brief Clears the device from whitelist.
2709 * @privlevel platform
2710 * @privilege %http://tizen.org/privilege/bluetooth.admin
2713 * @retval #BT_ERROR_NONE Successful
2714 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2715 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2716 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2717 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2719 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2720 * @see bt_dpm_get_allow_bluetooth_mode()
2722 int bt_dpm_clear_devices_from_whitelist(void);
2725 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2726 * @brief Clears the uuids from blacklist.
2728 * @privlevel platform
2729 * @privilege %http://tizen.org/privilege/bluetooth.admin
2732 * @retval #BT_ERROR_NONE Successful
2733 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2734 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2735 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2736 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2738 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2739 * @see bt_dpm_get_allow_bluetooth_mode()
2741 int bt_dpm_clear_uuids_from_blacklist(void);
2744 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2745 * @brief Clears the uuids from whitelist.
2747 * @privlevel platform
2748 * @privilege %http://tizen.org/privilege/bluetooth.admin
2751 * @retval #BT_ERROR_NONE Successful
2752 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2753 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2754 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2755 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2757 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2758 * @see bt_dpm_get_allow_bluetooth_mode()
2760 int bt_dpm_clear_uuids_from_whitelist(void);
2763 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2764 * @brief Reads the devices from blacklist.
2766 * @privlevel platform
2767 * @privilege %http://tizen.org/privilege/bluetooth.admin
2769 * @param[out] device_list - list of devices
2770 * @retval #BT_ERROR_NONE Successful
2771 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2772 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2773 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2774 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2776 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2777 * @see bt_dpm_get_allow_bluetooth_mode()
2779 int bt_dpm_get_devices_from_blacklist(bt_dpm_device_list_s **device_list);
2782 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2783 * @brief Reads the devices from whitelist.
2785 * @privlevel platform
2786 * @privilege %http://tizen.org/privilege/bluetooth.admin
2788 * @param[out] device_list - list of devices
2789 * @retval #BT_ERROR_NONE Successful
2790 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2791 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2792 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2793 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2795 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2796 * @see bt_dpm_get_allow_bluetooth_mode()
2798 int bt_dpm_get_devices_from_whitelist(bt_dpm_device_list_s **device_list);
2801 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2802 * @brief Reads the uuids from blacklist.
2804 * @privlevel platform
2805 * @privilege %http://tizen.org/privilege/bluetooth.admin
2807 * @param[out] uuid_list - list of uuids
2808 * @retval #BT_ERROR_NONE Successful
2809 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2810 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2811 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2812 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2814 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2815 * @see bt_dpm_get_allow_bluetooth_mode()
2817 int bt_dpm_get_uuids_from_blacklist(bt_dpm_uuids_list_s **uuid_list);
2820 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2821 * @brief Reads the uuids from whitelist.
2823 * @privlevel platform
2824 * @privilege %http://tizen.org/privilege/bluetooth.admin
2826 * @param[out] uuid_list - list of uuids
2827 * @retval #BT_ERROR_NONE Successful
2828 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2829 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2830 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2831 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2833 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2834 * @see bt_dpm_get_allow_bluetooth_mode()
2836 int bt_dpm_get_uuids_from_whitelist(bt_dpm_uuids_list_s **uuid_list);
2839 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2840 * @brief Removes the devices from whitelist.
2842 * @privlevel platform
2843 * @privilege %http://tizen.org/privilege/bluetooth.admin
2845 * @param[in] device_address - Device address
2846 * @retval #BT_ERROR_NONE Successful
2847 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2848 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2849 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2850 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2852 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2853 * @see bt_dpm_get_allow_bluetooth_mode()
2855 int bt_dpm_remove_device_from_whitelist(const char *device_address);
2858 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2859 * @brief Removes the devices from blacklist.
2861 * @privlevel platform
2862 * @privilege %http://tizen.org/privilege/bluetooth.admin
2864 * @param[in] device_address - Device address
2865 * @retval #BT_ERROR_NONE Successful
2866 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2867 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2868 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2869 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2871 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2872 * @see bt_dpm_get_allow_bluetooth_mode()
2874 int bt_dpm_remove_device_from_blacklist(const char *device_address);
2877 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2878 * @brief Removes the uuids from whitelist.
2880 * @privlevel platform
2881 * @privilege %http://tizen.org/privilege/bluetooth.admin
2883 * @param[in] service_uuids - profile or custom service uuids
2884 * @retval #BT_ERROR_NONE Successful
2885 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2886 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2887 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2888 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2890 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2891 * @see bt_dpm_get_allow_bluetooth_mode()
2893 int bt_dpm_remove_uuid_from_whitelist(const char *service_uuid);
2896 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2897 * @brief Removes the uuids from blacklist.
2899 * @privlevel platform
2900 * @privilege %http://tizen.org/privilege/bluetooth.admin
2902 * @param[in] service_uuids - profile or custom service uuids
2903 * @retval #BT_ERROR_NONE Successful
2904 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2905 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2906 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2907 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2909 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2910 * @see bt_dpm_get_allow_bluetooth_mode()
2912 int bt_dpm_remove_uuid_from_blacklist(const char *service_uuid);
2915 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2916 * @brief Sets the Restriction for outgoing call.
2918 * @privlevel platform
2919 * @privilege %http://tizen.org/privilege/bluetooth.admin
2921 * @param[in] value - State value.
2922 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
2923 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
2924 * @retval #BT_ERROR_NONE Successful
2925 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2926 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2927 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2928 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2930 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2931 * @see bt_dpm_get_allow_bluetooth_mode()
2933 int bt_dpm_set_allow_outgoing_call(bt_dpm_status_e value);
2936 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2937 * @brief Reads the Restriction for outgoing call.
2939 * @privlevel platform
2940 * @privilege %http://tizen.org/privilege/bluetooth.admin
2942 * @param[out] value - State value.
2943 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
2944 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
2945 * @retval #BT_ERROR_NONE Successful
2946 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2947 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2948 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2949 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2951 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2952 * @see bt_dpm_get_allow_bluetooth_mode()
2954 int bt_dpm_get_allow_outgoing_call(bt_dpm_status_e *value);
2957 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2958 * @brief Sets the Restriction for pairing.
2960 * @privlevel platform
2961 * @privilege %http://tizen.org/privilege/bluetooth.admin
2963 * @param[in] value - State value.
2964 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
2965 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
2966 * @retval #BT_ERROR_NONE Successful
2967 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2968 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2969 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2970 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2972 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2973 * @see bt_dpm_get_allow_bluetooth_mode()
2975 int bt_dpm_set_pairing_state(bt_dpm_status_e value);
2978 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
2979 * @brief Reads the Restriction for pairing.
2981 * @privlevel platform
2982 * @privilege %http://tizen.org/privilege/bluetooth.admin
2984 * @param[out] value - State value.
2985 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
2986 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
2987 * @retval #BT_ERROR_NONE Successful
2988 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
2989 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
2990 * @retval #BT_ERROR_NOT_ENABLED Not enabled
2991 * @retval #BT_ERROR_OPERATION_FAILED operation failed
2993 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
2994 * @see bt_dpm_get_allow_bluetooth_mode()
2996 int bt_dpm_get_pairing_state(bt_dpm_status_e *value);
2999 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
3000 * @brief Sets the Restriction for profiles.
3002 * @privlevel platform
3003 * @privilege %http://tizen.org/privilege/bluetooth.admin
3005 * @param[in]profile - Profile.
3006 * BT_DPM_POLICY_A2DP_PROFILE_STATE,
3007 * BT_DPM_POLICY_AVRCP_PROFILE_STATE,
3008 * BT_DPM_POLICY_BPP_PROFILE_STATE,
3009 * BT_DPM_POLICY_DUN_PROFILE_STATE,
3010 * BT_DPM_POLICY_FTP_PROFILE_STATE,
3011 * BT_DPM_POLICY_HFP_PROFILE_STATE,
3012 * BT_DPM_POLICY_HSP_PROFILE_STATE,
3013 * BT_DPM_POLICY_PBAP_PROFILE_STATE,
3014 * BT_DPM_POLICY_SAP_PROFILE_STATE,
3015 * BT_DPM_POLICY_SPP_PROFILE_STATE,
3016 * BT_DPM_PROFILE_NONE
3017 * @retval #BT_ERROR_NONE Successful
3018 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
3019 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
3020 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3021 * @retval #BT_ERROR_OPERATION_FAILED operation failed
3023 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
3024 * @see bt_dpm_get_allow_bluetooth_mode()
3026 int bt_dpm_set_profile_state(bt_dpm_profile_e profile, bt_dpm_status_e value);
3029 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
3030 * @brief Reads the Restriction for profiles.
3032 * @privlevel platform
3033 * @privilege %http://tizen.org/privilege/bluetooth.admin
3035 * @param[in]profile - Profile.
3036 * BT_DPM_POLICY_A2DP_PROFILE_STATE,
3037 * BT_DPM_POLICY_AVRCP_PROFILE_STATE,
3038 * BT_DPM_POLICY_BPP_PROFILE_STATE,
3039 * BT_DPM_POLICY_DUN_PROFILE_STATE,
3040 * BT_DPM_POLICY_FTP_PROFILE_STATE,
3041 * BT_DPM_POLICY_HFP_PROFILE_STATE,
3042 * BT_DPM_POLICY_HSP_PROFILE_STATE,
3043 * BT_DPM_POLICY_PBAP_PROFILE_STATE,
3044 * BT_DPM_POLICY_SAP_PROFILE_STATE,
3045 * BT_DPM_POLICY_SPP_PROFILE_STATE,
3046 * BT_DPM_PROFILE_NONE
3047 * @param[out] value - State value.
3048 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
3049 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
3050 * @retval #BT_ERROR_NONE Successful
3051 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
3052 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
3053 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3054 * @retval #BT_ERROR_OPERATION_FAILED operation failed
3056 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
3057 * @see bt_dpm_get_allow_bluetooth_mode()
3059 int bt_dpm_get_profile_state(bt_dpm_profile_e profile, bt_dpm_status_e *value);
3062 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
3063 * @brief Sets the Restriction for desktop connectivity.
3065 * @privlevel platform
3066 * @privilege %http://tizen.org/privilege/bluetooth.admin
3068 * @param[in] value - State value.
3069 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
3070 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
3071 * @retval #BT_ERROR_NONE Successful
3072 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
3073 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
3074 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3075 * @retval #BT_ERROR_OPERATION_FAILED operation failed
3077 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
3078 * @see bt_dpm_get_allow_bluetooth_mode()
3080 int bt_dpm_set_desktop_connectivity_state(bt_dpm_status_e value);
3083 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
3084 * @brief Reads the Restriction for desktop connectivity.
3086 * @privlevel platform
3087 * @privilege %http://tizen.org/privilege/bluetooth.admin
3089 * @param[out] value - State value.
3090 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
3091 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
3092 * @retval #BT_ERROR_NONE Successful
3093 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
3094 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
3095 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3096 * @retval #BT_ERROR_OPERATION_FAILED operation failed
3098 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
3099 * @see bt_dpm_get_allow_bluetooth_mode()
3101 int bt_dpm_get_desktop_connectivity_state(bt_dpm_status_e *value);
3104 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
3105 * @brief Sets the Restriction for discoverable mode.
3107 * @privlevel platform
3108 * @privilege %http://tizen.org/privilege/bluetooth.admin
3110 * @param[in] value - State value.
3111 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
3112 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
3113 * @retval #BT_ERROR_NONE Successful
3114 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
3115 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
3116 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3117 * @retval #BT_ERROR_OPERATION_FAILED operation failed
3119 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
3120 * @see bt_dpm_get_allow_bluetooth_mode()
3122 int bt_dpm_set_discoverable_state(bt_dpm_status_e value);
3125 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
3126 * @brief Reads the Restriction for discoverable mode.
3128 * @privlevel platform
3129 * @privilege %http://tizen.org/privilege/bluetooth.admin
3131 * @param[out] value - State value.
3132 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
3133 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
3134 * @retval #BT_ERROR_NONE Successful
3135 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
3136 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
3137 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3138 * @retval #BT_ERROR_OPERATION_FAILED operation failed
3140 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
3141 * @see bt_dpm_get_allow_bluetooth_mode()
3143 int bt_dpm_get_discoverable_state(bt_dpm_status_e *value);
3146 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
3147 * @brief Sets the Restriction for limited discoverable mode.
3149 * @privlevel platform
3150 * @privilege %http://tizen.org/privilege/bluetooth.admin
3152 * @param[in] value - State value.
3153 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
3154 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
3155 * @retval #BT_ERROR_NONE Successful
3156 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
3157 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
3158 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3159 * @retval #BT_ERROR_OPERATION_FAILED operation failed
3161 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
3162 * @see bt_dpm_get_allow_bluetooth_mode()
3165 int bt_dpm_set_limited_discoverable_state(bt_dpm_status_e value);
3168 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
3169 * @brief Reads the Restriction for limited discoverable mode.
3171 * @privlevel platform
3172 * @privilege %http://tizen.org/privilege/bluetooth.admin
3174 * @param[out] value - State value.
3175 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
3176 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
3177 * @retval #BT_ERROR_NONE Successful
3178 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
3179 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
3180 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3181 * @retval #BT_ERROR_OPERATION_FAILED operation failed
3183 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
3184 * @see bt_dpm_get_allow_bluetooth_mode()
3186 int bt_dpm_get_limited_discoverable_state(bt_dpm_status_e *value);
3189 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
3190 * @brief Sets the Restriction for Data transfer.
3192 * @privlevel platform
3193 * @privilege %http://tizen.org/privilege/bluetooth.admin
3195 * @param[in] value - State value.
3196 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
3197 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
3198 * @retval #BT_ERROR_NONE Successful
3199 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
3200 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
3201 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3202 * @retval #BT_ERROR_OPERATION_FAILED operation failed
3204 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
3205 * @see bt_dpm_get_allow_bluetooth_mode()
3207 int bt_dpm_set_data_transfer_state(bt_dpm_status_e value);
3210 * @ingroup CAPI_NETWORK_BLUETOOTH_DPM_MODULE
3211 * @brief Reads the Restriction for Data transfer.
3213 * @privlevel platform
3214 * @privilege %http://tizen.org/privilege/bluetooth.admin
3216 * @param[out] value - State value.
3217 * BT_DPM_ALLOWED = 0, < DPM Policy status allowed.
3218 * BT_DPM_RESTRICTED = 1, < DPM Policy status restricted.
3219 * @retval #BT_ERROR_NONE Successful
3220 * @retval #BT_ERROR_INVALID_PARAMETER invalid paramter
3221 * @retval #BT_ERROR_NOT_SUPPORTED Not suported
3222 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3223 * @retval #BT_ERROR_OPERATION_FAILED operation failed
3225 * @pre bt_dpm_set_allow_bluetooth_mode must be allowed.
3226 * @see bt_dpm_get_allow_bluetooth_mode()
3228 int bt_dpm_get_data_transfer_state(bt_dpm_status_e *value);
3231 * @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE
3232 * @brief Gets the pbap connected status.
3234 * @param[in] remote_address The address of the remote device
3235 * @param[out] connected_status the connected status
3236 * @return 0 on success, otherwise a negative error value.
3237 * @retval #BT_ERROR_NONE Successful
3238 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3239 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3240 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3241 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_BONDED Remote device not bonded
3242 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
3243 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3245 * @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED.
3247 int bt_pbap_client_is_connected(const char *address, bool *connected_status);
3250 * @ingroup CAPI_NETWORK_BLUETOOTH_HID_MODULE
3251 * @brief Sends the custom event data.
3252 * @since_tizen @if WEARABLE 3.0 @endif
3253 * @privlevel platform
3254 * @privilege %http://tizen.org/privilege/bluetooth.admin
3256 * @param[in] remote_address device address of remote device.
3257 * @param[in] report_id reoport id need to be passed to remote device
3258 * @param[in] data The data need to be passed to remote device
3259 * @param[in] data_len The length of the data
3260 * @return 0 on success, otherwise a negative error value.
3261 * @retval #BT_ERROR_NONE Successful
3262 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3263 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3264 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
3265 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
3267 * @pre The HID connection must be established.
3268 * @see bt_hid_device_connection_state_changed_cb()
3270 int bt_hid_device_send_custom_event(const char *remote_address,
3271 unsigned char report_id, const char *data, unsigned int data_len);
3274 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE
3275 * @brief Sends the volume change request to the remote device.
3277 * @privlevel platform
3278 * @privilege %http://tizen.org/privilege/bluetooth.admin
3279 * @param[in] value The new volume level
3280 * @return 0 on success, otherwise a negative error value.
3281 * @retval #BT_ERROR_NONE Successful
3282 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3283 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3284 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3285 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
3286 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
3287 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
3288 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3290 * @pre The remote device must be connected.
3291 * @see bt_avrcp_target_connection_state_changed_cb()
3292 * @see bt_avrcp_target_initialize()
3294 int bt_avrcp_control_set_absolute_volume(unsigned int value);
3297 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE
3298 * @brief Sends the volume up request to the remote device.
3300 * @privlevel platform
3301 * @privilege %http://tizen.org/privilege/bluetooth.admin
3302 * @return 0 on success, otherwise a negative error value.
3303 * @retval #BT_ERROR_NONE Successful
3304 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3305 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3306 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3307 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
3308 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
3309 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
3310 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3312 * @pre The remote device must be connected.
3313 * @see bt_avrcp_control_connect()
3314 * @see bt_avrcp_control_initialize()
3316 int bt_avrcp_control_increase_volume(void);
3319 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE
3320 * @brief Sends the volume down request to the remote device.
3322 * @privlevel platform
3323 * @privilege %http://tizen.org/privilege/bluetooth.admin
3324 * @return 0 on success, otherwise a negative error value.
3325 * @retval #BT_ERROR_NONE Successful
3326 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3327 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3328 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3329 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
3330 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
3331 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
3332 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3334 * @pre The remote device must be connected.
3335 * @see bt_avrcp_control_connect()
3336 * @see bt_avrcp_control_initialize()
3338 int bt_avrcp_control_decrease_volume(void);
3341 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE
3342 * @brief Sends the delay report to the remote device.
3344 * @privlevel platform
3345 * @privilege %http://tizen.org/privilege/bluetooth.admin
3346 * @param[in] value The new delay level
3347 * @return 0 on success, otherwise a negative error value.
3348 * @retval #BT_ERROR_NONE Successful
3349 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3350 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3351 * @retval #BT_ERROR_NOT_ENABLED Not enabled
3352 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
3353 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
3354 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
3355 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3357 * @pre The remote device must be connected.
3358 * @see bt_avrcp_target_connection_state_changed_cb()
3359 * @see bt_avrcp_target_initialize()
3361 int bt_avrcp_control_send_delay_report(unsigned int value);
3364 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE
3365 * @brief Registers a callback function that will be invoked when the delay is changed.
3367 * @param[in] callback The callback function to register
3368 * @param[in] user_data The user data to be passed to the callback function
3369 * @return 0 on success, otherwise a negative error value.
3370 * @retval #BT_ERROR_NONE Successful
3371 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3372 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3373 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3375 * @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize().
3376 * @see bt_avrcp_target_initialize()
3377 * @see bt_avrcp_control_initialize()
3379 int bt_avrcp_set_delay_changed_cb(bt_avrcp_delay_changed_cb callback, void *user_data);
3382 * @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE
3383 * @brief Unregisters a callback function that will be invoked when the delay is changed.
3385 * @return 0 on success, otherwise a negative error value.
3386 * @retval #BT_ERROR_NONE Successful
3387 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3388 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3390 * @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize().
3391 * @see bt_avrcp_target_initialize()
3392 * @see bt_avrcp_control_initialize()
3393 * @see bt_avrcp_set_delay_changed_cb()
3395 int bt_avrcp_unset_delay_changed_cb(void);
3398 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3399 * @brief Creates the Proximity Profile Reporter Role.
3402 * @privilege %http://tizen.org/privilege/bluetooth
3404 * @param[out] reporter proximity reporter server handle
3405 * @return @c 0 on success,
3406 * otherwise a negative error value
3407 * @retval #BT_ERROR_NONE Successful
3408 * @retval #BT_ERROR_ALREADY_DONE Already Enabled
3409 * @retval #BT_ERROR_OUT_OF_MEMORY out Of Memory
3411 int bt_proximity_reporter_create(bt_proximity_reporter_h *reporter);
3414 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3415 * @brief Destroys the Proximity Profile Reporter Role.
3418 * @privilege %http://tizen.org/privilege/bluetooth
3419 * @param[in] reporter proximity reporter server handle
3420 * @return @c 0 on success,
3421 * otherwise a negative error value
3422 * @retval #BT_ERROR_NONE Successful
3423 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3425 int bt_proximity_reporter_destroy(bt_proximity_reporter_h reporter);
3428 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3429 * @brief Creates the Proximity Profile Monitor Role.
3432 * @privilege %http://tizen.org/privilege/bluetooth
3433 * @param[in] remote address
3434 * @param[out] monitor proximity monitor handle
3435 * @return @c 0 on success,
3436 * otherwise a negative error value
3437 * @retval #BT_ERROR_NONE Successful
3438 * @retval #BT_ERROR_ALREADY_DONE Already Enabled
3439 * @retval #BT_ERROR_OUT_OF_MEMORY out Of Memory
3441 int bt_proximity_monitor_create(const char *remote_address, bt_proximity_monitor_h *monitor);
3444 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3445 * @brief Creates the Proximity Profile Monitor Role.
3448 * @privilege %http://tizen.org/privilege/bluetooth
3449 * @param[in] monitor proximity monitor handle
3450 * @return @c 0 on success,
3451 * otherwise a negative error value
3452 * @retval #BT_ERROR_NONE Successful
3453 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Device not Connected
3455 int bt_proximity_monitor_destroy(bt_proximity_monitor_h monitor);
3458 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3459 * @brief Proximity Monitor initiates the connection to remote reporter device.
3462 * @privilege %http://tizen.org/privilege/bluetooth
3463 * @param[in] monitor proximity monitor handle
3464 * @return @c 0 on success,
3465 * otherwise a negative error value
3466 * @retval #BT_ERROR_NONE Successful
3467 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3469 int bt_proximity_monitor_connect(bt_proximity_monitor_h monitor);
3472 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3473 * @brief Proximity Monitor disconnects with the remote reporter device.
3476 * @privilege %http://tizen.org/privilege/bluetooth
3477 * @param[in] proximity monitor handle
3478 * @return @c 0 on success,
3479 * otherwise a negative error value
3480 * @retval #BT_ERROR_NONE Successful
3481 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3483 int bt_proximity_monitor_disconnect(bt_proximity_monitor_h monitor);
3486 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3487 * @brief Sets proximity monitor connection state changed event change callback.
3490 * @privilege %http://tizen.org/privilege/bluetooth
3491 * @param[in] proximity monitor handle
3492 * @param[in] callback The callback function to register
3493 * @param[in] user_data The user data to be passed to the callback function
3494 * @return @c 0 on success,
3495 * otherwise a negative error value
3496 * @retval #BT_ERROR_NONE Successful
3497 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Device not Connected
3499 int bt_proximity_monitor_set_connection_state_changed_cb(bt_proximity_monitor_h monitor,
3500 bt_proximity_monitor_connection_state_changed_cb callback, void *user_data);
3503 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3504 * @brief Unsets proximity monitor connection state changed event change callback.
3507 * @privilege %http://tizen.org/privilege/bluetooth
3508 * @param[in] proximity monitor handle
3509 * @return @c 0 on success,
3510 * otherwise a negative error value
3511 * @retval #BT_ERROR_NONE Successful
3512 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Device not Connected
3514 int bt_proximity_monitor_unset_connection_state_changed_cb(bt_proximity_monitor_h monitor);
3517 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3518 * @brief Sets proximity reporter connection state changed event change callback.
3521 * @privilege %http://tizen.org/privilege/bluetooth
3522 * @param[in] reporter proximity reporter handle
3523 * @param[in] callback The callback function to register
3524 * @param[in] user_data The user data to be passed to the callback function
3525 * @return @c 0 on success,
3526 * otherwise a negative error value
3527 * @retval #BT_ERROR_NONE Successful
3529 int bt_proximity_reporter_set_connection_state_changed_cb(bt_proximity_reporter_h reporter,
3530 bt_proximity_reporter_connection_state_changed_cb callback, void *user_data);
3533 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3534 * @brief Unsets proximity reporter connection state changed event change callback.
3537 * @privilege %http://tizen.org/privilege/bluetooth
3538 * @param[in] proximity reporter handle
3539 * @return @c 0 on success,
3540 * otherwise a negative error value
3541 * @retval #BT_ERROR_NONE Successful
3543 int bt_proximity_reporter_unset_connection_state_changed_cb(bt_proximity_reporter_h reporter);
3546 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3547 * @brief Sets proximity reporter properties change callback.
3550 * @privilege %http://tizen.org/privilege/bluetooth
3551 * @param[in] reporter proximity reporter handle
3552 * @param[in] callback The callback function to register
3553 * @param[in] user_data The user data to be passed to the callback function
3554 * @return @c 0 on success,
3555 * otherwise a negative error value
3556 * @retval #BT_ERROR_NONE Successful
3558 int bt_proximity_reporter_set_property_changed_cb(bt_proximity_reporter_h reporter,
3559 bt_proximity_reporter_property_changed_cb callback, void *user_data);
3562 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3563 * @brief Unsets proximity reporter properties change callback.
3566 * @privilege %http://tizen.org/privilege/bluetooth
3567 * @param[in] reporter proximity reporter handle
3568 * @return @c 0 on success,
3569 * otherwise a negative error value
3570 * @retval #BT_ERROR_NONE Successful
3572 int bt_proximity_reporter_unset_property_changed_cb(bt_proximity_reporter_h reporter);
3575 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3576 * @brief Set the Proximity Profile monitor linkloss alert value.
3579 * @privilege %http://tizen.org/privilege/bluetooth
3580 * @param[in] monitor proximity monitor handle
3581 * @param[in] value The value to be set for link loss alert
3582 * @return @c 0 on success,
3583 * otherwise a negative error value
3584 * @retval #BT_ERROR_NONE Successful
3585 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Device not Connected
3586 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3588 int bt_proximity_monitor_set_linkloss_alert(bt_proximity_monitor_h monitor, int value);
3591 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3592 * @brief Set the Proximity Profile monitor immediate alert value.
3595 * @privilege %http://tizen.org/privilege/bluetooth
3596 * @param[in] monitor proximity monitor handle
3597 * @param[in] value The value to be set for immediate alert
3598 * @return @c 0 on success,
3599 * otherwise a negative error value
3600 * @retval #BT_ERROR_NONE Successful
3601 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Device not Connected
3602 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3604 int bt_proximity_monitor_set_immediate_alert(bt_proximity_monitor_h monitor, int value);
3607 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3608 * @brief Read the Proximity Profile monitor linkloss alert value.
3611 * @privilege %http://tizen.org/privilege/bluetooth
3612 * @param[in] monitor proximity monitor handle
3613 * @param[out] value value read for the linkloss alert.
3614 * @return @c 0 on success,
3615 * otherwise a negative error value
3616 * @retval #BT_ERROR_NONE Successful
3617 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Device not Connected
3618 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3620 int bt_proximity_monitor_get_linkloss_alert(bt_proximity_monitor_h monitor, int *value);
3623 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3624 * @brief Read the Proximity Profile monitor immediate alert value.
3627 * @privilege %http://tizen.org/privilege/bluetooth
3628 * @param[in] monitor proximity monitor handle
3629 * @param[out] value value read for the immedaite alert.
3630 * @return @c 0 on success,
3631 * otherwise a negative error value
3632 * @retval #BT_ERROR_NONE Successful
3633 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Device not Connected
3634 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3636 int bt_proximity_monitor_get_immediate_alert(bt_proximity_monitor_h monitor, int *value);
3639 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3640 * @brief Read the Proximity Profile monitor Signal level value.
3643 * @privilege %http://tizen.org/privilege/bluetooth
3644 * @param[in] monitor proximity monitor handle
3645 * @param[out] value value read for the signal level.
3646 * @return @c 0 on success,
3647 * otherwise a negative error value
3648 * @retval #BT_ERROR_NONE Successful
3649 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Device not Connected
3650 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3652 int bt_proximity_monitor_get_signal_level(bt_proximity_monitor_h monitor, int *value);
3655 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3656 * @brief Read the Proximity Profile reporter linkloss alert value.
3659 * @privilege %http://tizen.org/privilege/bluetooth
3660 * @param[in] remote_address remote device reporter address
3661 * @param[out] value value read for the linkloss alert.
3662 * @return @c 0 on success,
3663 * otherwise a negative error value
3664 * @retval #BT_ERROR_NONE Successful
3665 * @retval #BT_ERROR_NOT_INITIALIZED not initialized
3666 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3668 int bt_proximity_reporter_get_linkloss_alert(const char *remote_address, int *value);
3671 * @ingroup CAPI_NETWORK_BLUETOOTH_PROXIMITY_MODULE
3672 * @brief Read the Proximity Profile reporter immediate alert value.
3675 * @privilege %http://tizen.org/privilege/bluetooth
3676 * @param[in] remote_address remote device reporter address
3677 * @param[out] value value read for the immediate alert.
3678 * @return @c 0 on success,
3679 * otherwise a negative error value
3680 * @retval #BT_ERROR_NONE Successful
3681 * @retval #BT_ERROR_NOT_INITIALIZED not initialized
3682 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3684 int bt_proximity_reporter_get_immediate_alert(const char *remote_address, int *value);
3686 /* This internal API will be removed */
3689 * @deprecated Deprecated since 4.0. Use bt_adapter_le_scan_filter_unregister instead.
3690 * @brief API to Unset the Proximity uuids scan report
3692 int bt_adapter_le_scan_filter_unset_proximity_uuid(bt_scan_filter_h scan_filter) TIZEN_DEPRECATED_API;
3696 * @brief API to register TDS provider.
3697 * @since_tizen @if WEARABLE 3.0 @endif
3698 * @privlevel platform
3699 * @privilege %http://tizen.org/privilege/bluetooth.admin
3704 * @return 0 on success, otherwise a negative error value.
3705 * @retval #BT_ERROR_NONE Successful
3706 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3707 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3709 * @pre The Bluetooth service must be initialized with bt_initialize().
3711 * @see bt_initialize()
3712 * @see bt_tds_provider_unregister()
3714 int bt_tds_provider_register(void);
3718 * @brief API to unregister TDS provider.
3719 * @since_tizen @if WEARABLE 3.0 @endif
3720 * @privlevel platform
3721 * @privilege %http://tizen.org/privilege/bluetooth.admin
3726 * @return 0 on success, otherwise a negative error value.
3727 * @retval #BT_ERROR_NONE Successful
3728 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3729 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3731 * @pre The Bluetooth service must be initialized with bt_initialize().
3732 * @pre TDS provider must be registered with bt_tds_provider_register().
3734 * @see bt_initialize()
3735 * @see bt_tds_provider_register()
3737 int bt_tds_provider_unregister(void);
3741 * @brief API to create TDS provider.
3742 * @since_tizen @if WEARABLE 3.0 @endif
3743 * @privlevel platform
3744 * @privilege %http://tizen.org/privilege/bluetooth.admin
3746 * @param[in] transport Transport to be discovered over BLE.
3747 * @param[out] provider The handle associated with the newly created provider.
3749 * @return 0 on success, otherwise a negative error value.
3750 * @retval #BT_ERROR_NONE Successful
3751 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3752 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3753 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3755 * @pre The Bluetooth service must be initialized with bt_initialize().
3756 * @pre TDS provider must be registered with bt_tds_provider_register().
3758 * @see bt_initialize()
3759 * @see bt_tds_provider_register()
3760 * @see bt_tds_provider_unregister()
3761 * @see bt_tds_provider_destroy()
3763 int bt_tds_provider_create(bt_tds_provider_h *provider, bt_tds_transport_e transport);
3767 * @brief API to destroy TDS provider.
3768 * @since_tizen @if WEARABLE 3.0 @endif
3769 * @privlevel platform
3770 * @privilege %http://tizen.org/privilege/bluetooth.admin
3772 * @param[in] provider The handle associated with the provider
3774 * @return 0 on success, otherwise a negative error value.
3775 * @retval #BT_ERROR_NONE Successful
3776 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3777 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3778 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3780 * @pre The Bluetooth service must be initialized with bt_initialize().
3781 * @pre TDS provider must be registered with bt_tds_provider_register().
3782 * @pre TDS provider must be created with bt_tds_provider_create().
3784 * @see bt_initialize()
3785 * @see bt_tds_provider_register()
3786 * @see bt_tds_provider_create()
3788 int bt_tds_provider_destroy(bt_tds_provider_h provider);
3792 * @brief API to set transport block data for transport provider.
3793 * @since_tizen @if WEARABLE 3.0 @endif
3794 * @privlevel platform
3795 * @privilege %http://tizen.org/privilege/bluetooth.admin
3797 * @param[in] provider The handle associated with the provider
3798 * @param[in] transport_state State of transport
3799 * @param[in] buf transport block data
3800 * @param[in] length transport block data length
3802 * @return 0 on success, otherwise a negative error value.
3803 * @retval #BT_ERROR_NONE Successful
3804 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3805 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3806 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3808 * @pre The Bluetooth service must be initialized with bt_initialize().
3809 * @pre TDS provider must be registered with bt_tds_provider_register().
3810 * @pre TDS provider must be created with bt_tds_provider_create().
3812 * @see bt_initialize()
3813 * @see bt_tds_provider_register()
3814 * @see bt_tds_provider_create()
3816 int bt_tds_provider_set_transport_data(bt_tds_provider_h provider,
3817 bt_tds_transport_state_e transport_state, unsigned char *buf, int length);
3821 * @brief API to set TDS provider manufacturer specific data.
3822 * @since_tizen @if WEARABLE 3.0 @endif
3823 * @privlevel platform
3824 * @privilege %http://tizen.org/privilege/bluetooth.admin
3826 * @param[in] buf manufacturer specific data
3827 * @param[in] length manufacturer data length
3829 * @return 0 on success, otherwise a negative error value.
3830 * @retval #BT_ERROR_NONE Successful
3831 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3832 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3833 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3835 * @pre The Bluetooth service must be initialized with bt_initialize().
3836 * @pre TDS provider must be registered with bt_tds_provider_register().
3838 * @see bt_initialize()
3839 * @see bt_tds_provider_register()
3840 * @see bt_tds_provider_create()
3842 int bt_tds_provider_set_manufacturer_data(unsigned char *buf, int length);
3846 * @brief API to send activation response to TDS seeker.
3847 * @since_tizen @if WEARABLE 3.0 @endif
3848 * @privlevel platform
3849 * @privilege %http://tizen.org/privilege/bluetooth.admin
3851 * @param[in] address Remote device bluetooth address
3852 * @param[in] result Result of activation request
3853 * BT_ERROR_NONE: success
3854 * BT_ERROR_INVALID_PARAMETER: Invalid data in activation request
3855 * BT_ERROR_OPERATION_FAILED: Operation failed
3856 * @param[in] provider The handle associated with the provider
3858 * @return 0 on success, otherwise a negative error value.
3859 * @retval #BT_ERROR_NONE Successful
3860 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3861 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3862 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3864 * @pre The Bluetooth service must be initialized with bt_initialize().
3865 * @pre TDS provider must be registered with bt_tds_provider_register().
3867 * @see bt_initialize()
3868 * @see bt_tds_provider_register()
3869 * @see bt_tds_activation_requested_cb()
3870 * @see bt_tds_set_transport_activation_requested_cb()
3871 * @see bt_tds_unset_transport_activation_requested_cb()
3873 int bt_tds_provider_send_activation_resp(char *address, int result, bt_tds_provider_h provider);
3877 * @brief API to set activation requeste callback.
3878 * @since_tizen @if WEARABLE 3.0 @endif
3880 * @privilege %http://tizen.org/privilege/bluetooth.admin
3882 * @param[in] callback The callback function to invoke
3883 * @param[in] user_data The user data to be passed to the callback function
3885 * @return 0 on success, otherwise a negative error value.
3886 * @retval #BT_ERROR_NONE Successful
3887 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3888 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3889 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
3891 * @pre The Bluetooth service must be initialized with bt_initialize().
3892 * @post bt_tds_activation_requested_cb() will be invoked.
3894 * @see bt_initialize()
3895 * @see bt_tds_activation_requested_cb()
3896 * @see bt_tds_unset_transport_activation_requested_cb()
3898 int bt_tds_set_transport_activation_requested_cb(
3899 bt_tds_activation_requested_cb callback, void *user_data);
3903 * @brief API to unset activation requeste callback.
3904 * @since_tizen @if WEARABLE 3.0 @endif
3906 * @privilege %http://tizen.org/privilege/bluetooth.admin
3909 * @return 0 on success, otherwise a negative error value.
3910 * @retval #BT_ERROR_NONE Successful
3911 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
3912 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
3914 * @see bt_initialize()
3915 * @see bt_tds_set_transport_activation_requested_cb()
3917 int bt_tds_unset_transport_activation_requested_cb(void);
3921 * @brief TDS Seeker Profile API to start seeking Remote TDS providers only
3923 int bt_tds_start_seeking_providers(bt_tds_provider_scan_result_cb cb, void *user_data);
3927 * @brief TDS Seeker Profile API to stop seeking Remote TDS providers
3929 int bt_tds_stop_seeking_providers(void);
3933 * @brief TDS Seeker Profile API to create Seeker Role associated with Remote TDS provider
3935 int bt_tds_seeker_create(const char *remote_address, bt_tds_seeker_h *seeker);
3939 * @brief TDS Seeker Profile API to destroy Seeker Role associated with Remote TDS provider
3941 int bt_tds_seeker_destroy(bt_tds_seeker_h seeker);
3945 * @brief TDS Seeker Profile API to set connection state changed event associated with Remote TDS provider
3947 int bt_tds_seeker_set_connection_state_changed_cb(bt_tds_seeker_h seeker,
3948 bt_tds_seeker_connection_state_changed_cb callback, void *user_data);
3952 * @brief TDS Seeker Profile API to unset connection state changed event associated with Remote TDS provider
3954 int bt_tds_seeker_unset_connection_state_changed_cb(bt_tds_seeker_h seeker);
3958 * @brief TDS Seeker Profile API to connect to Remote TDS provider
3960 int bt_tds_seeker_connect(bt_tds_seeker_h seeker);
3964 * @brief TDS Seeker Profile API to disconnect to Remote TDS provider
3966 int bt_tds_seeker_disconnect(bt_tds_seeker_h seeker);
3970 * @brief TDS Seeker Profile API to read complete TDS block data which is stored in Remote TDS provider's GATT database
3972 int bt_tds_seeker_get_complete_transport_blocks(bt_tds_seeker_h seeker,
3973 bt_tds_seeker_complete_transport_data_cb callback, void *user_data);
3977 * @brief TDS Seeker Profile API to Activate ALternate transport supported by Remote TDS provider
3979 int bt_tds_seeker_activate_control_point(bt_tds_seeker_h seeker,
3980 bt_tds_transport_e transport, unsigned char *buffer, int len,
3981 bt_tds_control_point_activation_indication_cb callback, void *user_data);
3985 * @brief Starts OTP server on the given directory location.
3987 int bt_otp_server_initialize(const char *directory);
3991 * @brief Stops OTP server.
3993 int bt_otp_server_deinitialize();
3997 * @brief Registers a callback function that will be invoked when the server state is changed.
3999 int bt_otp_set_server_state_changed_cb(bt_otp_server_state_changed_cb callback, void *user_data);
4003 * @brief Registers a callback function that will be invoked when the server state is changed.
4005 int bt_otp_unset_server_state_changed_cb(void);
4009 * @brief OTP Client Profile API to create Client Role associated with Remote OTP Server
4011 int bt_otp_client_create(const char *remote_address, bt_otp_client_h *otp_client);
4015 * @brief OTP Client Profile API to destroy Client Role associated with Remote OTP Server
4017 int bt_otp_client_destroy(bt_otp_client_h otp_client);
4021 * @brief OTP Client Profile API to set connection state changed event associated with Remote OTP Server
4023 int bt_otp_client_set_connection_state_changed_cb(bt_otp_client_h otp_client,
4024 bt_otp_client_state_changed_cb callback, void *user_data);
4028 * @brief OTP Client Profile API to unset connection state changed event associated with Remote OTP Server
4030 int bt_otp_client_unset_connection_state_changed_cb(bt_otp_client_h otp_client);
4034 * @brief OTP client API to connect to Remote OTP Server
4036 int bt_otp_client_connect(bt_otp_client_h otp_client);
4040 * @brief OTP client API to disconnect to Remote OTP Server
4042 int bt_otp_client_disconnect(bt_otp_client_h otp_client);
4046 * @brief OTP client API to discover all objects in Remote OTP Server
4048 int bt_otp_client_discover_all_objects(bt_otp_client_h otp_client,
4049 bt_otp_client_object_discovery_cb callback, void *user_data);
4053 * @brief OTP client API to select object in Remote OTP Server
4055 int bt_otp_client_select_object(bt_otp_client_h otp_client, unsigned long long id,
4056 bt_otp_client_object_select_cb callback, void *user_data);
4059 * @brief OTP client API to read remote objects contents
4061 int bt_otp_client_read_object_contents(bt_otp_client_h otp_client,
4062 bt_otp_client_read_object_complete_cb callback, void *user_data);
4065 * @brief OTP client API to create object on remote server
4067 int bt_otp_client_create_object(bt_otp_client_h otp_client,
4068 const char *file_path,
4069 bt_otp_client_object_create_cb callback,
4073 * @brief OTP client API to write object contents on remote server
4075 int bt_otp_client_write_object(bt_otp_client_h otp_client,
4076 const char *file_path,
4077 int offset, int length, int mode,
4078 bt_otp_client_object_write_cb callback,
4082 * @brief OTP client API to execute object on remote server
4084 int bt_otp_client_execute_object(bt_otp_client_h otp_client,
4085 bt_otp_client_object_execute_cb callback,
4089 * @brief OTP client API to delete object on remote server
4091 int bt_otp_client_delete_object(bt_otp_client_h otp_client,
4092 bt_otp_client_object_delete_cb callback,
4095 //======================================================================================
4099 * @brief HRP Sensor API to set initial heart rate value , will also notify to all connected clients if notification is enabled .
4101 int bt_hrp_sensor_set_heartrate_value(int heartrate);
4105 * @brief HRP Sensor API to set initial Location value , before creating sensor.
4107 int bt_hrp_sensor_set_location_value(bt_body_sensor_location_e location);
4111 * @brief HRP Sensor API to set initial energy value (Value Range : 0-9) , before creating sensor.
4113 int bt_hrp_sensor_set_energy_value(int energy_value);
4117 * @brief HRP Sensor API to set initial rr interval value (Value range : 0-8 If EE is supported,
4118 * 0-9 if EE not supported) before creating sensor.
4120 int bt_hrp_sensor_set_rr_interval(int interval);
4124 * @brief HRP Sensor API to set initial contact value , wearable in contact with
4125 * user or user has removed it, before creating sensor.
4127 int bt_hrp_sensor_set_contact_value(bool enable);
4131 * @brief HRP Sensor API to set manufacturer name , before creating sensor.
4133 int bt_hrp_sensor_set_device_manufacturer_name(char *manuf_name);
4137 * @brief HRP Sensor API for creating sensor and services.
4140 int bt_hrp_sensor_create(void);
4144 * @brief HRP Sensor API to destory heart rate sensor .
4147 int bt_hrp_sensor_destroy(void);
4151 * @brief HRP collector API to create collector .
4154 int bt_hrp_collector_create(const char *remote_address,
4155 bt_hrp_collector_h *collector);
4159 * @brief HRP collector API to destory collector.
4161 int bt_hrp_collector_destory(bt_hrp_collector_h collector);
4165 * @brief HRP collector API to start scan .
4167 int bt_hrp_collector_start_scan(bt_hrp_collector_scan_result_cb cb, void *user_data);
4171 * @brief HRP collector API to stop scan.
4173 int bt_hrp_collector_stop_scan(void);
4177 * @brief HRP collector API to connect to remote sensor .
4179 int bt_hrp_collector_connect(bt_hrp_collector_h collector);
4183 * @brief HRP collector API to disconnect to remote sensor .
4185 int bt_hrp_collector_disconnect(bt_hrp_collector_h collector);
4189 * @brief HRP collector API to set notification on / off.
4191 int bt_hrp_collector_set_notification(bt_hrp_collector_h collector,
4192 bt_hrp_collector_heart_rate_value_changed_cb callback,
4197 * @brief HRP collector API to read Body Sensor location , fills body sensor location in bsl_location
4200 int bt_hrp_collector_get_body_sensor_location(bt_hrp_collector_h collector,
4201 bt_hrp_collector_bsl_read_completed_cb bsl_read_cb);
4206 * @brief HRP collector API to set connection state callback
4209 int bt_hrp_collector_set_connection_state_changed_cb(bt_hrp_collector_h collector,
4210 bt_hrp_collector_connection_state_changed_cb callback,
4215 * @brief HRP collector API to unset connection state callback
4218 int bt_hrp_collector_unset_connection_state_changed_cb(bt_hrp_collector_h collector);
4221 * @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE
4222 * @brief Gets number of available packets to be used as a threshold for GATT data batching.
4223 * @since_tizen 5.5.0.0
4224 * @privlevel platform
4225 * @privilege %http://tizen.org/privilege/bluetooth.admin
4227 * @param[out] available_packets The number of available packets to be used as a threshold.
4229 * @return 0 on success, otherwise a negative error value.
4230 * @retval #BT_ERROR_NONE Successful
4231 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
4232 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
4233 * @retval #BT_ERROR_NOT_ENABLED Not enabled
4234 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
4235 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
4236 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
4238 * @see bt_gatt_enable_data_batching()
4240 int bt_gatt_get_data_batching_available_packets(int *available_packets);
4243 * @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE
4244 * @brief Enables GATT data batching.
4245 * @since_tizen 5.5.0.0
4246 * @privlevel platform
4247 * @privilege %http://tizen.org/privilege/bluetooth.admin
4248 * @remarks GATT data batching is disabled even if the gatt is disconnected or bt adapter is disabled.
4250 * @param[in] remote_address The address of the remote Bluetooth device for which RSSI is to be monitored.
4251 * @param[in] packet_threshold The threshold of packet count for receiving data.
4252 * @param[in] timeout The timeout to flush buffer.
4254 * @return 0 on success, otherwise a negative error value.
4255 * @retval #BT_ERROR_NONE Successful
4256 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
4257 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
4258 * @retval #BT_ERROR_QUOTA_EXCEEDED Quota exceeded
4259 * @retval #BT_ERROR_NOT_ENABLED Not enabled
4260 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
4261 * @retval #BT_ERROR_ALREADY_DONE Already enabled
4262 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
4263 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
4264 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
4266 * @see bt_gatt_get_data_batching_available_packets()
4267 * @see bt_gatt_disable_data_batching()
4269 int bt_gatt_enable_data_batching(const char *remote_address, int packet_threshold, int timeout);
4272 * @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE
4273 * @brief Disables GATT data batching.
4274 * @since_tizen 5.5.0.0
4275 * @privlevel platform
4276 * @privilege %http://tizen.org/privilege/bluetooth.admin
4278 * @param[in] remote_address The address of the remote Bluetooth device for which RSSI is to be monitored.
4280 * @return 0 on success, otherwise a negative error value.
4281 * @retval #BT_ERROR_NONE Successful
4282 * @retval #BT_ERROR_NOT_INITIALIZED Not initialized
4283 * @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter
4284 * @retval #BT_ERROR_NOT_ENABLED Not enabled
4285 * @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected
4286 * @retval #BT_ERROR_NOT_IN_PROGRESS Not enabled
4287 * @retval #BT_ERROR_OPERATION_FAILED Operation failed
4288 * @retval #BT_ERROR_PERMISSION_DENIED Permission denied
4289 * @retval #BT_ERROR_NOT_SUPPORTED Not supported
4291 * @see bt_gatt_enable_data_batching()
4293 int bt_gatt_disable_data_batching(const char *remote_address);
4298 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4299 * @brief Initializes the Mesh API
4301 * @remarks This function must be called before starting use BT Mesh API's.
4302 * You must free all resources of the BT Mesh service by
4303 * calling bt_mesh_deinitialize()
4304 * if Mesh service is no longer needed.
4306 * @privlevel platform
4308 int bt_mesh_initialize(void);
4312 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4313 * @brief Must be called if BT Mesh service is no longer needed
4315 * @privlevel platform
4317 int bt_mesh_deinitialize(void);
4321 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4322 * @brief API to create a arbitrary node.
4323 * Primary element is mandatory element for any node
4326 * @privlevel platform
4328 int bt_mesh_node_create(bt_mesh_node_features_s *features,
4329 bt_mesh_node_h *node_handle);
4333 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4334 * @brief Destroys the locally created mesh node
4335 * & all resources contained in it
4337 * @remarks: It is not allowed to arbitrarily destroy a locally created node,
4338 * if it is part of a mesh network already.
4339 * @remarks: Destroying a remote node is not supported.
4340 * @remarks: In order to reset a remote provisioned node, use bt_mesh_node_reset() API
4343 * @privlevel platform
4345 int bt_mesh_node_destroy(bt_mesh_node_h node_handle);
4349 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4350 * @brief API to create a mesh element. In case of Mesh Provisioner,
4351 * it will serve as a element of the local node of a Mesh Provisioner.
4354 * @privlevel platform
4356 int bt_mesh_node_create_element(bt_mesh_node_h node_handle,
4357 bt_mesh_element_h *element_handle);
4361 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4362 * @brief Destroys the locally created mesh element &
4363 * all resources contained in it (Ex: models)
4365 * @remarks: It is not allowed to arbitrarily destroy a
4366 * locally created element, if it is part of a mesh network already.
4367 * @remarks: Destroying element of a remote node is not supported.
4368 * @remarks: In order to reset a remote provisioned node,
4369 * use bt_mesh_node_reset() API
4372 * @privlevel platform
4374 int bt_mesh_element_destroy(bt_mesh_element_h element_handle);
4378 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4379 * @brief API to create a mesh Model instance.
4380 * In case of Mesh Provisioner, it will serve as a
4381 * Model of one of the elements of the local node of a Mesh Provisioner.
4384 * @privlevel platform
4386 int bt_mesh_element_create_model(bt_mesh_element_h element_handle,
4387 bt_mesh_model_id_s *model_id,
4388 bt_mesh_model_h *model_handle);
4392 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4393 * @brief Destroys the locally created mesh Model
4395 * @remarks: It is not allowed to arbitrarily destroy a locally created model,
4396 * if it is part of a mesh network already.
4397 * @remarks: Destroying model of a remote element is not supported.
4398 * @remarks: In order to reset a remote provisioned node,
4399 * use bt_mesh_node_reset() API
4402 * @privlevel platform
4404 int bt_mesh_model_destroy(bt_mesh_model_h model);
4408 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4409 * @brief API to get Model ID from handle.
4412 * @privlevel platform
4414 int bt_mesh_model_get_id(bt_mesh_model_h model,
4415 bt_mesh_model_id_s *model_id);
4419 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4420 * @brief Get Network instance in which node is contained.
4423 * @privlevel platform
4425 int bt_mesh_node_get_network(bt_mesh_node_h node,
4426 bt_mesh_network_h *netkwork);
4430 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4431 * @brief Get node instance in which element is contained.
4434 * @privlevel platform
4436 int bt_mesh_element_get_node(bt_mesh_element_h element,
4437 bt_mesh_node_h *node);
4441 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4442 * @brief Get element instance in which model is contained.
4445 * @privlevel platform
4447 int bt_mesh_model_get_element(bt_mesh_model_h model,
4448 bt_mesh_element_h *element);
4452 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4453 * @brief Get Network instance in which node is contained.
4456 * @privlevel platform
4458 int bt_mesh_appkey_get_netkey(bt_mesh_appkey_h appkey,
4459 bt_mesh_netkey_h *netkey);
4463 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4464 * @brief Call to create a fresh Local Mesh Provisioner.
4465 * Each Mesh Network will be characterisized
4466 * by only one Mesh Provisioner. Mesh Provisioner will
4467 * contain a Mesh Node which be called "local node".
4468 * CAPI user(application) can create multiple Mesh Network.
4469 * Each network will have a unique Mesh Provisioner
4471 * @param: in: config_client, local Mesh Provisioner node
4472 * @param: in: network_name, Mesh Network user friendly Name
4473 * @param: out: token, The token parameter is a hexadecimal string
4474 * of 8 bytes has been assigned to
4475 * the application when it first got provisioned/joined mesh.
4476 * order to authenticate itself and attach to the network as a mesh node.
4477 * @param: out: network, created Mesh Network instance
4479 * Note: Once the Mesh Network is successfully created
4480 * OR the 'local Node' is attached, it is *NOT* allowed to
4481 * change Local Node Hierarchy (Add/Delete Element(s), Add/Delete Model(s) etc.)
4484 * @privlevel platform
4486 int bt_mesh_network_create(bt_mesh_node_h config_client,
4487 const char *network_name,
4488 bt_mesh_network_h *network,
4493 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4494 * @brief Call to load a previously created Local Mesh Provisioner.
4495 * Each Mesh Network will be characterisized
4496 * by only one Mesh Provisioner. Mesh Provisioner will contain a
4497 * Mesh Config Node which be called "local node".
4498 * CAPI user(application) can create multiple Mesh Network.
4499 * Each network will have a unique Mesh Provisioner
4501 * @param: in: token, The token parameter is a 8 byte hexadecimal
4502 * string that has been assigned to the application when it first
4503 * got provisioned/joined mesh. The API will use the token to
4504 * authenticate itself and attach to the network as a mesh node.
4505 * Application should use a valid token to authenticate itself
4506 * as a Mesh Network Provisioner.
4507 * @param: out: network, created Mesh Network instance
4509 * Note: Once the Mesh Network is successfully created OR the
4510 * 'local Node' is attached,
4511 * it is *NOT* allowed to change Local Node Hierarchy
4512 * (Add/Delete Element(s), Add/Delete Model(s) etc.)
4514 * @see bt_mesh_network_create
4516 * @privlevel platform
4518 int bt_mesh_network_load(const char *token,
4519 bt_mesh_network_h *network);
4523 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4524 * @brief Set Mesh Network's user fiendly name.
4526 * @see bt_mesh_network_create
4528 * @privlevel platform
4530 int bt_mesh_network_set_name(bt_mesh_network_h network,
4531 const char *network_name);
4535 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4536 * @brief Get Mesh Network's user fiendly name.
4538 * @see bt_mesh_network_create
4540 * @privlevel platform
4542 int bt_mesh_network_get_name(bt_mesh_network_h network,
4543 char **network_name);
4547 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4548 * @brief Call to create and associate a mesh Network Key to Mesh Network
4550 * @see bt_mesh_network_create
4552 * @privlevel platform
4554 int bt_mesh_network_add_netkey(bt_mesh_network_h network,
4555 bt_mesh_netkey_h *netkey);
4559 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4560 * @brief Get all NetKey(s) attached to the Local Network.
4562 * @see bt_mesh_network_create
4563 * @see bt_mesh_network_add_netkey
4565 * @privlevel platform
4567 int bt_mesh_network_foreach_netkeys(bt_mesh_network_h network,
4568 bt_mesh_network_netkey_info_cb callback,
4573 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4574 * @brief Get global Netkey index from NetKey instance
4576 * @see bt_mesh_network_add_netkey
4578 * @privlevel platform
4580 int bt_mesh_netkey_get_index(bt_mesh_netkey_h netkey,
4585 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4586 * @brief Call to update a mesh Network Key.
4588 * @see bt_mesh_network_add_netkey
4590 * @privlevel platform
4592 int bt_mesh_netkey_update(bt_mesh_netkey_h netkey);
4596 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4597 * @brief Call to delete a mesh Network Key.
4599 * @remarks It is not allowed to destroy a netkey if it is already
4600 * added to any of nodes in the Mesh Network
4602 * @see bt_mesh_network_add_netkey
4604 * @privlevel platform
4606 int bt_mesh_netkey_delete(bt_mesh_netkey_h netkey);
4610 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4611 * @brief Call to create & associate a Application Key to a Network Key
4614 * @privlevel platform
4616 int bt_mesh_netkey_add_appkey(bt_mesh_netkey_h netkey,
4617 bt_mesh_appkey_h *appkey);
4621 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4622 * @brief Get all appkeys associated with a NetKey.
4624 * @see bt_mesh_netkey_add_appkey
4626 * @privlevel platform
4628 int bt_mesh_netkey_foreach_appkeys(bt_mesh_netkey_h netkey,
4629 bt_mesh_appkey_info_cb callback,
4634 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4635 * @brief Get global AppKey index from AppKey instance.
4637 * @see bt_mesh_netkey_add_appkey
4639 * @privlevel platform
4641 int bt_mesh_appkey_get_index(bt_mesh_appkey_h netkey,
4646 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4647 * @brief Call to update a mesh Network Key.
4649 * @see bt_mesh_netkey_add_appkey
4651 * @privlevel platform
4653 int bt_mesh_appkey_update(bt_mesh_appkey_h appkey);
4657 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4658 * @brief Call to delete a mesh Application Key.
4660 * @remarks It is not allowed to destroy an AppKey if it is already
4661 * added to any of nodes in the Mesh Network
4663 * @see bt_mesh_netkey_add_appkey
4665 * @privlevel platform
4667 int bt_mesh_appkey_delete(bt_mesh_appkey_h appkey);
4671 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4672 * @brief Call to get all devices attached to the network.
4673 * Node handle along with its primary unicast address will be returned
4676 * @privlevel platform
4678 int bt_mesh_network_foreach_devices(bt_mesh_network_h network,
4679 bt_mesh_network_device_info_cb callback,
4684 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4685 * @brief Call to get primary unicast address of the node from its handle
4688 * @privlevel platform
4690 int bt_mesh_node_get_primary_address(bt_mesh_node_h node,
4691 uint16_t *primary_address);
4695 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4696 * @brief Find each element present in a node
4699 * @privlevel platform
4701 int bt_mesh_node_foreach_element(bt_mesh_node_h node,
4702 bt_mesh_node_element_info_cb callback,
4707 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4708 * @brief Find each models present in an element
4711 * @privlevel platform
4713 int bt_mesh_element_foreach_models(bt_mesh_element_h element,
4714 bt_mesh_element_model_info_cb callback,
4720 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4721 * @brief Async call to discover unprovisioned device.
4722 * Each unprovisioned device will advertise itself with a unique Device UUID
4724 * @remarks scan result will be NULL when scan state is started or finished.
4725 * scan result is valid only when scan state is 'device found'
4727 * @see bt_mesh_scanning_state_e
4728 * @see bt_mesh_network_scan_unprovisioned_device_result_cb
4730 * @privlevel platform
4732 int bt_mesh_network_unprovisioned_device_scan(bt_mesh_network_h network,
4733 bt_mesh_scan_params_s *scan_params,
4734 bt_mesh_network_scan_unprovisioned_device_result_cb callback,
4739 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4740 * @brief Stop discovring unprovisioned device.
4743 * @privlevel platform
4745 int bt_mesh_stop_unprovisioned_device_scan(bt_mesh_network_h network);
4749 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4750 * @brief Set capabilities of a provisioner application.
4751 * Provisioning capabilities will as per Input/Output capabilities of the
4752 * device/application creating the provisioner.
4753 * For e.g, if device/application has Wi-Fi/NFC connectivity and can
4754 * procure Provisioning keys Out-Of-Band over Wi-Fi network/Remote Web URL/NFC Connectivity,
4755 * then following capabilities can be set to true, otherwise left false
4756 * a/ bool public_oob b/ bool static_oob
4757 * Above capabilities indicate whether, Public Key for ECC exchange & Static Key for
4758 * authentication can be procured out-of-band or not
4760 * @param: in: network Mesh network instance which represents a provisioner node
4761 * @param: in: capabilities Provisioner capabilities structure
4763 * @remarks: A single provisioner network can provision multiple remote devices.
4764 * During security provisioning, capabilities are selected *By Provisioner*
4765 * based on combination of supported capabilities of provisioner & remote nodes together.
4767 * @remarks: A mesh network instance represents a single Mesh provisioning node
4768 * & multiple remote provisioned nodes.
4769 * Therefore, setting capabilities one time, for a network or a provisioner node is sufficient.
4770 * Normally, Input/output capabilities do not change over time for a device
4771 * or an application. Incase, it is changed, application is free to refresh the
4772 * capabilities of the Provisioner at any point of time.
4773 * The next provisioning process will automatically consider the refreshed capabilities.
4774 * @remarks: Capabilities can be set one time after local provisioner node is attached to a network.
4776 * @see: bt_mesh_provisioner_capabilities_s structure
4777 * @see: bt_mesh_network_create()
4779 * @privlevel platform
4781 int bt_mesh_network_set_provisioning_capabilities(
4782 bt_mesh_network_h network,
4783 bt_mesh_provisioner_capabilities_s *capabilities);
4787 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4788 * @brief Async call to provision a device to the Mesh Network
4790 * @remarks: In Tizen, only one provisioning process is allowed,
4791 * irrespective of Provisioner or node role.
4793 * @privlevel platform
4795 int bt_mesh_network_provision_device(bt_mesh_network_h network,
4796 const char *dev_uuid,
4797 bt_mesh_network_device_provision_cb callback,
4802 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4803 * @brief Registers a callback that will be invoked when remote
4804 * device requests authentication, during the provisioning process.
4806 * @pre Either bt_mesh_network_provision_device() in case of Provisioner role
4807 * or bt_mesh_node_network_join() in case of Node role must be
4808 * called (Node role API is not defined yet)
4810 * @param[in] callback callback function which is set, for receiving
4811 * authentication request during provisioning process.
4812 * @param[in] user_data data from application which will be provided in callback.
4814 * @remarks: This method is designed common for both Provisioner & Node role.
4815 * @remarks: This callback is not invoked without the local device initiating the process
4816 * of either Provisioning(in case of local provisioner) or
4817 * Joining Network(in case of local node role).
4818 * Therefore, application will be completely aware, when the callback is invoked.
4819 * @remarks: In Tizen, only one provisioning process is allowed, irrespective of Provisioner or node role.
4820 * Therefore, when the callback is invoked, aplication exactly knows following
4821 * a/ whether the process is for provisioner role trying to provision a remote device
4822 * b/ Or process if for local node role, which is inviting remote provisioners
4823 * to join itself to a Mesh Network
4825 * @see bt_network_provision_device()
4827 * @privlevel platform
4829 int bt_mesh_authentication_set_request_cb(
4830 bt_mesh_authentication_request_cb callback,
4834 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4835 * @brief Un-registers a callback that will be invoked when
4836 * remote device requests authentication,during the provisioning process
4838 * @param[in] callback callback function to be set when
4839 * authentication request is received.
4841 * @remarks: This method is designed common for both Provisioner & Node role.
4842 * @see bt_mesh_authentication_set_request_cb()
4843 * @see bt_mesh_authentication_request_cb()
4845 * @privlevel platform
4847 int bt_mesh_authentication_unset_request_cb(
4848 bt_mesh_authentication_request_cb callback);
4852 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4853 * @brief API to reply authentication request.
4854 * @remarks This function can be called by application when remote
4855 * device requests authentication due to either of following process
4856 * a/ Local provisioner role trying to provision a remote device
4857 * b/ Local node role, inviting remote provisioners to join itself to a Mesh Network
4858 * @param[in] auth_type Specific authentiation type, for which reply is being sent
4859 * @param[in] value Reply string corresponding to authentication type
4860 * @param[in] auth_reply Accept or cancel ongoing provisioning process
4861 * @pre This function can only be called when application receieves authentication
4862 * callback bt_mesh_authentication_request_cb
4863 * @remarks: value string is valid, when autnetication type is of following
4864 * a/ BT_MESH_AUTH_REQ_ALPHANUMERIC_INPUT
4865 * b/ BT_MESH_AUTH_REQ_NUMERIC_INPUT
4866 * c/ BT_MESH_AUTH_REQ_BLINK_COUNT_INPUT
4867 * d/ BT_MESH_AUTH_REQ_BEEP_COUNT_INPUT
4868 * e/ BT_MESH_AUTH_REQ_VIBRATE_COUNT_INPUT
4869 * f/ BT_MESH_AUTH_REQ_OOB_PUBLIC_KEY_INPUT
4870 * g/ BT_MESH_AUTH_REQ_OOB_STATIC_KEY_INPUT
4872 * @remarks: This method is designed common for both Provisioner & Node role.
4873 * @see bt_mesh_authentication_set_request_cb()
4874 * @see bt_mesh_authentication_request_cb()
4875 * @see bt_mesh_authentication_type_e
4877 * @privlevel platform
4879 int bt_mesh_authentication_reply(
4880 bt_mesh_authentication_type_e auth_type,
4881 const char *value, bool auth_reply);
4885 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4886 * @brief Async call to identify the newly provisioned device
4888 * @remarks: After provisioning is done, device must be
4889 * discovered first of all in order to
4890 * use it. If device is successfully discovered, node handle
4891 * will be returned in the callback.
4892 * @see bt_mesh_network_provision_device
4894 * @privlevel platform
4896 int bt_mesh_network_discover_node(bt_mesh_network_h network,
4897 const char *dev_uuid,
4898 bt_mesh_node_discover_status_cb callback,
4903 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4904 * @brief Async call to browse the features of a node.
4905 * Features of the node are returned in callback
4907 * @see bt_mesh_network_provision_device
4908 * @see bt_mesh_network_discover_node
4910 * @privlevel platform
4912 int bt_mesh_node_get_features(bt_mesh_node_h node,
4913 bt_mesh_node_features_cb callback,
4918 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4919 * @brief Async call to Add/Update/Delete a NetKey to a node
4921 * @see bt_mesh_network_add_netkey
4923 * @privlevel platform
4925 int bt_mesh_node_configure_netkey(bt_mesh_node_h node,
4926 bt_mesh_node_key_configuration_e netkey_op,
4927 bt_mesh_netkey_h netkey,
4928 bt_mesh_netkey_status_cb callback,
4933 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4934 * @brief Async call to add/update/delete an Application to a node
4936 * @see bt_mesh_netkey_add_appkey
4938 * @privlevel platform
4940 int bt_mesh_node_configure_appkey(bt_mesh_node_h node,
4941 bt_mesh_node_key_configuration_e appkey_op,
4942 bt_mesh_appkey_h appkey,
4943 bt_mesh_appkey_status_cb callback,
4948 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4949 * @brief Find all NetKey(s) attached to a node
4951 * @see bt_mesh_node_configure_netkey
4953 * @privlevel platform
4955 int bt_mesh_node_foreach_netkeys(bt_mesh_node_h node,
4956 bt_mesh_node_netkey_info_cb callback,
4961 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4962 * @brief Find all AppKey(s) bound to a NetKey in a node
4964 * @see bt_mesh_node_configure_appkey
4966 * @privlevel platform
4968 int bt_mesh_node_foreach_appkeys(bt_mesh_node_h node,
4969 bt_mesh_netkey_h netkey,
4970 bt_mesh_node_appkey_info_cb callback,
4975 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4976 * @brief Query TTL set to a node in the network
4979 * @privlevel platform
4981 int bt_mesh_node_get_ttl(bt_mesh_node_h node,
4982 bt_mesh_node_ttl_cb callback,
4987 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
4988 * @brief Query TTL set to a node in the network
4991 * @privlevel platform
4993 int bt_mesh_node_set_ttl(bt_mesh_node_h node, uint8_t ttl,
4994 bt_mesh_node_ttl_cb callback,
4999 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5000 * @brief Async call to bind a locally created application key
5001 * to a Model of a node
5004 * @privlevel platform
5006 int bt_mesh_model_bind_appkey(bt_mesh_model_h model,
5007 bt_mesh_appkey_h appkey, bt_mesh_model_bind_cb callback,
5012 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5013 * @brief Async call to Unbind a locally created application key
5014 * to a Model of a node
5016 * @see bt_mesh_model_bind_appkey
5018 * @privlevel platform
5020 int bt_mesh_model_unbind_appkey(bt_mesh_model_h model,
5021 bt_mesh_appkey_h appkey,
5022 bt_mesh_model_unbind_cb callback,
5027 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5028 * @brief Async call to find all AppKey(s) bound to a model of a node
5030 * @see bt_mesh_model_bind_appkey
5032 * @privlevel platform
5034 int bt_mesh_model_get_appkey_list(bt_mesh_model_h model,
5035 bt_mesh_model_appkey_list_cb callback,
5040 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5041 * @brief Send message originated by a local mesh model.
5043 * @param: in: model, model handle to which message to be sent
5044 * @param: in: appkey, appkey to encrypt mesh message
5045 * appkey must be valid for corresponding model, i.e
5046 * appkey must be bound to the model
5047 * @param: in: msg_params, opcode and the message to be sent
5048 * @param: in: callback, callback to be called for msg response
5050 * @see bt_mesh_model_msg_params_s
5053 * @privlevel platform
5055 int bt_mesh_model_send_msg(bt_mesh_model_h model,
5056 bt_mesh_appkey_h appkey, bt_mesh_model_msg_params_s *msg_params,
5057 bt_mesh_model_msg_cb callback, void *user_data);
5061 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5062 * @brief Send Group message originated by a local mesh model.
5064 * @param: in: group, group handle to which message to be sent
5065 * @param: in: appkey, appkey to encrypt mesh message
5066 * appkey must be valid for corresponding model, i.e
5067 * appkey must be bound to the model
5068 * @param: in: msg_params, opcode and the message to be sent
5069 * @param: in: callback, callback to be called for msg response
5071 * @see bt_mesh_model_msg_params_s
5074 * @privlevel platform
5076 int bt_mesh_group_send_msg(bt_mesh_group_h group,
5077 bt_mesh_appkey_h appkey, bt_mesh_model_msg_params_s *msg_params,
5078 bt_mesh_model_msg_cb callback, void *user_data);
5082 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5083 * @brief Create a Mesh group with a given group address in the Local Network
5086 * @privlevel platform
5088 int bt_mesh_network_create_group(bt_mesh_network_h network,
5089 uint16_t group_addr,
5090 bt_mesh_group_h *group);
5094 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5095 * @brief Create a Mesh Virtual group in the Local Network.
5097 * @remarks Virtual group label (128-bit UUID) is internally managed by Framework.
5099 * @privlevel platform
5101 int bt_mesh_network_create_virtual_group(bt_mesh_network_h network,
5102 bt_mesh_group_h *group);
5106 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5107 * @brief Remove a create Mesh group in the Local Network.
5109 * @see bt_mesh_network_create_group
5110 * @see bt_mesh_network_create_virtual_group
5112 * @privlevel platform
5114 int bt_mesh_network_remove_group(bt_mesh_group_h group);
5118 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5119 * @brief Find all Mesh group(s), that are created in the Local Network.
5121 * @remarks Group handles will be returned for each created group.
5122 * @see bt_mesh_network_create_group
5123 * @see bt_mesh_network_create_virtual_group
5125 * @privlevel platform
5127 int bt_mesh_network_foreach_groups(bt_mesh_network_h network,
5128 bt_mesh_network_group_info_cb callback,
5133 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5134 * @brief Subscription Add/Delete/Overwrite request to a Model of an element.
5136 * @param: in: model_op: Add/Delete/Overwrite
5137 * @param: in: model Model on which subscription operation will be applied
5138 * @param: in: group Mesh Group handle.
5139 * @param: in: callback result of model subscription operation
5140 * request from remote node
5141 * @param: in: user_data async callback data
5143 * @see bt_mesh_network_create_group
5145 * @privlevel platform
5147 int bt_mesh_model_configure_group_subscription(
5148 bt_mesh_model_subscription_op_e model_op,
5149 bt_mesh_model_h model, bt_mesh_group_h group,
5150 bt_mesh_model_subscription_op_cb callback,
5155 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5156 * @brief Subscription Add/Delete/Overwrite request of a
5157 * Virtual Group, to Model of an element.
5159 * @param: in: model_op: Add/Delete/Overwrite
5160 * @param: in: model Model on which subscription operation will be applied
5161 * @param: in: group Mesh Group handle.
5162 * @param: in: callback result of model subscription operation
5163 * request from remote node
5164 * @param: in: user_data async callback data
5166 * @see bt_mesh_network_create_virtual_group
5168 * @privlevel platform
5170 int bt_mesh_model_configure_virtual_group_subscription(
5171 bt_mesh_model_subscription_op_e model_op,
5172 bt_mesh_model_h model, bt_mesh_group_h group,
5173 bt_mesh_model_subscription_op_cb callback,
5179 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5180 * @brief Find all Subscription list of a model in a node.
5181 * A List of all groups handles will be returned in callback, if success
5183 * @remarks Group handles will be returned for each created group.
5185 * @privlevel platform
5187 int bt_mesh_model_get_subscription_list(bt_mesh_model_h model,
5188 bt_mesh_model_subscription_list_cb callback,
5193 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5194 * @brief Add a publiation to a Model of a node.
5196 * @param: in: model Model which will generate the Publication message
5197 * @param: in: appkey application key handle which will be used to
5198 * encrypt publication message
5199 * @param: in: group Mesh Group handle.
5200 * @param: in: param Model Publication Parameters
5201 * @param: in: callback result of model publication set request,
5203 * @param: in: user_data async callback data
5206 * @privlevel platform
5208 int bt_mesh_model_set_publication(bt_mesh_model_h model,
5209 bt_mesh_appkey_h appkey, bt_mesh_group_h group,
5210 bt_mesh_model_pub_params_s *params,
5211 bt_mesh_model_publication_status_cb callback,
5216 * @ingroup CAPI_NETWORK_BLUETOOTH_MESH_MODULE
5217 * @brief Find Publication, set in model of a node, attached to a Network.
5218 * Publication group handle will be returned in callback, if success
5221 * @privlevel platform
5223 int bt_mesh_model_get_publication(bt_mesh_model_h model,
5224 bt_mesh_model_publication_status_cb callback,
5234 #endif /* __cplusplus */
5236 #endif /* __TIZEN_NETWORK_BLUETOOTH_INTERNAL_H__ */