📄 chi.h
字号:
* ------------------------------------------------------------------------- */typedef struct CH_optmgmt_ack { ch_ulong ch_primitive; /* always CH_OPTMGMT_REQ */ ch_ulong ch_opt_length; /* length of options */ ch_ulong ch_opt_offset; /* offset of options */ ch_ulong ch_mgmt_flags; /* option flags */} CH_optmgmt_ack_t;/* management flags for CH_OPTMGMT */#define CH_SET_OPT 0x01#define CH_GET_OPT 0x02#define CH_NEGOTIATE 0x03#define CH_DEFAULT 0x04/* * CH_ATTACH_REQ * ------------------------------------------------------------------------- */typedef struct CH_attach_req { ch_ulong ch_primitive; /* always CH_ATTACH_REQ */ ch_ulong ch_addr_length; /* length of channel address */ ch_ulong ch_addr_offset; /* offset of channel address */ ch_ulong ch_flags; /* options flags */} CH_attach_req_t;/* * CH_DETACH_REQ * ------------------------------------------------------------------------- */typedef struct CH_detach_req { ch_ulong ch_primitive; /* always CH_DETACH_REQ */} CH_detach_req_t;/* * CH_OK_ACK * ------------------------------------------------------------------------- */typedef struct CH_ok_ack { ch_ulong ch_primitive; /* always CH_OK_ACK */ ch_ulong ch_correct_prim; /* correct primitive */ ch_ulong ch_state; /* resulting state */} CH_ok_ack_t;/* * CH_ERROR_ACK * ------------------------------------------------------------------------- */typedef struct CH_error_ack { ch_ulong ch_primitive; /* always CH_ERROR_ACK */ ch_ulong ch_error_primitive; /* primitive in error */ ch_ulong ch_error_type; /* CHI error */ ch_ulong ch_unix_error; /* UNIX error */ ch_ulong ch_state; /* resulting state */} CH_error_ack_t;/* error types */#define CHSYSERR 0 /* UNIX system error */#define CHBADADDR 1 /* Bad address format or content */#define CHOUTSTATE 2 /* Interface out of state */#define CHBADOPT 3 /* Bad options format or content */#define CHBADPARM 4 /* Bad parameter format or content */#define CHBADPARMTYPE 5 /* Bad paramater structure type */#define CHBADFLAG 6 /* Bad flag */#define CHBADPRIM 7 /* Bad primitive */#define CHNOTSUPP 8 /* Primitive not supported */#define CHBADSLOT 9 /* Bad multplex slot *//* * CH_ENABLE_REQ * ------------------------------------------------------------------------- */typedef struct CH_enable_req { ch_ulong ch_primitive; /* always CH_ENABLE_REQ */} CH_enable_req_t;/* * CH_ENABLE_CON * ------------------------------------------------------------------------- */typedef struct CH_enable_con { ch_ulong ch_primitive; /* always CH_ENABLE_CON */} CH_enable_con_t;/* * CH_DISABLE_REQ * ------------------------------------------------------------------------- */typedef struct CH_disable_req { ch_ulong ch_primitive; /* always CH_DISABLE_REQ */} CH_disable_req_t;/* * CH_DISABLE_IND * ------------------------------------------------------------------------- */typedef struct CH_disable_ind { ch_ulong ch_primitive; /* always CH_DISABLE_IND */ ch_ulong ch_cause; /* cause for disable */} CH_disable_ind_t;/* * CH_DISABLE_CON * ------------------------------------------------------------------------- */typedef struct CH_disable_con { ch_ulong ch_primitive; /* always CH_DISABLE_CON */} CH_disable_con_t;/* * CH_DATA_REQ * ------------------------------------------------------------------------- */typedef struct CH_data_req { ch_ulong ch_primitive; /* always CH_DATA_REQ */ ch_ulong ch_slot; /* slot within channel */} CH_data_req_t;/* * CH_DATA_IND * ------------------------------------------------------------------------- */typedef struct CH_data_ind { ch_ulong ch_primitive; /* always CH_DATA_IND */ ch_ulong ch_slot; /* slot within channel */} CH_data_ind_t;/* * CH_CONNECT_REQ * ------------------------------------------------------------------------- */typedef struct CH_connect_req { ch_ulong ch_primitive; /* always CH_CONNECT_REQ */ ch_ulong ch_conn_flags; /* direction to connect */ ch_ulong ch_slot; /* slot within channel */} CH_connect_req_t;/* connect flags */#define CHF_RX_DIR 0x01#define CHF_TX_DIR 0x02#define CHF_BOTH_DIR (CHF_RX_DIR|CHF_TX_DIR)/* * CH_CONNECT_CON * ------------------------------------------------------------------------- */typedef struct CH_connect_con { ch_ulong ch_primitive; /* always CH_CONNECT_CON */ ch_ulong ch_conn_flags; /* direction connected */ ch_ulong ch_slot; /* slot within channel */} CH_connect_con_t;/* * CH_DISCONNECT_REQ * ------------------------------------------------------------------------- */typedef struct CH_disconnect_req { ch_ulong ch_primitive; /* always CH_DISCONNECT_REQ */ ch_ulong ch_conn_flags; /* direction to disconnect */ ch_ulong ch_slot; /* slot within channel */} CH_disconnect_req_t;/* * CH_DISCONNECT_IND * ------------------------------------------------------------------------- */typedef struct CH_disconnect_ind { ch_ulong ch_primitive; /* always CH_DISCONNECT_IND */ ch_ulong ch_conn_flags; /* direction disconnected */ ch_ulong ch_cause; /* cause for disconnection */ ch_ulong ch_slot; /* slot within channel */} CH_disconnect_ind_t;/* * CH_DISCONNECT_CON * ------------------------------------------------------------------------- */typedef struct CH_disconnect_con { ch_ulong ch_primitive; /* always CH_DISCONNECT_CON */ ch_ulong ch_conn_flags; /* direction disconnected */ ch_ulong ch_slot; /* slot within channel */} CH_disconnect_con_t;/* * CH_EVENT_IND * ------------------------------------------------------------------------- */typedef struct CH_event_ind { ch_ulong ch_primitive; /* always CH_EVENT_IND */ ch_ulong ch_event; /* event */ ch_ulong ch_slot; /* slot within channel for event */} CH_event_ind_t;#define CH_EVT_DCD_ASSERT 0#define CH_EVT_DCD_DEASSERT 1#define CH_EVT_DSR_ASSERT 2#define CH_EVT_DSR_DEASSERT 3#define CH_EVT_DTR_ASSERT 4#define CH_EVT_DTR_DEASSERT 5#define CH_EVT_RTS_ASSERT 6#define CH_EVT_RTS_DEASSERT 7#define CH_EVT_CTS_ASSERT 8#define CH_EVT_CTS_DEASSERT 9#define CH_EVT_RI_ASSERT 10#define CH_EVT_RI_DEASSERT 11#define CH_EVT_YEL_ALARM 12#define CH_EVT_BLU_ALARM 13#define CH_EVT_RED_ALARM 14#define CH_EVT_NO_ALARM 15#define CHF_EVT_DCD_ASSERT (1 << 0)#define CHF_EVT_DCD_DEASSERT (1 << 1)#define CHF_EVT_DSR_ASSERT (1 << 2)#define CHF_EVT_DSR_DEASSERT (1 << 3)#define CHF_EVT_DTR_ASSERT (1 << 4)#define CHF_EVT_DTR_DEASSERT (1 << 5)#define CHF_EVT_RTS_ASSERT (1 << 6)#define CHF_EVT_RTS_DEASSERT (1 << 7)#define CHF_EVT_CTS_ASSERT (1 << 8)#define CHF_EVT_CTS_DEASSERT (1 << 9)#define CHF_EVT_RI_ASSERT (1 << 10)#define CHF_EVT_RI_DEASSERT (1 << 11)#define CHF_EVT_YEL_ALARM (1 << 12)#define CHF_EVT_BLU_ALARM (1 << 13)#define CHF_EVT_RED_ALARM (1 << 14)#define CHF_EVT_NO_ALARM (1 << 15)#define CHF_EVT_DCD_CHANGE (CHF_EVT_DCD_ASSERT|CHF_EVT_DCD_DEASSERT)#define CHF_EVT_DSR_CHANGE (CHF_EVT_DSR_ASSERT|CHF_EVT_DSR_DEASSERT)#define CHF_EVT_DTR_CHANGE (CHF_EVT_DTR_ASSERT|CHF_EVT_DTR_DEASSERT)#define CHF_EVT_RTS_CHANGE (CHF_EVT_RTS_ASSERT|CHF_EVT_RTS_DEASSERT)#define CHF_EVT_CTS_CHANGE (CHF_EVT_CTS_ASSERT|CHF_EVT_CTS_DEASSERT)#define CHF_EVT_RI_CHANGE (CHF_EVT_RI_ASSERT|CHF_EVT_RI_DEASSERT)#endif /* __SS7_CHI_H__ */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -