summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2018-03-24 22:32:01 +0100
committerHarald Welte <laforge@gnumonks.org>2018-03-24 22:33:59 +0100
commit1450953d2e8af2781dbf129867f0e6d656c3e0e1 (patch)
treee13071d375456a997c05258b6512d0c06ad14bb3
parent930d0a70e3c0f7dc6318725a371dbac6ef27b03c (diff)
MNCC_Emulation: Send HELLO in "server" role
-rw-r--r--library/MNCC_Emulation.ttcn1
-rw-r--r--library/MNCC_Types.ttcn14
2 files changed, 15 insertions, 0 deletions
diff --git a/library/MNCC_Emulation.ttcn b/library/MNCC_Emulation.ttcn
index 856575e..0669266 100644
--- a/library/MNCC_Emulation.ttcn
+++ b/library/MNCC_Emulation.ttcn
@@ -267,6 +267,7 @@ runs on MNCC_Emulation_CT {
if (role_server) {
f_listen(sock);
+ MNCC.send(t_SD_MNCC(g_mncc_ud_id, ts_MNCC_HELLO));
} else {
f_connect(sock);
}
diff --git a/library/MNCC_Types.ttcn b/library/MNCC_Types.ttcn
index 8d47efb..1818ff3 100644
--- a/library/MNCC_Types.ttcn
+++ b/library/MNCC_Types.ttcn
@@ -398,6 +398,20 @@ external function enc_MNCC_PDU(in MNCC_PDU pdu) return octetstring;
external function dec_MNCC_PDU(in octetstring stream) return MNCC_PDU;
+template (value) MNCC_PDU ts_MNCC_HELLO(uint32_t version := 5) := {
+ msg_type := MNCC_SOCKET_HELLO,
+ u := {
+ hello := {
+ version := version,
+ mncc_size := 836,
+ data_frame_size := 8,
+ called_offset := 104,
+ signal_offset := 796,
+ emergency_offset := 812,
+ lchan_type_offset := 0
+ }
+ }
+}
template MNCC_PDU ts_MNCC_Sign(MNCC_MsgType msg_type, MNCC_PDU_Signal sign) := {
msg_type := msg_type,