Mon May 14 04:42:54 2007

Asterisk developer's documentation


causes.h

Go to the documentation of this file.
00001 /*
00002  * Asterisk -- An open source telephony toolkit.
00003  *
00004  * Copyright (C) 1999 - 2005, Digium, Inc.
00005  *
00006  * Martin Pycko <martinp@digium.com>
00007  *
00008  * See http://www.asterisk.org for more information about
00009  * the Asterisk project. Please do not directly contact
00010  * any of the maintainers of this project for assistance;
00011  * the project provides a web site, mailing lists and IRC
00012  * channels for your use.
00013  *
00014  * This program is free software, distributed under the terms of
00015  * the GNU General Public License Version 2. See the LICENSE file
00016  * at the top of the source tree.
00017  */
00018 
00019 /*! \file
00020  * \brief Internal Asterisk hangup causes
00021  */
00022 
00023 #ifndef _ASTERISK_CAUSES_H
00024 #define _ASTERISK_CAUSES_H
00025 
00026 /*! \page AstCauses Hangup Causes for Asterisk
00027 
00028 The Asterisk hangup causes are delivered to the dialplan in the
00029 ${HANGUPCAUSE} channel variable after a call (after execution
00030 of "dial"). 
00031 
00032 In SIP, we have a conversion table to convert between SIP
00033 return codes and Q.931 both ways. This is to improve SIP/ISDN
00034 compatibility.
00035 
00036 These are the current codes, based on the Q.931
00037 specification:
00038 
00039    - AST_CAUSE_UNALLOCATED          1
00040    - AST_CAUSE_NO_ROUTE_TRANSIT_NET       2
00041    - AST_CAUSE_NO_ROUTE_DESTINATION       3
00042    - AST_CAUSE_CHANNEL_UNACCEPTABLE       6
00043    - AST_CAUSE_CALL_AWARDED_DELIVERED     7
00044    - AST_CAUSE_NORMAL_CLEARING         16
00045    - AST_CAUSE_USER_BUSY            17
00046    - AST_CAUSE_NO_USER_RESPONSE        18
00047    - AST_CAUSE_NO_ANSWER            19
00048    - AST_CAUSE_CALL_REJECTED           21
00049    - AST_CAUSE_NUMBER_CHANGED       22
00050    - AST_CAUSE_DESTINATION_OUT_OF_ORDER      27
00051    - AST_CAUSE_INVALID_NUMBER_FORMAT         28
00052    - AST_CAUSE_FACILITY_REJECTED       29
00053    - AST_CAUSE_RESPONSE_TO_STATUS_ENQUIRY    30
00054    - AST_CAUSE_NORMAL_UNSPECIFIED         31
00055    - AST_CAUSE_NORMAL_CIRCUIT_CONGESTION     34
00056    - AST_CAUSE_NETWORK_OUT_OF_ORDER       38
00057    - AST_CAUSE_NORMAL_TEMPORARY_FAILURE      41
00058    - AST_CAUSE_SWITCH_CONGESTION       42
00059    - AST_CAUSE_ACCESS_INFO_DISCARDED         43
00060    - AST_CAUSE_REQUESTED_CHAN_UNAVAIL     44
00061    - AST_CAUSE_PRE_EMPTED           45
00062    - AST_CAUSE_FACILITY_NOT_SUBSCRIBED       50
00063    - AST_CAUSE_OUTGOING_CALL_BARRED          52
00064    - AST_CAUSE_INCOMING_CALL_BARRED          54
00065    - AST_CAUSE_BEARERCAPABILITY_NOTAUTH      57
00066    - AST_CAUSE_BEARERCAPABILITY_NOTAVAIL        58
00067    - AST_CAUSE_BEARERCAPABILITY_NOTIMPL      65
00068    - AST_CAUSE_CHAN_NOT_IMPLEMENTED          66
00069    - AST_CAUSE_FACILITY_NOT_IMPLEMENTED         69
00070    - AST_CAUSE_INVALID_CALL_REFERENCE     81
00071    - AST_CAUSE_INCOMPATIBLE_DESTINATION      88
00072    - AST_CAUSE_INVALID_MSG_UNSPECIFIED       95
00073    - AST_CAUSE_MANDATORY_IE_MISSING       96
00074    - AST_CAUSE_MESSAGE_TYPE_NONEXIST         97
00075    - AST_CAUSE_WRONG_MESSAGE           98
00076    - AST_CAUSE_IE_NONEXIST          99
00077    - AST_CAUSE_INVALID_IE_CONTENTS        100
00078    - AST_CAUSE_WRONG_CALL_STATE        101
00079    - AST_CAUSE_RECOVERY_ON_TIMER_EXPIRE      102
00080    - AST_CAUSE_MANDATORY_IE_LENGTH_ERROR     103
00081    - AST_CAUSE_PROTOCOL_ERROR       111
00082    - AST_CAUSE_INTERWORKING            127
00083 
00084 For more information:
00085 - \ref app_dial.c
00086 */
00087 
00088 /* Causes for disconnection (from Q.931) */
00089 #define AST_CAUSE_UNALLOCATED          1
00090 #define AST_CAUSE_NO_ROUTE_TRANSIT_NET       2
00091 #define AST_CAUSE_NO_ROUTE_DESTINATION       3
00092 #define AST_CAUSE_CHANNEL_UNACCEPTABLE       6
00093 #define AST_CAUSE_CALL_AWARDED_DELIVERED     7
00094 #define AST_CAUSE_NORMAL_CLEARING         16
00095 #define AST_CAUSE_USER_BUSY            17
00096 #define AST_CAUSE_NO_USER_RESPONSE        18
00097 #define AST_CAUSE_NO_ANSWER            19
00098 #define AST_CAUSE_CALL_REJECTED           21
00099 #define AST_CAUSE_NUMBER_CHANGED       22
00100 #define AST_CAUSE_DESTINATION_OUT_OF_ORDER      27
00101 #define AST_CAUSE_INVALID_NUMBER_FORMAT         28
00102 #define AST_CAUSE_FACILITY_REJECTED       29
00103 #define AST_CAUSE_RESPONSE_TO_STATUS_ENQUIRY    30
00104 #define AST_CAUSE_NORMAL_UNSPECIFIED         31
00105 #define AST_CAUSE_NORMAL_CIRCUIT_CONGESTION     34
00106 #define AST_CAUSE_NETWORK_OUT_OF_ORDER       38
00107 #define AST_CAUSE_NORMAL_TEMPORARY_FAILURE      41
00108 #define AST_CAUSE_SWITCH_CONGESTION       42
00109 #define AST_CAUSE_ACCESS_INFO_DISCARDED         43
00110 #define AST_CAUSE_REQUESTED_CHAN_UNAVAIL     44
00111 #define AST_CAUSE_PRE_EMPTED           45
00112 #define AST_CAUSE_FACILITY_NOT_SUBSCRIBED       50
00113 #define AST_CAUSE_OUTGOING_CALL_BARRED          52
00114 #define AST_CAUSE_INCOMING_CALL_BARRED          54
00115 #define AST_CAUSE_BEARERCAPABILITY_NOTAUTH      57
00116 #define AST_CAUSE_BEARERCAPABILITY_NOTAVAIL        58
00117 #define AST_CAUSE_BEARERCAPABILITY_NOTIMPL      65
00118 #define AST_CAUSE_CHAN_NOT_IMPLEMENTED          66
00119 #define AST_CAUSE_FACILITY_NOT_IMPLEMENTED         69
00120 #define AST_CAUSE_INVALID_CALL_REFERENCE     81
00121 #define AST_CAUSE_INCOMPATIBLE_DESTINATION      88
00122 #define AST_CAUSE_INVALID_MSG_UNSPECIFIED       95
00123 #define AST_CAUSE_MANDATORY_IE_MISSING       96
00124 #define AST_CAUSE_MESSAGE_TYPE_NONEXIST         97
00125 #define AST_CAUSE_WRONG_MESSAGE           98
00126 #define AST_CAUSE_IE_NONEXIST          99
00127 #define AST_CAUSE_INVALID_IE_CONTENTS        100
00128 #define AST_CAUSE_WRONG_CALL_STATE        101
00129 #define AST_CAUSE_RECOVERY_ON_TIMER_EXPIRE      102
00130 #define AST_CAUSE_MANDATORY_IE_LENGTH_ERROR     103
00131 #define AST_CAUSE_PROTOCOL_ERROR       111
00132 #define AST_CAUSE_INTERWORKING            127
00133 
00134 /* Special Asterisk aliases */
00135 #define AST_CAUSE_BUSY              AST_CAUSE_USER_BUSY
00136 #define AST_CAUSE_FAILURE           AST_CAUSE_NETWORK_OUT_OF_ORDER
00137 #define AST_CAUSE_NORMAL            AST_CAUSE_NORMAL_CLEARING
00138 #define AST_CAUSE_NOANSWER          AST_CAUSE_NO_ANSWER
00139 #define AST_CAUSE_CONGESTION           AST_CAUSE_NORMAL_CIRCUIT_CONGESTION
00140 #define AST_CAUSE_UNREGISTERED            AST_CAUSE_NO_ROUTE_DESTINATION
00141 #define AST_CAUSE_NOTDEFINED           0
00142 #define AST_CAUSE_NOSUCHDRIVER            AST_CAUSE_CHAN_NOT_IMPLEMENTED
00143 
00144 #endif /* _ASTERISK_CAUSES_H */

Generated on Mon May 14 04:42:54 2007 for Asterisk - the Open Source PBX by  doxygen 1.5.1