2 * Copyright (c) 2016 Samsung Electronics Co., Ltd. All rights reserved.
4 * Contact: Suresh Kumar N (suresh.n@samsung.com)
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
10 * http://www.apache.org/licenses/LICENSE-2.0
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
19 #ifndef __ZIGBEE_LIB_TYPES_H__
20 #define __ZIGBEE_LIB_TYPES_H__
22 /* --------------------------------------------------------------------------------------
24 * -------------------------------------------------------------------------------------*/
32 #ifndef TIZEN_ERROR_NONE
33 #define TIZEN_ERROR_NONE 0 /**< Successful */
36 #ifndef TIZEN_ERROR_INVALID_PARAMETER
37 #define TIZEN_ERROR_INVALID_PARAMETER -EINVAL /**< Invalid function parameter */
40 #ifndef TIZEN_ERROR_RESULT_OUT_OF_RANGE
41 #define TIZEN_ERROR_RESULT_OUT_OF_RANGE -ERANGE /**< Math result not representable */
44 #ifndef TIZEN_ERROR_OUT_OF_MEMORY
45 #define TIZEN_ERROR_OUT_OF_MEMORY -ENOMEM /**< Out of memory */
48 #ifndef TIZEN_ERROR_IO_ERROR
49 #define TIZEN_ERROR_IO_ERROR -EIO /**< I/O error */
52 #ifndef TIZEN_ERROR_NO_DATA
53 #define TIZEN_ERROR_NO_DATA -ENODATA /**< No data available */
56 #ifndef TIZEN_ERROR_MIN_PLATFORM_ERROR
57 #define TIZEN_ERROR_MIN_PLATFORM_ERROR (-1073741824LL) /* = -2147483648 / 2 */
60 #ifndef TIZEN_ERROR_NOT_SUPPORTED
61 #define TIZEN_ERROR_NOT_SUPPORTED TIZEN_ERROR_MIN_PLATFORM_ERROR + 2 /**< Not supported */
64 #ifndef TIZEN_ERROR_PERMISSION_DENIED
65 #define TIZEN_ERROR_PERMISSION_DENIED -EACCES /**< Permission denied */
68 #ifndef TIZEN_ERROR_ZIGBEE
69 #define TIZEN_ERROR_ZIGBEE -0x02F70000
72 /* Enumeration for zigbee library error code. */
74 ZBLIB_ERROR_NONE = TIZEN_ERROR_NONE, /**< Successful */
75 ZBLIB_ERROR_INVALID_PARAMETER = TIZEN_ERROR_INVALID_PARAMETER, /**< parameter error */
76 ZBLIB_ERROR_PARAMETER_OUT_OF_RANGE = TIZEN_ERROR_RESULT_OUT_OF_RANGE, /**< out of range error */
77 ZBLIB_ERROR_OUT_OF_MEMORY = TIZEN_ERROR_OUT_OF_MEMORY, /**< out of memory */
78 ZBLIB_ERROR_IO_ERROR = TIZEN_ERROR_IO_ERROR, /**< DBus error */
79 ZBLIB_ERROR_NO_DATA = TIZEN_ERROR_NO_DATA, /**< No data available */
80 ZBLIB_ERROR_NOT_SUPPORTED = TIZEN_ERROR_NOT_SUPPORTED, /**< not supported */
81 ZBLIB_ERROR_PERMISSION_DENIED = TIZEN_ERROR_PERMISSION_DENIED, /**< Permission denied */
82 ZBLIB_ERROR_INVALID_ENDPOINT = TIZEN_ERROR_ZIGBEE | 0x01, /**< endpoint 0 is reserved for ZDP */
83 ZBLIB_ERROR_INVALID_ADDRESS = TIZEN_ERROR_ZIGBEE | 0x01, /**< wrong address */
84 ZIGBEE_ERROR_OPERATION_FAILED = TIZEN_ERROR_ZIGBEE | 0x03, /**< Invalid data available */
91 #endif /* __ZIGBEE_LIB_TYPES_H__ */