OM2000: Introduce VTY commands to initiate OM2000 procedures

This commit is contained in:
Harald Welte 2011-02-12 14:42:59 +01:00
parent 7354107946
commit e1d5eca916
5 changed files with 17 additions and 2 deletions

View File

@ -29,11 +29,16 @@ struct abis_om2k_mo {
uint8_t inst;
} __attribute__ ((packed));
extern const struct value_string om2k_mo_class_short_vals[];
int abis_om2k_rcvmsg(struct msgb *msg);
extern const struct abis_om2k_mo om2k_mo_cf;
int abis_om2k_tx_reset_cmd(struct gsm_bts *bts, struct abis_om2k_mo *mo);
int abis_om2k_tx_start_req(struct gsm_bts *bts, struct abis_om2k_mo *mo);
int abis_om2k_tx_status_req(struct gsm_bts *bts, struct abis_om2k_mo *mo);
int abis_om2k_vty_init(void);
#endif /* OPENBCS_ABIS_OM2K_H */

View File

@ -33,6 +33,7 @@ enum bsc_vty_node {
NAT_NODE,
NAT_BSC_NODE,
MSC_NODE,
OM2K_NODE,
};
extern int bsc_vty_is_config_node(struct vty *vty, int node);

View File

@ -17,7 +17,7 @@ sbin_PROGRAMS = bsc_hack bs11_config isdnsync bsc_mgcp
noinst_LIBRARIES = libbsc.a libmsc.a libvty.a libmgcp.a
libbsc_a_SOURCES = abis_rsl.c abis_nm.c abis_om2000.c gsm_data.c gsm_04_08_utils.c \
chan_alloc.c debug.c socket.c abis_nm_vty.c \
chan_alloc.c debug.c socket.c abis_nm_vty.c abis_om2000_vty.c \
gsm_subscriber_base.c subchan_demux.c bsc_rll.c transaction.c \
trau_frame.c trau_mux.c paging.c \
e1_config.c e1_input.c e1_input_vty.c \

View File

@ -100,6 +100,9 @@ enum abis_om2k_msgtype {
OM2K_MSGT_START_RES_ACK = 0x0088,
OM2K_MSGT_START_RES_NACK = 0x0089,
OM2K_MSGT_START_RES = 0x008a,
OM2K_MSGT_STATUS_REQ = 0x008c,
OM2K_MSGT_STATUS_RESP = 0x008e,
OM2K_MSGT_STATUS_REJ = 0x008f,
OM2K_MSGT_NEGOT_REQ_ACK = 0x0104,
OM2K_MSGT_NEGOT_REQ_NACK = 0x0105,
@ -435,7 +438,7 @@ static const struct value_string om2k_attr_vals[] = {
{ 0, NULL }
};
static const struct value_string om2k_mo_class_short_vals[] = {
const struct value_string om2k_mo_class_short_vals[] = {
{ 0x01, "TRXC" },
{ 0x03, "TS" },
{ 0x04, "TF" },
@ -534,6 +537,11 @@ int abis_om2k_tx_start_req(struct gsm_bts *bts, struct abis_om2k_mo *mo)
return abis_om2k_tx_simple(bts, mo, OM2K_MSGT_START_REQ);
}
int abis_om2k_tx_status_req(struct gsm_bts *bts, struct abis_om2k_mo *mo)
{
return abis_om2k_tx_simple(bts, mo, OM2K_MSGT_STATUS_REQ);
}
static int abis_om2k_tx_op_info(struct gsm_bts *bts, struct abis_om2k_mo *mo,
uint8_t operational)
{

View File

@ -2702,6 +2702,7 @@ int bsc_vty_init(void)
install_element(ENABLE_NODE, &pdch_act_cmd);
abis_nm_vty_init();
abis_om2k_vty_init();
e1inp_vty_init();
bsc_vty_init_extra();