2010-09-15 14:29:25 +00:00
|
|
|
/*
|
|
|
|
* Data for the true BSC
|
|
|
|
*
|
|
|
|
* (C) 2010 by Holger Hans Peter Freyther <zecke@selfish.org>
|
|
|
|
* (C) 2010 by On-Waves
|
|
|
|
* All Rights Reserved
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
2011-01-01 14:25:50 +00:00
|
|
|
* it under the terms of the GNU Affero General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 3 of the License, or
|
2010-09-15 14:29:25 +00:00
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
2011-01-01 14:25:50 +00:00
|
|
|
* GNU Affero General Public License for more details.
|
2010-09-15 14:29:25 +00:00
|
|
|
*
|
2011-01-01 14:25:50 +00:00
|
|
|
* You should have received a copy of the GNU Affero General Public License
|
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
2010-09-15 14:29:25 +00:00
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef _OSMO_MSC_DATA_H
|
|
|
|
#define _OSMO_MSC_DATA_H
|
|
|
|
|
|
|
|
#include "bsc_msc.h"
|
|
|
|
|
2011-03-22 15:47:59 +00:00
|
|
|
#include <osmocom/core/timer.h>
|
2010-09-15 18:14:41 +00:00
|
|
|
|
2010-09-15 15:53:54 +00:00
|
|
|
struct osmo_bsc_rf;
|
2010-11-14 19:38:06 +00:00
|
|
|
struct gsm_network;
|
2010-09-15 15:53:54 +00:00
|
|
|
|
2010-11-03 12:55:49 +00:00
|
|
|
struct gsm_audio_support {
|
2010-11-14 19:38:06 +00:00
|
|
|
uint8_t hr : 1,
|
|
|
|
ver : 7;
|
2010-11-03 12:55:49 +00:00
|
|
|
};
|
|
|
|
|
2010-09-15 14:29:25 +00:00
|
|
|
struct osmo_msc_data {
|
2010-09-15 15:28:49 +00:00
|
|
|
/* Connection data */
|
|
|
|
char *bsc_token;
|
|
|
|
int msc_port;
|
|
|
|
int msc_ip_dscp;
|
|
|
|
char *msc_ip;
|
|
|
|
int ping_timeout;
|
|
|
|
int pong_timeout;
|
2010-09-15 18:14:41 +00:00
|
|
|
struct timer_list ping_timer;
|
|
|
|
struct timer_list pong_timer;
|
2010-09-15 14:29:25 +00:00
|
|
|
struct bsc_msc_connection *msc_con;
|
2010-11-03 12:12:18 +00:00
|
|
|
int core_ncc;
|
2010-11-05 18:43:07 +00:00
|
|
|
int core_mcc;
|
2010-11-03 12:32:48 +00:00
|
|
|
int rtp_base;
|
2010-09-15 15:28:49 +00:00
|
|
|
|
2010-11-03 12:55:49 +00:00
|
|
|
/* audio codecs */
|
|
|
|
struct gsm_audio_support **audio_support;
|
|
|
|
int audio_length;
|
|
|
|
|
|
|
|
|
2010-09-15 18:14:41 +00:00
|
|
|
/* mgcp agent */
|
|
|
|
struct write_queue mgcp_agent;
|
|
|
|
|
2010-09-15 15:28:49 +00:00
|
|
|
/* rf ctl related bits */
|
2010-11-22 17:30:21 +00:00
|
|
|
char *mid_call_txt;
|
|
|
|
int mid_call_timeout;
|
2011-04-07 21:23:27 +00:00
|
|
|
char *rf_ctrl_name;
|
2010-09-15 15:53:54 +00:00
|
|
|
struct osmo_bsc_rf *rf_ctl;
|
2010-11-05 17:41:04 +00:00
|
|
|
|
|
|
|
/* ussd welcome text */
|
|
|
|
char *ussd_welcome_txt;
|
2010-09-15 14:29:25 +00:00
|
|
|
};
|
|
|
|
|
2010-09-15 18:14:41 +00:00
|
|
|
int osmo_bsc_msc_init(struct gsm_network *network);
|
2010-11-03 15:40:03 +00:00
|
|
|
int osmo_bsc_sccp_init(struct gsm_network *gsmnet);
|
2010-09-15 18:22:20 +00:00
|
|
|
int msc_queue_write(struct bsc_msc_connection *conn, struct msgb *msg, int proto);
|
2010-09-15 18:14:41 +00:00
|
|
|
|
2010-11-14 19:38:06 +00:00
|
|
|
int osmo_bsc_audio_init(struct gsm_network *network);
|
|
|
|
|
2010-09-15 14:29:25 +00:00
|
|
|
#endif
|