Commit a1520aac authored by Robert Schmidt's avatar Robert Schmidt

Remove useless MSCGEN macro

parent 00e05853
Branches unavailable
2025.w14 2025.w13 2025.w12 2025.w11 2025.w10 2025.w09 2025.w08 2025.w07 2025.w06 2025.w05 2025.w04 2025.w03 2025.w02 2024.w51 2024.w50 2024.w49 2024.w48 2024.w47 2024.w46 2024.w45 2024.w44 2024.w43 2024.w42 2024.w41 2024.w40 2024.w39 2024.w38 2024.w36 2024.w35 2024.w34 2024.w33 2024.w32 2024.w31 2024.w30 2024.w29 2024.w28 2024.w27 2024.w26 2024.w25 2024.w24 2024.w23 2024.w22 2024.w21 2024.w18 2024.w17 2024.w16 2024.w15 2024.w14 2024.w13 2024.w12 2024.w11 2024.w10 2024.w09 2024.w08 2024.w06 2024.w05 2024.w04 2024.w03 2024.w02 2024.w01 2023.w51 2023.w50 2023.w49 2023.w48 2023.w47 2023.w45 2023.w43 2023.w42 2023.w41 2023.w40 2023.w39 2023.w38 2023.w37 2023.w36 2023.w34 2023.w33 2023.w32 2023.w31 2023.w30 2023.w29 2023.w28 2023.w27 2023.w26 2023.w25 2023.w24 2023.w23 2023.w22 2023.w21 2023.w20 2023.w19 2023.w18 2023.w18b 2023.w16 2023.w15 2023.w14 2023.w13 2023.w12 2023.w11 2023.w11b 2023.w10 2023.w10b 2023.w09 2023.w08 2023.w08b 2023.w07 2023.w06 2023.w05 2023.w03 2023.w02 2022.42 2022.41 2022.w51 2022.w50 2022.w49 2022.w48 2022.w47 2022.w46 2022.w45 2022.w43 2022.w42 2022.w42b 2022.w41 2022.w40 2022.w39 2022.w38 2022.w37 2022.w37b 2022.w36 2022.w35 2022.w33 2022.w32 2022.w31 2022.w31b 2022.w30 2022.w29 2022.w26 2022.w25 2022.w24 2022.w24b 2022.w23 2022.w22 2022.w21 2022.w20 2022.w19 2022.w18 2022.w17 2022.w15 2022.w15b 2022.w14a 2022.w13 2022.w13b 2022.w13a 2022.w12 2022.w10 2022.w09 2022.w09b 2022.w08 2022.w08b v2.2.0 v2.1.0 v2.0.0 setparam flexran-eol ARC_1.3
......@@ -47,14 +47,6 @@ Description Defines constants and functions used by the AS simulator
/********************* G L O B A L C O N S T A N T S *******************/
/****************************************************************************/
/*
* Constansts used for MSCGEN (Message Sequence Chart Generator)
*/
#define MSCGEN(args...) fprintf(stderr, ##args);
#define _ue_id "UE"
#define _mme_id "MME"
#define _as_id "AS"
/****************************************************************************/
/************************ G L O B A L T Y P E S ************************/
/****************************************************************************/
......
......@@ -102,7 +102,7 @@ int process_cell_info_req(int msg_id, const cell_info_req_t* req,
index += _process_plmn(_mscgen_buffer, &req->plmnID, MSCGEN_BUFFER_SIZE);
snprintf(_mscgen_buffer + index, MSCGEN_BUFFER_SIZE - index,
", rat = 0x%x%c", req->rat, '\0');
MSCGEN("[MSC_MSG][%s][%s][--- Cell Information Request (0x%.4x)\\n%s --->][%s]\n",
printf("[%s][%s][--- Cell Information Request (0x%.4x)\\n%s --->][%s]\n",
getTime(), _ue_id, msg_id, _mscgen_buffer, _as_id);
/* Setup cell information confirm message */
......@@ -116,7 +116,7 @@ int process_cell_info_req(int msg_id, const cell_info_req_t* req,
snprintf(_mscgen_buffer, MSCGEN_BUFFER_SIZE,
"tac = 0x%.4x, cellID = 0x%.8x, rat = 0x%x, RSRQ = %u, RSRP = %u%c",
cnf->tac, cnf->cellID, cnf->rat, cnf->rsrq, cnf->rsrp, '\0');
MSCGEN("[MSC_MSG][%s][%s][--- Cell Information Confirm (0x%.4x)\\n%s --->][%s]\n",
printf("[%s][%s][--- Cell Information Confirm (0x%.4x)\\n%s --->][%s]\n",
getTime(), _as_id, AS_CELL_INFO_CNF, _mscgen_buffer, _ue_id);
printf("INFO\t: %s - Send cell informtion confirm\n", __FUNCTION__);
......@@ -146,13 +146,13 @@ int process_nas_establish_req(int msg_id, const nas_establish_req_t* req,
"cause = %s, type = %s, tmsi = {MMEcode = %d, m_tmsi = %u}%c",
rrcCause(req->cause), rrcType(req->type),
req->s_tmsi.MMEcode, req->s_tmsi.m_tmsi, '\0');
MSCGEN("[MSC_MSG][%s][%s][--- NAS Signalling Connection Establishment Request "
printf("[%s][%s][--- NAS Signalling Connection Establishment Request "
"(0x%.4x)\\n%s --->][%s]\n",
getTime(), _ue_id, msg_id, _mscgen_buffer, _as_id);
_process_dump(_mscgen_buffer, MSCGEN_BUFFER_SIZE,
(char*)req->initialNasMsg.data, req->initialNasMsg.length);
MSCGEN("[MSC_RBOX][%s][%s][%s]\n", _ue_id, _as_id, _mscgen_buffer);
printf("[%s][%s][%s]\n", _ue_id, _as_id, _mscgen_buffer);
/* Process initial NAS message */
bytes = nas_process(_mscgen_buffer, MSCGEN_BUFFER_SIZE,
......@@ -160,7 +160,7 @@ int process_nas_establish_req(int msg_id, const nas_establish_req_t* req,
req->initialNasMsg.length);
if (bytes < 0) {
MSCGEN("[MSC_MSG][%s][%s][--- NAS Signalling Connection Establishment "
printf("[%s][%s][--- NAS Signalling Connection Establishment "
"Indication (0x%.4x)\\ntac = 0x%.4x\\n%s ---x][%s]\n", getTime(),
_as_id, AS_NAS_ESTABLISH_IND, ind->tac, _mscgen_buffer, _mme_id);
/* Setup NAS signalling connection establishment confirmation message */
......@@ -190,7 +190,7 @@ int process_nas_establish_req(int msg_id, const nas_establish_req_t* req,
// Transmission failure of Attach Request message
//cnf->errCode = AS_FAILURE; // UE DEBUG
MSCGEN("[MSC_MSG][%s][%s][--- NAS Signalling Connection Establishment Indication "
printf("[%s][%s][--- NAS Signalling Connection Establishment Indication "
"(0x%.4x)\\nUEid = %u, tac = 0x%.4x\\n%s --->][%s]\n", getTime(),
_as_id, AS_NAS_ESTABLISH_IND, ind->UEid, ind->tac, _mscgen_buffer, _mme_id);
......@@ -224,13 +224,13 @@ int process_ul_info_transfer_req(int msg_id, const ul_info_transfer_req_t* req,
snprintf(_mscgen_buffer, MSCGEN_BUFFER_SIZE,
"tmsi = {MMEcode = %d, m_tmsi = %u}%c",
req->s_tmsi.MMEcode, req->s_tmsi.m_tmsi, '\0');
MSCGEN("[MSC_MSG][%s][%s][--- Uplink Information Request "
printf("[%s][%s][--- Uplink Information Request "
"(0x%.4x)\\n%s --->][%s]\n",
getTime(), _ue_id, msg_id, _mscgen_buffer, _as_id);
_process_dump(_mscgen_buffer, MSCGEN_BUFFER_SIZE,
(char*)req->nasMsg.data, req->nasMsg.length);
MSCGEN("[MSC_RBOX][%s][%s][%s]\n", _ue_id, _as_id, _mscgen_buffer);
printf("[%s][%s][%s]\n", _ue_id, _as_id, _mscgen_buffer);
/* Process NAS message */
bytes = nas_process(_mscgen_buffer, MSCGEN_BUFFER_SIZE,
......@@ -238,7 +238,7 @@ int process_ul_info_transfer_req(int msg_id, const ul_info_transfer_req_t* req,
req->nasMsg.length);
if (bytes < 0) {
MSCGEN("[MSC_MSG][%s][%s][--- Uplink Information Indication "
printf("[%s][%s][--- Uplink Information Indication "
"(0x%.4x)\\n%s ---x][%s]\n", getTime(),
_as_id, AS_UL_INFO_TRANSFER_IND, _mscgen_buffer, _mme_id);
/* Setup uplink information confirmation message */
......@@ -279,7 +279,7 @@ int process_ul_info_transfer_req(int msg_id, const ul_info_transfer_req_t* req,
// cnf->errCode = AS_FAILURE; // UE DEBUG
//}
MSCGEN("[MSC_MSG][%s][%s][--- Uplink Information Indication "
printf("[%s][%s][--- Uplink Information Indication "
"(0x%.4x), UEid = %u\\n%s --->][%s]\n", getTime(),
_as_id, AS_UL_INFO_TRANSFER_IND, ind->UEid, _mscgen_buffer, _mme_id);
......@@ -297,7 +297,7 @@ int process_nas_release_req(int msg_id, const nas_release_req_t* req)
printf("INFO\t: %s - Process NAS signalling connection release request\n",
__FUNCTION__);
MSCGEN("[MSC_MSG][%s][%s][--- NAS Signalling Release Request "
printf("[%s][%s][--- NAS Signalling Release Request "
"(0x%.4x), tmsi = {MMEcode = %d, m_tmsi = %u}, "
"cause = %s (%u) --->][%s]\n", getTime(), _ue_id, msg_id,
req->s_tmsi.MMEcode, req->s_tmsi.m_tmsi,
......@@ -332,14 +332,14 @@ int process_nas_establish_rsp(int msg_id, const nas_establish_rsp_t* rsp,
//rsp->nasMsg.data[21] = 0xc4; // MME DEBUG (Send ESM status)
//}
MSCGEN("[MSC_MSG][%s][%s][--- NAS Signalling Connection Establishment "
printf("[%s][%s][--- NAS Signalling Connection Establishment "
"Response (0x%.4x)\\nerrCode = %s, UEid = %u --->][%s]\n",
getTime(), _mme_id, msg_id,
rrcErrCode(rsp->errCode), rsp->UEid, _as_id);
_process_dump(_mscgen_buffer, MSCGEN_BUFFER_SIZE,
(char*)rsp->nasMsg.data, rsp->nasMsg.length);
MSCGEN("[MSC_RBOX][%s][%s][%s]\n", _mme_id, _as_id, _mscgen_buffer);
printf("[%s][%s][%s]\n", _mme_id, _as_id, _mscgen_buffer);
// Discard Attach Accept message
//return (0); // UE DEBUG
......@@ -350,7 +350,7 @@ int process_nas_establish_rsp(int msg_id, const nas_establish_rsp_t* rsp,
rsp->nasMsg.length);
if (bytes < 0) {
MSCGEN("[MSC_MSG][%s][%s][--- NAS Signalling Connection Establishment "
printf("[%s][%s][--- NAS Signalling Connection Establishment "
"Confirm (0x%.4x)\\n%s ---x][%s]\n", getTime(),
_as_id, AS_NAS_ESTABLISH_CNF, _mscgen_buffer, _ue_id);
return (0);
......@@ -369,7 +369,7 @@ int process_nas_establish_rsp(int msg_id, const nas_establish_rsp_t* rsp,
}
}
MSCGEN("[MSC_MSG][%s][%s][--- NAS Signalling Connection Establishment "
printf("[%s][%s][--- NAS Signalling Connection Establishment "
"Confirm (0x%.4x)\\n%s --->][%s]\n", getTime(),
_as_id, AS_NAS_ESTABLISH_CNF, _mscgen_buffer, _ue_id);
......@@ -401,13 +401,13 @@ int process_dl_info_transfer_req(int msg_id, const dl_info_transfer_req_t* req,
// req->nasMsg.data[6] = 0x02; // UE DEBUG
//}
MSCGEN("[MSC_MSG][%s][%s][--- Downlink Information Request "
printf("[%s][%s][--- Downlink Information Request "
"(0x%.4x), UEid = %u --->][%s]\n",
getTime(), _mme_id, msg_id, req->UEid, _as_id);
_process_dump(_mscgen_buffer, MSCGEN_BUFFER_SIZE,
(char*)req->nasMsg.data, req->nasMsg.length);
MSCGEN("[MSC_RBOX][%s][%s][%s]\n", _mme_id, _as_id, _mscgen_buffer);
printf("[%s][%s][%s]\n", _mme_id, _as_id, _mscgen_buffer);
/* Process NAS message */
bytes = nas_process(_mscgen_buffer, MSCGEN_BUFFER_SIZE,
......@@ -415,7 +415,7 @@ int process_dl_info_transfer_req(int msg_id, const dl_info_transfer_req_t* req,
req->nasMsg.length);
if (bytes < 0) {
MSCGEN("[MSC_MSG][%s][%s][--- Downlink Information Indication "
printf("[%s][%s][--- Downlink Information Indication "
"(0x%.4x)\\n%s ---x][%s]\n", getTime(),
_as_id, AS_DL_INFO_TRANSFER_IND, _mscgen_buffer, _ue_id);
/* Setup downlink information confirmation message */
......@@ -445,7 +445,7 @@ int process_dl_info_transfer_req(int msg_id, const dl_info_transfer_req_t* req,
// return (0); // MME DEBUG
//}
MSCGEN("[MSC_MSG][%s][%s][--- Downlink Information Indication "
printf("[%s][%s][--- Downlink Information Indication "
"(0x%.4x)\\n%s --->][%s]\n", getTime(),
_as_id, AS_DL_INFO_TRANSFER_IND, _mscgen_buffer, _ue_id);
......@@ -464,14 +464,14 @@ int process_nas_release_ind(int msg_id, const nas_release_req_t* req,
printf("INFO\t: %s - Process NAS signalling connection release request\n",
__FUNCTION__);
MSCGEN("[MSC_MSG][%s][%s][--- NAS Signalling Connection Release Request "
printf("[%s][%s][--- NAS Signalling Connection Release Request "
"(0x%.4x), UEid = %u, cause = %s (%u) --->][%s]\n",
getTime(), _mme_id, msg_id, req->UEid,
rrcReleaseCause(req->cause), req->cause, _as_id);
/* Forward NAS release indication to the UE */
ind->cause = req->cause;
MSCGEN("[MSC_MSG][%s][%s][--- NAS Signalling Connection Release Indication "
printf("[%s][%s][--- NAS Signalling Connection Release Indication "
"(0x%.4x), cause = %s (%u) --->][%s]\n",
getTime(), _as_id, msg_id, rrcReleaseCause(req->cause),
ind->cause, _ue_id);
......
......@@ -193,7 +193,7 @@ int main (int argc, const char* argv[])
printf("INFO\t: %s - The RRC Simulator is now connected to %s/%s (%d)\n",
__FUNCTION__, mhost, mport, socket_get_fd(_as_simulator_mme_sid));
MSCGEN("[MSC_NEW][%s][AS=%s]\n", getTime(), _as_id);
printf("[%s][AS=%s]\n", getTime(), _as_id);
/*
* Set up signal handler
......@@ -325,7 +325,7 @@ static void* _as_simulator_ue_mngr(void* args)
printf("INFO\t: %s - UE connection manager started\n", __FUNCTION__);
MSCGEN("[MSC_NEW][%s][NAS-UE=%s]\n", getTime(), _ue_id);
printf("[%s][NAS-UE=%s]\n", getTime(), _ue_id);
/* Receiving loop */
while (_as_simulator_ue_is_running) {
......@@ -407,7 +407,7 @@ static void* _as_simulator_mme_mngr(void* args)
printf("INFO\t: %s - MME connection manager started\n", __FUNCTION__);
MSCGEN("[MSC_NEW][%s][NAS-MME=%s]\n", getTime(), _mme_id);
printf("[%s][NAS-MME=%s]\n", getTime(), _mme_id);
/* Receiving loop */
while (_as_simulator_mme_is_running) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment