📄 manageprocess.c
字号:
LPs_NoofBroadcastComlList->s_BSC_NoOfBroadCastcoml[i].s_NoOfBroadcastComl[j].iNoOfBroadcastsCompl
);
}
}
/* Close stream */
fclose( stream );
}
/* 打印接收到BSC的Response响应 */
void Print_BSC_Response(PID_t s_Pid,
int MessageType,
int BSCPosi,
CBC_BSC_UNPACK_t *LPs_CBCBSC_Unpack)
{
FILE *stream;
char filename[100];
int i;
memset(&filename[0],0,100);
sprintf(filename, "C:\\CBCdebug\\BSC_ResponsePid=%dPosi=%d.txt" ,s_Pid.iProcessId,BSCPosi);
if( (stream = fopen( filename, "w+" )) == NULL )
{
return;
}
fprintf(stream,"Receive BSCResponse Message:\n");
fprintf(stream," Bscid=%d %d\n",s_BscConnectInfo[BSCPosi].BscIdentifier[0],s_BscConnectInfo[BSCPosi].BscIdentifier[1]);
/* 打印MessageIdentifier */
fprintf(stream,"\n MessageIdentifier\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_MessageIdentifier.bFlag);
fprintf(stream," Value=%d\n",LPs_CBCBSC_Unpack->p_MessageIdentifier.iMessageIdentifier);
/* 打印SerialNumber */
fprintf(stream,"\n SerialNumber\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_Serialnumber.bFlag);
fprintf(stream," Value=%d\n",LPs_CBCBSC_Unpack->p_Serialnumber.iSerialNumber);
/* 打印Channel Indicator */
fprintf(stream,"\n ChannelIndicator\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_ChannelIndicator.bFlag);
fprintf(stream," Value=%d\n",LPs_CBCBSC_Unpack->p_ChannelIndicator.cChannelIndicator);
/* 打印NoOfBroadcastCompleted */
fprintf(stream,"\n NoOfBroadcastCompleted\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.bFlag);
if (LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.bFlag==EXIST)
{
fprintf(stream," Length=%d\n",LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.ilength);
for(i=0;i<LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.ilength;i++)
{
fprintf(stream," CellId=%d %d %d %d ,Coml=%d ,ComlType=%d \n",
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].s_Cellid.cCellId[0],
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].s_Cellid.cCellId[1],
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].s_Cellid.cCellId[2],
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].s_Cellid.cCellId[3],
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].iNoOfBroadcastsCompl,
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].cNoOfBroadcastsComplType
);
}
}
/* 打印Failure-List */
fprintf(stream,"\n Failure-List\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_FailureReportList.bFlag);
if (LPs_CBCBSC_Unpack->p_FailureReportList.bFlag==EXIST)
{
fprintf(stream," Length=%d\n",LPs_CBCBSC_Unpack->p_FailureReportList.iLength);
for(i=0;i<LPs_CBCBSC_Unpack->p_FailureReportList.iLength;i++)
{
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cDiagnostic[DIAGNOSTIC_INFO_LEN-1]=0;
fprintf(stream," CellId=%d %d %d %d ,Cause=%d ,Diagnostic=%s \n",
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[0],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[1],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[2],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[3],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cCause,
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cDiagnostic
);
}
}
/* Close stream */
fclose( stream );
}
/* 打印接收到BSC的Status_CBCH_Query_Response响应 */
void Print_Status_CBCH_Query_RESP(PID_t s_Pid,
int MessageType,
int BSCPosi,
CBC_BSC_UNPACK_t *LPs_CBCBSC_Unpack)
{
FILE *stream;
char filename[100];
int i;
memset(&filename[0],0,100);
sprintf(filename, "C:\\CBCdebug\\BSC_CBCHRespPid=%dPosi=%d.txt" ,s_Pid.iProcessId,BSCPosi);
if( (stream = fopen( filename, "w+" )) == NULL )
{
return;
}
fprintf(stream,"Receive BSC Status-CBCH-Query-Resp Message:\n");
fprintf(stream," Bscid=%d %d\n",s_BscConnectInfo[BSCPosi].BscIdentifier[0],s_BscConnectInfo[BSCPosi].BscIdentifier[1]);
/* 打印CBCH-Loading-List */
fprintf(stream,"\n CBCH-Loading-List\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_CBCLOADINGSTATUSList.bFlag);
if (LPs_CBCBSC_Unpack->p_CBCLOADINGSTATUSList.bFlag==EXIST)
{
fprintf(stream," Length=%d\n",LPs_CBCBSC_Unpack->p_CBCLOADINGSTATUSList.iLength);
for(i=0;i<LPs_CBCBSC_Unpack->p_CBCLOADINGSTATUSList.iLength;i++)
{
fprintf(stream," CellId=%d %d %d %d ,CellIdDisc=%d ,Loading=%d \n",
LPs_CBCBSC_Unpack->p_CBCLOADINGSTATUSList.s_CbcLoadingStatus[i].s_Cellid.cCellId[0],
LPs_CBCBSC_Unpack->p_CBCLOADINGSTATUSList.s_CbcLoadingStatus[i].s_Cellid.cCellId[1],
LPs_CBCBSC_Unpack->p_CBCLOADINGSTATUSList.s_CbcLoadingStatus[i].s_Cellid.cCellId[2],
LPs_CBCBSC_Unpack->p_CBCLOADINGSTATUSList.s_CbcLoadingStatus[i].s_Cellid.cCellId[3],
LPs_CBCBSC_Unpack->p_CBCLOADINGSTATUSList.s_CbcLoadingStatus[i].s_Cellid.cCellIdDisc,
LPs_CBCBSC_Unpack->p_CBCLOADINGSTATUSList.s_CbcLoadingStatus[i].cCbcLoading
);
}
}
/* 打印Failure-List */
fprintf(stream,"\n Failure-List\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_FailureReportList.bFlag);
if (LPs_CBCBSC_Unpack->p_FailureReportList.bFlag==EXIST)
{
fprintf(stream," Length=%d\n",LPs_CBCBSC_Unpack->p_FailureReportList.iLength);
for(i=0;i<LPs_CBCBSC_Unpack->p_FailureReportList.iLength;i++)
{
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cDiagnostic[DIAGNOSTIC_INFO_LEN-1]=0;
fprintf(stream," CellId=%d %d %d %d ,Cause=%d ,Diagnostic=%s \n",
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[0],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[1],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[2],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[3],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cCause,
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cDiagnostic
);
}
}
/* 打印Channel Indicator */
fprintf(stream,"\n ChannelIndicator\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_ChannelIndicator.bFlag);
fprintf(stream," Value=%d\n",LPs_CBCBSC_Unpack->p_ChannelIndicator.cChannelIndicator);
/* Close stream */
fclose( stream );
}
/* 打印接收到BSC的StatusMessageQuery_Response响应 */
void Print_StatusMessageQuery_Response(PID_t s_Pid,
int MessageType,
int BSCPosi,
CBC_BSC_UNPACK_t *LPs_CBCBSC_Unpack)
{
FILE *stream;
char filename[100];
int i;
memset(&filename[0],0,100);
sprintf(filename, "C:\\CBCdebug\\BSC_StatusMsgQueryRespPid=%dPosi=%d.txt" ,s_Pid.iProcessId,BSCPosi);
if( (stream = fopen( filename, "w+" )) == NULL )
{
return;
}
fprintf(stream,"Receive BSC StatusMsgQuery Response Message:\n");
fprintf(stream," Bscid=%d %d\n",s_BscConnectInfo[BSCPosi].BscIdentifier[0],s_BscConnectInfo[BSCPosi].BscIdentifier[1]);
/* 打印MessageIdentifier */
fprintf(stream,"\n MessageIdentifier\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_MessageIdentifier.bFlag);
fprintf(stream," Value=%d\n",LPs_CBCBSC_Unpack->p_MessageIdentifier.iMessageIdentifier);
/* 打印SerialNumber */
fprintf(stream,"\n SerialNumber\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_Serialnumber.bFlag);
fprintf(stream," Value=%d\n",LPs_CBCBSC_Unpack->p_Serialnumber.iSerialNumber);
/* 打印Channel Indicator */
fprintf(stream,"\n ChannelIndicator\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_ChannelIndicator.bFlag);
fprintf(stream," Value=%d\n",LPs_CBCBSC_Unpack->p_ChannelIndicator.cChannelIndicator);
/* 打印NoOfBroadcastCompleted */
fprintf(stream,"\n NoOfBroadcastCompleted\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.bFlag);
if (LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.bFlag==EXIST)
{
fprintf(stream," Length=%d\n",LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.ilength);
for(i=0;i<LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.ilength;i++)
{
fprintf(stream," CellId=%d %d %d %d ,Coml=%d ,ComlType=%d \n",
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].s_Cellid.cCellId[0],
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].s_Cellid.cCellId[1],
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].s_Cellid.cCellId[2],
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].s_Cellid.cCellId[3],
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].iNoOfBroadcastsCompl,
LPs_CBCBSC_Unpack->p_NoofBroadcastComlList.s_NoOfBroadcastComl[i].cNoOfBroadcastsComplType
);
}
}
/* 打印Failure-List */
fprintf(stream,"\n Failure-List\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_FailureReportList.bFlag);
if (LPs_CBCBSC_Unpack->p_FailureReportList.bFlag==EXIST)
{
fprintf(stream," Length=%d\n",LPs_CBCBSC_Unpack->p_FailureReportList.iLength);
for(i=0;i<LPs_CBCBSC_Unpack->p_FailureReportList.iLength;i++)
{
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cDiagnostic[DIAGNOSTIC_INFO_LEN-1]=0;
fprintf(stream," CellId=%d %d %d %d ,Cause=%d ,Diagnostic=%s \n",
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[0],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[1],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[2],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[3],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cCause,
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cDiagnostic
);
}
}
/* Close stream */
fclose( stream );
}
/* 打印接收到BSC的RESTART-INDICATION Request响应 */
void Print_RestartIndication_Response(PID_t s_Pid,
int MessageType,
int BSCPosi,
CBC_BSC_UNPACK_t *LPs_CBCBSC_Unpack)
{
FILE *stream;
char filename[100];
int i;
memset(&filename[0],0,100);
sprintf(filename, "C:\\CBCdebug\\BSC_RestartRespPid=%dPosi=%d.txt" ,s_Pid.iProcessId,BSCPosi);
if( (stream = fopen( filename, "w+" )) == NULL )
{
return;
}
fprintf(stream,"Receive BSC Restart Indication Response Message:\n");
fprintf(stream," Bscid=%d %d\n",s_BscConnectInfo[BSCPosi].BscIdentifier[0],s_BscConnectInfo[BSCPosi].BscIdentifier[1]);
/* 打印CellList */
fprintf(stream,"\n CellList\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_CELLLIST.bFlag);
if (LPs_CBCBSC_Unpack->p_CELLLIST.bFlag==EXIST)
{
fprintf(stream," Length=%d\n",LPs_CBCBSC_Unpack->p_CELLLIST.iLength);
for(i=0;i<LPs_CBCBSC_Unpack->p_CELLLIST.iLength;i++)
{
fprintf(stream," CellIdDisc=%d\n",LPs_CBCBSC_Unpack->p_CELLLIST.cCellIdDisc);
fprintf(stream," CellId=%d %d %d %d \n",
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[0],
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[1],
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[2],
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[3]
);
}
}
/* 打印RecoveryIndicator */
fprintf(stream,"\n RecoveryIndicator\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_RECOVERYINDICATION.bFlag);
if (LPs_CBCBSC_Unpack->p_RECOVERYINDICATION.bFlag==EXIST)
{
fprintf(stream," RecoveryIndicator=%d\n",LPs_CBCBSC_Unpack->p_RECOVERYINDICATION.bRecoveryIndicator);
}
/* Close stream */
fclose( stream );
}
/* 打印接收到BSC的FAILURE-INDICATION Request响应 */
void Print_FailureIndication_Response(PID_t s_Pid,
int MessageType,
int BSCPosi,
CBC_BSC_UNPACK_t *LPs_CBCBSC_Unpack)
{
FILE *stream;
char filename[100];
int i;
memset(&filename[0],0,100);
sprintf(filename, "C:\\CBCdebug\\BSC_FailureIndicatorRespPid=%dPosi=%d.txt" ,s_Pid.iProcessId,BSCPosi);
if( (stream = fopen( filename, "w+" )) == NULL )
{
return;
}
fprintf(stream,"Receive BSC FAILURE_INDICATION Response Message:\n");
fprintf(stream," Bscid=%d %d\n",s_BscConnectInfo[BSCPosi].BscIdentifier[0],s_BscConnectInfo[BSCPosi].BscIdentifier[1]);
/* 打印CellList */
fprintf(stream,"\n CellList\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_CELLLIST.bFlag);
if (LPs_CBCBSC_Unpack->p_CELLLIST.bFlag==EXIST)
{
fprintf(stream," Length=%d\n",LPs_CBCBSC_Unpack->p_CELLLIST.iLength);
for(i=0;i<LPs_CBCBSC_Unpack->p_CELLLIST.iLength;i++)
{
fprintf(stream," CellIdDisc=%d\n",LPs_CBCBSC_Unpack->p_CELLLIST.cCellIdDisc);
fprintf(stream," CellId=%d %d %d %d \n",
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[0],
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[1],
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[2],
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[3]
);
}
}
/* Close stream */
fclose( stream );
}
/* 打印接收到BSC的SET-DRX-REPORT Response响应 */
void Print_SETDRX_REPORT_Response(PID_t s_Pid,
int MessageType,
int BSCPosi,
CBC_BSC_UNPACK_t *LPs_CBCBSC_Unpack)
{
FILE *stream;
char filename[100];
int i;
memset(&filename[0],0,100);
sprintf(filename, "C:\\CBCdebug\\BSC_SETDRXRespPid=%dPosi=%d.txt" ,s_Pid.iProcessId,BSCPosi);
if( (stream = fopen( filename, "w+" )) == NULL )
{
return;
}
fprintf(stream,"Receive BSC SETDRX_REPORT Response Message:\n");
fprintf(stream," Bscid=%d %d\n",s_BscConnectInfo[BSCPosi].BscIdentifier[0],s_BscConnectInfo[BSCPosi].BscIdentifier[1]);
/* 打印CellList */
fprintf(stream,"\n CellList\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_CELLLIST.bFlag);
if (LPs_CBCBSC_Unpack->p_CELLLIST.bFlag==EXIST)
{
fprintf(stream," Length=%d\n",LPs_CBCBSC_Unpack->p_CELLLIST.iLength);
for(i=0;i<LPs_CBCBSC_Unpack->p_CELLLIST.iLength;i++)
{
fprintf(stream," CellIdDisc=%d\n",LPs_CBCBSC_Unpack->p_CELLLIST.cCellIdDisc);
fprintf(stream," CellId=%d %d %d %d \n",
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[0],
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[1],
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[2],
LPs_CBCBSC_Unpack->p_CELLLIST.s_CellList[i].cCellId[3]
);
}
}
/* 打印Failure-List */
fprintf(stream,"\n Failure-List\n");
fprintf(stream," Flag=%d\n",LPs_CBCBSC_Unpack->p_FailureReportList.bFlag);
if (LPs_CBCBSC_Unpack->p_FailureReportList.bFlag==EXIST)
{
fprintf(stream," Length=%d\n",LPs_CBCBSC_Unpack->p_FailureReportList.iLength);
for(i=0;i<LPs_CBCBSC_Unpack->p_FailureReportList.iLength;i++)
{
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cDiagnostic[DIAGNOSTIC_INFO_LEN-1]=0;
fprintf(stream," CellId=%d %d %d %d ,Cause=%d ,Diagnostic=%s \n",
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[0],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[1],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[2],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].s_Cellid.cCellId[3],
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cCause,
LPs_CBCBSC_Unpack->p_FailureReportList.s_FailureReason[i].cDiagnostic
);
}
}
/* 打印Channel Indicator */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -