####################################
## SCFD file version: 0.10         ##
## PDDB version: TLF16_1509_003   ##
####################################

#General checking for rule file execution
check_version minor TL16A
check_version minor TLF16A
check_version minor TLC16A

#v0.8 change for TLF16_1509_003 PDDB:
#check_param minor LNBTS actRadioPosFlexibility
check_param minor MRBTS validatePlanAgainstDetectedHW
#v0.8 change for TLF16_1509_003 PDDB END

###########
# COMMON: #
###########

################################################################################################
# CRL9710 Preparation of LTE2805 in FDD/TD-LTE16 in OAM interface for Macro eNB
################################################################################################
# Macro specific
#add_param minor BTSSCL actRxMonitoring true

################################################################################################
# CRL9682 The feature flag to enable LTE2026 (DL SRB Robustness) needs to be renamed to indicate that it also enables LTE2392 (UL SRB Robustness)
################################################################################################
#Parameter actDlSrb1Robustness replaced by actSrb1Robustness

rename_param minor LNCEL actDlSrb1Robustness actSrb1Robustness

################################################################################################
# PR076971 A typo in parameter name ActRadioPosFlexibility 
################################################################################################
# delete
del_param minor LNBTS actRadioPosFlexibilty

# add with false
add_param minor LNBTS actRadioPosFlexibility false

################################################################################################
# CRL9441 RF Based VoLTE DRX Deactivation 
################################################################################################
# add with false

add_param minor LNCEL actQci1RfDrx false


# v0.2 change for TL16_1509_003 PDDB
##########
#LTE2060-B-k Addition or replacement of radios without site outage
#	late change: new modification type

#v0.4 correction for PR087233
################################################################################################
# LBT3245 CRL9088 Introduce consistency check in BTSSM to reduce possible amount of PLMN-IDs per eNB
################################################################################################
# 1. Create temporary parameters to calculate items
add_param minor LNBTS AmountOfFurtherPlmnIdLItemsPereNB 0
#add_param minor LNCEL tempAmountOfFurtherPlmnIdLItems 0
add_list minor LNBTS tempFurtherPlmnIdL

#1.1 Create temporary list based on furtherPlmnIdL
copy_list_param minor LNCEL LNCEL furtherPlmnIdL tempFurtherPlmnIdL

#1.2 Add item indicator to the tempFurtherPlmnIdL
add_list_param minor LNCEL tempFurtherPlmnIdL 0 tempItemCount 1
add_list_param minor LNCEL tempFurtherPlmnIdL 1 tempItemCount 1
add_list_param minor LNCEL tempFurtherPlmnIdL 2 tempItemCount 1
add_list_param minor LNCEL tempFurtherPlmnIdL 3 tempItemCount 1
add_list_param minor LNCEL tempFurtherPlmnIdL 4 tempItemCount 1

#1.3 Move LNCEL tempFurtherPlmnIdL listy items to the LNBTS tempFurtherPlmnIdL 
dependence_move_list_item_relative minor MRBTS/LNBTS/LNCEL tempFurtherPlmnIdL tempItemCount 1 MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL

#1.4 Modify LNCEL furtherPlmnIdL tempItemCount value to the "0" if duplicate found and delete those
dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL * tempItemCount = LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mcc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 0 mcc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mnc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 0 mnc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mncLength == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 0 mncLength ? CONST 0 : 
dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL 0 tempItemCount = CONST 0 == CONST 0 ? CONST 1 : 
dependence_del_target_relative minor LISTITEM MRBTS/LNBTS tempFurtherPlmnIdL * ? LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} tempItemCount == CONST 0 

dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL * tempItemCount = LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mcc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 1 mcc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mnc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 1 mnc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mncLength == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 1 mncLength ? CONST 0 :
dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL 1 tempItemCount = CONST 0 == CONST 0 ? CONST 1 : 
dependence_del_target_relative minor LISTITEM MRBTS/LNBTS tempFurtherPlmnIdL * ? LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} tempItemCount == CONST 0 

dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL * tempItemCount = LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mcc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 2 mcc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mnc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 2 mnc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mncLength == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 2 mncLength ? CONST 0 :
dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL 2 tempItemCount = CONST 0 == CONST 0 ? CONST 1 : 
dependence_del_target_relative minor LISTITEM MRBTS/LNBTS tempFurtherPlmnIdL * ? LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} tempItemCount == CONST 0 

dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL * tempItemCount = LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mcc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 3 mcc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mnc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 3 mnc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mncLength == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 3 mncLength ? CONST 0 :
dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL 3 tempItemCount = CONST 0 == CONST 0 ? CONST 1 : 
dependence_del_target_relative minor LISTITEM MRBTS/LNBTS tempFurtherPlmnIdL * ? LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} tempItemCount == CONST 0 

dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL * tempItemCount = LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mcc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 4 mcc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mnc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 4 mnc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mncLength == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 4 mncLength ? CONST 0 :
dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL 4 tempItemCount = CONST 0 == CONST 0 ? CONST 1 : 
dependence_del_target_relative minor LISTITEM MRBTS/LNBTS tempFurtherPlmnIdL * ? LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} tempItemCount == CONST 0 

dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL * tempItemCount = LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mcc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 5 mcc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mnc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 5 mnc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mncLength == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 5 mncLength ? CONST 0 :
dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL 5 tempItemCount = CONST 0 == CONST 0 ? CONST 1 : 
dependence_del_target_relative minor LISTITEM MRBTS/LNBTS tempFurtherPlmnIdL * ? LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} tempItemCount == CONST 0 

dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL * tempItemCount = LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mcc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 6 mcc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mnc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 6 mnc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mncLength == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 6 mncLength ? CONST 0 :
dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL 6 tempItemCount = CONST 0 == CONST 0 ? CONST 1 : 
dependence_del_target_relative minor LISTITEM MRBTS/LNBTS tempFurtherPlmnIdL * ? LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} tempItemCount == CONST 0 

dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL * tempItemCount = LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mcc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 7 mcc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mnc == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 7 mnc && LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} mncLength == LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 7 mncLength ? CONST 0 :
dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS tempFurtherPlmnIdL 7 tempItemCount = CONST 0 == CONST 0 ? CONST 1 : 
dependence_del_target_relative minor LISTITEM MRBTS/LNBTS tempFurtherPlmnIdL * ? LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL ${tempFurtherPlmnIdL} tempItemCount == CONST 0 

# 2. Calculate item amount
# 2.1 Calculate item amount in LNCEL level
#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL tempAmountOfFurtherPlmnIdLItems = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} tempAmountOfFurtherPlmnIdLItems + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} furtherPlmnIdL 0 tempItemCount :
#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL tempAmountOfFurtherPlmnIdLItems = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} tempAmountOfFurtherPlmnIdLItems + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} furtherPlmnIdL 1 tempItemCount :
#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL tempAmountOfFurtherPlmnIdLItems = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} tempAmountOfFurtherPlmnIdLItems + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} furtherPlmnIdL 2 tempItemCount :
#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL tempAmountOfFurtherPlmnIdLItems = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} tempAmountOfFurtherPlmnIdLItems + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} furtherPlmnIdL 3 tempItemCount :
#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL tempAmountOfFurtherPlmnIdLItems = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} tempAmountOfFurtherPlmnIdLItems + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} furtherPlmnIdL 4 tempItemCount :

# 2.2 move temporary LNCEL parameter to list
#add_list minor LNCEL tempItemList
#add_list_item minor LNCEL tempItemList
#add_list_param minor LNCEL tempItemList 0 itemAmounth 0
#dependence_mod_param_conditional_expression_relative minor LISTPARAM MRBTS/LNBTS/LNCEL tempItemList 0 itemAmounth = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} tempAmountOfFurtherPlmnIdLItems :
#add_list_param minor LNCEL tempItemList 0 itemTag 0

# 2.3 Calculate item amount in LNBTS level
#add_list minor LNBTS enbItemList
#dependence_move_list_item_relative minor MRBTS/LNBTS/LNCEL tempItemList itemTag 0 MRBTS-${MRBTS}/LNBTS-${LNBTS} enbItemList

dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 0 tempItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 1 tempItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 2 tempItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 3 tempItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 4 tempItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 5 tempItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 6 tempItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 7 tempItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 8 tempItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 9 tempItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB + LISTPARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} tempFurtherPlmnIdL 10 tempItemCount :

# 3. Delete temporary parameters
dependence_del_target_relative major PARAM MRBTS/LNBTS AmountOfFurtherPlmnIdLItemsPereNB ? PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS} AmountOfFurtherPlmnIdLItemsPereNB <= CONST 7
del_param minor LNBTS AmountOfFurtherPlmnIdLItemsPereNB
#del_param minor LNCEL tempAmountOfFurtherPlmnIdLItems
#del_list_param minor LNCEL furtherPlmnIdL tempItemCount  
#del_list minor LNCEL tempItemList
#del_list minor LNBTS enbItemList  
del_list minor LNCEL tempFurtherPlmnIdL
del_list minor LNBTS tempFurtherPlmnIdL

#v0.4 correction for PR087233 END

################################################################################################
# LBT2692-A CRL6722 Parameter to enforce strict plan validation against HW in eNB
################################################################################################
#MRBTS validatePlanAgainstDetectedHW needs to be added with value "false"

add_param minor MRBTS validatePlanAgainstDetectedHW false


# FZM specific
################################################################################################
# LTE2569 Flexi Zone Controller Legacy FDD/TD-LTE 15A and FDD/TD-LTE 16 Feature Support
################################################################################################
del_param minor LNCEL filterCenterTx

# FZC specific
################################################################################################
# PR084223 - Misc PDDB cleanup for LTE2569-F &amp; K
################################################################################################
#SECADM actServicePortState - parameter is not shown at the GUI, set to 'false'
#SECADM sshClientAliveTimer - parameter is not shown at the GUI, set to 60
#SECADM sshSessionLoginDelayTimer - parameter is not shown at the GUI, set to 1
dependence_mod_param_if_key_parameter_value_matches minor UNIT unitTypeExpected FZC1100 SECADM actServicePortState false
dependence_mod_param_if_key_parameter_value_matches minor UNIT unitTypeExpected FZC1100 SECADM sshClientAliveTimer 60
dependence_mod_param_if_key_parameter_value_matches minor UNIT unitTypeExpected FZC1100 SECADM sshSessionLoginDelayTimer 1

# v0.2 change for TL16_1509_003 PDDB END



# FZM specific
################################################################################################
# PR080527: Parameter syncMaster and ownedByThisBts should be set to 'true' in FZM PDDB
################################################################################################

mod_param minor SMOD syncMaster false true
mod_param minor SMOD ownedByThisBts false true


#parameter SMOD-totalDelayFromSHM removed from FZM PDDB as macro specific
del_param minor SMOD totalDelayFromSHM


# FZC specific
################################################################################################
# LTE2201-A-f
################################################################################################
#BTSSCL-actLocationLock hidden at the GUI and set to 'false'
dependence_mod_param_if_key_parameter_value_matches minor UNIT unitTypeExpected FZC1100 BTSSCL actLocationLock false


# v0.5 PR088367: [TLF16] RNW incorrect / CellP Crash 
# FZM specific
# in TLF16_1509_003 PDDB coreModuleSyncInputList-syncInputType removed values: "1pps/ToD from Sync Hub Master", "1pps/ToD from external GNSS receiver"
# change for "internal GNSS receiver"

# 1. delete items where syncInputType == "1pps/ToD from Sync Hub Master" or "1pps/ToD from external GNSS receiver"
dependence_del_target_relative minor LISTITEM MRBTS/SMOD coreModuleSyncInputList * ? LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList ${coreModuleSyncInputList} syncInputType == CONST "1pps/ToD from Sync Hub Master"
dependence_del_target_relative minor LISTITEM MRBTS/SMOD coreModuleSyncInputList * ? LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList ${coreModuleSyncInputList} syncInputType == CONST "1pps/ToD from external GNSS receiver"

# 2. add param for counting items in coreModuleSyncInputList
add_param minor SMOD tempItemCount 0
# 3. add item indicator to the coreModuleSyncInputList
add_list_param minor SMOD coreModuleSyncInputList * tempNotEmptyItemCount 1
# 4. count items in coreModuleSyncInputList
dependence_mod_param_conditional_expression_relative minor PARAM SMOD tempItemCount = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/SMOD-${SMOD} tempItemCount + LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 0 tempNotEmptyItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM SMOD tempItemCount = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/SMOD-${SMOD} tempItemCount + LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 1 tempNotEmptyItemCount :
dependence_mod_param_conditional_expression_relative minor PARAM SMOD tempItemCount = CONST 0 == CONST 0 ? PARAM MRBTS-${MRBTS}/SMOD-${SMOD} tempItemCount + LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 2 tempNotEmptyItemCount :

# 5. if tempItemCount == 0 (empty coreModuleSyncInputList) add item where syncInputType == "internal GNSS receiver"
add_param minor SMOD tempEmptyList notEmpty
dependence_mod_param_if_key_parameter_value_matches minor SMOD tempItemCount 0 SMOD tempEmptyList empty

dependence_add_list_item_if_key_parameter_does_not_match minor SMOD tempEmptyList notEmpty SMOD coreModuleSyncInputList
add_list_param minor SMOD coreModuleSyncInputList * syncInputType "internal GNSS receiver"
# v0.9 syncInputPrio updated
#add_list_param minor SMOD coreModuleSyncInputList * syncInputPrio 0
add_list_param minor SMOD coreModuleSyncInputList * syncInputPrio 1
# v0.9 end

# 6. del temp params
del_list_param minor SMOD coreModuleSyncInputList tempNotEmptyItemCount  
del_param minor SMOD tempItemCount
del_param minor SMOD tempEmptyList

# v0.5 end

#v0.6 PR086208: [FL16] GNSSE and GNSSI objects created after FL15A to FL16 upgrad
# Macro migration made in SCFDFB1507v00.txt
#1.3.3 Remove GNSSE or/and GNSSI when no related sync input configured
#1.3.3.1 Remove GNSSE if "1pps/ToD from external GNSS receiver  is NOT configured on coreModuleSyncInputList
dependence_del_target_relative minor MOC MRBTS/SMOD/GNSSE ? LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 0 syncInputType != CONST "1pps/ToD from external GNSS receiver"
#1.3.3.2 Remove GNSSI if "internal GNSS receiver  is NOT configured on coreModuleSyncInputList

#v0.10 PR127649: Object GNSSI disappears from AP configuration after SW upgrade 
#dependence_del_target_relative minor MOC MRBTS/SMOD/GNSSI ? LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 0 syncInputType != CONST "internal GNSS receiver"
#GNSSI should be deleted if none of entries of coreModuleSyncInputList contains "internal GNSS receiver"
add_param minor SMOD tempCheckGNSSIreceiver noGNSSIreceiver
dependence_mod_param_conditional_expression_relative minor PARAM SMOD tempCheckGNSSIreceiver = LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 0 syncInputType == CONST "internal GNSS receiver" ? CONST "presentGNSSIreceiver" :
dependence_mod_param_conditional_expression_relative minor PARAM SMOD tempCheckGNSSIreceiver = LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 1 syncInputType == CONST "internal GNSS receiver" ? CONST "presentGNSSIreceiver" :
dependence_mod_param_conditional_expression_relative minor PARAM SMOD tempCheckGNSSIreceiver = LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 2 syncInputType == CONST "internal GNSS receiver" ? CONST "presentGNSSIreceiver" :
dependence_del_target_relative minor MOC MRBTS/SMOD/GNSSI ? PARAM MRBTS-${MRBTS}/SMOD-${SMOD} tempCheckGNSSIreceiver == CONST "noGNSSIreceiver"
del_param minor SMOD tempCheckGNSSIreceiver
#v0.10 end

#v0.6 end

###########
# TDD:    #
###########

# FZM specific
################################################################################################
# PR077919: [TL16 FZM]BTS keeps integrated and report 6253 fault
################################################################################################
#If the number of list items in LCELL-resourceList is not equal to 8 then LNCEL-dlSectorBeamformingMode must not be configured.
#LCELL-resourceList maxOccurs=4
del_param minor LNCEL dlSectorBeamformingMode


# v0.2 change for TL16_1509_003 PDDB

# FZM specific
################################################################################################
# PR084835 [FZM RL16] PDDB misalignment for sFreqPrio and maxNumScellSwaps
################################################################################################
add_param minor CADPR maxNumScellSwaps 0
add_param minor CADPR sFreqPrio 1

# FZC specific
################################################################################################
# PR084223 - Misc PDDB cleanup for LTE2569-F &amp; K
################################################################################################
# dlMimoMode enumeration updated: removed "4-way TXDiv", "Closed Loop MIMO (4x2)", "Closed Loop MIMO (4x4)"
# add temp param
add_param minor LNCEL tempDlMimoMode noNeedToChange
# if dlMimoMode has one of forbidden values tempDlMimoMode is set to "needToChange"
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL tempDlMimoMode = PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} dlMimoMode == CONST "4-way TXDiv" || PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} dlMimoMode == CONST "Closed Loop MIMO (4x2)" || PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} dlMimoMode == CONST "Closed Loop MIMO (4x4)" ? CONST "needToChange" :
# if in FZC and dlMimoMode has one of forbidden values (tempDlMimoMode is set to "needToChange") - set dlMimoMode to "TXDiv"
dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL dlMimoMode = PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/FTM-${FTM}/UNIT-${UNIT} unitTypeExpected == CONST "FZC1100" && PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} tempDlMimoMode == CONST "needToChange" ? CONST "TXDiv" :
# del temp param
del_param minor LNCEL tempDlMimoMode


#v0.7
#FZM/FZC specific
################################################################################################
# LTE2614 Radio Interface Based Synchronization for TDD Flexi Zone BTS
################################################################################################
# If the eNodeB is configured to utilize the Radio Interface Based Synchroization (RIBS) synchronization reference source through the SMOD-syncInputType parameter, this parameter is mandatory.
# If the APMOD is configured to utilize the Radio Interface Based Synchroization (RIBS) synchronization reference source through the APMOD-syncInputType parameter, this parameter is mandatory.
# For APMOD's supporting two (2) LTE carriers, the APMOD-ribsEarfcn will be used to select which carrier / channel will be used to receive source eNodeB transmissions. The APMOD-ribsEarfcn setting must be the same as one of the two LNCEL-earfcn settings.
# For eNodeB's supporting two (2) LTE carriers, the LNCEL-ribsEarfcn will be used to select which carrier / channel will be used to receive source eNodeB transmissions. The LNCEL-ribsEarfcn setting must be the same as one of the two LNCEL-earfcn settings.</para>

# check if radio interface based sync is used in syncInputType
add_param minor SMOD tempRibs absent
add_param minor APMOD tempRibs absent

dependence_mod_param_conditional_expression_relative minor PARAM SMOD tempRibs = LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 0 syncInputType == CONST "radio interface based sync" ? CONST "present" :
dependence_mod_param_conditional_expression_relative minor PARAM SMOD tempRibs = LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 1 syncInputType == CONST "radio interface based sync" ? CONST "present" :
dependence_mod_param_conditional_expression_relative minor PARAM SMOD tempRibs = LISTPARAM MRBTS-${MRBTS}/SMOD-${SMOD} coreModuleSyncInputList 2 syncInputType == CONST "radio interface based sync" ? CONST "present" :

dependence_mod_param_conditional_expression_relative minor PARAM APMOD tempRibs = LISTPARAM MRBTS-${MRBTS}/APMOD-${APMOD} coreModuleSyncInputList 0 syncInputType == CONST "radio interface based sync" ? CONST "present" :
dependence_mod_param_conditional_expression_relative minor PARAM APMOD tempRibs = LISTPARAM MRBTS-${MRBTS}/APMOD-${APMOD} coreModuleSyncInputList 1 syncInputType == CONST "radio interface based sync" ? CONST "present" :
dependence_mod_param_conditional_expression_relative minor PARAM APMOD tempRibs = LISTPARAM MRBTS-${MRBTS}/APMOD-${APMOD} coreModuleSyncInputList 2 syncInputType == CONST "radio interface based sync" ? CONST "present" :

# add ribsSrcCellId if radio interface based sync is used
dependence_add_param minor APMOD tempRibs present ribsEarfcn 0
dependence_add_param minor SMOD tempRibs present ribsEarfcn 0

# del temp params
del_param minor SMOD tempRibs
del_param minor APMOD tempRibs

#v0.7 end

# v0.2 change for TL16_1509_003 PDDB END


#v0.3 correction for PR083540: [TL16 FSIH][LTE2326] Error report on parameter actFastMimoSwitch and dlSectorBeamformingMode when do re-commissioning after eNB upgrade from TL15A to TL16
#commented out totally because there will be done technical note for customer instead of this incomplete migration

################################################################################################
# Leftover from LTE1987 Downlink Adaptive Close Loop SU MIMO (4x4) - TM9 - PDDB changed done with PR062744:[LTE1987] actFastMimoSwitch and dlMimoMode - bidirectional consistency check handling to be assured to the xL16_1508_001
################################################################################################
#OM_LTE_SFS_RNL.14687
#If in TL15A configuration database actFastMimoSwitch is set to 'false' following rule need to be done during migration to TL16 dependent on the value of dlMimoMode:
#- if dlMimoMode is set to 'Closed Loop Mimo': actFastMimoSwitch shall be change from value 'false' to 'true'
#- if dlMimoMode is NOT set to 'Closed Loop Mimo', no change to the actFastMimoSwitch is required.

#NSNIDD: Macro
#If dlMimoMode is set to ('Closed Loop Mimo' OR 'Closed Loop MIMO (4x2)' OR 'Closed Loop MIMO (4x4)' OR 'Closed Loop MIMO (8x2)' OR 'Closed Loop MIMO (8x4)') , actFastMimoSwitch must be configured to 'true'.
#If actFastMimoSwitch is set to 'true' following conditions need to be fulfilled:
#- riPerOffset must be configured to '-1'
#- riPerM must be set to '1'.

#NSNIDD: FZM
#If dlMimoMode is set to ('Closed Loop MIMO (4x2)' OR 'Closed Loop MIMO (4x4)' OR 'Closed Loop MIMO (8x2)'), actFastMimoSwitch must be configured to 'true'.
#If actFastMimoSwitch is set to 'true' following conditions need to be fulfilled:
#- riPerOffset must be configured to '-1'
#- riPerM must be set to '1'.

##Macro#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL actFastMimoSwitch = PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} actFastMimoSwitch == CONST "false" && PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} dlMimoMode == CONST "Closed Loop Mimo" ? CONST "GoingTrue" :
#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL actFastMimoSwitch = PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} actFastMimoSwitch == CONST "false" && PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} dlMimoMode == CONST "Closed Loop MIMO (4x2)" ? CONST "GoingTrue" :
#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL actFastMimoSwitch = PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} actFastMimoSwitch == CONST "false" && PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} dlMimoMode == CONST "Closed Loop MIMO (4x4)" ? CONST "GoingTrue" :
#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL actFastMimoSwitch = PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} actFastMimoSwitch == CONST "false" && PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} dlMimoMode == CONST "Closed Loop MIMO (8x2)" ? CONST "GoingTrue" :
##Macro#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL actFastMimoSwitch = PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} actFastMimoSwitch == CONST "false" && PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} dlMimoMode == CONST "Closed Loop MIMO (8x4)" ? CONST "GoingTrue" :

#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL riPerOffset = PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} actFastMimoSwitch == CONST "GoingTrue" && PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} riPerOffset != CONST "-1" ? CONST "-1" :
#dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL riPerM = PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} actFastMimoSwitch == CONST "GoingTrue" && PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} riPerM != CONST 1 ? CONST 1 :
##dependence_mod_param_conditional_expression_relative minor PARAM MRBTS/LNBTS/LNCEL actFastMimoSwitch = PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/LNCEL-${LNCEL} actFastMimoSwitch == CONST "GoingTrue" ? CONST "true"
#mod_param minor LNCEL actFastMimoSwitch GoingTrue true

#v0.3 correction for PR083540: [TL16 FSIH][LTE2326] Error report on parameter actFastMimoSwitch and dlSectorBeamformingMode when do re-commissioning after eNB upgrade from TL15A to TL16 END


#version
#FZM Replace# set_version major TL16
dependence_set_version major PARAM MRBTS-${MRBTS}/LNBTS-${LNBTS}/FTM-${FTM}/UNIT-${UNIT} unitTypeExpected == CONST "FZC1100" ? CONST "TLC16" : CONST "TLF16"

#history:
#FZM Replace# add_log minor "Conversion from TL16 FB15.09 (001) to TL16 FB15.09 (003)"
add_log minor "Conversion from TLF16 FB15.09 (001) to TLF16 FB15.09 (003)"