Commit 784b8a81 authored by petersenj's avatar petersenj
Browse files

Changed and resolved type-issues

parent 19c0f2e5
Loading
Loading
Loading
Loading
+19 −27
Original line number Diff line number Diff line
@@ -74,51 +74,43 @@ type record Frame4 {

// 5.2 Header frame


type record HeaderFrame {
  HeaderType          headerType,
  CalledId            calledId,
  OwnId               ownId,
  CommunicationsMode  communicationsMode,
  CommsFormat         commsFormat,
  Reserved2bit        reserved2bit,
  CallInformation     callInformation,
  ColourCode		  colourCode			// Not part of the Header Information but needed for testing
	Preamble preamble,
	FrameSync1 frameSync1,
	HeaderInformation headerInformation0,
	ColourCode		  colourCode,
	HeaderInformation headerInformation1
}


// 5.3 End frame

type record EndFrame {
  EndType        endType,
  AckRequest     ackRequest,
  TxWait         txWait,
  StatusMessage  statusMessage,
  Reserved4bit   reserved4bit
	FrameSync3 frameSync3,
  	EndInformation endInformation0,
  	EndInformation endInformation1
}

// 5.4 Packed data header

type record PacketDataHeader {
  HeaderType          headerType,
  CalledId            calledId,
  OwnId               ownId,
  CommunicationsMode  communicationsMode,
  CommsFormat         commsFormat,
  Reserved2bit        reserved2bit,
  CallInformation     callInformation
	Preamble preamble,
	FrameSync4 frameSync4,
	HeaderInformation headerInformation0,
	ColourCode		  colourCode,
	HeaderInformation headerInformation1
}


// 5.5 ACK frame

type record AckFrame {
  HeaderType          headerType,
  CalledId            calledId,
  OwnId               ownId,
  CommunicationsMode  communicationsMode,
  CommsFormat         commsFormat,
  Reserved2bit        reserved2bit,
  CallInformation     callInformation
	Preamble preamble,
	FrameSync1 frameSync1,
	HeaderInformation headerInformation0,
	ColourCode		  colourCode,
	HeaderInformation headerInformation1
}

} // End group Frames
+30 −26
Original line number Diff line number Diff line
@@ -26,12 +26,11 @@
			endFrame := p_endFrame 
		}


 	template HeaderFrame m_headerFrameConnectReq( CalledId p_calledId , 
 	template HeaderInformation  m_headerInformation ( CalledId p_calledId , 
												      OwnId    p_ownId, 
												      CommunicationsMode p_commMode,
												  CommsFormat p_commFormat,
												  ColourCode p_cc ) := {
												      CommsFormat p_commFormat
												     ) := {
		headerType := e_connReqHeader,
  		calledId := p_calledId,
  		ownId := p_ownId,
@@ -39,18 +38,30 @@
    	commsFormat := p_commFormat,
  		reserved2bit := c_reserved2bits,
  		callInformation := { 
			ciInformationNormalOrPws :=c_ciInformationNormal },
		colourCode := p_cc
	}

			ciInformationNormalOrPws :=c_ciInformationNormal }
	} // end m_headerInformation

 	template HeaderFrame m_headerFrameConnectReq (in template HeaderInformation p_headerInformation, 
															  ColourCode        p_cc) := { 
		preamble := c_preamble,
		frameSync1 := c_fs1,
		headerInformation0 := p_headerInformation,
		headerInformation1 := p_headerInformation,
		colourCode := p_cc
	}// end m_headerFrameConnectReq

	template EndFrame m_endFrameConnectReq := {
 	template EndInformation  m_endInformation := {
		endType := e_endFrame ,
  		ackRequest := e_AckReq,
  		txWait := e_noSpecTime,
  		statusMessage := c_dummyStatusValue,
  		reserved4bit := c_reserved4bits
	}// end m_endInformation

	template EndFrame m_endFrameConnectReq := {
		frameSync3 := c_fs3,
		endInformation0 := m_endInformation,
		endInformation1 := m_endInformation
	}

 	
@@ -59,20 +70,13 @@
		colourCode := p_cc
	}



	template AckFrame mw_acknowledgementAckOnConnectReq( CalledId p_calledId , 
												  		 OwnId    p_ownId ,
														 CommunicationsMode p_commMode,
														 CommsFormat p_commFormat ) := {
	  headerType := e_ack,
	  calledId := p_calledId,
	  ownId := p_ownId,
	  communicationsMode := p_commMode,
	  commsFormat := p_commFormat,
	  reserved2bit := c_reserved2bits,
  	  callInformation := { 
		  ciInformationNormalOrPws :=c_ciInformationNormal }
	template AckFrame mw_acknowledgementAckOnConnectReq( in template HeaderInformation p_headerInformation, 
															  ColourCode        p_cc) := { 
		preamble := c_preamble,
		frameSync1 := c_fs1,
		headerInformation0 := p_headerInformation,
		headerInformation1 := p_headerInformation,
		colourCode := p_cc
	}

 } // end module dPMR_Templates
 No newline at end of file
+43 −3
Original line number Diff line number Diff line
@@ -27,6 +27,37 @@ module dPMR_TestCases {

group IsfCsfCommon {

	group AllCall {

	/*
	 * @desc	TP Ref: TC_PMR_0824_01
	*/
		testcase TC_PMR_0824_01(ColourCode p_cc, MSAddress p_ms_address) 	// The Common ID is User Selectable!
																			// Here it should be > 0 && < 255
																			// fixed part shall be '1111111111111111'
		runs on ServerSyncComp
		system TestAdapter {

			//Variables
			var Simu v_simu;
			var Ut v_ut;

			//Configuration Up
			f_cfSimuUp(v_simu, v_ut);

			//Test body
//			v_simu.start(f_msVoiceTransmissionCommon_ID_set_255(p_cc));
//			v_ut.start(f_TC_IutToStandby_withCommon_ID_Ut(p_cc,p_ms_address)); // where to set the ,p_ms_address?????

			// synchronize both PTCs
			f_serverSync2ClientsAndStop({c_prDone});

			// Configuration Down
			f_cfSimuDown(v_simu, v_ut);

		} // end TC_PMR_0824_01
	} // end group AllCall

	group Framing {

	/*
@@ -44,7 +75,7 @@ group IsfCsfCommon {
		f_cfSimuUp(v_simu, v_ut);

		//Test body
		v_simu.start(f_msAckOnConnectionRequest_Simu(p_cc/*c_grpBcf1*/));
		v_simu.start(f_msAckOnConnectionRequest_Simu(p_cc));
		v_ut.start(f_TC_MsToStandby_Ut(p_cc/*c_grpBcf1*/)); // select CC B channel 1

		// synchronize both PTCs
@@ -68,9 +99,18 @@ group IsfCsfCommon {
		
		//Test Body
		tc_ac.start ;
		dp1Port.send(m_callOrSrvReq(m_headerFrameConnectReq(PXT_CALLED_ID, PXT_OWN_ID, e_voice, e_p2p, p_cc),m_endFrameConnectReq));
		dp1Port.send(m_callOrSrvReq(
						m_headerFrameConnectReq(
							m_headerInformation(PXT_CALLED_ID, PXT_OWN_ID, e_voice, e_p2p),
							p_cc),
						m_endFrameConnectReq)
					);
		alt {
			[] dp1Port.receive(mw_acknowledgementAckOnConnectReq(PXT_OWN_ID, PXT_CALLED_ID, e_voice, e_p2p)) {
			[] dp1Port.receive(mw_acknowledgementAckOnConnectReq(
								    m_headerInformation(PXT_OWN_ID, PXT_CALLED_ID, e_voice, e_p2p),
									p_cc)
							   )
				{
					setverdict(pass);
				}
			[] tc_ac.timeout {
+48 −0
Original line number Diff line number Diff line
@@ -16,6 +16,33 @@ module dPMR_Types {

// ------------ Information elements ---------------


//// This needs to be declared in "LibCommon_DataStrings.ttcn" ????????????????
type bitstring  Bit72   length(72) with {encode "length(72)"};
group FrameCodingTypes {

// 5.1 to 5.5 Header Information

type record HeaderInformation {
  HeaderType          headerType,
  CalledId            calledId,
  OwnId               ownId,
  CommunicationsMode  communicationsMode,
  CommsFormat         commsFormat,
  Reserved2bit        reserved2bit,
  CallInformation     callInformation
}

type record EndInformation {
  EndType        endType,
  AckRequest     ackRequest,
  TxWait         txWait,
  StatusMessage  statusMessage,
  Reserved4bit   reserved4bit
}

}

group InformationElements {

// 5.6 Frame numbering
@@ -349,6 +376,12 @@ type union Data {
  UserDataPds3  userDataPds3    // 180 octets maximum
}

type Bit72 Preamble;
type Bit48 FrameSync1;
type Bit24 FrameSync2;
type Bit24 FrameSync3;
type Bit48 FrameSync4;


type Oct36   UserDataPds0;
type Oct84   UserDataPds1;
@@ -367,6 +400,21 @@ type octetstring Oct180 length(180) with {encode "180 bytes"};
type Bit12 CalledIdUP;
type Bit12 CalledIdLP;

type Bit8 Common_ID;
type Bit16 FixedPart;

type record ISFAddress {
	Common_ID common_ID,
	FixedPart fixedPart
}

type Bit24 CSFAddress;

type union MSAddress {
	ISFAddress isfAddress,
	CSFAddress cfsAddress
}

type Bit24 CalledId;

type Bit12 OwnIdUP;
+4 −1
Original line number Diff line number Diff line
@@ -57,12 +57,15 @@ const ColourCode c_grpBcf14 := '111111010111111101110101'B;
const ColourCode c_grpBcf15 := '111111011101011101110111'B;
const ColourCode c_grpBcf16 := '111111011111110101110111'B;

// 6.1.6 Preamble

const Preamble c_preamble := hex2bit('5F5F5F5F5F5F5F5F5F'H);


// Maximum number of Super frames in a continuous payload transmission. Limited by the rule of max 180 sec
// continuous transmission.

const UInt10 c_maxNbrOfSfs := 665;
const UInt10 c_maxNbrOfSfs := 562;


// Maximum number of packet frames in a Packet data transmission