Contiki 2.5
error.h
1 /**
2  * @file error.h
3  * @brief Return codes for API functions and module definitions.
4  *
5  * See @ref status_codes for documentation.
6  *
7  * <!--(C) COPYRIGHT 2010 STMicroelectronics. All rights reserved. -->
8  */
9 
10 #ifndef __ERRORS_H__
11 #define __ERRORS_H__
12 
13 /**
14  * @brief Return type for St functions.
15  */
16 #ifndef __STSTATUS_TYPE__
17 #define __STSTATUS_TYPE__
18  typedef int8u StStatus;
19 #endif //__STSTATUS_TYPE__
20 
21 /**
22  * @addtogroup status_codes
23  * @{
24  */
25 
26 /**
27  * @brief Macro used by error-def.h to define all of the return codes.
28  *
29  * @param symbol The name of the constant being defined. All St returns
30  * begin with ST_. For example, ::ST_CONNECTION_OPEN.
31  *
32  * @param value The value of the return code. For example, 0x61.
33  */
34 #define DEFINE_ERROR(symbol, value) \
35  ST_ ## symbol = value,
36 
37 
38 enum {
39 #ifndef DOXYGEN_SHOULD_SKIP_THIS
40 #include "error-def.h"
41 #endif //DOXYGEN_SHOULD_SKIP_THIS
42  /** Gets defined as a count of all the possible return codes in the
43  * StZNet stack API.
44  */
46 
47 };
48 
49 #undef DEFINE_ERROR
50 
51 #endif // __ERRORS_H__
52 
53 /**@} // End of addtogroup
54  */
55 
56