Newer
Older
* @version $Url: https://oldforge.etsi.org/svn/LibIts/tags/20170222_STF527_Final/ttcn/BTP/LibItsBtp_Templates.ttcn $
* $Id: LibItsBtp_Templates.ttcn 1318 2017-01-26 10:20:53Z filatov $
* @copyright ETSI Copyright Notification
* No part may be reproduced except as authorized by written permission.
* The copyright and the foregoing restriction extend to reproduction in all media.
* All rights reserved.
import from LibItsCommon_TypesAndValues all;
* @param p_btpPkt BTP Packet to be sent
/**
* @desc Receive template for BTP packet (BtpPort Primitive)
* @param p_btpPkt BTP Packet to be received
/**
* @desc Initializes the BTP IUT.
template (value) UtBtpInitialize m_btpInitialize := {
hashedId8 := '0000000000000000'O
/**
* @desc Generate a BTP A packet
* @param p_destPort The destination port
* @param p_srcPort The source port
template (value) UtBtpTrigger m_generateBtpA(in BtpPortId p_destPort, in BtpPortId p_srcPort) := {
btpA := {
btpAHeader := {
destinationPort := p_destPort,
sourcePort := p_srcPort
}
}
}
/**
* @desc Generate a BTP B packet
* @param p_destPort The destination port
* @param p_destPortInfo The destination port information
*/
template (value) UtBtpTrigger m_generateBtpB(in BtpPortId p_destPort, in BtpPortInfo p_destPortInfo) := {
btpB := {
btpBHeader := {
destinationPort := p_destPort,
destinationPortInfo := p_destPortInfo
}
} // btpPrimitivesTemplates
group btpPduTemplates {
/**
* @desc Send template for BTP-A packet
* @param p_destPort Destination port
* @param p_srcPort Source port
* @param p_payload Payload
*/
template (value) BtpPacket m_btpA (
template (value) BtpRawPayload p_payload
):= {
header := {
btpAHeader := {
destinationPort := PX_DESTINATION_PORT,
sourcePort := PX_SOURCE_PORT
}
},
payload := p_payload
}
/**
* @desc Send template for BTP-B packet
* @param p_destPort Destination port
* @param p_destPortInfo Destination port information
* @param p_payload Payload
*/
template( value) BtpPacket m_btpB (
template (value) BtpRawPayload p_payload
) := {
header := {
btpBHeader := {
destinationPort := PX_DESTINATION_PORT,
destinationPortInfo := 0
}
},
payload := p_payload
}
/**
* @desc Send template for BTP-A packet with port parameters
* @param p_destPort Destination port
* @param p_srcPort Source port
* @param p_payload Payload
template (value) BtpPortId p_destPort,
template (value) BtpPortId p_srcPort,
template (value) BtpRawPayload p_payload
):= {
header := {
btpAHeader := {
destinationPort := p_destPort,
sourcePort := p_srcPort
}
},
/**
* @desc Send template for BTP-B packet with port parameters
* @param p_destPort Destination port
* @param p_destPortInfo Destination port information
* @param p_payload Payload
template (value) BtpPortId p_destPort,
template (value) BtpPortInfo p_destPortInfo,
template (value) BtpRawPayload p_payload
) := {
header := {
btpBHeader := {
destinationPort := p_destPort,
destinationPortInfo := p_destPortInfo
}
},
/**
* @desc Receive template for BTP-A packet
* @param p_destPort Destination port
* @param p_srcPort Source port
* @param p_payload Payload
template (present) BtpPortId p_destPort,
template (present) BtpPortId p_srcPort,
template BtpRawPayload p_payload
) := {
header := {
btpAHeader := {
destinationPort := p_destPort,
sourcePort := p_srcPort
}
},
/**
* @desc Receive template for BTP-B packet
* @param p_destPort Destination port
* @param p_destPortInfo Destination port information
* @param p_payload Payload
template (present) BtpPortId p_destPort,
template (present) BtpPortInfo p_destPortInfo,
template BtpRawPayload p_payload
) := {
header := {
btpBHeader := {
destinationPort := p_destPort,
destinationPortInfo := p_destPortInfo
}
},