[GATT] Fix ATT application ecode 26/140726/2
authorGowtham Anandha Babu <gowtham.ab@samsung.com>
Wed, 26 Jul 2017 07:06:30 +0000 (12:36 +0530)
committerGowtham Anandha Babu <gowtham.ab@samsung.com>
Wed, 26 Jul 2017 07:10:53 +0000 (07:10 +0000)
1) Add error codes defined in Common Profile and
Service Error Code descriptions (see Supplement to the
Bluetooth Core Specification, sections 1.2 and 2).

2) Seperate out OTP specific application ecode.

Change-Id: I63113596ee74f86b6dc721048a193f5296b4f0fb
Signed-off-by: Gowtham Anandha Babu <gowtham.ab@samsung.com>
include/bluetooth_type_internal.h

index e01cedca025a4c2e5a535d11f8151323315a90c0..08e68a94d4c3e3cd9555957242ebcb06369ab544 100644 (file)
@@ -70,18 +70,26 @@ typedef enum {
        BT_ATT_ERROR_INSUFFICIENT_RESOURCES = 0x11,
 
        /* Common profile error codes */
-       BT_ATT_ERROR_WRITE_REQUEST_REJECTED = 0x80,
+       BT_ATT_ERROR_WRITE_REQUEST_REJECTED = 0xFC,
        BT_ATT_ERROR_CCCD_IMPROPERLY_CONFIGURED = 0xFD,
        BT_ATT_ERROR_PROCEDURE_ALREADY_IN_PROGRESS = 0xFE,
        BT_ATT_ERROR_OUT_OF_RANGE = 0xFF,
 
-       /* Bluetooth OTP error codes */
-       BT_ATT_ERROR_OBJECT_NOT_SELECTED = 0x81,
-       BT_ATT_ERROR_CONCURRENCY_LIMIT_EXCEEDED = 0x82,
-       BT_ATT_ERROR_OBJECT_NAME_EXISTS = 0x83,
-
 } bt_att_error_e;
 
+/**
+ * @ingroup CAPI_NETWORK_BLUETOOTH_OTP_MODULE
+ * @brief  Enumerations of the ATT error codes specific to OTP.
+ * @since_tizen 4.0
+ */
+typedef enum {
+       /* Bluetooth OTP error codes */
+       BT_OTP_ERROR_WRITE_REQUEST_REJECTED = 0x80,
+       BT_OTP_ERROR_OBJECT_NOT_SELECTED = 0x81,
+       BT_OTP_ERROR_CONCURRENCY_LIMIT_EXCEEDED = 0x82,
+       BT_OTP_ERROR_OBJECT_NAME_EXISTS = 0x83,
+} bt_otp_error_e;
+
 /**
  * @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE
  * @brief  Called when the Bluetooth adapter le state changes.