<p>laforge <strong>merged</strong> this change.</p><p><a href="https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/15374">View Change</a></p><div style="white-space:pre-wrap">Approvals:
  laforge: Looks good to me, approved
  pespin: Looks good to me, but someone else must approve
  Jenkins Builder: Verified

</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">Add CBSP (Cell Broadcast Service Protocol) types + templates<br><br>Change-Id: Ida2e0af7d282fd7d5318110c05efa5a10114242c<br>---<br>A library/CBSP_Templates.ttcn<br>A library/CBSP_Types.ttcn<br>2 files changed, 1,125 insertions(+), 0 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/library/CBSP_Templates.ttcn b/library/CBSP_Templates.ttcn</span><br><span>new file mode 100644</span><br><span>index 0000000..3c60f14</span><br><span>--- /dev/null</span><br><span>+++ b/library/CBSP_Templates.ttcn</span><br><span>@@ -0,0 +1,744 @@</span><br><span style="color: hsl(120, 100%, 40%);">+module CBSP_Templates {</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+import from Osmocom_Types all;</span><br><span style="color: hsl(120, 100%, 40%);">+import from BSSAP_Types all;</span><br><span style="color: hsl(120, 100%, 40%);">+import from CBSP_Types all;</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* TODO: receive templates must match IEs in any arbitrary order */</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* For some reason the TTCN-3 RAW codec cannot automatically figure out the IEI</span><br><span style="color: hsl(120, 100%, 40%);">+ * that it needs to set for a given union-choice (body).  So we have to explicitly</span><br><span style="color: hsl(120, 100%, 40%);">+ * specify the IEI by the caller :( */</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CBSP_IE(CBSP_IEI iei, template (value) CBSP_IE_Body body) := {</span><br><span style="color: hsl(120, 100%, 40%);">+   iei := iei,</span><br><span style="color: hsl(120, 100%, 40%);">+   body := body</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CBSP_IE(template CBSP_IE_Body body) := {</span><br><span style="color: hsl(120, 100%, 40%);">+       iei := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+     body := body</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspMsgId(template (value) uint16_t val) :=</span><br><span style="color: hsl(120, 100%, 40%);">+  ts_CBSP_IE(CBSP_IEI_MSG_ID, {msg_id := val});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspMsgId(template uint16_t val := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+   tr_CBSP_IE({msg_id := val});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_NewSerNo(template (value) uint16_t val) :=</span><br><span style="color: hsl(120, 100%, 40%);">+        ts_CBSP_IE(CBSP_IEI_NEW_SERIAL_NR, {new_ser_nr := val});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_NewSerNo(template uint16_t val := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+ tr_CBSP_IE({new_ser_nr := val});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_OldSerNo(template (value) uint16_t val) :=</span><br><span style="color: hsl(120, 100%, 40%);">+    ts_CBSP_IE(CBSP_IEI_OLD_SERIAL_NR, {old_ser_nr := val});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_OldSerNo(template uint16_t val := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+ tr_CBSP_IE({old_ser_nr := val});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspKARepPeriod(template (value) uint8_t rep_per) :=</span><br><span style="color: hsl(120, 100%, 40%);">+  ts_CBSP_IE(CBSP_IEI_KEEP_ALIVE_REP_PERIOD, {keep_alive_rep_period := rep_per});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspKARepPeriod(template uint8_t rep_per := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+        tr_CBSP_IE({keep_alive_rep_period := rep_per});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+function ts_CbspChannelInd(template (omit) uint8_t val) return template (omit) CBSP_IE {</span><br><span style="color: hsl(120, 100%, 40%);">+   var template (omit) CBSP_IE ie;</span><br><span style="color: hsl(120, 100%, 40%);">+       if (istemplatekind(val, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+          ie := omit;</span><br><span style="color: hsl(120, 100%, 40%);">+   } else {</span><br><span style="color: hsl(120, 100%, 40%);">+              ie := ts_CBSP_IE(CBSP_IEI_CHANNEL_IND, {channel_ind := val});</span><br><span style="color: hsl(120, 100%, 40%);">+ }</span><br><span style="color: hsl(120, 100%, 40%);">+     return ie;</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+function tr_CbspChannelInd(template uint8_t val := ?) return template CBSP_IE {</span><br><span style="color: hsl(120, 100%, 40%);">+        var template CBSP_IE ie;</span><br><span style="color: hsl(120, 100%, 40%);">+      if (istemplatekind(val, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+          ie := omit;</span><br><span style="color: hsl(120, 100%, 40%);">+   } else if (istemplatekind(val, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+              ie := tr_CBSP_IE({channel_ind := ?}) ifpresent;</span><br><span style="color: hsl(120, 100%, 40%);">+       } else {</span><br><span style="color: hsl(120, 100%, 40%);">+              ie := tr_CBSP_IE({channel_ind := val});</span><br><span style="color: hsl(120, 100%, 40%);">+       }</span><br><span style="color: hsl(120, 100%, 40%);">+     return ie;</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspCause(template (value) CBSP_Cause c) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      ts_CBSP_IE(CBSP_IEI_CAUSE, {cause := c});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspCause(template CBSP_Cause c := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+       tr_CBSP_IE({cause := c});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspCellList(template (value) BSSMAP_FIELD_CellIdentificationList list) :=</span><br><span style="color: hsl(120, 100%, 40%);">+   ts_CBSP_IE(CBSP_IEI_CELL_LIST, {</span><br><span style="color: hsl(120, 100%, 40%);">+                      cell_list := {</span><br><span style="color: hsl(120, 100%, 40%);">+                                len := 0,</span><br><span style="color: hsl(120, 100%, 40%);">+                             spare1_4 := '0000'B,</span><br><span style="color: hsl(120, 100%, 40%);">+                          cell_id_discr := '0000'B,</span><br><span style="color: hsl(120, 100%, 40%);">+                             cell_id := list</span><br><span style="color: hsl(120, 100%, 40%);">+                       }});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspCellList(template BSSMAP_FIELD_CellIdentificationList list := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+     tr_CBSP_IE({</span><br><span style="color: hsl(120, 100%, 40%);">+                  cell_list := {</span><br><span style="color: hsl(120, 100%, 40%);">+                                len := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                             spare1_4 := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                cell_id_discr := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                           cell_id := list</span><br><span style="color: hsl(120, 100%, 40%);">+                       }});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspCategory(template (value) CBSP_Category cat) :=</span><br><span style="color: hsl(120, 100%, 40%);">+       ts_CBSP_IE(CBSP_IEI_CATEGORY, {category := cat});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspCategory(template CBSP_Category cat := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+       tr_CBSP_IE({category := cat});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspRepetitionPeriod(template (value) uint16_t per) :=</span><br><span style="color: hsl(120, 100%, 40%);">+  ts_CBSP_IE(CBSP_IEI_REP_PERIOD, {rep_period := per});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspRepetitionPeriod(template uint16_t per := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+        tr_CBSP_IE({rep_period := per});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspNumBcastReq(template (value) uint16_t num) :=</span><br><span style="color: hsl(120, 100%, 40%);">+     ts_CBSP_IE(CBSP_IEI_NUM_BCAST_REQ, {num_bcast_req := num});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspNumBcastReq(template uint16_t num := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+       tr_CBSP_IE({num_bcast_req := num});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspNumPages(template (value) uint8_t num) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      ts_CBSP_IE(CBSP_IEI_NUM_OF_PAGES, {num_of_pages := num});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspNumPages(template uint16_t num := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+    tr_CBSP_IE({num_of_pages := num});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_EmergencyInd(template (value) uint8_t val) :=</span><br><span style="color: hsl(120, 100%, 40%);">+       ts_CBSP_IE(CBSP_IEI_EMERG_IND, {emerg_ind := val});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_EmergencyInd(template uint8_t val := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+   tr_CBSP_IE({emerg_ind := val});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_WarningType(template (value) uint16_t val) :=</span><br><span style="color: hsl(120, 100%, 40%);">+  ts_CBSP_IE(CBSP_IEI_WARN_TYPE, {warn_type := val});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_WarningType(template uint16_t val) :=</span><br><span style="color: hsl(120, 100%, 40%);">+        tr_CBSP_IE({warn_type := val});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_WarnSecInfo(template (value) octetstring payl := ''O) :=</span><br><span style="color: hsl(120, 100%, 40%);">+       ts_CBSP_IE(CBSP_IEI_WARN_SEC_INFO, {warn_sec_info := payl});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_WarnSecInfo(template octetstring payl := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      tr_CBSP_IE({warn_sec_info := payl});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_WarningPeriod(template (value) uint8_t val) :=</span><br><span style="color: hsl(120, 100%, 40%);">+    ts_CBSP_IE(CBSP_IEI_WARNING_PERIOD, {warning_period := val});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_WarningPeriod(template uint8_t val := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+        tr_CBSP_IE({warning_period := val});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspFailList(template (value) CBSP_FailureListItems items) :=</span><br><span style="color: hsl(120, 100%, 40%);">+     ts_CBSP_IE(CBSP_IEI_FAILURE_LIST, {failure_list := {</span><br><span style="color: hsl(120, 100%, 40%);">+                                          len := 0,</span><br><span style="color: hsl(120, 100%, 40%);">+                                             list := items</span><br><span style="color: hsl(120, 100%, 40%);">+                         }});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspFailList(template CBSP_FailureListItems items := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+  tr_CBSP_IE({failure_list := {</span><br><span style="color: hsl(120, 100%, 40%);">+                                         len := 0,</span><br><span style="color: hsl(120, 100%, 40%);">+                                             list := items</span><br><span style="color: hsl(120, 100%, 40%);">+                         }});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspNumComplList(template (value) CBSP_IE_NumBcastComplList list) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      ts_CBSP_IE(CBSP_IEI_NUM_BCAST_COMPL_LIST, {num_bcast_compl_list := list});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspNumComplList(template CBSP_IE_NumBcastComplList list := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+     tr_CBSP_IE({num_bcast_compl_list := list});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspBcastMsgType(template (value) CBSP_BcastMsgType bi) :=</span><br><span style="color: hsl(120, 100%, 40%);">+ ts_CBSP_IE(CBSP_IEI_BCAST_MSG_TYPE, {bcast_msg_type := {</span><br><span style="color: hsl(120, 100%, 40%);">+                      spare1_4 := '0000'B,</span><br><span style="color: hsl(120, 100%, 40%);">+                  msg_type := bi</span><br><span style="color: hsl(120, 100%, 40%);">+                }});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspBcastMsgType(template CBSP_BcastMsgType bi := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+     tr_CBSP_IE({bcast_msg_type := {</span><br><span style="color: hsl(120, 100%, 40%);">+                       spare1_4 := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                        msg_type := bi</span><br><span style="color: hsl(120, 100%, 40%);">+                }});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspRecoveryInd(template (value) CBSP_RecoveryInd ri) :=</span><br><span style="color: hsl(120, 100%, 40%);">+  ts_CBSP_IE(CBSP_IEI_RECOVERY_IND, {recovery_ind := {</span><br><span style="color: hsl(120, 100%, 40%);">+                  spare1_4 := '0000'B,</span><br><span style="color: hsl(120, 100%, 40%);">+                  recovery := ri</span><br><span style="color: hsl(120, 100%, 40%);">+                }});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspRecoveryInd(template CBSP_RecoveryInd ri) :=</span><br><span style="color: hsl(120, 100%, 40%);">+    tr_CBSP_IE({recovery_ind := {</span><br><span style="color: hsl(120, 100%, 40%);">+                 spare1_4 := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                        recovery := ri</span><br><span style="color: hsl(120, 100%, 40%);">+                }});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspMsgContent(template (value) octetstring payload, uint8_t user_len) :=</span><br><span style="color: hsl(120, 100%, 40%);">+ ts_CBSP_IE(CBSP_IEI_MSG_CONTENT, {msg_content := {</span><br><span style="color: hsl(120, 100%, 40%);">+                    user_len := user_len,</span><br><span style="color: hsl(120, 100%, 40%);">+                 val := payload</span><br><span style="color: hsl(120, 100%, 40%);">+                }});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspMsgContent(template octetstring payload := ?, template uint8_t user_len := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+        tr_CBSP_IE({msg_content := {</span><br><span style="color: hsl(120, 100%, 40%);">+                  user_len := user_len,</span><br><span style="color: hsl(120, 100%, 40%);">+                 val := payload</span><br><span style="color: hsl(120, 100%, 40%);">+                }});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_IE ts_CbspDCS(template (value) uint8_t dcs) :=</span><br><span style="color: hsl(120, 100%, 40%);">+  ts_CBSP_IE(CBSP_IEI_DCS, {dcs := dcs});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_IE tr_CbspDCS(template uint8_t dcs := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+    tr_CBSP_IE({dcs := dcs});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP(CBSP_MessageType msg_type, template (value) CBSP_IEs ies) := {</span><br><span style="color: hsl(120, 100%, 40%);">+       msg_type := msg_type,</span><br><span style="color: hsl(120, 100%, 40%);">+ len := 0, /* overwritten */</span><br><span style="color: hsl(120, 100%, 40%);">+   ies := ies</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP(template CBSP_MessageType msg_type := ?, template CBSP_IEs ies := *) := {</span><br><span style="color: hsl(120, 100%, 40%);">+    msg_type := msg_type,</span><br><span style="color: hsl(120, 100%, 40%);">+ len := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+     ies := ies</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.1 WRITE REPLACE */</span><br><span style="color: hsl(120, 100%, 40%);">+function ts_CBSP_WRITE_CBS(template (value) uint16_t msg_id,</span><br><span style="color: hsl(120, 100%, 40%);">+                            template (value) uint16_t new_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                         template (value) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                       template (value) uint8_t channel_ind,</span><br><span style="color: hsl(120, 100%, 40%);">+                         template (value) CBSP_Category category,</span><br><span style="color: hsl(120, 100%, 40%);">+                      template (value) uint16_t rep_period,</span><br><span style="color: hsl(120, 100%, 40%);">+                         template (value) uint16_t num_bcast_req,</span><br><span style="color: hsl(120, 100%, 40%);">+                      template (value) uint8_t dcs,</span><br><span style="color: hsl(120, 100%, 40%);">+                         template (value) CBSP_IEs content) return template (value) CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+     var template (value) CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         ts_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+           ts_CbspChannelInd(channel_ind),</span><br><span style="color: hsl(120, 100%, 40%);">+               ts_CbspCategory(category),</span><br><span style="color: hsl(120, 100%, 40%);">+            ts_CbspRepetitionPeriod(rep_period),</span><br><span style="color: hsl(120, 100%, 40%);">+          ts_CbspNumBcastReq(num_bcast_req),</span><br><span style="color: hsl(120, 100%, 40%);">+            ts_CbspDCS(dcs),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_CbspNumPages(lengthof(content))</span><br><span style="color: hsl(120, 100%, 40%);">+    };</span><br><span style="color: hsl(120, 100%, 40%);">+    return ts_CBSP(CBSP_MSGT_WRITE_REPLACE, valueof(ies) & valueof(content));</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_WRITE_CBS(template uint16_t msg_id := ?, template uint16_t new_ser_nr := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                   template BSSMAP_FIELD_CellIdentificationList cell_list := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                  template uint8_t channel_ind := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                    template CBSP_Category category := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template uint16_t rep_period := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                    template uint16_t num_bcast_req := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template uint8_t dcs := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                    template CBSP_IEs content := ?</span><br><span style="color: hsl(120, 100%, 40%);">+                                ) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      tr_CBSP(CBSP_MSGT_WRITE_REPLACE, ({</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+                 tr_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      tr_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_CbspChannelInd(channel_ind),</span><br><span style="color: hsl(120, 100%, 40%);">+                       tr_CbspCategory(category),</span><br><span style="color: hsl(120, 100%, 40%);">+                    tr_CbspRepetitionPeriod(rep_period),</span><br><span style="color: hsl(120, 100%, 40%);">+                  tr_CbspNumBcastReq(num_bcast_req),</span><br><span style="color: hsl(120, 100%, 40%);">+                    tr_CbspDCS(dcs),</span><br><span style="color: hsl(120, 100%, 40%);">+                      tr_CbspNumPages(lengthof(content)), all from content }));</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+function ts_CBSP_REPLACE_CBS(uint16_t msg_id, uint16_t new_ser_nr, uint16_t old_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                            template (value) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                       template (value) uint8_t channel_ind,</span><br><span style="color: hsl(120, 100%, 40%);">+                         template (value) CBSP_Category category,</span><br><span style="color: hsl(120, 100%, 40%);">+                      template (value) uint16_t rep_period,</span><br><span style="color: hsl(120, 100%, 40%);">+                         template (value) uint16_t num_bcast_req,</span><br><span style="color: hsl(120, 100%, 40%);">+                      template (value) uint8_t dcs,</span><br><span style="color: hsl(120, 100%, 40%);">+                         template (value) CBSP_IEs content) return template (value) CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+     var template (value) CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         ts_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+           ts_CbspChannelInd(channel_ind),</span><br><span style="color: hsl(120, 100%, 40%);">+               ts_CbspCategory(category),</span><br><span style="color: hsl(120, 100%, 40%);">+            ts_CbspRepetitionPeriod(rep_period),</span><br><span style="color: hsl(120, 100%, 40%);">+          ts_CbspNumBcastReq(num_bcast_req),</span><br><span style="color: hsl(120, 100%, 40%);">+            ts_CbspDCS(dcs),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_CbspNumPages(lengthof(content))</span><br><span style="color: hsl(120, 100%, 40%);">+    };</span><br><span style="color: hsl(120, 100%, 40%);">+    return ts_CBSP(CBSP_MSGT_WRITE_REPLACE, valueof(ies) & valueof(content));</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_REPLACE_CBS(template uint16_t msg_id := ?, template uint16_t new_ser_nr := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                   template uint16_t old_ser_nr := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                    template BSSMAP_FIELD_CellIdentificationList cell_list := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                  template uint8_t channel_ind := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                    template CBSP_Category category := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template uint16_t rep_period := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                    template uint16_t num_bcast_req := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template uint8_t dcs := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                    template CBSP_IEs content := ?</span><br><span style="color: hsl(120, 100%, 40%);">+                              ) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      tr_CBSP(CBSP_MSGT_WRITE_REPLACE, ({</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+                 tr_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      tr_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      tr_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_CbspChannelInd(channel_ind),</span><br><span style="color: hsl(120, 100%, 40%);">+                       tr_CbspCategory(category),</span><br><span style="color: hsl(120, 100%, 40%);">+                    tr_CbspRepetitionPeriod(rep_period),</span><br><span style="color: hsl(120, 100%, 40%);">+                  tr_CbspNumBcastReq(num_bcast_req),</span><br><span style="color: hsl(120, 100%, 40%);">+                    tr_CbspDCS(dcs),</span><br><span style="color: hsl(120, 100%, 40%);">+                      tr_CbspNumPages(lengthof(content)), all from content }));</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_WRITE_EMERG(uint16_t msg_id, uint16_t new_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                              template (value) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                               template (value) uint8_t emerg_ind,</span><br><span style="color: hsl(120, 100%, 40%);">+                                           template (value) uint16_t warn_type,</span><br><span style="color: hsl(120, 100%, 40%);">+                                          template (value) uint16_t num_bcast_req,</span><br><span style="color: hsl(120, 100%, 40%);">+                                              template (value) uint8_t warn_per</span><br><span style="color: hsl(120, 100%, 40%);">+                                         ) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      ts_CBSP(CBSP_MSGT_WRITE_REPLACE, {</span><br><span style="color: hsl(120, 100%, 40%);">+                    ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+                 ts_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      ts_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   ts_EmergencyInd(emerg_ind),</span><br><span style="color: hsl(120, 100%, 40%);">+                   ts_WarningType(warn_type),</span><br><span style="color: hsl(120, 100%, 40%);">+                    ts_WarnSecInfo,</span><br><span style="color: hsl(120, 100%, 40%);">+                       ts_WarningPeriod(warn_per) });</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_WRITE_EMERG(template uint16_t msg_id := ?, template uint16_t new_ser_nr := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                       template BSSMAP_FIELD_CellIdentificationList cell_list := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                  template uint8_t emerg_ind := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                      template uint16_t warn_type := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                     template uint16_t num_bcast_req := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template uint8_t warn_per := ?</span><br><span style="color: hsl(120, 100%, 40%);">+                                    ) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      tr_CBSP(CBSP_MSGT_WRITE_REPLACE, {</span><br><span style="color: hsl(120, 100%, 40%);">+                    tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+                 tr_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      tr_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_EmergencyInd(emerg_ind),</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_WarningType(warn_type),</span><br><span style="color: hsl(120, 100%, 40%);">+                    tr_WarnSecInfo,</span><br><span style="color: hsl(120, 100%, 40%);">+                       tr_WarningPeriod(warn_per) });</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_REPLACE_EMERG(uint16_t msg_id, uint16_t new_ser_nr, uint16_t old_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                                template (value) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                               template (value) uint8_t emerg_ind,</span><br><span style="color: hsl(120, 100%, 40%);">+                                           template (value) uint16_t warn_type,</span><br><span style="color: hsl(120, 100%, 40%);">+                                          template (value) uint16_t num_bcast_req,</span><br><span style="color: hsl(120, 100%, 40%);">+                                              template (value) uint8_t warn_per</span><br><span style="color: hsl(120, 100%, 40%);">+                                         ) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      ts_CBSP(CBSP_MSGT_WRITE_REPLACE, {</span><br><span style="color: hsl(120, 100%, 40%);">+                    ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+                 ts_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      ts_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      ts_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   ts_EmergencyInd(emerg_ind),</span><br><span style="color: hsl(120, 100%, 40%);">+                   ts_WarningType(warn_type),</span><br><span style="color: hsl(120, 100%, 40%);">+                    ts_WarnSecInfo,</span><br><span style="color: hsl(120, 100%, 40%);">+                       ts_WarningPeriod(warn_per) });</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_REPLACE_EMERG(template uint16_t msg_id := ?, template uint16_t new_ser_nr := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                     template uint16_t old_ser_nr := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                    template BSSMAP_FIELD_CellIdentificationList cell_list := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                  template uint8_t emerg_ind := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                      template uint16_t warn_type := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                     template uint16_t num_bcast_req := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template uint8_t warn_per := ?</span><br><span style="color: hsl(120, 100%, 40%);">+                                    ) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      tr_CBSP(CBSP_MSGT_WRITE_REPLACE, {</span><br><span style="color: hsl(120, 100%, 40%);">+                    tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+                 tr_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      tr_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      tr_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_EmergencyInd(emerg_ind),</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_WarningType(warn_type),</span><br><span style="color: hsl(120, 100%, 40%);">+                    tr_WarnSecInfo,</span><br><span style="color: hsl(120, 100%, 40%);">+                       tr_WarningPeriod(warn_per) });</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.2 WRITE-REPLACE COMPLETE */</span><br><span style="color: hsl(120, 100%, 40%);">+function ts_CBSP_WRITE_CBS_COMPL(uint16_t msg_id, uint16_t new_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template (omit) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template (value) uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template (value) CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+    var template (value) CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         ts_NewSerNo(new_ser_nr)</span><br><span style="color: hsl(120, 100%, 40%);">+       };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := ts_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     ies[lengthof(ies)] := ts_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ return ts_CBSP(CBSP_MSGT_WRITE_REPLACE_COMPL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+function tr_CBSP_WRITE_CBS_COMPL(template uint16_t msg_id, template uint16_t new_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                               template BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                               template uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+    var template CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         tr_NewSerNo(new_ser_nr)</span><br><span style="color: hsl(120, 100%, 40%);">+       };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (istemplatekind(cell_list, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := tr_CbspCellList ifpresent;</span><br><span style="color: hsl(120, 100%, 40%);">+      } else if (istemplatekind(cell_list, "?")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := tr_CbspCellList(?);</span><br><span style="color: hsl(120, 100%, 40%);">+     } else if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+         ies[lengthof(ies)] := tr_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     ies[lengthof(ies)] := tr_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ return tr_CBSP(CBSP_MSGT_WRITE_REPLACE_COMPL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+function ts_CBSP_REPLACE_CBS_COMPL(uint16_t msg_id, uint16_t new_ser_nr, uint16_t old_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template (value) CBSP_IE_NumBcastComplList compl_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template (omit) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template (value) uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template (value) CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+  var template (value) CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         ts_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_CbspNumComplList(compl_list)</span><br><span style="color: hsl(120, 100%, 40%);">+       };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := ts_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     ies[lengthof(ies)] := ts_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ return ts_CBSP(CBSP_MSGT_WRITE_REPLACE_COMPL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+function tr_CBSP_REPLACE_CBS_COMPL(template uint16_t msg_id, template uint16_t new_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                               template uint16_t old_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template CBSP_IE_NumBcastComplList compl_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                               template uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+  var template CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         tr_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              tr_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              tr_CbspNumComplList(compl_list)</span><br><span style="color: hsl(120, 100%, 40%);">+       };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (istemplatekind(cell_list, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := tr_CbspCellList ifpresent;</span><br><span style="color: hsl(120, 100%, 40%);">+      } else if (istemplatekind(cell_list, "?")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := tr_CbspCellList(?);</span><br><span style="color: hsl(120, 100%, 40%);">+     } else if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+         ies[lengthof(ies)] := tr_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     ies[lengthof(ies)] := tr_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ return tr_CBSP(CBSP_MSGT_WRITE_REPLACE_COMPL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.3 WRITE-REPLACE FAILURE */</span><br><span style="color: hsl(120, 100%, 40%);">+function ts_CBSP_WRITE_CBS_FAIL(uint16_t msg_id, uint16_t new_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template (value) CBSP_FailureListItems fail_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                             template (omit) CBSP_IE_NumBcastComplList compl_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                         template (omit) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template (value) uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template (value) CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+     var template (value) CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         ts_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_CbspFailList(fail_list)</span><br><span style="color: hsl(120, 100%, 40%);">+    };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (not istemplatekind(compl_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := ts_CbspNumComplList(compl_list);</span><br><span style="color: hsl(120, 100%, 40%);">+        }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := ts_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     ies[lengthof(ies)] := ts_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ return ts_CBSP(CBSP_MSGT_WRITE_REPLACE_FAIL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+function tr_CBSP_WRITE_CBS_FAIL(template uint16_t msg_id, template uint16_t new_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template CBSP_FailureListItems fail_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                             template CBSP_IE_NumBcastComplList compl_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                               template uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+     var template CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         tr_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              tr_CbspFailList(fail_list)</span><br><span style="color: hsl(120, 100%, 40%);">+    };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (istemplatekind(compl_list, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+              ies[lengthof(ies)] := tr_CbspNumComplList ifpresent;</span><br><span style="color: hsl(120, 100%, 40%);">+  } else if (istemplatekind(compl_list, "?")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := tr_CbspNumComplList(?);</span><br><span style="color: hsl(120, 100%, 40%);">+ } else if (not istemplatekind(compl_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := tr_CbspNumComplList(compl_list);</span><br><span style="color: hsl(120, 100%, 40%);">+        }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (istemplatekind(cell_list, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := tr_CbspCellList ifpresent;</span><br><span style="color: hsl(120, 100%, 40%);">+      } else if (istemplatekind(cell_list, "?")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := tr_CbspCellList(?);</span><br><span style="color: hsl(120, 100%, 40%);">+     } else if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+         ies[lengthof(ies)] := tr_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     ies[lengthof(ies)] := ts_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ return tr_CBSP(CBSP_MSGT_WRITE_REPLACE_FAIL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+function ts_CBSP_REPLACE_CBS_FAIL(uint16_t msg_id, uint16_t new_ser_nr, uint16_t old_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                  template (value) CBSP_FailureListItems fail_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                             template (omit) CBSP_IE_NumBcastComplList compl_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template (omit) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template (value) uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template (value) CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+  var template (value) CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         ts_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_CbspFailList(fail_list)</span><br><span style="color: hsl(120, 100%, 40%);">+    };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (not istemplatekind(compl_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := ts_CbspNumComplList(compl_list);</span><br><span style="color: hsl(120, 100%, 40%);">+        }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := ts_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     ies[lengthof(ies)] := ts_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ return ts_CBSP(CBSP_MSGT_WRITE_REPLACE_FAIL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+function tr_CBSP_REPLACE_CBS_FAIL(template uint16_t msg_id, template uint16_t new_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template uint16_t old_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template CBSP_FailureListItems fail_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                             template CBSP_IE_NumBcastComplList compl_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                               template uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+  var template CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         tr_NewSerNo(new_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              tr_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              tr_CbspFailList(fail_list)</span><br><span style="color: hsl(120, 100%, 40%);">+    };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (istemplatekind(compl_list, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+              ies[lengthof(ies)] := tr_CbspCellList ifpresent;</span><br><span style="color: hsl(120, 100%, 40%);">+      } else if (istemplatekind(compl_list, "?")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := tr_CbspNumComplList(?);</span><br><span style="color: hsl(120, 100%, 40%);">+ } else if (not istemplatekind(compl_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := tr_CbspNumComplList(compl_list);</span><br><span style="color: hsl(120, 100%, 40%);">+        }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (istemplatekind(cell_list, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := tr_CbspCellList ifpresent;</span><br><span style="color: hsl(120, 100%, 40%);">+      } else if (istemplatekind(cell_list, "?")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := tr_CbspCellList(?);</span><br><span style="color: hsl(120, 100%, 40%);">+     } else if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+         ies[lengthof(ies)] := tr_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     ies[lengthof(ies)] := tr_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ return tr_CBSP(CBSP_MSGT_WRITE_REPLACE_FAIL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.4 KILL */</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_KILL(template (value) uint16_t msg_id,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template (value) uint16_t old_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                 template (value) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                       template (omit) uint8_t channel_ind) :=</span><br><span style="color: hsl(120, 100%, 40%);">+       ts_CBSP(CBSP_MSGT_KILL, {</span><br><span style="color: hsl(120, 100%, 40%);">+                     ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+                 ts_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      ts_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   ts_CbspChannelInd(channel_ind)});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_KILL(template uint16_t msg_id := ?, template uint16_t old_ser_nr := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                           template BSSMAP_FIELD_CellIdentificationList cell_list := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                          template uint8_t channel_ind := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+ tr_CBSP(CBSP_MSGT_KILL, {</span><br><span style="color: hsl(120, 100%, 40%);">+                     tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+                 tr_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+                      tr_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_CbspChannelInd(channel_ind) });</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.5 KILL COMPLETE */</span><br><span style="color: hsl(120, 100%, 40%);">+function ts_CBSP_KILL_COMPL(template (value) uint16_t msg_id, template (value) uint16_t old_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                            template (omit) CBSP_IE_NumBcastComplList compl_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                         template (omit) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                        template (omit) uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template (value) CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+  var template (value) CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         ts_OldSerNo(old_ser_nr)</span><br><span style="color: hsl(120, 100%, 40%);">+       };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (not istemplatekind(compl_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := ts_CbspNumComplList(compl_list);</span><br><span style="color: hsl(120, 100%, 40%);">+        }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := ts_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (not istemplatekind(channel_ind, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+              ies[lengthof(ies)] := ts_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ }</span><br><span style="color: hsl(120, 100%, 40%);">+     return ts_CBSP(CBSP_MSGT_KILL_COMPL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+function tr_CBSP_KILL_COMPL(template uint16_t msg_id := ?, template uint16_t old_ser_nr := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                      template CBSP_IE_NumBcastComplList compl_list := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                           template BSSMAP_FIELD_CellIdentificationList cell_list := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                          template uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+ var template CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         tr_OldSerNo(old_ser_nr)</span><br><span style="color: hsl(120, 100%, 40%);">+       };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (istemplatekind(compl_list, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+              ies[lengthof(ies)] := *;</span><br><span style="color: hsl(120, 100%, 40%);">+      } else if (not istemplatekind(compl_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := tr_CbspNumComplList(compl_list);</span><br><span style="color: hsl(120, 100%, 40%);">+        }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (istemplatekind(cell_list, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := *;</span><br><span style="color: hsl(120, 100%, 40%);">+      } else if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+         ies[lengthof(ies)] := tr_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (istemplatekind(channel_ind, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+             ies[lengthof(ies)] := *;</span><br><span style="color: hsl(120, 100%, 40%);">+      } else if (not istemplatekind(channel_ind, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := tr_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ }</span><br><span style="color: hsl(120, 100%, 40%);">+     return tr_CBSP(CBSP_MSGT_KILL_COMPL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.6 KILL FAILURE */</span><br><span style="color: hsl(120, 100%, 40%);">+function ts_CBSP_KILL_FAIL(template (value) uint16_t msg_id, template (value) uint16_t old_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+                          template (value) CBSP_FailureListItems fail_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                     template (omit) CBSP_IE_NumBcastComplList compl_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                         template (omit) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                        template (omit) uint8_t channel_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+return template (value) CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+   var template (value) CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                ts_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         ts_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              ts_CbspFailList(fail_list)</span><br><span style="color: hsl(120, 100%, 40%);">+    };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (not istemplatekind(compl_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := ts_CbspNumComplList(compl_list);</span><br><span style="color: hsl(120, 100%, 40%);">+        }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := ts_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (not istemplatekind(channel_ind, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+              ies[lengthof(ies)] := ts_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ }</span><br><span style="color: hsl(120, 100%, 40%);">+     return ts_CBSP(CBSP_MSGT_KILL_FAIL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+function tr_CBSP_KILL_FAIL(template uint16_t msg_id := ?, template uint16_t old_ser_nr := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                       template CBSP_FailureListItems fail_list := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                        template CBSP_IE_NumBcastComplList compl_list := *,</span><br><span style="color: hsl(120, 100%, 40%);">+                           template BSSMAP_FIELD_CellIdentificationList cell_list := *,</span><br><span style="color: hsl(120, 100%, 40%);">+                          template uint8_t channel_ind := *)</span><br><span style="color: hsl(120, 100%, 40%);">+return template CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+     var template CBSP_IEs ies := {</span><br><span style="color: hsl(120, 100%, 40%);">+                tr_CbspMsgId(msg_id),</span><br><span style="color: hsl(120, 100%, 40%);">+         tr_OldSerNo(old_ser_nr),</span><br><span style="color: hsl(120, 100%, 40%);">+              tr_CbspFailList(fail_list)</span><br><span style="color: hsl(120, 100%, 40%);">+    };</span><br><span style="color: hsl(120, 100%, 40%);">+    if (istemplatekind(compl_list, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+              ies[lengthof(ies)] := tr_CbspNumComplList ifpresent;</span><br><span style="color: hsl(120, 100%, 40%);">+  } else if (not istemplatekind(compl_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+                ies[lengthof(ies)] := tr_CbspNumComplList(compl_list);</span><br><span style="color: hsl(120, 100%, 40%);">+        }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (istemplatekind(compl_list, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+              ies[lengthof(ies)] := tr_CbspCellList ifpresent;</span><br><span style="color: hsl(120, 100%, 40%);">+      } else if (not istemplatekind(cell_list, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+         ies[lengthof(ies)] := tr_CbspCellList(cell_list);</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     if (istemplatekind(channel_ind, "*")) {</span><br><span style="color: hsl(120, 100%, 40%);">+             ies[lengthof(ies)] := tr_CbspChannelInd(?) ifpresent;</span><br><span style="color: hsl(120, 100%, 40%);">+ } else if (not istemplatekind(channel_ind, "omit")) {</span><br><span style="color: hsl(120, 100%, 40%);">+               ies[lengthof(ies)] := tr_CbspChannelInd(channel_ind);</span><br><span style="color: hsl(120, 100%, 40%);">+ }</span><br><span style="color: hsl(120, 100%, 40%);">+     return tr_CBSP(CBSP_MSGT_KILL_FAIL, ies);</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.16 RESET */</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_RESET(template (value) BSSMAP_FIELD_CellIdentificationList cell_list) :=</span><br><span style="color: hsl(120, 100%, 40%);">+    ts_CBSP(CBSP_MSGT_RESET, {</span><br><span style="color: hsl(120, 100%, 40%);">+                    ts_CbspCellList(cell_list)</span><br><span style="color: hsl(120, 100%, 40%);">+            });</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_RESET(template BSSMAP_FIELD_CellIdentificationList cell_list := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+  tr_CBSP(CBSP_MSGT_RESET, {</span><br><span style="color: hsl(120, 100%, 40%);">+                    tr_CbspCellList(cell_list)</span><br><span style="color: hsl(120, 100%, 40%);">+            });</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.17 RESET COMPLETE */</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_RESET_COMPL(template (value) BSSMAP_FIELD_CellIdentificationList cell_list) :=</span><br><span style="color: hsl(120, 100%, 40%);">+        ts_CBSP(CBSP_MSGT_RESET_COMPL, {</span><br><span style="color: hsl(120, 100%, 40%);">+                      ts_CbspCellList(cell_list)</span><br><span style="color: hsl(120, 100%, 40%);">+            });</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_RESET_COMPL(template BSSMAP_FIELD_CellIdentificationList cell_list := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+    tr_CBSP(CBSP_MSGT_RESET_COMPL, {</span><br><span style="color: hsl(120, 100%, 40%);">+                      tr_CbspCellList(cell_list)</span><br><span style="color: hsl(120, 100%, 40%);">+            });</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.18 RESET FAILURE */</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_RESET_FAIL(template (value) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                          template (value) CBSP_FailureListItems fail_items) :=</span><br><span style="color: hsl(120, 100%, 40%);">+    ts_CBSP(CBSP_MSGT_RESET_FAIL, {</span><br><span style="color: hsl(120, 100%, 40%);">+                       ts_CbspFailList(fail_items),</span><br><span style="color: hsl(120, 100%, 40%);">+                  ts_CbspCellList(cell_list)</span><br><span style="color: hsl(120, 100%, 40%);">+            });</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_RESET_FAIL(template BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                template CBSP_FailureListItems fail_items) :=</span><br><span style="color: hsl(120, 100%, 40%);">+    tr_CBSP(CBSP_MSGT_RESET_FAIL, {</span><br><span style="color: hsl(120, 100%, 40%);">+                       tr_CbspFailList(fail_items),</span><br><span style="color: hsl(120, 100%, 40%);">+                  tr_CbspCellList(cell_list)</span><br><span style="color: hsl(120, 100%, 40%);">+            });</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.18a KEEP-ALIVE */</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_KEEP_ALIVE(uint8_t rep_period) :=</span><br><span style="color: hsl(120, 100%, 40%);">+        ts_CBSP(CBSP_MSGT_KEEP_ALIVE, {ts_CbspKARepPeriod(rep_period)});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_KEEP_ALIVE(template uint8_t rep_period := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+   tr_CBSP(CBSP_MSGT_KEEP_ALIVE, {tr_CbspKARepPeriod(rep_period)});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.18b KEEP-ALIVE COMPLETE */</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_KEEP_ALIVE_COMPL :=</span><br><span style="color: hsl(120, 100%, 40%);">+        ts_CBSP(CBSP_MSGT_KEEP_ALIVE_COMPL, {});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_KEEP_ALIVE_COMPL :=</span><br><span style="color: hsl(120, 100%, 40%);">+       tr_CBSP(CBSP_MSGT_KEEP_ALIVE_COMPL, {});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.19 RESTART */</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_RESTART(template (value) BSSMAP_FIELD_CellIdentificationList cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                   template (value) CBSP_BcastMsgType msg_type,</span><br><span style="color: hsl(120, 100%, 40%);">+                                          template (value) CBSP_RecoveryInd rec_ind) :=</span><br><span style="color: hsl(120, 100%, 40%);">+       ts_CBSP(CBSP_MSGT_RESTART, {</span><br><span style="color: hsl(120, 100%, 40%);">+                  ts_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   ts_CbspBcastMsgType(msg_type),</span><br><span style="color: hsl(120, 100%, 40%);">+                        ts_CbspRecoveryInd(rec_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+           });</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_RESTART(template BSSMAP_FIELD_CellIdentificationList cell_list := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                             template CBSP_BcastMsgType msg_type := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                             template CBSP_RecoveryInd rec_ind := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+  tr_CBSP(CBSP_MSGT_RESTART, {</span><br><span style="color: hsl(120, 100%, 40%);">+                  tr_CbspCellList(cell_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_CbspBcastMsgType(msg_type),</span><br><span style="color: hsl(120, 100%, 40%);">+                        tr_CbspRecoveryInd(rec_ind)</span><br><span style="color: hsl(120, 100%, 40%);">+           });</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.20 FAILURE */</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_FAILURE(template (value) CBSP_FailureListItems fail_list,</span><br><span style="color: hsl(120, 100%, 40%);">+                                      template (value) CBSP_BcastMsgType msg_type) :=</span><br><span style="color: hsl(120, 100%, 40%);">+     ts_CBSP(CBSP_MSGT_FAILURE, {</span><br><span style="color: hsl(120, 100%, 40%);">+                  ts_CbspFailList(fail_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   ts_CbspBcastMsgType(msg_type)</span><br><span style="color: hsl(120, 100%, 40%);">+         });</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_FAILURE(template CBSP_FailureListItems fail_list := ?,</span><br><span style="color: hsl(120, 100%, 40%);">+                           template CBSP_BcastMsgType msg_type := ?) :=</span><br><span style="color: hsl(120, 100%, 40%);">+        tr_CBSP(CBSP_MSGT_FAILURE, {</span><br><span style="color: hsl(120, 100%, 40%);">+                  tr_CbspFailList(fail_list),</span><br><span style="color: hsl(120, 100%, 40%);">+                   tr_CbspBcastMsgType(msg_type)</span><br><span style="color: hsl(120, 100%, 40%);">+         });</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.1.3.21 ERROR INDICATION */</span><br><span style="color: hsl(120, 100%, 40%);">+template (value) CBSP_PDU ts_CBSP_ERROR_IND(CBSP_Cause cause) :=</span><br><span style="color: hsl(120, 100%, 40%);">+      ts_CBSP(CBSP_MSGT_ERROR_IND, {ts_CbspCause(cause)});</span><br><span style="color: hsl(120, 100%, 40%);">+template CBSP_PDU tr_CBSP_ERROR_IND(template CBSP_Cause cause) :=</span><br><span style="color: hsl(120, 100%, 40%);">+       tr_CBSP(CBSP_MSGT_ERROR_IND, {tr_CbspCause(cause), *});</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+function f_cbsp_find_ie(CBSP_PDU msg, CBSP_IEI iei, out CBSP_IE ret) return boolean {</span><br><span style="color: hsl(120, 100%, 40%);">+    for (var integer i := 0; i < sizeof(msg.ies); i := i+1) {</span><br><span style="color: hsl(120, 100%, 40%);">+          if (msg.ies[i].iei == iei) {</span><br><span style="color: hsl(120, 100%, 40%);">+                  ret := msg.ies[i];</span><br><span style="color: hsl(120, 100%, 40%);">+                    return true;</span><br><span style="color: hsl(120, 100%, 40%);">+          }</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+     return false;</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span>diff --git a/library/CBSP_Types.ttcn b/library/CBSP_Types.ttcn</span><br><span>new file mode 100644</span><br><span>index 0000000..43a7d7d</span><br><span>--- /dev/null</span><br><span>+++ b/library/CBSP_Types.ttcn</span><br><span>@@ -0,0 +1,381 @@</span><br><span style="color: hsl(120, 100%, 40%);">+module CBSP_Types {</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* CBSP_Types, defining abstract TTCN-3 data types for the CBSP protocol.</span><br><span style="color: hsl(120, 100%, 40%);">+ *</span><br><span style="color: hsl(120, 100%, 40%);">+ * CBSP is a ETSI/3GPP standard protocol used between CBC (Cell Broadcast Centre) </span><br><span style="color: hsl(120, 100%, 40%);">+ * and BSC (Base Station Controller) in 2G/GSM/GERAN networks. It is specified</span><br><span style="color: hsl(120, 100%, 40%);">+ * in 3GPP TS 48.049.</span><br><span style="color: hsl(120, 100%, 40%);">+ *</span><br><span style="color: hsl(120, 100%, 40%);">+ * (C) 2019 by Harald Welte <laforge@gnumonks.org></span><br><span style="color: hsl(120, 100%, 40%);">+ * All rights reserved.</span><br><span style="color: hsl(120, 100%, 40%);">+ *</span><br><span style="color: hsl(120, 100%, 40%);">+ * Released under the terms of GNU General Public License, Version 2 or</span><br><span style="color: hsl(120, 100%, 40%);">+ * (at your option) any later version.</span><br><span style="color: hsl(120, 100%, 40%);">+ */</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+import from General_Types all;</span><br><span style="color: hsl(120, 100%, 40%);">+import from Osmocom_Types all;</span><br><span style="color: hsl(120, 100%, 40%);">+import from BSSAP_Types all;</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.2.2 Message Type */</span><br><span style="color: hsl(120, 100%, 40%);">+type enumerated CBSP_MessageType {</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_WRITE_REPLACE                 ('01'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_WRITE_REPLACE_COMPL           ('02'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_WRITE_REPLACE_FAIL            ('03'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_KILL                          ('04'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_KILL_COMPL                    ('05'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_KILL_FAIL                     ('06'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_LOAD_QUERY                    ('07'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_LOAD_QUERY_COMPL              ('08'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_LOAD_QUERY_FAIL               ('09'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_MSG_STATUS_QUERY              ('0a'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_MSG_STATUS_QUERY_COMPL        ('0b'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_MSG_STATUS_QUERY_FAIL         ('0c'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_SET_DRX                       ('0d'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_SET_DRX_COMPL                 ('0e'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_SET_DRX_FAIL                  ('0f'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_RESET                         ('10'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_RESET_COMPL                   ('11'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_RESET_FAIL                    ('12'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_RESTART                       ('13'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_FAILURE                       ('14'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_ERROR_IND                     ('15'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_KEEP_ALIVE                    ('16'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_MSGT_KEEP_ALIVE_COMPL              ('17'O)</span><br><span style="color: hsl(120, 100%, 40%);">+} with { variant "FIELDLENGTH(8)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.2.1 Information Element Identifier */</span><br><span style="color: hsl(120, 100%, 40%);">+type enumerated CBSP_IEI {</span><br><span style="color: hsl(120, 100%, 40%);">+     CBSP_IEI_MSG_CONTENT                    ('01'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_OLD_SERIAL_NR                  ('02'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_NEW_SERIAL_NR                  ('03'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_CELL_LIST                      ('04'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_CATEGORY                       ('05'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_REP_PERIOD                     ('06'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_NUM_BCAST_REQ                  ('07'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_NUM_BCAST_COMPL_LIST           ('08'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_FAILURE_LIST                   ('09'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_RR_LOADING_LIST                ('0a'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_CAUSE                          ('0b'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_DCS                            ('0c'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_RECOVERY_IND                   ('0d'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_MSG_ID                         ('0e'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_EMERG_IND                      ('0f'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_WARN_TYPE                      ('10'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_WARN_SEC_INFO                  ('11'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_CHANNEL_IND                    ('12'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_NUM_OF_PAGES                   ('13'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_SCHEDULE_PERIOD                ('14'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_NUM_OF_RES_SLOTS               ('15'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_BCAST_MSG_TYPE                 ('16'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_WARNING_PERIOD                 ('17'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI_KEEP_ALIVE_REP_PERIOD          ('18'O)</span><br><span style="color: hsl(120, 100%, 40%);">+} with { variant "FIELDLENGTH(8)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.2.7 Category */</span><br><span style="color: hsl(120, 100%, 40%);">+type enumerated CBSP_Category {</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CATEG_HIGH_PRIO                    ('00'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CATEG_BACKGROUND                   ('01'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CATEG_NORMAL                       ('02'O)</span><br><span style="color: hsl(120, 100%, 40%);">+} with { variant "FIELDLENGTH(8)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* Cell ID Discriminator (8.2.11, ...) */</span><br><span style="color: hsl(120, 100%, 40%);">+type enumerated CBSP_CellIdDisc {</span><br><span style="color: hsl(120, 100%, 40%);">+       CBSP_CIDD_WHOLE_CGI             (0),</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_CIDD_LAC_CI                (1),</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_CIDD_CI                    (2),</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_CIDD_LAI                   (4),</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_CIDD_LAC                   (5),</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_CIDD_ALL_IN_BSC            (6)</span><br><span style="color: hsl(120, 100%, 40%);">+} with { variant "FIELDLENGTH(4)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.2.13 Cause */</span><br><span style="color: hsl(120, 100%, 40%);">+type enumerated CBSP_Cause {</span><br><span style="color: hsl(120, 100%, 40%);">+       CBSP_CAUSE_PARAM_NOT_RECOGNISED         ('00'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_PARAM_VAL_INVALID            ('01'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_MSG_REF_NOT_IDENTIFIED       ('02'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_CELL_ID_NOT_VALID            ('03'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_UNRECOGNISED_MSG             ('04'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_MISSING_MAND_IE              ('05'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_BSC_CAPACITY_EXCEEDED        ('06'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_CELL_MEMORY_EXCEEDED         ('07'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_BSC_MEMORY_EXCEEDED          ('08'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_CB_NOT_SUPPORTED             ('09'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_CB_NOT_OPERATIONAL           ('0a'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_INCOMPATIBLE_DRX_PARAM       ('0b'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_EXT_CHAN_NOT_SUPPORTED       ('0c'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_MSG_REF_ALREADY_USED         ('0d'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_UNSPECIFIED_ERROR            ('0e'O),</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_CAUSE_LAI_OR_LAC_NPT_VALID         ('0f'O)</span><br><span style="color: hsl(120, 100%, 40%);">+} with { variant "FIELDLENGTH(8)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_IE_MessageContent {</span><br><span style="color: hsl(120, 100%, 40%);">+       uint8_t         user_len,</span><br><span style="color: hsl(120, 100%, 40%);">+     octetstring     val</span><br><span style="color: hsl(120, 100%, 40%);">+} with { variant (val) "FIELDLENGTH(82)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.2.6 Cell List */</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_IE_CellList {</span><br><span style="color: hsl(120, 100%, 40%);">+   uint16_t        len,</span><br><span style="color: hsl(120, 100%, 40%);">+  BIT4            spare1_4,</span><br><span style="color: hsl(120, 100%, 40%);">+     BIT4            cell_id_discr,</span><br><span style="color: hsl(120, 100%, 40%);">+        BSSMAP_FIELD_CellIdentificationList cell_id</span><br><span style="color: hsl(120, 100%, 40%);">+} with {</span><br><span style="color: hsl(120, 100%, 40%);">+ variant (len) "LENGTHTO(cell_id_discr,spare1_4,cell_id)"</span><br><span style="color: hsl(120, 100%, 40%);">+    variant (cell_id) "CROSSTAG(</span><br><span style="color: hsl(120, 100%, 40%);">+             cIl_CGI,                cell_id_discr = '0000'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cIl_LAC_CI,             cell_id_discr = '0001'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cIl_CI,                 cell_id_discr = '0010'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cIl_LAI,                cell_id_discr = '0100'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cIl_LAC,                cell_id_discr = '0101'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cIl_allInBSS,           cell_id_discr = '0110'B;</span><br><span style="color: hsl(120, 100%, 40%);">+                      )"</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.2.10 Number of Broadcasts Completed List */</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_IE_NumBcastComplList {</span><br><span style="color: hsl(120, 100%, 40%);">+      uint16_t        len,</span><br><span style="color: hsl(120, 100%, 40%);">+  BIT4            spare1_4,</span><br><span style="color: hsl(120, 100%, 40%);">+     BIT4            cell_id_discr,</span><br><span style="color: hsl(120, 100%, 40%);">+        CBSP_FIELD_NumBcastCompl list</span><br><span style="color: hsl(120, 100%, 40%);">+} with {</span><br><span style="color: hsl(120, 100%, 40%);">+       variant (len) "LENGTHTO(cell_id_discr,spare1_4,list)"</span><br><span style="color: hsl(120, 100%, 40%);">+       variant (list) "CROSSTAG(</span><br><span style="color: hsl(120, 100%, 40%);">+                cI_CGI,         cell_id_discr = '0000'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_LAC_CI,      cell_id_discr = '0001'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_CI,          cell_id_discr = '0010'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_LAI,         cell_id_discr = '0100'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_LAC,         cell_id_discr = '0101'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_allInBSS,    cell_id_discr = '0110'B;</span><br><span style="color: hsl(120, 100%, 40%);">+                      )"</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type union CBSP_FIELD_NumBcastCompl {</span><br><span style="color: hsl(120, 100%, 40%);">+    CBSP_FIELD_NumBcastCompl_CGI            cI_CGI,</span><br><span style="color: hsl(120, 100%, 40%);">+       CBSP_FIELD_NumBcastCompl_LAC_CI         cI_LAC_CI,</span><br><span style="color: hsl(120, 100%, 40%);">+    OCT0                                    cI_allInBSS,</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_FIELD_NumBcastCompl_CI             cI_CI,</span><br><span style="color: hsl(120, 100%, 40%);">+        CBSP_FIELD_NumBcastCompl_LAC            cI_LAC,</span><br><span style="color: hsl(120, 100%, 40%);">+       CBSP_FIELD_NumBcastCompl_LAI            cI_LAI</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FIELD_NumBcastCompl_CGI {</span><br><span style="color: hsl(120, 100%, 40%);">+        BSSMAP_FIELD_CellIdentification_CGI     ci,</span><br><span style="color: hsl(120, 100%, 40%);">+   uint16_t                                num_bcats_compl,</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_NumBcastInfo                       num_bcast_info,</span><br><span style="color: hsl(120, 100%, 40%);">+       BIT4                                    spare1_4</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FIELD_NumBcastCompl_LAC_CI {</span><br><span style="color: hsl(120, 100%, 40%);">+   BSSMAP_FIELD_CellIdentification_LAC_CI  ci,</span><br><span style="color: hsl(120, 100%, 40%);">+   uint16_t                                num_bcats_compl,</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_NumBcastInfo                       num_bcast_info,</span><br><span style="color: hsl(120, 100%, 40%);">+       BIT4                                    spare1_4</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FIELD_NumBcastCompl_LAI {</span><br><span style="color: hsl(120, 100%, 40%);">+      BSSMAP_FIELD_CellIdentification_LAI     ci,</span><br><span style="color: hsl(120, 100%, 40%);">+   uint16_t                                num_bcats_compl,</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_NumBcastInfo                       num_bcast_info,</span><br><span style="color: hsl(120, 100%, 40%);">+       BIT4                                    spare1_4</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FIELD_NumBcastCompl_CI {</span><br><span style="color: hsl(120, 100%, 40%);">+       OCT2                                    ci,</span><br><span style="color: hsl(120, 100%, 40%);">+   uint16_t                                num_bcats_compl,</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_NumBcastInfo                       num_bcast_info,</span><br><span style="color: hsl(120, 100%, 40%);">+       BIT4                                    spare1_4</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FIELD_NumBcastCompl_LAC {</span><br><span style="color: hsl(120, 100%, 40%);">+      OCT2                                    lac,</span><br><span style="color: hsl(120, 100%, 40%);">+  uint16_t                                num_bcats_compl,</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_NumBcastInfo                       num_bcast_info,</span><br><span style="color: hsl(120, 100%, 40%);">+       BIT4                                    spare1_4</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type enumerated CBSP_NumBcastInfo {</span><br><span style="color: hsl(120, 100%, 40%);">+     CBSP_NUM_BCAST_INFO_VALID       (0),</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_NUM_BCAST_INFO_OVERFLOW    (1),</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_NUM_BCAST_INFO_UNKNOWN     (2)</span><br><span style="color: hsl(120, 100%, 40%);">+} with { variant "FIELDLENGTH(4)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.2.11 Failure List */</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FailureListItem {</span><br><span style="color: hsl(120, 100%, 40%);">+        BIT4            spare1_4,</span><br><span style="color: hsl(120, 100%, 40%);">+     BIT4            cell_id_discr,</span><br><span style="color: hsl(120, 100%, 40%);">+        CBSP_FIELD_CellIdentification cell_id,</span><br><span style="color: hsl(120, 100%, 40%);">+        CBSP_Cause      cause</span><br><span style="color: hsl(120, 100%, 40%);">+} with {</span><br><span style="color: hsl(120, 100%, 40%);">+       variant (cell_id) "CROSSTAG(</span><br><span style="color: hsl(120, 100%, 40%);">+             cI_CGI,         cell_id_discr = '0000'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_LAC_CI,      cell_id_discr = '0001'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_CI,          cell_id_discr = '0010'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_LAI,         cell_id_discr = '0100'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_LAC,         cell_id_discr = '0101'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_allInBSS,    cell_id_discr = '0110'B;</span><br><span style="color: hsl(120, 100%, 40%);">+                      )"</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type union CBSP_FIELD_CellIdentification</span><br><span style="color: hsl(120, 100%, 40%);">+{</span><br><span style="color: hsl(120, 100%, 40%);">+      BSSMAP_FIELD_CellIdentification_CGI    cI_CGI,</span><br><span style="color: hsl(120, 100%, 40%);">+        BSSMAP_FIELD_CellIdentification_LAC_CI cI_LAC_CI,</span><br><span style="color: hsl(120, 100%, 40%);">+     OCT2                                   cI_CI,</span><br><span style="color: hsl(120, 100%, 40%);">+ BSSMAP_FIELD_CellIdentification_LAI    cI_LAI,</span><br><span style="color: hsl(120, 100%, 40%);">+        OCT2                                   cI_LAC,</span><br><span style="color: hsl(120, 100%, 40%);">+        OCT2                                   cI_allInBSS</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+type record of CBSP_FailureListItem CBSP_FailureListItems;</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_IE_FailureList {</span><br><span style="color: hsl(120, 100%, 40%);">+       uint16_t        len,</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_FailureListItems list</span><br><span style="color: hsl(120, 100%, 40%);">+} with {</span><br><span style="color: hsl(120, 100%, 40%);">+  variant (len) "LENGTHTO(list)"</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.2.12 RR Loading List */</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_IE_RrLoadingList {</span><br><span style="color: hsl(120, 100%, 40%);">+     uint16_t        len,</span><br><span style="color: hsl(120, 100%, 40%);">+  BIT4            spare1_4,</span><br><span style="color: hsl(120, 100%, 40%);">+     BIT4            cell_id_discr,</span><br><span style="color: hsl(120, 100%, 40%);">+        CBSP_FIELD_RrLoadingList list</span><br><span style="color: hsl(120, 100%, 40%);">+} with {</span><br><span style="color: hsl(120, 100%, 40%);">+       variant (len) "LENGTHTO(cell_id_discr,spare1_4,list)"</span><br><span style="color: hsl(120, 100%, 40%);">+       variant (list) "CROSSTAG(</span><br><span style="color: hsl(120, 100%, 40%);">+                cI_CGI,         cell_id_discr = '0000'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_LAC_CI,      cell_id_discr = '0001'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_CI,          cell_id_discr = '0010'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_LAI,         cell_id_discr = '0100'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_LAC,         cell_id_discr = '0101'B;</span><br><span style="color: hsl(120, 100%, 40%);">+              cI_allInBSS,    cell_id_discr = '0110'B;</span><br><span style="color: hsl(120, 100%, 40%);">+                      )"</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type union CBSP_FIELD_RrLoadingList {</span><br><span style="color: hsl(120, 100%, 40%);">+    CBSP_FIELD_RrLoadingList_CGI            cI_CGI,</span><br><span style="color: hsl(120, 100%, 40%);">+       CBSP_FIELD_RrLoadingList_LAC_CI         cI_LAC_CI,</span><br><span style="color: hsl(120, 100%, 40%);">+    OCT0                                    cI_allInBSS,</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_FIELD_RrLoadingList_CI             cI_CI,</span><br><span style="color: hsl(120, 100%, 40%);">+        CBSP_FIELD_RrLoadingList_LAC            cI_LAC,</span><br><span style="color: hsl(120, 100%, 40%);">+       CBSP_FIELD_RrLoadingList_LAI            cI_LAI</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FIELD_RrLoadingList_CGI {</span><br><span style="color: hsl(120, 100%, 40%);">+        BSSMAP_FIELD_CellIdentification_CGI     ci,</span><br><span style="color: hsl(120, 100%, 40%);">+   uint8_t                                 load1,</span><br><span style="color: hsl(120, 100%, 40%);">+        uint8_t                                 load2</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FIELD_RrLoadingList_LAC_CI {</span><br><span style="color: hsl(120, 100%, 40%);">+      BSSMAP_FIELD_CellIdentification_LAC_CI  ci,</span><br><span style="color: hsl(120, 100%, 40%);">+   uint8_t                                 load1,</span><br><span style="color: hsl(120, 100%, 40%);">+        uint8_t                                 load2</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FIELD_RrLoadingList_LAI {</span><br><span style="color: hsl(120, 100%, 40%);">+ BSSMAP_FIELD_CellIdentification_LAI     ci,</span><br><span style="color: hsl(120, 100%, 40%);">+   uint8_t                                 load1,</span><br><span style="color: hsl(120, 100%, 40%);">+        uint8_t                                 load2</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FIELD_RrLoadingList_CI {</span><br><span style="color: hsl(120, 100%, 40%);">+  OCT2                                    ci,</span><br><span style="color: hsl(120, 100%, 40%);">+   uint8_t                                 load1,</span><br><span style="color: hsl(120, 100%, 40%);">+        uint8_t                                 load2</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_FIELD_RrLoadingList_LAC {</span><br><span style="color: hsl(120, 100%, 40%);">+ OCT2                                    lac,</span><br><span style="color: hsl(120, 100%, 40%);">+  uint8_t                                 load1,</span><br><span style="color: hsl(120, 100%, 40%);">+        uint8_t                                 load2</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.2.15 Recovery Indication */</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_IE_RecoveryInd {</span><br><span style="color: hsl(120, 100%, 40%);">+      BIT4                    spare1_4,</span><br><span style="color: hsl(120, 100%, 40%);">+     CBSP_RecoveryInd        recovery</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type enumerated CBSP_RecoveryInd {</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_RI_DATA_AVAILABLE  (0),</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_RI_DATA_LOST       (1)</span><br><span style="color: hsl(120, 100%, 40%);">+} with { variant "FIELDLENGTH(4)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+/* 8.2.24 Broadcast Message Type */</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_IE_BcastMsgType {</span><br><span style="color: hsl(120, 100%, 40%);">+        BIT4                    spare1_4,</span><br><span style="color: hsl(120, 100%, 40%);">+     CBSP_BcastMsgType       msg_type</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+type enumerated CBSP_BcastMsgType {</span><br><span style="color: hsl(120, 100%, 40%);">+     CBSP_BC_MSGT_CBS        (0),</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_BC_MSGT_EMERG      (1)</span><br><span style="color: hsl(120, 100%, 40%);">+} with { variant "FIELDLENGTH(4)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+type union CBSP_IE_Body {</span><br><span style="color: hsl(120, 100%, 40%);">+    CBSP_IE_MessageContent  msg_content,</span><br><span style="color: hsl(120, 100%, 40%);">+  uint16_t                old_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+   uint16_t                new_ser_nr,</span><br><span style="color: hsl(120, 100%, 40%);">+   CBSP_IE_CellList        cell_list,</span><br><span style="color: hsl(120, 100%, 40%);">+    CBSP_Category           category,</span><br><span style="color: hsl(120, 100%, 40%);">+     uint16_t                rep_period,</span><br><span style="color: hsl(120, 100%, 40%);">+   uint16_t                num_bcast_req,</span><br><span style="color: hsl(120, 100%, 40%);">+        CBSP_IE_NumBcastComplList num_bcast_compl_list,</span><br><span style="color: hsl(120, 100%, 40%);">+       CBSP_IE_FailureList     failure_list,</span><br><span style="color: hsl(120, 100%, 40%);">+ CBSP_IE_RrLoadingList   rr_loading_list,</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_Cause              cause,</span><br><span style="color: hsl(120, 100%, 40%);">+        uint8_t                 dcs,</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_IE_RecoveryInd     recovery_ind,</span><br><span style="color: hsl(120, 100%, 40%);">+ uint16_t                msg_id,</span><br><span style="color: hsl(120, 100%, 40%);">+       uint8_t                 emerg_ind,</span><br><span style="color: hsl(120, 100%, 40%);">+    uint16_t                warn_type,</span><br><span style="color: hsl(120, 100%, 40%);">+    octetstring             warn_sec_info,</span><br><span style="color: hsl(120, 100%, 40%);">+        uint8_t                 channel_ind,</span><br><span style="color: hsl(120, 100%, 40%);">+  uint8_t                 num_of_pages,</span><br><span style="color: hsl(120, 100%, 40%);">+ uint8_t                 schedule_period,</span><br><span style="color: hsl(120, 100%, 40%);">+      uint8_t                 num_of_res_slots,</span><br><span style="color: hsl(120, 100%, 40%);">+     CBSP_IE_BcastMsgType    bcast_msg_type,</span><br><span style="color: hsl(120, 100%, 40%);">+       uint8_t                 warning_period,</span><br><span style="color: hsl(120, 100%, 40%);">+       uint8_t                 keep_alive_rep_period</span><br><span style="color: hsl(120, 100%, 40%);">+} with {</span><br><span style="color: hsl(120, 100%, 40%);">+       variant (warn_sec_info) "FIELDLENGTH(50)"</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_IE {</span><br><span style="color: hsl(120, 100%, 40%);">+      CBSP_IEI                iei,</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_IE_Body            body</span><br><span style="color: hsl(120, 100%, 40%);">+} with {</span><br><span style="color: hsl(120, 100%, 40%);">+        variant (body)  "CROSSTAG( msg_content, iei = CBSP_IEI_MSG_CONTENT;</span><br><span style="color: hsl(120, 100%, 40%);">+                                      old_ser_nr, iei = CBSP_IEI_OLD_SERIAL_NR;</span><br><span style="color: hsl(120, 100%, 40%);">+                                     new_ser_nr, iei = CBSP_IEI_NEW_SERIAL_NR;</span><br><span style="color: hsl(120, 100%, 40%);">+                                     cell_list, iei = CBSP_IEI_CELL_LIST;</span><br><span style="color: hsl(120, 100%, 40%);">+                                  category, iei = CBSP_IEI_CATEGORY;</span><br><span style="color: hsl(120, 100%, 40%);">+                                    rep_period, iei = CBSP_IEI_REP_PERIOD;</span><br><span style="color: hsl(120, 100%, 40%);">+                                        num_bcast_req, iei = CBSP_IEI_NUM_BCAST_REQ;</span><br><span style="color: hsl(120, 100%, 40%);">+                                  num_bcast_compl_list, iei = CBSP_IEI_NUM_BCAST_COMPL_LIST;</span><br><span style="color: hsl(120, 100%, 40%);">+                                    failure_list, iei = CBSP_IEI_FAILURE_LIST;</span><br><span style="color: hsl(120, 100%, 40%);">+                                    rr_loading_list, iei = CBSP_IEI_RR_LOADING_LIST;</span><br><span style="color: hsl(120, 100%, 40%);">+                                      cause, iei = CBSP_IEI_CAUSE;</span><br><span style="color: hsl(120, 100%, 40%);">+                                  dcs, iei = CBSP_IEI_DCS;</span><br><span style="color: hsl(120, 100%, 40%);">+                                      recovery_ind, iei = CBSP_IEI_RECOVERY_IND;</span><br><span style="color: hsl(120, 100%, 40%);">+                                    msg_id, iei = CBSP_IEI_MSG_ID;</span><br><span style="color: hsl(120, 100%, 40%);">+                                        emerg_ind, iei = CBSP_IEI_EMERG_IND;</span><br><span style="color: hsl(120, 100%, 40%);">+                                  warn_type, iei = CBSP_IEI_WARN_TYPE;</span><br><span style="color: hsl(120, 100%, 40%);">+                                  warn_sec_info, iei = CBSP_IEI_WARN_SEC_INFO;</span><br><span style="color: hsl(120, 100%, 40%);">+                                  channel_ind, iei = CBSP_IEI_CHANNEL_IND;</span><br><span style="color: hsl(120, 100%, 40%);">+                                      num_of_pages, iei = CBSP_IEI_NUM_OF_PAGES;</span><br><span style="color: hsl(120, 100%, 40%);">+                                    schedule_period, iei = CBSP_IEI_SCHEDULE_PERIOD;</span><br><span style="color: hsl(120, 100%, 40%);">+                                      num_of_res_slots, iei = CBSP_IEI_NUM_OF_RES_SLOTS;</span><br><span style="color: hsl(120, 100%, 40%);">+                                    bcast_msg_type, iei = CBSP_IEI_BCAST_MSG_TYPE;</span><br><span style="color: hsl(120, 100%, 40%);">+                                        warning_period, iei = CBSP_IEI_WARNING_PERIOD;</span><br><span style="color: hsl(120, 100%, 40%);">+                                        keep_alive_rep_period, iei = CBSP_IEI_KEEP_ALIVE_REP_PERIOD</span><br><span style="color: hsl(120, 100%, 40%);">+           )"</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+type set of CBSP_IE CBSP_IEs;</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+type record CBSP_PDU {</span><br><span style="color: hsl(120, 100%, 40%);">+        CBSP_MessageType        msg_type,</span><br><span style="color: hsl(120, 100%, 40%);">+     uint24_t                len,</span><br><span style="color: hsl(120, 100%, 40%);">+  CBSP_IEs                ies</span><br><span style="color: hsl(120, 100%, 40%);">+} with {</span><br><span style="color: hsl(120, 100%, 40%);">+ variant (len) "LENGTHTO(ies)"</span><br><span style="color: hsl(120, 100%, 40%);">+};</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+external function enc_CBSP_PDU(in CBSP_PDU msg) return octetstring</span><br><span style="color: hsl(120, 100%, 40%);">+     with { extension "prototype(convert) encode(RAW)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+external function dec_CBSP_PDU(in octetstring msg) return CBSP_PDU</span><br><span style="color: hsl(120, 100%, 40%);">+  with { extension "prototype(convert) decode(RAW)" };</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+} with { encode "RAW"; variant "FIELDORDER(msb)" }</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/15374">change 15374</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/15374"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmo-ttcn3-hacks </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: Ida2e0af7d282fd7d5318110c05efa5a10114242c </div>
<div style="display:none"> Gerrit-Change-Number: 15374 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: laforge <laforge@gnumonks.org> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins Builder </div>
<div style="display:none"> Gerrit-Reviewer: laforge <laforge@gnumonks.org> </div>
<div style="display:none"> Gerrit-Reviewer: pespin <pespin@sysmocom.de> </div>
<div style="display:none"> Gerrit-MessageType: merged </div>