summaryrefslogtreecommitdiff
path: root/KME-specific-types.erl
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2015-10-23 10:18:38 +0200
committerDimitri Sokolyuk <demon@dim13.org>2015-10-23 10:18:38 +0200
commit31cd25a7dd51f9cb8676370fadf630cf4c81c93b (patch)
treeb9a8fa7b25ababaccab2a6ce5e7cc777e9cb7f02 /KME-specific-types.erl
Initial import
Diffstat (limited to 'KME-specific-types.erl')
-rw-r--r--KME-specific-types.erl10502
1 files changed, 10502 insertions, 0 deletions
diff --git a/KME-specific-types.erl b/KME-specific-types.erl
new file mode 100644
index 0000000..d23ccf6
--- /dev/null
+++ b/KME-specific-types.erl
@@ -0,0 +1,10502 @@
+%% Generated by the Erlang ASN.1 BER-compiler version:1.7
+%% Purpose: encoder and decoder to the types in mod KME-specific-types
+
+-module('KME-specific-types').
+-include("KME-specific-types.hrl").
+-define('RT_BER',asn1rt_ber_bin).
+-asn1_info([{vsn,'1.7'},
+ {module,'KME-specific-types'},
+ {options,[{i,[47,104,111,109,101,47,113,117,97,120,47,101,114,108,47,97,115,110]},warnings,ber,errors,{cwd,[47,104,111,109,101,47,113,117,97,120,47,101,114,108,47,97,115,110]},{outdir,[47,104,111,109,101,47,113,117,97,120,47,101,114,108,47,97,115,110]},{i,[47,104,111,109,101,47,113,117,97,120,47,101,114,108,47,97,115,110,47,99,115,116,97]},{i,[46]},{i,[47,104,111,109,101,47,113,117,97,120,47,101,114,108,47,97,115,110,47,107,109,101]}]}]).
+
+-export([encoding_rule/0]).
+-export([
+'enc_KmeDeviceLock'/2,
+'enc_KmeTimeStamp'/2,
+'enc_KmeSpeedDialRequest'/2,
+'enc_KmeSpeedDial'/2,
+'enc_KmeWakeUpTime'/2,
+'enc_KmeWakeUpSchedule'/2,
+'enc_KmeWakeUpInfo'/2,
+'enc_KmeWakeupState'/2,
+'enc_KmeAbsentMessage'/2,
+'enc_KmeDnMode'/2,
+'enc_KmeDayNightMode'/2,
+'enc_KmeOgmPlayState'/2,
+'enc_KmeForwardType'/2,
+'enc_KmeSetForwardInfo'/2,
+'enc_KmeFeatureList'/2,
+'enc_KmeExtGroupEntry'/2,
+'enc_KmeTrkGroupEntry'/2,
+'enc_KmeExtMembers'/2,
+'enc_KmeTrkMembers'/2,
+'enc_KmeExtTrkGroupList'/2,
+'enc_KmeGroupMembers'/2,
+'enc_KmePckPagGroupList'/2,
+'enc_KmeIcmGrpMembers'/2,
+'enc_KmeIncomingGroupList'/2,
+'enc_KmeDoorPhone'/2,
+'enc_KmeVmGroup'/2,
+'enc_KmeVmDtmfType'/2,
+'enc_KmeVmGroupList'/2,
+'enc_KmePsGroupList'/2,
+'enc_KmeChangeExtNo'/2,
+'enc_KmeChangeName'/2,
+'enc_KmeDeviceCategory'/2,
+'enc_KmeRequestedDevice'/2,
+'enc_KmeChangedDeviceCategory'/2,
+'enc_KmeDeviceStateList'/2,
+'enc_KmeDeviceStateEntry'/2,
+'enc_KmeDeviceState'/2,
+'enc_KmeGroupType'/2,
+'enc_KmePhoneProperty'/2,
+'enc_KmeDeviceExtNo'/2,
+'enc_KmeDeviceName'/2,
+'enc_KmeFcoKeyInfo'/2,
+'enc_KmeFcoKeyList'/2,
+'enc_KmeExternalSensorList'/2,
+'enc_KmeTenantSpeedDial'/2,
+'enc_KmeDistributionMethod'/2,
+'enc_KmePDFStart'/2,
+'enc_KmePDFStop'/2,
+'enc_KmePDFStatus'/2,
+'enc_KmePDFSrvEvt'/2,
+'enc_KmeSvmList'/2,
+'enc_KmeExtName'/2,
+'enc_NumberOfMsgPort'/2,
+'enc_KmeDndOverride'/2,
+'enc_KmeInteruptCall'/2,
+'enc_KmeExternalFeatureAccess'/2,
+'enc_KmeTempTollChange'/2,
+'enc_KmeDoorOpen'/2,
+'enc_KmeTwoWayRec'/2,
+'enc_KmeCallBackInvokeReq'/2,
+'enc_KmeCallBackInvokeRsp'/2,
+'enc_CallBackNotification'/2,
+'enc_KmeCallBackInvoke'/2,
+'enc_KmePcRec'/2,
+'enc_KmeDeviceAgentStatus'/2,
+'enc_KmeDeviceCallStatus'/2,
+'enc_KmeDeviceServiceStatus'/2,
+'enc_KmeLineStatus'/2,
+'enc_KmeLineStatusSegment'/2,
+'enc_KmeStartDeviceMonitor'/2,
+'enc_KmeStopDeviceMonitor'/2,
+'enc_CallMonitorEvent'/2,
+'enc_KmeBroadcastGroupList'/2,
+'enc_KmeBroadcastGrpMembers'/2,
+'enc_KmeAlterIfSrvEvt'/2,
+'enc_KmeAlterIf'/2,
+'enc_KmeIfAltered'/2,
+'enc_IfVersion'/2,
+'enc_KmeDeviceDataList'/2,
+'enc_KmePdnGMembers'/2,
+'enc_KmeHotelSrvEvt'/2,
+'enc_KmeCheckStatusList'/2,
+'enc_KmeRoomStatus'/2,
+'enc_KmeCleanUpStatus'/2,
+'enc_KmeGetSystemDataReq'/2,
+'enc_KmeGetSystemDataRsp'/2,
+'enc_KmeGetSystemData'/2,
+'enc_KmeSetSystemData'/2,
+'enc_KmeSystemDataChanged'/2,
+'enc_KmeSystemDataLinkedReply'/2,
+'enc_KmeGetSystemDataPosAck'/2,
+'enc_KmeSystemCrossRefID'/2,
+'enc_KmeLockSystemData'/2,
+'enc_KmeSystemDataStatus'/2,
+'enc_KmeSystemDataRevision'/2,
+'enc_KmeGetSystemDataRevision'/2,
+'enc_KmeRevisionType'/2,
+'enc_ProgrammingEventOn'/2,
+'enc_KmeSetProgrammingEventOn'/2,
+'enc_KmeLocalAlerm'/2,
+'enc_KmeTrunkId'/2,
+'enc_KmeOtherDevice'/2,
+'enc_KmeCdrConditionCode'/2,
+'enc_KmeFeatureNumber'/2,
+'enc_KmeProprietaryChars'/2,
+'enc_KmeHoldType'/2,
+'enc_KmeForcedAlerting'/2,
+'enc_KmeDigitsReport'/2,
+'enc_KmeOgmStatus'/2,
+'enc_KmeWakeupResult'/2,
+'enc_KmeUnconferenced'/2,
+'enc_KmeTamEnded'/2,
+'enc_KmePcRecEnded'/2,
+'enc_KmeSwitchChannel'/2,
+'enc_KmeFreeOgmPort'/2,
+'enc_KmeCallControlSrvEvt'/2,
+'enc_KmeDeviceStatus'/2,
+'enc_KmeDeviceMonitor'/2,
+'enc_KmeSystemData'/2,
+'enc_KmeAdditionalData'/2,
+'enc_KmePrivateEvent'/2,
+'enc_KmeResourceControl'/2,
+'enc_KmeOgmStart'/2,
+'enc_KmeOgmStop'/2,
+'enc_KmeGenericSrvEvt'/2,
+'enc_KmeGenericServiceReq'/2,
+'enc_KmeGenericServiceRsp'/2,
+'enc_KmeGenericEvent'/2,
+'enc_KMESpecificPrivateData'/2
+]).
+
+-export([
+'dec_KmeDeviceLock'/2,
+'dec_KmeTimeStamp'/2,
+'dec_KmeSpeedDialRequest'/2,
+'dec_KmeSpeedDial'/2,
+'dec_KmeWakeUpTime'/2,
+'dec_KmeWakeUpSchedule'/2,
+'dec_KmeWakeUpInfo'/2,
+'dec_KmeWakeupState'/2,
+'dec_KmeAbsentMessage'/2,
+'dec_KmeDnMode'/2,
+'dec_KmeDayNightMode'/2,
+'dec_KmeOgmPlayState'/2,
+'dec_KmeForwardType'/2,
+'dec_KmeSetForwardInfo'/2,
+'dec_KmeFeatureList'/2,
+'dec_KmeExtGroupEntry'/2,
+'dec_KmeTrkGroupEntry'/2,
+'dec_KmeExtMembers'/2,
+'dec_KmeTrkMembers'/2,
+'dec_KmeExtTrkGroupList'/2,
+'dec_KmeGroupMembers'/2,
+'dec_KmePckPagGroupList'/2,
+'dec_KmeIcmGrpMembers'/2,
+'dec_KmeIncomingGroupList'/2,
+'dec_KmeDoorPhone'/2,
+'dec_KmeVmGroup'/2,
+'dec_KmeVmDtmfType'/2,
+'dec_KmeVmGroupList'/2,
+'dec_KmePsGroupList'/2,
+'dec_KmeChangeExtNo'/2,
+'dec_KmeChangeName'/2,
+'dec_KmeDeviceCategory'/2,
+'dec_KmeRequestedDevice'/2,
+'dec_KmeChangedDeviceCategory'/2,
+'dec_KmeDeviceStateList'/2,
+'dec_KmeDeviceStateEntry'/2,
+'dec_KmeDeviceState'/2,
+'dec_KmeGroupType'/2,
+'dec_KmePhoneProperty'/2,
+'dec_KmeDeviceExtNo'/2,
+'dec_KmeDeviceName'/2,
+'dec_KmeFcoKeyInfo'/2,
+'dec_KmeFcoKeyList'/2,
+'dec_KmeExternalSensorList'/2,
+'dec_KmeTenantSpeedDial'/2,
+'dec_KmeDistributionMethod'/2,
+'dec_KmePDFStart'/2,
+'dec_KmePDFStop'/2,
+'dec_KmePDFStatus'/2,
+'dec_KmePDFSrvEvt'/2,
+'dec_KmeSvmList'/2,
+'dec_KmeExtName'/2,
+'dec_NumberOfMsgPort'/2,
+'dec_KmeDndOverride'/2,
+'dec_KmeInteruptCall'/2,
+'dec_KmeExternalFeatureAccess'/2,
+'dec_KmeTempTollChange'/2,
+'dec_KmeDoorOpen'/2,
+'dec_KmeTwoWayRec'/2,
+'dec_KmeCallBackInvokeReq'/2,
+'dec_KmeCallBackInvokeRsp'/2,
+'dec_CallBackNotification'/2,
+'dec_KmeCallBackInvoke'/2,
+'dec_KmePcRec'/2,
+'dec_KmeDeviceAgentStatus'/2,
+'dec_KmeDeviceCallStatus'/2,
+'dec_KmeDeviceServiceStatus'/2,
+'dec_KmeLineStatus'/2,
+'dec_KmeLineStatusSegment'/2,
+'dec_KmeStartDeviceMonitor'/2,
+'dec_KmeStopDeviceMonitor'/2,
+'dec_CallMonitorEvent'/2,
+'dec_KmeBroadcastGroupList'/2,
+'dec_KmeBroadcastGrpMembers'/2,
+'dec_KmeAlterIfSrvEvt'/2,
+'dec_KmeAlterIf'/2,
+'dec_KmeIfAltered'/2,
+'dec_IfVersion'/2,
+'dec_KmeDeviceDataList'/2,
+'dec_KmePdnGMembers'/2,
+'dec_KmeHotelSrvEvt'/2,
+'dec_KmeCheckStatusList'/2,
+'dec_KmeRoomStatus'/2,
+'dec_KmeCleanUpStatus'/2,
+'dec_KmeGetSystemDataReq'/2,
+'dec_KmeGetSystemDataRsp'/2,
+'dec_KmeGetSystemData'/2,
+'dec_KmeSetSystemData'/2,
+'dec_KmeSystemDataChanged'/2,
+'dec_KmeSystemDataLinkedReply'/2,
+'dec_KmeGetSystemDataPosAck'/2,
+'dec_KmeSystemCrossRefID'/2,
+'dec_KmeLockSystemData'/2,
+'dec_KmeSystemDataStatus'/2,
+'dec_KmeSystemDataRevision'/2,
+'dec_KmeGetSystemDataRevision'/2,
+'dec_KmeRevisionType'/2,
+'dec_ProgrammingEventOn'/2,
+'dec_KmeSetProgrammingEventOn'/2,
+'dec_KmeLocalAlerm'/2,
+'dec_KmeTrunkId'/2,
+'dec_KmeOtherDevice'/2,
+'dec_KmeCdrConditionCode'/2,
+'dec_KmeFeatureNumber'/2,
+'dec_KmeProprietaryChars'/2,
+'dec_KmeHoldType'/2,
+'dec_KmeForcedAlerting'/2,
+'dec_KmeDigitsReport'/2,
+'dec_KmeOgmStatus'/2,
+'dec_KmeWakeupResult'/2,
+'dec_KmeUnconferenced'/2,
+'dec_KmeTamEnded'/2,
+'dec_KmePcRecEnded'/2,
+'dec_KmeSwitchChannel'/2,
+'dec_KmeFreeOgmPort'/2,
+'dec_KmeCallControlSrvEvt'/2,
+'dec_KmeDeviceStatus'/2,
+'dec_KmeDeviceMonitor'/2,
+'dec_KmeSystemData'/2,
+'dec_KmeAdditionalData'/2,
+'dec_KmePrivateEvent'/2,
+'dec_KmeResourceControl'/2,
+'dec_KmeOgmStart'/2,
+'dec_KmeOgmStop'/2,
+'dec_KmeGenericSrvEvt'/2,
+'dec_KmeGenericServiceReq'/2,
+'dec_KmeGenericServiceRsp'/2,
+'dec_KmeGenericEvent'/2,
+'dec_KMESpecificPrivateData'/2
+]).
+
+-export([
+'dec_KmeDeviceLock'/3,
+'dec_KmeTimeStamp'/3,
+'dec_KmeSpeedDialRequest'/3,
+'dec_KmeSpeedDial'/3,
+'dec_KmeWakeUpTime'/3,
+'dec_KmeWakeUpSchedule'/3,
+'dec_KmeWakeUpInfo'/3,
+'dec_KmeWakeupState'/3,
+'dec_KmeAbsentMessage'/3,
+'dec_KmeDnMode'/3,
+'dec_KmeDayNightMode'/3,
+'dec_KmeOgmPlayState'/3,
+'dec_KmeForwardType'/3,
+'dec_KmeSetForwardInfo'/3,
+'dec_KmeFeatureList'/3,
+'dec_KmeExtGroupEntry'/3,
+'dec_KmeTrkGroupEntry'/3,
+'dec_KmeExtMembers'/3,
+'dec_KmeTrkMembers'/3,
+'dec_KmeExtTrkGroupList'/3,
+'dec_KmeGroupMembers'/3,
+'dec_KmePckPagGroupList'/3,
+'dec_KmeIcmGrpMembers'/3,
+'dec_KmeIncomingGroupList'/3,
+'dec_KmeDoorPhone'/3,
+'dec_KmeVmGroup'/3,
+'dec_KmeVmDtmfType'/3,
+'dec_KmeVmGroupList'/3,
+'dec_KmePsGroupList'/3,
+'dec_KmeChangeExtNo'/3,
+'dec_KmeChangeName'/3,
+'dec_KmeDeviceCategory'/3,
+'dec_KmeRequestedDevice'/3,
+'dec_KmeChangedDeviceCategory'/3,
+'dec_KmeDeviceStateList'/3,
+'dec_KmeDeviceStateEntry'/3,
+'dec_KmeDeviceState'/3,
+'dec_KmeGroupType'/3,
+'dec_KmePhoneProperty'/3,
+'dec_KmeDeviceExtNo'/3,
+'dec_KmeDeviceName'/3,
+'dec_KmeFcoKeyInfo'/3,
+'dec_KmeFcoKeyList'/3,
+'dec_KmeExternalSensorList'/3,
+'dec_KmeTenantSpeedDial'/3,
+'dec_KmeDistributionMethod'/3,
+'dec_KmePDFStart'/3,
+'dec_KmePDFStop'/3,
+'dec_KmePDFStatus'/3,
+'dec_KmePDFSrvEvt'/3,
+'dec_KmeSvmList'/3,
+'dec_KmeExtName'/3,
+'dec_NumberOfMsgPort'/3,
+'dec_KmeDndOverride'/3,
+'dec_KmeInteruptCall'/3,
+'dec_KmeExternalFeatureAccess'/3,
+'dec_KmeTempTollChange'/3,
+'dec_KmeDoorOpen'/3,
+'dec_KmeTwoWayRec'/3,
+'dec_KmeCallBackInvokeReq'/3,
+'dec_KmeCallBackInvokeRsp'/3,
+'dec_CallBackNotification'/3,
+'dec_KmeCallBackInvoke'/3,
+'dec_KmePcRec'/3,
+'dec_KmeDeviceAgentStatus'/3,
+'dec_KmeDeviceCallStatus'/3,
+'dec_KmeDeviceServiceStatus'/3,
+'dec_KmeLineStatus'/3,
+'dec_KmeLineStatusSegment'/3,
+'dec_KmeStartDeviceMonitor'/3,
+'dec_KmeStopDeviceMonitor'/3,
+'dec_CallMonitorEvent'/3,
+'dec_KmeBroadcastGroupList'/3,
+'dec_KmeBroadcastGrpMembers'/3,
+'dec_KmeAlterIfSrvEvt'/3,
+'dec_KmeAlterIf'/3,
+'dec_KmeIfAltered'/3,
+'dec_IfVersion'/3,
+'dec_KmeDeviceDataList'/3,
+'dec_KmePdnGMembers'/3,
+'dec_KmeHotelSrvEvt'/3,
+'dec_KmeCheckStatusList'/3,
+'dec_KmeRoomStatus'/3,
+'dec_KmeCleanUpStatus'/3,
+'dec_KmeGetSystemDataReq'/3,
+'dec_KmeGetSystemDataRsp'/3,
+'dec_KmeGetSystemData'/3,
+'dec_KmeSetSystemData'/3,
+'dec_KmeSystemDataChanged'/3,
+'dec_KmeSystemDataLinkedReply'/3,
+'dec_KmeGetSystemDataPosAck'/3,
+'dec_KmeSystemCrossRefID'/3,
+'dec_KmeLockSystemData'/3,
+'dec_KmeSystemDataStatus'/3,
+'dec_KmeSystemDataRevision'/3,
+'dec_KmeGetSystemDataRevision'/3,
+'dec_KmeRevisionType'/3,
+'dec_ProgrammingEventOn'/3,
+'dec_KmeSetProgrammingEventOn'/3,
+'dec_KmeLocalAlerm'/3,
+'dec_KmeTrunkId'/3,
+'dec_KmeOtherDevice'/3,
+'dec_KmeCdrConditionCode'/3,
+'dec_KmeFeatureNumber'/3,
+'dec_KmeProprietaryChars'/3,
+'dec_KmeHoldType'/3,
+'dec_KmeForcedAlerting'/3,
+'dec_KmeDigitsReport'/3,
+'dec_KmeOgmStatus'/3,
+'dec_KmeWakeupResult'/3,
+'dec_KmeUnconferenced'/3,
+'dec_KmeTamEnded'/3,
+'dec_KmePcRecEnded'/3,
+'dec_KmeSwitchChannel'/3,
+'dec_KmeFreeOgmPort'/3,
+'dec_KmeCallControlSrvEvt'/3,
+'dec_KmeDeviceStatus'/3,
+'dec_KmeDeviceMonitor'/3,
+'dec_KmeSystemData'/3,
+'dec_KmeAdditionalData'/3,
+'dec_KmePrivateEvent'/3,
+'dec_KmeResourceControl'/3,
+'dec_KmeOgmStart'/3,
+'dec_KmeOgmStop'/3,
+'dec_KmeGenericSrvEvt'/3,
+'dec_KmeGenericServiceReq'/3,
+'dec_KmeGenericServiceRsp'/3,
+'dec_KmeGenericEvent'/3,
+'dec_KMESpecificPrivateData'/3
+]).
+
+-export([info/0]).
+
+
+-export([encode/2,decode/2,encode_disp/2,decode_disp/2]).
+
+encoding_rule() ->
+ ber.
+
+encode(Type,Data) ->
+case catch encode_disp(Type,Data) of
+ {'EXIT',{error,Reason}} ->
+ {error,Reason};
+ {'EXIT',Reason} ->
+ {error,{asn1,Reason}};
+ {Bytes,_Len} ->
+ {ok,wrap_encode(Bytes)};
+ Bytes ->
+ {ok,wrap_encode(Bytes)}
+end.
+
+decode(Type,Data) ->
+case catch decode_disp(Type,wrap_decode(Data)) of
+ {'EXIT',{error,Reason}} ->
+ {error,Reason};
+ {'EXIT',Reason} ->
+ {error,{asn1,Reason}};
+ {X,_Rest} ->
+ {ok,X};
+ {X,_Rest,_Len} ->
+ {ok,X}
+end.
+
+encode_disp('KmeDeviceLock',Data) -> 'enc_KmeDeviceLock'(Data,[]);
+encode_disp('KmeTimeStamp',Data) -> 'enc_KmeTimeStamp'(Data,[]);
+encode_disp('KmeSpeedDialRequest',Data) -> 'enc_KmeSpeedDialRequest'(Data,[]);
+encode_disp('KmeSpeedDial',Data) -> 'enc_KmeSpeedDial'(Data,[]);
+encode_disp('KmeWakeUpTime',Data) -> 'enc_KmeWakeUpTime'(Data,[]);
+encode_disp('KmeWakeUpSchedule',Data) -> 'enc_KmeWakeUpSchedule'(Data,[]);
+encode_disp('KmeWakeUpInfo',Data) -> 'enc_KmeWakeUpInfo'(Data,[]);
+encode_disp('KmeWakeupState',Data) -> 'enc_KmeWakeupState'(Data,[]);
+encode_disp('KmeAbsentMessage',Data) -> 'enc_KmeAbsentMessage'(Data,[]);
+encode_disp('KmeDnMode',Data) -> 'enc_KmeDnMode'(Data,[]);
+encode_disp('KmeDayNightMode',Data) -> 'enc_KmeDayNightMode'(Data,[]);
+encode_disp('KmeOgmPlayState',Data) -> 'enc_KmeOgmPlayState'(Data,[]);
+encode_disp('KmeForwardType',Data) -> 'enc_KmeForwardType'(Data,[]);
+encode_disp('KmeSetForwardInfo',Data) -> 'enc_KmeSetForwardInfo'(Data,[]);
+encode_disp('KmeFeatureList',Data) -> 'enc_KmeFeatureList'(Data,[]);
+encode_disp('KmeExtGroupEntry',Data) -> 'enc_KmeExtGroupEntry'(Data,[]);
+encode_disp('KmeTrkGroupEntry',Data) -> 'enc_KmeTrkGroupEntry'(Data,[]);
+encode_disp('KmeExtMembers',Data) -> 'enc_KmeExtMembers'(Data,[]);
+encode_disp('KmeTrkMembers',Data) -> 'enc_KmeTrkMembers'(Data,[]);
+encode_disp('KmeExtTrkGroupList',Data) -> 'enc_KmeExtTrkGroupList'(Data,[]);
+encode_disp('KmeGroupMembers',Data) -> 'enc_KmeGroupMembers'(Data,[]);
+encode_disp('KmePckPagGroupList',Data) -> 'enc_KmePckPagGroupList'(Data,[]);
+encode_disp('KmeIcmGrpMembers',Data) -> 'enc_KmeIcmGrpMembers'(Data,[]);
+encode_disp('KmeIncomingGroupList',Data) -> 'enc_KmeIncomingGroupList'(Data,[]);
+encode_disp('KmeDoorPhone',Data) -> 'enc_KmeDoorPhone'(Data,[]);
+encode_disp('KmeVmGroup',Data) -> 'enc_KmeVmGroup'(Data,[]);
+encode_disp('KmeVmDtmfType',Data) -> 'enc_KmeVmDtmfType'(Data,[]);
+encode_disp('KmeVmGroupList',Data) -> 'enc_KmeVmGroupList'(Data,[]);
+encode_disp('KmePsGroupList',Data) -> 'enc_KmePsGroupList'(Data,[]);
+encode_disp('KmeChangeExtNo',Data) -> 'enc_KmeChangeExtNo'(Data,[]);
+encode_disp('KmeChangeName',Data) -> 'enc_KmeChangeName'(Data,[]);
+encode_disp('KmeDeviceCategory',Data) -> 'enc_KmeDeviceCategory'(Data,[]);
+encode_disp('KmeRequestedDevice',Data) -> 'enc_KmeRequestedDevice'(Data,[]);
+encode_disp('KmeChangedDeviceCategory',Data) -> 'enc_KmeChangedDeviceCategory'(Data,[]);
+encode_disp('KmeDeviceStateList',Data) -> 'enc_KmeDeviceStateList'(Data,[]);
+encode_disp('KmeDeviceStateEntry',Data) -> 'enc_KmeDeviceStateEntry'(Data,[]);
+encode_disp('KmeDeviceState',Data) -> 'enc_KmeDeviceState'(Data,[]);
+encode_disp('KmeGroupType',Data) -> 'enc_KmeGroupType'(Data,[]);
+encode_disp('KmePhoneProperty',Data) -> 'enc_KmePhoneProperty'(Data,[]);
+encode_disp('KmeDeviceExtNo',Data) -> 'enc_KmeDeviceExtNo'(Data,[]);
+encode_disp('KmeDeviceName',Data) -> 'enc_KmeDeviceName'(Data,[]);
+encode_disp('KmeFcoKeyInfo',Data) -> 'enc_KmeFcoKeyInfo'(Data,[]);
+encode_disp('KmeFcoKeyList',Data) -> 'enc_KmeFcoKeyList'(Data,[]);
+encode_disp('KmeExternalSensorList',Data) -> 'enc_KmeExternalSensorList'(Data,[]);
+encode_disp('KmeTenantSpeedDial',Data) -> 'enc_KmeTenantSpeedDial'(Data,[]);
+encode_disp('KmeDistributionMethod',Data) -> 'enc_KmeDistributionMethod'(Data,[]);
+encode_disp('KmePDFStart',Data) -> 'enc_KmePDFStart'(Data,[]);
+encode_disp('KmePDFStop',Data) -> 'enc_KmePDFStop'(Data,[]);
+encode_disp('KmePDFStatus',Data) -> 'enc_KmePDFStatus'(Data,[]);
+encode_disp('KmePDFSrvEvt',Data) -> 'enc_KmePDFSrvEvt'(Data,[]);
+encode_disp('KmeSvmList',Data) -> 'enc_KmeSvmList'(Data,[]);
+encode_disp('KmeExtName',Data) -> 'enc_KmeExtName'(Data,[]);
+encode_disp('NumberOfMsgPort',Data) -> 'enc_NumberOfMsgPort'(Data,[]);
+encode_disp('KmeDndOverride',Data) -> 'enc_KmeDndOverride'(Data,[]);
+encode_disp('KmeInteruptCall',Data) -> 'enc_KmeInteruptCall'(Data,[]);
+encode_disp('KmeExternalFeatureAccess',Data) -> 'enc_KmeExternalFeatureAccess'(Data,[]);
+encode_disp('KmeTempTollChange',Data) -> 'enc_KmeTempTollChange'(Data,[]);
+encode_disp('KmeDoorOpen',Data) -> 'enc_KmeDoorOpen'(Data,[]);
+encode_disp('KmeTwoWayRec',Data) -> 'enc_KmeTwoWayRec'(Data,[]);
+encode_disp('KmeCallBackInvokeReq',Data) -> 'enc_KmeCallBackInvokeReq'(Data,[]);
+encode_disp('KmeCallBackInvokeRsp',Data) -> 'enc_KmeCallBackInvokeRsp'(Data,[]);
+encode_disp('CallBackNotification',Data) -> 'enc_CallBackNotification'(Data,[]);
+encode_disp('KmeCallBackInvoke',Data) -> 'enc_KmeCallBackInvoke'(Data,[]);
+encode_disp('KmePcRec',Data) -> 'enc_KmePcRec'(Data,[]);
+encode_disp('KmeDeviceAgentStatus',Data) -> 'enc_KmeDeviceAgentStatus'(Data,[]);
+encode_disp('KmeDeviceCallStatus',Data) -> 'enc_KmeDeviceCallStatus'(Data,[]);
+encode_disp('KmeDeviceServiceStatus',Data) -> 'enc_KmeDeviceServiceStatus'(Data,[]);
+encode_disp('KmeLineStatus',Data) -> 'enc_KmeLineStatus'(Data,[]);
+encode_disp('KmeLineStatusSegment',Data) -> 'enc_KmeLineStatusSegment'(Data,[]);
+encode_disp('KmeStartDeviceMonitor',Data) -> 'enc_KmeStartDeviceMonitor'(Data,[]);
+encode_disp('KmeStopDeviceMonitor',Data) -> 'enc_KmeStopDeviceMonitor'(Data,[]);
+encode_disp('CallMonitorEvent',Data) -> 'enc_CallMonitorEvent'(Data,[]);
+encode_disp('KmeBroadcastGroupList',Data) -> 'enc_KmeBroadcastGroupList'(Data,[]);
+encode_disp('KmeBroadcastGrpMembers',Data) -> 'enc_KmeBroadcastGrpMembers'(Data,[]);
+encode_disp('KmeAlterIfSrvEvt',Data) -> 'enc_KmeAlterIfSrvEvt'(Data,[]);
+encode_disp('KmeAlterIf',Data) -> 'enc_KmeAlterIf'(Data,[]);
+encode_disp('KmeIfAltered',Data) -> 'enc_KmeIfAltered'(Data,[]);
+encode_disp('IfVersion',Data) -> 'enc_IfVersion'(Data,[]);
+encode_disp('KmeDeviceDataList',Data) -> 'enc_KmeDeviceDataList'(Data,[]);
+encode_disp('KmePdnGMembers',Data) -> 'enc_KmePdnGMembers'(Data,[]);
+encode_disp('KmeHotelSrvEvt',Data) -> 'enc_KmeHotelSrvEvt'(Data,[]);
+encode_disp('KmeCheckStatusList',Data) -> 'enc_KmeCheckStatusList'(Data,[]);
+encode_disp('KmeRoomStatus',Data) -> 'enc_KmeRoomStatus'(Data,[]);
+encode_disp('KmeCleanUpStatus',Data) -> 'enc_KmeCleanUpStatus'(Data,[]);
+encode_disp('KmeGetSystemDataReq',Data) -> 'enc_KmeGetSystemDataReq'(Data,[]);
+encode_disp('KmeGetSystemDataRsp',Data) -> 'enc_KmeGetSystemDataRsp'(Data,[]);
+encode_disp('KmeGetSystemData',Data) -> 'enc_KmeGetSystemData'(Data,[]);
+encode_disp('KmeSetSystemData',Data) -> 'enc_KmeSetSystemData'(Data,[]);
+encode_disp('KmeSystemDataChanged',Data) -> 'enc_KmeSystemDataChanged'(Data,[]);
+encode_disp('KmeSystemDataLinkedReply',Data) -> 'enc_KmeSystemDataLinkedReply'(Data,[]);
+encode_disp('KmeGetSystemDataPosAck',Data) -> 'enc_KmeGetSystemDataPosAck'(Data,[]);
+encode_disp('KmeSystemCrossRefID',Data) -> 'enc_KmeSystemCrossRefID'(Data,[]);
+encode_disp('KmeLockSystemData',Data) -> 'enc_KmeLockSystemData'(Data,[]);
+encode_disp('KmeSystemDataStatus',Data) -> 'enc_KmeSystemDataStatus'(Data,[]);
+encode_disp('KmeSystemDataRevision',Data) -> 'enc_KmeSystemDataRevision'(Data,[]);
+encode_disp('KmeGetSystemDataRevision',Data) -> 'enc_KmeGetSystemDataRevision'(Data,[]);
+encode_disp('KmeRevisionType',Data) -> 'enc_KmeRevisionType'(Data,[]);
+encode_disp('ProgrammingEventOn',Data) -> 'enc_ProgrammingEventOn'(Data,[]);
+encode_disp('KmeSetProgrammingEventOn',Data) -> 'enc_KmeSetProgrammingEventOn'(Data,[]);
+encode_disp('KmeLocalAlerm',Data) -> 'enc_KmeLocalAlerm'(Data,[]);
+encode_disp('KmeTrunkId',Data) -> 'enc_KmeTrunkId'(Data,[]);
+encode_disp('KmeOtherDevice',Data) -> 'enc_KmeOtherDevice'(Data,[]);
+encode_disp('KmeCdrConditionCode',Data) -> 'enc_KmeCdrConditionCode'(Data,[]);
+encode_disp('KmeFeatureNumber',Data) -> 'enc_KmeFeatureNumber'(Data,[]);
+encode_disp('KmeProprietaryChars',Data) -> 'enc_KmeProprietaryChars'(Data,[]);
+encode_disp('KmeHoldType',Data) -> 'enc_KmeHoldType'(Data,[]);
+encode_disp('KmeForcedAlerting',Data) -> 'enc_KmeForcedAlerting'(Data,[]);
+encode_disp('KmeDigitsReport',Data) -> 'enc_KmeDigitsReport'(Data,[]);
+encode_disp('KmeOgmStatus',Data) -> 'enc_KmeOgmStatus'(Data,[]);
+encode_disp('KmeWakeupResult',Data) -> 'enc_KmeWakeupResult'(Data,[]);
+encode_disp('KmeUnconferenced',Data) -> 'enc_KmeUnconferenced'(Data,[]);
+encode_disp('KmeTamEnded',Data) -> 'enc_KmeTamEnded'(Data,[]);
+encode_disp('KmePcRecEnded',Data) -> 'enc_KmePcRecEnded'(Data,[]);
+encode_disp('KmeSwitchChannel',Data) -> 'enc_KmeSwitchChannel'(Data,[]);
+encode_disp('KmeFreeOgmPort',Data) -> 'enc_KmeFreeOgmPort'(Data,[]);
+encode_disp('KmeCallControlSrvEvt',Data) -> 'enc_KmeCallControlSrvEvt'(Data,[]);
+encode_disp('KmeDeviceStatus',Data) -> 'enc_KmeDeviceStatus'(Data,[]);
+encode_disp('KmeDeviceMonitor',Data) -> 'enc_KmeDeviceMonitor'(Data,[]);
+encode_disp('KmeSystemData',Data) -> 'enc_KmeSystemData'(Data,[]);
+encode_disp('KmeAdditionalData',Data) -> 'enc_KmeAdditionalData'(Data,[]);
+encode_disp('KmePrivateEvent',Data) -> 'enc_KmePrivateEvent'(Data,[]);
+encode_disp('KmeResourceControl',Data) -> 'enc_KmeResourceControl'(Data,[]);
+encode_disp('KmeOgmStart',Data) -> 'enc_KmeOgmStart'(Data,[]);
+encode_disp('KmeOgmStop',Data) -> 'enc_KmeOgmStop'(Data,[]);
+encode_disp('KmeGenericSrvEvt',Data) -> 'enc_KmeGenericSrvEvt'(Data,[]);
+encode_disp('KmeGenericServiceReq',Data) -> 'enc_KmeGenericServiceReq'(Data,[]);
+encode_disp('KmeGenericServiceRsp',Data) -> 'enc_KmeGenericServiceRsp'(Data,[]);
+encode_disp('KmeGenericEvent',Data) -> 'enc_KmeGenericEvent'(Data,[]);
+encode_disp('KMESpecificPrivateData',Data) -> 'enc_KMESpecificPrivateData'(Data,[]);
+encode_disp(Type,_Data) -> exit({error,{asn1,{undefined_type,Type}}}).
+
+
+decode_disp('KmeDeviceLock',Data) -> 'dec_KmeDeviceLock'(Data,mandatory);
+decode_disp('KmeTimeStamp',Data) -> 'dec_KmeTimeStamp'(Data,mandatory);
+decode_disp('KmeSpeedDialRequest',Data) -> 'dec_KmeSpeedDialRequest'(Data,mandatory);
+decode_disp('KmeSpeedDial',Data) -> 'dec_KmeSpeedDial'(Data,mandatory);
+decode_disp('KmeWakeUpTime',Data) -> 'dec_KmeWakeUpTime'(Data,mandatory);
+decode_disp('KmeWakeUpSchedule',Data) -> 'dec_KmeWakeUpSchedule'(Data,mandatory);
+decode_disp('KmeWakeUpInfo',Data) -> 'dec_KmeWakeUpInfo'(Data,mandatory);
+decode_disp('KmeWakeupState',Data) -> 'dec_KmeWakeupState'(Data,mandatory);
+decode_disp('KmeAbsentMessage',Data) -> 'dec_KmeAbsentMessage'(Data,mandatory);
+decode_disp('KmeDnMode',Data) -> 'dec_KmeDnMode'(Data,mandatory);
+decode_disp('KmeDayNightMode',Data) -> 'dec_KmeDayNightMode'(Data,mandatory);
+decode_disp('KmeOgmPlayState',Data) -> 'dec_KmeOgmPlayState'(Data,mandatory);
+decode_disp('KmeForwardType',Data) -> 'dec_KmeForwardType'(Data,mandatory);
+decode_disp('KmeSetForwardInfo',Data) -> 'dec_KmeSetForwardInfo'(Data,mandatory);
+decode_disp('KmeFeatureList',Data) -> 'dec_KmeFeatureList'(Data,mandatory);
+decode_disp('KmeExtGroupEntry',Data) -> 'dec_KmeExtGroupEntry'(Data,mandatory);
+decode_disp('KmeTrkGroupEntry',Data) -> 'dec_KmeTrkGroupEntry'(Data,mandatory);
+decode_disp('KmeExtMembers',Data) -> 'dec_KmeExtMembers'(Data,mandatory);
+decode_disp('KmeTrkMembers',Data) -> 'dec_KmeTrkMembers'(Data,mandatory);
+decode_disp('KmeExtTrkGroupList',Data) -> 'dec_KmeExtTrkGroupList'(Data,mandatory);
+decode_disp('KmeGroupMembers',Data) -> 'dec_KmeGroupMembers'(Data,mandatory);
+decode_disp('KmePckPagGroupList',Data) -> 'dec_KmePckPagGroupList'(Data,mandatory);
+decode_disp('KmeIcmGrpMembers',Data) -> 'dec_KmeIcmGrpMembers'(Data,mandatory);
+decode_disp('KmeIncomingGroupList',Data) -> 'dec_KmeIncomingGroupList'(Data,mandatory);
+decode_disp('KmeDoorPhone',Data) -> 'dec_KmeDoorPhone'(Data,mandatory);
+decode_disp('KmeVmGroup',Data) -> 'dec_KmeVmGroup'(Data,mandatory);
+decode_disp('KmeVmDtmfType',Data) -> 'dec_KmeVmDtmfType'(Data,mandatory);
+decode_disp('KmeVmGroupList',Data) -> 'dec_KmeVmGroupList'(Data,mandatory);
+decode_disp('KmePsGroupList',Data) -> 'dec_KmePsGroupList'(Data,mandatory);
+decode_disp('KmeChangeExtNo',Data) -> 'dec_KmeChangeExtNo'(Data,mandatory);
+decode_disp('KmeChangeName',Data) -> 'dec_KmeChangeName'(Data,mandatory);
+decode_disp('KmeDeviceCategory',Data) -> 'dec_KmeDeviceCategory'(Data,mandatory);
+decode_disp('KmeRequestedDevice',Data) -> 'dec_KmeRequestedDevice'(Data,mandatory);
+decode_disp('KmeChangedDeviceCategory',Data) -> 'dec_KmeChangedDeviceCategory'(Data,mandatory);
+decode_disp('KmeDeviceStateList',Data) -> 'dec_KmeDeviceStateList'(Data,mandatory);
+decode_disp('KmeDeviceStateEntry',Data) -> 'dec_KmeDeviceStateEntry'(Data,mandatory);
+decode_disp('KmeDeviceState',Data) -> 'dec_KmeDeviceState'(Data,mandatory);
+decode_disp('KmeGroupType',Data) -> 'dec_KmeGroupType'(Data,mandatory);
+decode_disp('KmePhoneProperty',Data) -> 'dec_KmePhoneProperty'(Data,mandatory);
+decode_disp('KmeDeviceExtNo',Data) -> 'dec_KmeDeviceExtNo'(Data,mandatory);
+decode_disp('KmeDeviceName',Data) -> 'dec_KmeDeviceName'(Data,mandatory);
+decode_disp('KmeFcoKeyInfo',Data) -> 'dec_KmeFcoKeyInfo'(Data,mandatory);
+decode_disp('KmeFcoKeyList',Data) -> 'dec_KmeFcoKeyList'(Data,mandatory);
+decode_disp('KmeExternalSensorList',Data) -> 'dec_KmeExternalSensorList'(Data,mandatory);
+decode_disp('KmeTenantSpeedDial',Data) -> 'dec_KmeTenantSpeedDial'(Data,mandatory);
+decode_disp('KmeDistributionMethod',Data) -> 'dec_KmeDistributionMethod'(Data,mandatory);
+decode_disp('KmePDFStart',Data) -> 'dec_KmePDFStart'(Data,mandatory);
+decode_disp('KmePDFStop',Data) -> 'dec_KmePDFStop'(Data,mandatory);
+decode_disp('KmePDFStatus',Data) -> 'dec_KmePDFStatus'(Data,mandatory);
+decode_disp('KmePDFSrvEvt',Data) -> 'dec_KmePDFSrvEvt'(Data,mandatory);
+decode_disp('KmeSvmList',Data) -> 'dec_KmeSvmList'(Data,mandatory);
+decode_disp('KmeExtName',Data) -> 'dec_KmeExtName'(Data,mandatory);
+decode_disp('NumberOfMsgPort',Data) -> 'dec_NumberOfMsgPort'(Data,mandatory);
+decode_disp('KmeDndOverride',Data) -> 'dec_KmeDndOverride'(Data,mandatory);
+decode_disp('KmeInteruptCall',Data) -> 'dec_KmeInteruptCall'(Data,mandatory);
+decode_disp('KmeExternalFeatureAccess',Data) -> 'dec_KmeExternalFeatureAccess'(Data,mandatory);
+decode_disp('KmeTempTollChange',Data) -> 'dec_KmeTempTollChange'(Data,mandatory);
+decode_disp('KmeDoorOpen',Data) -> 'dec_KmeDoorOpen'(Data,mandatory);
+decode_disp('KmeTwoWayRec',Data) -> 'dec_KmeTwoWayRec'(Data,mandatory);
+decode_disp('KmeCallBackInvokeReq',Data) -> 'dec_KmeCallBackInvokeReq'(Data,mandatory);
+decode_disp('KmeCallBackInvokeRsp',Data) -> 'dec_KmeCallBackInvokeRsp'(Data,mandatory);
+decode_disp('CallBackNotification',Data) -> 'dec_CallBackNotification'(Data,mandatory);
+decode_disp('KmeCallBackInvoke',Data) -> 'dec_KmeCallBackInvoke'(Data,mandatory);
+decode_disp('KmePcRec',Data) -> 'dec_KmePcRec'(Data,mandatory);
+decode_disp('KmeDeviceAgentStatus',Data) -> 'dec_KmeDeviceAgentStatus'(Data,mandatory);
+decode_disp('KmeDeviceCallStatus',Data) -> 'dec_KmeDeviceCallStatus'(Data,mandatory);
+decode_disp('KmeDeviceServiceStatus',Data) -> 'dec_KmeDeviceServiceStatus'(Data,mandatory);
+decode_disp('KmeLineStatus',Data) -> 'dec_KmeLineStatus'(Data,mandatory);
+decode_disp('KmeLineStatusSegment',Data) -> 'dec_KmeLineStatusSegment'(Data,mandatory);
+decode_disp('KmeStartDeviceMonitor',Data) -> 'dec_KmeStartDeviceMonitor'(Data,mandatory);
+decode_disp('KmeStopDeviceMonitor',Data) -> 'dec_KmeStopDeviceMonitor'(Data,mandatory);
+decode_disp('CallMonitorEvent',Data) -> 'dec_CallMonitorEvent'(Data,mandatory);
+decode_disp('KmeBroadcastGroupList',Data) -> 'dec_KmeBroadcastGroupList'(Data,mandatory);
+decode_disp('KmeBroadcastGrpMembers',Data) -> 'dec_KmeBroadcastGrpMembers'(Data,mandatory);
+decode_disp('KmeAlterIfSrvEvt',Data) -> 'dec_KmeAlterIfSrvEvt'(Data,mandatory);
+decode_disp('KmeAlterIf',Data) -> 'dec_KmeAlterIf'(Data,mandatory);
+decode_disp('KmeIfAltered',Data) -> 'dec_KmeIfAltered'(Data,mandatory);
+decode_disp('IfVersion',Data) -> 'dec_IfVersion'(Data,mandatory);
+decode_disp('KmeDeviceDataList',Data) -> 'dec_KmeDeviceDataList'(Data,mandatory);
+decode_disp('KmePdnGMembers',Data) -> 'dec_KmePdnGMembers'(Data,mandatory);
+decode_disp('KmeHotelSrvEvt',Data) -> 'dec_KmeHotelSrvEvt'(Data,mandatory);
+decode_disp('KmeCheckStatusList',Data) -> 'dec_KmeCheckStatusList'(Data,mandatory);
+decode_disp('KmeRoomStatus',Data) -> 'dec_KmeRoomStatus'(Data,mandatory);
+decode_disp('KmeCleanUpStatus',Data) -> 'dec_KmeCleanUpStatus'(Data,mandatory);
+decode_disp('KmeGetSystemDataReq',Data) -> 'dec_KmeGetSystemDataReq'(Data,mandatory);
+decode_disp('KmeGetSystemDataRsp',Data) -> 'dec_KmeGetSystemDataRsp'(Data,mandatory);
+decode_disp('KmeGetSystemData',Data) -> 'dec_KmeGetSystemData'(Data,mandatory);
+decode_disp('KmeSetSystemData',Data) -> 'dec_KmeSetSystemData'(Data,mandatory);
+decode_disp('KmeSystemDataChanged',Data) -> 'dec_KmeSystemDataChanged'(Data,mandatory);
+decode_disp('KmeSystemDataLinkedReply',Data) -> 'dec_KmeSystemDataLinkedReply'(Data,mandatory);
+decode_disp('KmeGetSystemDataPosAck',Data) -> 'dec_KmeGetSystemDataPosAck'(Data,mandatory);
+decode_disp('KmeSystemCrossRefID',Data) -> 'dec_KmeSystemCrossRefID'(Data,mandatory);
+decode_disp('KmeLockSystemData',Data) -> 'dec_KmeLockSystemData'(Data,mandatory);
+decode_disp('KmeSystemDataStatus',Data) -> 'dec_KmeSystemDataStatus'(Data,mandatory);
+decode_disp('KmeSystemDataRevision',Data) -> 'dec_KmeSystemDataRevision'(Data,mandatory);
+decode_disp('KmeGetSystemDataRevision',Data) -> 'dec_KmeGetSystemDataRevision'(Data,mandatory);
+decode_disp('KmeRevisionType',Data) -> 'dec_KmeRevisionType'(Data,mandatory);
+decode_disp('ProgrammingEventOn',Data) -> 'dec_ProgrammingEventOn'(Data,mandatory);
+decode_disp('KmeSetProgrammingEventOn',Data) -> 'dec_KmeSetProgrammingEventOn'(Data,mandatory);
+decode_disp('KmeLocalAlerm',Data) -> 'dec_KmeLocalAlerm'(Data,mandatory);
+decode_disp('KmeTrunkId',Data) -> 'dec_KmeTrunkId'(Data,mandatory);
+decode_disp('KmeOtherDevice',Data) -> 'dec_KmeOtherDevice'(Data,mandatory);
+decode_disp('KmeCdrConditionCode',Data) -> 'dec_KmeCdrConditionCode'(Data,mandatory);
+decode_disp('KmeFeatureNumber',Data) -> 'dec_KmeFeatureNumber'(Data,mandatory);
+decode_disp('KmeProprietaryChars',Data) -> 'dec_KmeProprietaryChars'(Data,mandatory);
+decode_disp('KmeHoldType',Data) -> 'dec_KmeHoldType'(Data,mandatory);
+decode_disp('KmeForcedAlerting',Data) -> 'dec_KmeForcedAlerting'(Data,mandatory);
+decode_disp('KmeDigitsReport',Data) -> 'dec_KmeDigitsReport'(Data,mandatory);
+decode_disp('KmeOgmStatus',Data) -> 'dec_KmeOgmStatus'(Data,mandatory);
+decode_disp('KmeWakeupResult',Data) -> 'dec_KmeWakeupResult'(Data,mandatory);
+decode_disp('KmeUnconferenced',Data) -> 'dec_KmeUnconferenced'(Data,mandatory);
+decode_disp('KmeTamEnded',Data) -> 'dec_KmeTamEnded'(Data,mandatory);
+decode_disp('KmePcRecEnded',Data) -> 'dec_KmePcRecEnded'(Data,mandatory);
+decode_disp('KmeSwitchChannel',Data) -> 'dec_KmeSwitchChannel'(Data,mandatory);
+decode_disp('KmeFreeOgmPort',Data) -> 'dec_KmeFreeOgmPort'(Data,mandatory);
+decode_disp('KmeCallControlSrvEvt',Data) -> 'dec_KmeCallControlSrvEvt'(Data,mandatory);
+decode_disp('KmeDeviceStatus',Data) -> 'dec_KmeDeviceStatus'(Data,mandatory);
+decode_disp('KmeDeviceMonitor',Data) -> 'dec_KmeDeviceMonitor'(Data,mandatory);
+decode_disp('KmeSystemData',Data) -> 'dec_KmeSystemData'(Data,mandatory);
+decode_disp('KmeAdditionalData',Data) -> 'dec_KmeAdditionalData'(Data,mandatory);
+decode_disp('KmePrivateEvent',Data) -> 'dec_KmePrivateEvent'(Data,mandatory);
+decode_disp('KmeResourceControl',Data) -> 'dec_KmeResourceControl'(Data,mandatory);
+decode_disp('KmeOgmStart',Data) -> 'dec_KmeOgmStart'(Data,mandatory);
+decode_disp('KmeOgmStop',Data) -> 'dec_KmeOgmStop'(Data,mandatory);
+decode_disp('KmeGenericSrvEvt',Data) -> 'dec_KmeGenericSrvEvt'(Data,mandatory);
+decode_disp('KmeGenericServiceReq',Data) -> 'dec_KmeGenericServiceReq'(Data,mandatory);
+decode_disp('KmeGenericServiceRsp',Data) -> 'dec_KmeGenericServiceRsp'(Data,mandatory);
+decode_disp('KmeGenericEvent',Data) -> 'dec_KmeGenericEvent'(Data,mandatory);
+decode_disp('KMESpecificPrivateData',Data) -> 'dec_KMESpecificPrivateData'(Data,mandatory);
+decode_disp(Type,_Data) -> exit({error,{asn1,{undefined_type,Type}}}).
+
+
+
+wrap_encode(Bytes) when is_list(Bytes) ->
+ binary_to_list(list_to_binary(Bytes));
+wrap_encode(Bytes) when is_binary(Bytes) ->
+ binary_to_list(Bytes);
+wrap_encode(Bytes) -> Bytes.
+
+wrap_decode(Bytes) when is_list(Bytes) ->
+ list_to_binary(Bytes);
+wrap_decode(Bytes) -> Bytes.
+
+
+info() ->
+ case ?MODULE:module_info() of
+ MI when is_list(MI) ->
+ case lists:keysearch(attributes,1,MI) of
+ {value,{_,Attributes}} when is_list(Attributes) ->
+ case lists:keysearch(asn1_info,1,Attributes) of
+ {value,{_,Info}} when is_list(Info) ->
+ Info;
+ _ ->
+ []
+ end;
+ _ ->
+ []
+ end
+ end.
+
+
+%%================================
+%% KmeDeviceLock
+%%================================
+
+'enc_KmeDeviceLock'({'KmeDeviceLock',Val}, TagIn) ->
+ 'enc_KmeDeviceLock'(Val, TagIn);
+
+'enc_KmeDeviceLock'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+lock -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+unlock -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeDeviceLock'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceLock'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceLock'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{lock,0},{unlock,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeTimeStamp
+%%================================
+
+'enc_KmeTimeStamp'({'KmeTimeStamp',Val}, TagIn) ->
+ 'enc_KmeTimeStamp'(Val, TagIn);
+
+'enc_KmeTimeStamp'(Val, TagIn) ->
+?RT_BER:encode_generalized_time([], Val, TagIn ++ []).
+
+
+'dec_KmeTimeStamp'(Bytes, OptOrMand) ->
+ 'dec_KmeTimeStamp'(Bytes, OptOrMand, []).
+
+'dec_KmeTimeStamp'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_generalized_time(Bytes,[],TagIn++[], no_length, OptOrMand).
+
+
+
+%%================================
+%% KmeSpeedDialRequest
+%%================================
+'enc_KmeSpeedDialRequest'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,startSerialNo), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_integer([], ?RT_BER:cindex(3,Val,number), []),
+
+%%-------------------------------------------------
+%% attribute number 3 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,tenantNo) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(4,Val,tenantNo), [{tag,128,0,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeSpeedDialRequest'(Bytes, OptOrMand) ->
+ 'dec_KmeSpeedDialRequest'(Bytes, OptOrMand, []).
+
+'dec_KmeSpeedDialRequest'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,{0,999},[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_integer(Bytes3,{1,1000},[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<2:2,_:1,0:5,_/binary>> ->
+?RT_BER:decode_integer(Bytes4,[],[{tag,128,0,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeSpeedDialRequest', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+%%================================
+%% KmeSpeedDial
+%%================================
+
+'enc_KmeSpeedDial'({'KmeSpeedDial',Val}, TagIn) ->
+ 'enc_KmeSpeedDial'(Val, TagIn);
+
+'enc_KmeSpeedDial'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeSpeedDial_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeSpeedDial_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeSpeedDial_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeSpeedDial_SEQOF'(H, []),
+ 'enc_KmeSpeedDial_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeSpeedDial_SEQOF
+%%================================
+'enc_KmeSpeedDial_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,serialNumber), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,registeredDigits) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(3,Val,registeredDigits), 22, [{tag,128,1,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,callerName) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeSpeedDial_SEQOF_callerName'(?RT_BER:cindex(4,Val,callerName), [{tag,128,2,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeSpeedDial_SEQOF_callerName
+%%================================
+
+'enc_KmeSpeedDial_SEQOF_callerName'({'KmeSpeedDial_SEQOF_callerName',Val}, TagIn) ->
+ 'enc_KmeSpeedDial_SEQOF_callerName'(Val, TagIn);
+
+'enc_KmeSpeedDial_SEQOF_callerName'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeSpeedDial_SEQOF_callerName'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeSpeedDial_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,{0,999},[{tag,128,0,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<2:2,_:1,1:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes3,{1,32},22,[{tag,128,1,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<2:2,_:1,2:5,_/binary>> ->
+'dec_KmeSpeedDial_SEQOF_callerName'(Bytes4, opt_or_default, [{tag,128,2,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeSpeedDial_SEQOF', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+'dec_KmeSpeedDial'(Bytes, OptOrMand) ->
+ 'dec_KmeSpeedDial'(Bytes, OptOrMand, []).
+
+'dec_KmeSpeedDial'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeSpeedDial_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeWakeUpTime
+%%================================
+'enc_KmeWakeUpTime'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type IA5String
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(2,Val,hour), 22, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(3,Val,minute), 22, [{tag,128,1,'EXPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeWakeUpTime'(Bytes, OptOrMand) ->
+ 'dec_KmeWakeUpTime'(Bytes, OptOrMand, []).
+
+'dec_KmeWakeUpTime'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type IA5String
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_restricted_string(Bytes2,2,22,[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_restricted_string(Bytes3,2,22,[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeWakeUpTime', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeWakeUpSchedule
+%%================================
+
+'enc_KmeWakeUpSchedule'({'KmeWakeUpSchedule',Val}, TagIn) ->
+ 'enc_KmeWakeUpSchedule'(Val, TagIn);
+
+'enc_KmeWakeUpSchedule'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+noSchedule -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+once -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+everyday -> ?RT_BER:encode_enumerated(2,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeWakeUpSchedule'(Bytes, OptOrMand) ->
+ 'dec_KmeWakeUpSchedule'(Bytes, OptOrMand, []).
+
+'dec_KmeWakeUpSchedule'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{noSchedule,0},{once,1},{everyday,2}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeWakeUpInfo
+%%================================
+'enc_KmeWakeUpInfo'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External KME-specific-types:KmeWakeUpTime OPTIONAL
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = case ?RT_BER:cindex(2,Val,time) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeWakeUpTime'(?RT_BER:cindex(2,Val,time), [{tag,128,0,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,schedule) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(3,Val,schedule) end) of
+noSchedule -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+once -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+everyday -> ?RT_BER:encode_enumerated(2,[{tag,128,1,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeWakeUpInfo'(Bytes, OptOrMand) ->
+ 'dec_KmeWakeUpInfo'(Bytes, OptOrMand, []).
+
+'dec_KmeWakeUpInfo'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External KME-specific-types:KmeWakeUpTime OPTIONAL
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = case Bytes2 of
+<<2:2,_:1,0:5,_/binary>> ->
+'dec_KmeWakeUpTime'(Bytes2, opt_or_default, [{tag,128,0,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes2, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{noSchedule,0},{once,1},{everyday,2}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeWakeUpInfo', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeWakeupState
+%%================================
+
+'enc_KmeWakeupState'({'KmeWakeupState',Val}, TagIn) ->
+ 'enc_KmeWakeupState'(Val, TagIn);
+
+'enc_KmeWakeupState'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+answered -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+noAnswer -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeWakeupState'(Bytes, OptOrMand) ->
+ 'dec_KmeWakeupState'(Bytes, OptOrMand, []).
+
+'dec_KmeWakeupState'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{answered,0},{noAnswer,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeAbsentMessage
+%%================================
+
+'enc_KmeAbsentMessage'({'KmeAbsentMessage',Val}, TagIn) ->
+ 'enc_KmeAbsentMessage'(Val, TagIn);
+
+'enc_KmeAbsentMessage'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeAbsentMessage'(Bytes, OptOrMand) ->
+ 'dec_KmeAbsentMessage'(Bytes, OptOrMand, []).
+
+'dec_KmeAbsentMessage'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{0,16},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{0,32},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeDnMode
+%%================================
+
+'enc_KmeDnMode'({'KmeDnMode',Val}, TagIn) ->
+ 'enc_KmeDnMode'(Val, TagIn);
+
+'enc_KmeDnMode'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+day -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+lunch -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+break -> ?RT_BER:encode_enumerated(2,TagIn ++ []);
+night -> ?RT_BER:encode_enumerated(3,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeDnMode'(Bytes, OptOrMand) ->
+ 'dec_KmeDnMode'(Bytes, OptOrMand, []).
+
+'dec_KmeDnMode'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{day,0},{lunch,1},{break,2},{night,3}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeDayNightMode
+%%================================
+
+'enc_KmeDayNightMode'({'KmeDayNightMode',Val}, TagIn) ->
+ 'enc_KmeDayNightMode'(Val, TagIn);
+
+'enc_KmeDayNightMode'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeDayNightMode_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeDayNightMode_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeDayNightMode_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeDayNightMode_SEQOF'(H, []),
+ 'enc_KmeDayNightMode_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeDayNightMode_SEQOF
+%%================================
+'enc_KmeDayNightMode_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,tenantNo), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,mode) of {_,Enumval2}->Enumval2;_->?RT_BER:cindex(3,Val,mode) end) of
+day -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+lunch -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+break -> ?RT_BER:encode_enumerated(2,[{tag,128,1,'EXPLICIT',32}]);
+night -> ?RT_BER:encode_enumerated(3,[{tag,128,1,'EXPLICIT',32}]);
+Enumval3 -> exit({error,{asn1, {enumerated_not_in_range,Enumval3}}})
+end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+'dec_KmeDayNightMode_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[{tag,128,0,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{day,0},{lunch,1},{break,2},{night,3}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeDayNightMode_SEQOF', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+'dec_KmeDayNightMode'(Bytes, OptOrMand) ->
+ 'dec_KmeDayNightMode'(Bytes, OptOrMand, []).
+
+'dec_KmeDayNightMode'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeDayNightMode_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeOgmPlayState
+%%================================
+
+'enc_KmeOgmPlayState'({'KmeOgmPlayState',Val}, TagIn) ->
+ 'enc_KmeOgmPlayState'(Val, TagIn);
+
+'enc_KmeOgmPlayState'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+started -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+ended -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeOgmPlayState'(Bytes, OptOrMand) ->
+ 'dec_KmeOgmPlayState'(Bytes, OptOrMand, []).
+
+'dec_KmeOgmPlayState'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{started,0},{ended,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeForwardType
+%%================================
+
+'enc_KmeForwardType'({'KmeForwardType',Val}, TagIn) ->
+ 'enc_KmeForwardType'(Val, TagIn);
+
+'enc_KmeForwardType'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+forwardImmediate -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+forwardBusy -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+forwardNoAns -> ?RT_BER:encode_enumerated(2,TagIn ++ []);
+forwardBusyInt -> ?RT_BER:encode_enumerated(3,TagIn ++ []);
+forwardBusyExt -> ?RT_BER:encode_enumerated(4,TagIn ++ []);
+forwardNoAnsInt -> ?RT_BER:encode_enumerated(5,TagIn ++ []);
+forwardNoAnsExt -> ?RT_BER:encode_enumerated(6,TagIn ++ []);
+forwardImmInt -> ?RT_BER:encode_enumerated(7,TagIn ++ []);
+forwardImmExt -> ?RT_BER:encode_enumerated(8,TagIn ++ []);
+forwardDND -> ?RT_BER:encode_enumerated(9,TagIn ++ []);
+forwardDNDInt -> ?RT_BER:encode_enumerated(10,TagIn ++ []);
+forwardDNDExt -> ?RT_BER:encode_enumerated(11,TagIn ++ []);
+forwardBusyNoAnswer -> ?RT_BER:encode_enumerated(12,TagIn ++ []);
+forwardBusyNoAnswerInt -> ?RT_BER:encode_enumerated(13,TagIn ++ []);
+forwardBusyNoAnswerExt -> ?RT_BER:encode_enumerated(14,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeForwardType'(Bytes, OptOrMand) ->
+ 'dec_KmeForwardType'(Bytes, OptOrMand, []).
+
+'dec_KmeForwardType'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{forwardImmediate,0},{forwardBusy,1},{forwardNoAns,2},{forwardBusyInt,3},{forwardBusyExt,4},{forwardNoAnsInt,5},{forwardNoAnsExt,6},{forwardImmInt,7},{forwardImmExt,8},{forwardDND,9},{forwardDNDInt,10},{forwardDNDExt,11},{forwardBusyNoAnswer,12},{forwardBusyNoAnswerInt,13},{forwardBusyNoAnswerExt,14}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeSetForwardInfo
+%%================================
+'enc_KmeSetForwardInfo'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = case (case ?RT_BER:cindex(2,Val,forwardingType) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(2,Val,forwardingType) end) of
+forwardImmediate -> ?RT_BER:encode_enumerated(0,[{tag,128,0,'EXPLICIT',32}]);
+forwardBusy -> ?RT_BER:encode_enumerated(1,[{tag,128,0,'EXPLICIT',32}]);
+forwardNoAns -> ?RT_BER:encode_enumerated(2,[{tag,128,0,'EXPLICIT',32}]);
+forwardBusyInt -> ?RT_BER:encode_enumerated(3,[{tag,128,0,'EXPLICIT',32}]);
+forwardBusyExt -> ?RT_BER:encode_enumerated(4,[{tag,128,0,'EXPLICIT',32}]);
+forwardNoAnsInt -> ?RT_BER:encode_enumerated(5,[{tag,128,0,'EXPLICIT',32}]);
+forwardNoAnsExt -> ?RT_BER:encode_enumerated(6,[{tag,128,0,'EXPLICIT',32}]);
+forwardImmInt -> ?RT_BER:encode_enumerated(7,[{tag,128,0,'EXPLICIT',32}]);
+forwardImmExt -> ?RT_BER:encode_enumerated(8,[{tag,128,0,'EXPLICIT',32}]);
+forwardDND -> ?RT_BER:encode_enumerated(9,[{tag,128,0,'EXPLICIT',32}]);
+forwardDNDInt -> ?RT_BER:encode_enumerated(10,[{tag,128,0,'EXPLICIT',32}]);
+forwardDNDExt -> ?RT_BER:encode_enumerated(11,[{tag,128,0,'EXPLICIT',32}]);
+forwardBusyNoAnswer -> ?RT_BER:encode_enumerated(12,[{tag,128,0,'EXPLICIT',32}]);
+forwardBusyNoAnswerInt -> ?RT_BER:encode_enumerated(13,[{tag,128,0,'EXPLICIT',32}]);
+forwardBusyNoAnswerExt -> ?RT_BER:encode_enumerated(14,[{tag,128,0,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+%%-------------------------------------------------
+%% attribute number 2 with type BOOLEAN
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_boolean(?RT_BER:cindex(3,Val,activateForward), [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,forwardDN) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(4,Val,forwardDN), [{tag,128,2,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeSetForwardInfo'(Bytes, OptOrMand) ->
+ 'dec_KmeSetForwardInfo'(Bytes, OptOrMand, []).
+
+'dec_KmeSetForwardInfo'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type ENUMERATED
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_enumerated(Bytes2,[],[{forwardImmediate,0},{forwardBusy,1},{forwardNoAns,2},{forwardBusyInt,3},{forwardBusyExt,4},{forwardNoAnsInt,5},{forwardNoAnsExt,6},{forwardImmInt,7},{forwardImmExt,8},{forwardDND,9},{forwardDNDInt,10},{forwardDNDExt,11},{forwardBusyNoAnswer,12},{forwardBusyNoAnswerInt,13},{forwardBusyNoAnswerExt,14}],[{tag,128,0,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type BOOLEAN
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_boolean(Bytes3,[{tag,128,1,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<2:2,_:1,2:5,_/binary>> ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes4, opt_or_default, [{tag,128,2,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeSetForwardInfo', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+%%================================
+%% KmeFeatureList
+%%================================
+
+'enc_KmeFeatureList'({'KmeFeatureList',Val}, TagIn) ->
+ 'enc_KmeFeatureList'(Val, TagIn);
+
+'enc_KmeFeatureList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeFeatureList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeFeatureList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeFeatureList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeFeatureList_SEQOF'(H, []),
+ 'enc_KmeFeatureList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeFeatureList_SEQOF
+%%================================
+'enc_KmeFeatureList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,featureNo), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,featureDigits) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(3,Val,featureDigits), 22, [{tag,128,1,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+'dec_KmeFeatureList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[{tag,128,0,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<2:2,_:1,1:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes3,{1,6},22,[{tag,128,1,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeFeatureList_SEQOF', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+'dec_KmeFeatureList'(Bytes, OptOrMand) ->
+ 'dec_KmeFeatureList'(Bytes, OptOrMand, []).
+
+'dec_KmeFeatureList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeFeatureList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeExtGroupEntry
+%%================================
+'enc_KmeExtGroupEntry'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,name) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeExtGroupEntry_name'(?RT_BER:cindex(3,Val,name), [{tag,128,1,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(4,Val,devNumber), [{tag,128,2,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 4 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,cabinetNO) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(5,Val,cabinetNO), [{tag,128,3,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 5 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes5,EncLen5} = case ?RT_BER:cindex(6,Val,psNo) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(6,Val,psNo), 22, [{tag,128,4,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes6,EncLen6} = case ?RT_BER:cindex(7,Val,numberOfBch) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(7,Val,numberOfBch), [{tag,128,5,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4, EncBytes5, EncBytes6],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4 + EncLen5 + EncLen6,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeExtGroupEntry_name
+%%================================
+
+'enc_KmeExtGroupEntry_name'({'KmeExtGroupEntry_name',Val}, TagIn) ->
+ 'enc_KmeExtGroupEntry_name'(Val, TagIn);
+
+'enc_KmeExtGroupEntry_name'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeExtGroupEntry_name'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+'dec_KmeExtGroupEntry'(Bytes, OptOrMand) ->
+ 'dec_KmeExtGroupEntry'(Bytes, OptOrMand, []).
+
+'dec_KmeExtGroupEntry'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<2:2,_:1,1:5,_/binary>> ->
+'dec_KmeExtGroupEntry_name'(Bytes3, opt_or_default, [{tag,128,1,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes4, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 4 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<2:2,_:1,3:5,_/binary>> ->
+?RT_BER:decode_integer(Bytes5,[],[{tag,128,3,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 5 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term5,Bytes7,Rb6} = case Bytes6 of
+<<2:2,_:1,4:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes6,{1,3},22,[{tag,128,4,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes6, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term6,Bytes8,Rb7} = case Bytes7 of
+<<2:2,_:1,5:5,_/binary>> ->
+?RT_BER:decode_integer(Bytes7,[],[{tag,128,5,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes7, 0 }
+end,
+
+ {Bytes9,Rb8} = ?RT_BER:restbytes2(RemBytes, Bytes8,noext),
+ {{'KmeExtGroupEntry', Term1, Term2, Term3, Term4, Term5, Term6}, Bytes9, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6+Rb7+Rb8}.
+
+
+%%================================
+%% KmeTrkGroupEntry
+%%================================
+'enc_KmeTrkGroupEntry'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,name) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeTrkGroupEntry_name'(?RT_BER:cindex(3,Val,name), [{tag,128,1,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type IA5String
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(4,Val,coNo), 22, [{tag,128,2,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 4 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,cabinetNO) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(5,Val,cabinetNO), [{tag,128,3,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeTrkGroupEntry_name
+%%================================
+
+'enc_KmeTrkGroupEntry_name'({'KmeTrkGroupEntry_name',Val}, TagIn) ->
+ 'enc_KmeTrkGroupEntry_name'(Val, TagIn);
+
+'enc_KmeTrkGroupEntry_name'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeTrkGroupEntry_name'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+'dec_KmeTrkGroupEntry'(Bytes, OptOrMand) ->
+ 'dec_KmeTrkGroupEntry'(Bytes, OptOrMand, []).
+
+'dec_KmeTrkGroupEntry'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<2:2,_:1,1:5,_/binary>> ->
+'dec_KmeTrkGroupEntry_name'(Bytes3, opt_or_default, [{tag,128,1,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type IA5String
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = ?RT_BER:decode_restricted_string(Bytes4,{1,3},22,[{tag,128,2,'EXPLICIT',32}], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 4 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<2:2,_:1,3:5,_/binary>> ->
+?RT_BER:decode_integer(Bytes5,[],[{tag,128,3,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+ {Bytes7,Rb6} = ?RT_BER:restbytes2(RemBytes, Bytes6,noext),
+ {{'KmeTrkGroupEntry', Term1, Term2, Term3, Term4}, Bytes7, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6}.
+
+
+%%================================
+%% KmeExtMembers
+%%================================
+'enc_KmeExtMembers'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,groupNo), [{tag,128,0,'IMPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type SEQUENCE OF
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeExtMembers_members'(?RT_BER:cindex(3,Val,members), [{tag,128,1,'IMPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeExtMembers_members
+%%================================
+
+'enc_KmeExtMembers_members'({'KmeExtMembers_members',Val}, TagIn) ->
+ 'enc_KmeExtMembers_members'(Val, TagIn);
+
+'enc_KmeExtMembers_members'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeExtMembers_members_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeExtMembers_members_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeExtMembers_members_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeExtGroupEntry'(H, []),
+ 'enc_KmeExtMembers_members_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+'dec_KmeExtMembers_members'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeExtGroupEntry'/3, [], []).
+
+
+
+
+'dec_KmeExtMembers'(Bytes, OptOrMand) ->
+ 'dec_KmeExtMembers'(Bytes, OptOrMand, []).
+
+'dec_KmeExtMembers'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[{tag,128,0,'IMPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type SEQUENCE OF
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeExtMembers_members'(Bytes3, mandatory, [{tag,128,1,'IMPLICIT',32}]),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeExtMembers', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeTrkMembers
+%%================================
+'enc_KmeTrkMembers'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,groupNo), [{tag,128,0,'IMPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type SEQUENCE OF
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeTrkMembers_members'(?RT_BER:cindex(3,Val,members), [{tag,128,1,'IMPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeTrkMembers_members
+%%================================
+
+'enc_KmeTrkMembers_members'({'KmeTrkMembers_members',Val}, TagIn) ->
+ 'enc_KmeTrkMembers_members'(Val, TagIn);
+
+'enc_KmeTrkMembers_members'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeTrkMembers_members_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeTrkMembers_members_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeTrkMembers_members_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeTrkGroupEntry'(H, []),
+ 'enc_KmeTrkMembers_members_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+'dec_KmeTrkMembers_members'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeTrkGroupEntry'/3, [], []).
+
+
+
+
+'dec_KmeTrkMembers'(Bytes, OptOrMand) ->
+ 'dec_KmeTrkMembers'(Bytes, OptOrMand, []).
+
+'dec_KmeTrkMembers'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[{tag,128,0,'IMPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type SEQUENCE OF
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeTrkMembers_members'(Bytes3, mandatory, [{tag,128,1,'IMPLICIT',32}]),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeTrkMembers', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeExtTrkGroupList
+%%================================
+
+'enc_KmeExtTrkGroupList'({'KmeExtTrkGroupList',Val}, TagIn) ->
+ 'enc_KmeExtTrkGroupList'(Val, TagIn);
+
+'enc_KmeExtTrkGroupList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeExtTrkGroupList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeExtTrkGroupList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeExtTrkGroupList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeExtTrkGroupList_SEQOF'(H, []),
+ 'enc_KmeExtTrkGroupList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeExtTrkGroupList_SEQOF
+%%================================
+'enc_KmeExtTrkGroupList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,groupNo), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,name) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeExtTrkGroupList_SEQOF_name'(?RT_BER:cindex(3,Val,name), [{tag,128,1,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,tenantNo) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(4,Val,tenantNo), [{tag,128,2,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeExtTrkGroupList_SEQOF_name
+%%================================
+
+'enc_KmeExtTrkGroupList_SEQOF_name'({'KmeExtTrkGroupList_SEQOF_name',Val}, TagIn) ->
+ 'enc_KmeExtTrkGroupList_SEQOF_name'(Val, TagIn);
+
+'enc_KmeExtTrkGroupList_SEQOF_name'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeExtTrkGroupList_SEQOF_name'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeExtTrkGroupList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[{tag,128,0,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<2:2,_:1,1:5,_/binary>> ->
+'dec_KmeExtTrkGroupList_SEQOF_name'(Bytes3, opt_or_default, [{tag,128,1,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<2:2,_:1,2:5,_/binary>> ->
+?RT_BER:decode_integer(Bytes4,[],[{tag,128,2,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeExtTrkGroupList_SEQOF', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+'dec_KmeExtTrkGroupList'(Bytes, OptOrMand) ->
+ 'dec_KmeExtTrkGroupList'(Bytes, OptOrMand, []).
+
+'dec_KmeExtTrkGroupList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeExtTrkGroupList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeGroupMembers
+%%================================
+
+'enc_KmeGroupMembers'({'KmeGroupMembers',Val}, TagIn) ->
+ 'enc_KmeGroupMembers'(Val, TagIn);
+
+'enc_KmeGroupMembers'(Val, TagIn) ->
+?RT_BER:encode_bit_string([], Val, [{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}], TagIn ++ []).
+
+
+'dec_KmeGroupMembers'(Bytes, OptOrMand) ->
+ 'dec_KmeGroupMembers'(Bytes, OptOrMand, []).
+
+'dec_KmeGroupMembers'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_bit_string(Bytes,[],[{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}],TagIn++[], no_length, OptOrMand).
+
+
+
+%%================================
+%% KmePckPagGroupList
+%%================================
+
+'enc_KmePckPagGroupList'({'KmePckPagGroupList',Val}, TagIn) ->
+ 'enc_KmePckPagGroupList'(Val, TagIn);
+
+'enc_KmePckPagGroupList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmePckPagGroupList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmePckPagGroupList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmePckPagGroupList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmePckPagGroupList_SEQOF'(H, []),
+ 'enc_KmePckPagGroupList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmePckPagGroupList_SEQOF
+%%================================
+'enc_KmePckPagGroupList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,groupNo), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,memberList) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_bit_string([], ?RT_BER:cindex(3,Val,memberList), [{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}], [{tag,128,1,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+'dec_KmePckPagGroupList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[{tag,128,0,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<2:2,_:1,1:5,_/binary>> ->
+?RT_BER:decode_bit_string(Bytes3,[],[{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}],[{tag,128,1,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmePckPagGroupList_SEQOF', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+'dec_KmePckPagGroupList'(Bytes, OptOrMand) ->
+ 'dec_KmePckPagGroupList'(Bytes, OptOrMand, []).
+
+'dec_KmePckPagGroupList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmePckPagGroupList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeIcmGrpMembers
+%%================================
+'enc_KmeIcmGrpMembers'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,grpDevice), [{tag,128,0,'IMPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type SEQUENCE OF
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeIcmGrpMembers_members'(?RT_BER:cindex(3,Val,members), [{tag,128,1,'IMPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeIcmGrpMembers_members
+%%================================
+
+'enc_KmeIcmGrpMembers_members'({'KmeIcmGrpMembers_members',Val}, TagIn) ->
+ 'enc_KmeIcmGrpMembers_members'(Val, TagIn);
+
+'enc_KmeIcmGrpMembers_members'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeIcmGrpMembers_members_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeIcmGrpMembers_members_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeIcmGrpMembers_members_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'CSTA-device-identifiers':'enc_DeviceID'(H, []),
+ 'enc_KmeIcmGrpMembers_members_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+'dec_KmeIcmGrpMembers_members'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'CSTA-device-identifiers':'dec_DeviceID'/3, [], []).
+
+
+
+
+'dec_KmeIcmGrpMembers'(Bytes, OptOrMand) ->
+ 'dec_KmeIcmGrpMembers'(Bytes, OptOrMand, []).
+
+'dec_KmeIcmGrpMembers'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, [{tag,128,0,'IMPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type SEQUENCE OF
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeIcmGrpMembers_members'(Bytes3, mandatory, [{tag,128,1,'IMPLICIT',32}]),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeIcmGrpMembers', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeIncomingGroupList
+%%================================
+
+'enc_KmeIncomingGroupList'({'KmeIncomingGroupList',Val}, TagIn) ->
+ 'enc_KmeIncomingGroupList'(Val, TagIn);
+
+'enc_KmeIncomingGroupList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeIncomingGroupList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeIncomingGroupList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeIncomingGroupList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeIncomingGroupList_SEQOF'(H, []),
+ 'enc_KmeIncomingGroupList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeIncomingGroupList_SEQOF
+%%================================
+'enc_KmeIncomingGroupList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,groupNo), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(3,Val,device), [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,name) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeIncomingGroupList_SEQOF_name'(?RT_BER:cindex(4,Val,name), [{tag,128,2,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 4 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,extNo) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(5,Val,extNo), 22, [{tag,128,3,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 5 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes5,EncLen5} = case (case ?RT_BER:cindex(6,Val,groupType) of {_,Enumval3}->Enumval3;_->?RT_BER:cindex(6,Val,groupType) end) of
+ucd -> ?RT_BER:encode_enumerated(0,[{tag,128,4,'EXPLICIT',32}]);
+ring -> ?RT_BER:encode_enumerated(1,[{tag,128,4,'EXPLICIT',32}]);
+hunt -> ?RT_BER:encode_enumerated(2,[{tag,128,4,'EXPLICIT',32}]);
+Enumval4 -> exit({error,{asn1, {enumerated_not_in_range,Enumval4}}})
+end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type BOOLEAN
+%%-------------------------------------------------
+ {EncBytes6,EncLen6} = ?RT_BER:encode_boolean(?RT_BER:cindex(7,Val,acdMode), [{tag,128,5,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 7 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes7,EncLen7} = ?RT_BER:encode_integer([], ?RT_BER:cindex(8,Val,ctiWaitTime), [{tag,128,6,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 8 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes8,EncLen8} = case ?RT_BER:cindex(9,Val,queueSize) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(9,Val,queueSize), [{tag,128,7,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4, EncBytes5, EncBytes6, EncBytes7, EncBytes8],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4 + EncLen5 + EncLen6 + EncLen7 + EncLen8,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeIncomingGroupList_SEQOF_name
+%%================================
+
+'enc_KmeIncomingGroupList_SEQOF_name'({'KmeIncomingGroupList_SEQOF_name',Val}, TagIn) ->
+ 'enc_KmeIncomingGroupList_SEQOF_name'(Val, TagIn);
+
+'enc_KmeIncomingGroupList_SEQOF_name'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeIncomingGroupList_SEQOF_name'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeIncomingGroupList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[{tag,128,0,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes3, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<2:2,_:1,2:5,_/binary>> ->
+'dec_KmeIncomingGroupList_SEQOF_name'(Bytes4, opt_or_default, [{tag,128,2,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 4 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<2:2,_:1,3:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes5,{1,5},22,[{tag,128,3,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 5 with type ENUMERATED
+%%-------------------------------------------------
+ {Term5,Bytes7,Rb6} = ?RT_BER:decode_enumerated(Bytes6,[],[{ucd,0},{ring,1},{hunt,2}],[{tag,128,4,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 6 with type BOOLEAN
+%%-------------------------------------------------
+ {Term6,Bytes8,Rb7} = ?RT_BER:decode_boolean(Bytes7,[{tag,128,5,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 7 with type INTEGER
+%%-------------------------------------------------
+ {Term7,Bytes9,Rb8} = ?RT_BER:decode_integer(Bytes8,[],[{tag,128,6,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 8 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term8,Bytes10,Rb9} = case Bytes9 of
+<<2:2,_:1,7:5,_/binary>> ->
+?RT_BER:decode_integer(Bytes9,[],[{tag,128,7,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes9, 0 }
+end,
+
+ {Bytes11,Rb10} = ?RT_BER:restbytes2(RemBytes, Bytes10,noext),
+ {{'KmeIncomingGroupList_SEQOF', Term1, Term2, Term3, Term4, Term5, Term6, Term7, Term8}, Bytes11, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6+Rb7+Rb8+Rb9+Rb10}.
+
+
+'dec_KmeIncomingGroupList'(Bytes, OptOrMand) ->
+ 'dec_KmeIncomingGroupList'(Bytes, OptOrMand, []).
+
+'dec_KmeIncomingGroupList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeIncomingGroupList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeDoorPhone
+%%================================
+
+'enc_KmeDoorPhone'({'KmeDoorPhone',Val}, TagIn) ->
+ 'enc_KmeDoorPhone'(Val, TagIn);
+
+'enc_KmeDoorPhone'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeDoorPhone_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeDoorPhone_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeDoorPhone_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeDoorPhone_SEQOF'(H, []),
+ 'enc_KmeDoorPhone_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeDoorPhone_SEQOF
+%%================================
+'enc_KmeDoorPhone_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type IA5String
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(2,Val,doorPhoneNo), 22, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(3,Val,device), [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,name) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeDoorPhone_SEQOF_name'(?RT_BER:cindex(4,Val,name), [{tag,128,2,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeDoorPhone_SEQOF_name
+%%================================
+
+'enc_KmeDoorPhone_SEQOF_name'({'KmeDoorPhone_SEQOF_name',Val}, TagIn) ->
+ 'enc_KmeDoorPhone_SEQOF_name'(Val, TagIn);
+
+'enc_KmeDoorPhone_SEQOF_name'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeDoorPhone_SEQOF_name'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeDoorPhone_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type IA5String
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_restricted_string(Bytes2,{1,2},22,[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes3, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<2:2,_:1,2:5,_/binary>> ->
+'dec_KmeDoorPhone_SEQOF_name'(Bytes4, opt_or_default, [{tag,128,2,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeDoorPhone_SEQOF', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+'dec_KmeDoorPhone'(Bytes, OptOrMand) ->
+ 'dec_KmeDoorPhone'(Bytes, OptOrMand, []).
+
+'dec_KmeDoorPhone'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeDoorPhone_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeVmGroup
+%%================================
+
+'enc_KmeVmGroup'({'KmeVmGroup',Val}, TagIn) ->
+ 'enc_KmeVmGroup'(Val, TagIn);
+
+'enc_KmeVmGroup'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+dpt -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+dtmf -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeVmGroup'(Bytes, OptOrMand) ->
+ 'dec_KmeVmGroup'(Bytes, OptOrMand, []).
+
+'dec_KmeVmGroup'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{dpt,0},{dtmf,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeVmDtmfType
+%%================================
+
+'enc_KmeVmDtmfType'({'KmeVmDtmfType',Val}, TagIn) ->
+ 'enc_KmeVmDtmfType'(Val, TagIn);
+
+'enc_KmeVmDtmfType'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+aa -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+vm -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeVmDtmfType'(Bytes, OptOrMand) ->
+ 'dec_KmeVmDtmfType'(Bytes, OptOrMand, []).
+
+'dec_KmeVmDtmfType'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{aa,0},{vm,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeVmGroupList
+%%================================
+
+'enc_KmeVmGroupList'({'KmeVmGroupList',Val}, TagIn) ->
+ 'enc_KmeVmGroupList'(Val, TagIn);
+
+'enc_KmeVmGroupList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeVmGroupList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeVmGroupList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeVmGroupList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeVmGroupList_SEQOF'(H, []),
+ 'enc_KmeVmGroupList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeVmGroupList_SEQOF
+%%================================
+'enc_KmeVmGroupList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,vmType) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(3,Val,vmType) end) of
+dpt -> ?RT_BER:encode_enumerated(0,[]);
+dtmf -> ?RT_BER:encode_enumerated(1,[]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,name) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeVmGroupList_SEQOF_name'(?RT_BER:cindex(4,Val,name), [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 4 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,dtmfType) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ case (case ?RT_BER:cindex(5,Val,dtmfType) of {_,Enumval3}->Enumval3;_->?RT_BER:cindex(5,Val,dtmfType) end) of
+aa -> ?RT_BER:encode_enumerated(0,[]);
+vm -> ?RT_BER:encode_enumerated(1,[]);
+Enumval4 -> exit({error,{asn1, {enumerated_not_in_range,Enumval4}}})
+end
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeVmGroupList_SEQOF_name
+%%================================
+
+'enc_KmeVmGroupList_SEQOF_name'({'KmeVmGroupList_SEQOF_name',Val}, TagIn) ->
+ 'enc_KmeVmGroupList_SEQOF_name'(Val, TagIn);
+
+'enc_KmeVmGroupList_SEQOF_name'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeVmGroupList_SEQOF_name'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeVmGroupList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{dpt,0},{dtmf,1}],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case (catch 'dec_KmeVmGroupList_SEQOF_name'(Bytes4, opt_or_default, [])) of
+{'EXIT',{error,{asn1,{no_optional_tag,_}}}} -> { asn1_NOVALUE, Bytes4, 0 };
+Casetmp1-> Casetmp1
+end,
+
+%%-------------------------------------------------
+%% attribute number 4 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<0:2,_:1,10:5,_/binary>> ->
+?RT_BER:decode_enumerated(Bytes5,[],[{aa,0},{vm,1}],[], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+ {Bytes7,Rb6} = ?RT_BER:restbytes2(RemBytes, Bytes6,noext),
+ {{'KmeVmGroupList_SEQOF', Term1, Term2, Term3, Term4}, Bytes7, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6}.
+
+
+'dec_KmeVmGroupList'(Bytes, OptOrMand) ->
+ 'dec_KmeVmGroupList'(Bytes, OptOrMand, []).
+
+'dec_KmeVmGroupList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeVmGroupList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmePsGroupList
+%%================================
+
+'enc_KmePsGroupList'({'KmePsGroupList',Val}, TagIn) ->
+ 'enc_KmePsGroupList'(Val, TagIn);
+
+'enc_KmePsGroupList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmePsGroupList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmePsGroupList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmePsGroupList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmePsGroupList_SEQOF'(H, []),
+ 'enc_KmePsGroupList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmePsGroupList_SEQOF
+%%================================
+'enc_KmePsGroupList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,groupNo), []),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(3,Val,device), []),
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,name) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmePsGroupList_SEQOF_name'(?RT_BER:cindex(4,Val,name), [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 4 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,memberList) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_bit_string([], ?RT_BER:cindex(5,Val,memberList), [{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}], [{tag,128,2,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 5 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {EncBytes5,EncLen5} = case ?RT_BER:cindex(6,Val,memberList2) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_bit_string([], ?RT_BER:cindex(6,Val,memberList2), [{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}], [{tag,128,3,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {EncBytes6,EncLen6} = case ?RT_BER:cindex(7,Val,memberList3) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_bit_string([], ?RT_BER:cindex(7,Val,memberList3), [{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}], [{tag,128,4,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 7 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {EncBytes7,EncLen7} = case ?RT_BER:cindex(8,Val,memberList4) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_bit_string([], ?RT_BER:cindex(8,Val,memberList4), [{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}], [{tag,128,5,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4, EncBytes5, EncBytes6, EncBytes7],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4 + EncLen5 + EncLen6 + EncLen7,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmePsGroupList_SEQOF_name
+%%================================
+
+'enc_KmePsGroupList_SEQOF_name'({'KmePsGroupList_SEQOF_name',Val}, TagIn) ->
+ 'enc_KmePsGroupList_SEQOF_name'(Val, TagIn);
+
+'enc_KmePsGroupList_SEQOF_name'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmePsGroupList_SEQOF_name'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmePsGroupList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes3, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case (catch 'dec_KmePsGroupList_SEQOF_name'(Bytes4, opt_or_default, [])) of
+{'EXIT',{error,{asn1,{no_optional_tag,_}}}} -> { asn1_NOVALUE, Bytes4, 0 };
+Casetmp1-> Casetmp1
+end,
+
+%%-------------------------------------------------
+%% attribute number 4 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<2:2,_:1,2:5,_/binary>> ->
+?RT_BER:decode_bit_string(Bytes5,[],[{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}],[{tag,128,2,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 5 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {Term5,Bytes7,Rb6} = case Bytes6 of
+<<2:2,_:1,3:5,_/binary>> ->
+?RT_BER:decode_bit_string(Bytes6,[],[{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}],[{tag,128,3,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes6, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {Term6,Bytes8,Rb7} = case Bytes7 of
+<<2:2,_:1,4:5,_/binary>> ->
+?RT_BER:decode_bit_string(Bytes7,[],[{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}],[{tag,128,4,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes7, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 7 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {Term7,Bytes9,Rb8} = case Bytes8 of
+<<2:2,_:1,5:5,_/binary>> ->
+?RT_BER:decode_bit_string(Bytes8,[],[{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}],[{tag,128,5,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes8, 0 }
+end,
+
+ {Bytes10,Rb9} = ?RT_BER:restbytes2(RemBytes, Bytes9,noext),
+ {{'KmePsGroupList_SEQOF', Term1, Term2, Term3, Term4, Term5, Term6, Term7}, Bytes10, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6+Rb7+Rb8+Rb9}.
+
+
+'dec_KmePsGroupList'(Bytes, OptOrMand) ->
+ 'dec_KmePsGroupList'(Bytes, OptOrMand, []).
+
+'dec_KmePsGroupList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmePsGroupList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeChangeExtNo
+%%================================
+'enc_KmeChangeExtNo'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,requestingDevice), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(3,Val,newExtNo), 22, []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeChangeExtNo'(Bytes, OptOrMand) ->
+ 'dec_KmeChangeExtNo'(Bytes, OptOrMand, []).
+
+'dec_KmeChangeExtNo'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_restricted_string(Bytes3,{1,5},22,[], no_length, mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeChangeExtNo', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeChangeName
+%%================================
+'enc_KmeChangeName'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,requestingDevice), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,newName) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeChangeName_newName'(?RT_BER:cindex(3,Val,newName), [])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeChangeName_newName
+%%================================
+
+'enc_KmeChangeName_newName'({'KmeChangeName_newName',Val}, TagIn) ->
+ 'enc_KmeChangeName_newName'(Val, TagIn);
+
+'enc_KmeChangeName_newName'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeChangeName_newName'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+'dec_KmeChangeName'(Bytes, OptOrMand) ->
+ 'dec_KmeChangeName'(Bytes, OptOrMand, []).
+
+'dec_KmeChangeName'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case (catch 'dec_KmeChangeName_newName'(Bytes3, opt_or_default, [])) of
+{'EXIT',{error,{asn1,{no_optional_tag,_}}}} -> { asn1_NOVALUE, Bytes3, 0 };
+Casetmp1-> Casetmp1
+end,
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeChangeName', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeDeviceCategory
+%%================================
+
+'enc_KmeDeviceCategory'({'KmeDeviceCategory',Val}, TagIn) ->
+ 'enc_KmeDeviceCategory'(Val, TagIn);
+
+'enc_KmeDeviceCategory'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ standardDevice ->
+ case (case element(2,Val) of {_,Enumval1}->Enumval1;_->element(2,Val) end) of
+acd -> ?RT_BER:encode_enumerated(0,[{tag,128,0,'EXPLICIT',32}]);
+group -> ?RT_BER:encode_enumerated(1,[{tag,128,0,'EXPLICIT',32}]);
+networkInterface -> ?RT_BER:encode_enumerated(2,[{tag,128,0,'EXPLICIT',32}]);
+park -> ?RT_BER:encode_enumerated(3,[{tag,128,0,'EXPLICIT',32}]);
+routeingDevice -> ?RT_BER:encode_enumerated(4,[{tag,128,0,'EXPLICIT',32}]);
+station -> ?RT_BER:encode_enumerated(5,[{tag,128,0,'EXPLICIT',32}]);
+voiceUnit -> ?RT_BER:encode_enumerated(6,[{tag,128,0,'EXPLICIT',32}]);
+other -> ?RT_BER:encode_enumerated(7,[{tag,128,0,'EXPLICIT',32}]);
+genericInteractiveVoice -> ?RT_BER:encode_enumerated(8,[{tag,128,0,'EXPLICIT',32}]);
+listenerInteractiveVoice -> ?RT_BER:encode_enumerated(9,[{tag,128,0,'EXPLICIT',32}]);
+dtmfInteractiveVoice -> ?RT_BER:encode_enumerated(10,[{tag,128,0,'EXPLICIT',32}]);
+promptInteractiveVoice -> ?RT_BER:encode_enumerated(11,[{tag,128,0,'EXPLICIT',32}]);
+promptQueueInteractiveVoice -> ?RT_BER:encode_enumerated(12,[{tag,128,0,'EXPLICIT',32}]);
+messageInteractiveVoice -> ?RT_BER:encode_enumerated(13,[{tag,128,0,'EXPLICIT',32}]);
+conference -> ?RT_BER:encode_enumerated(14,[{tag,128,0,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end;
+ kmeDevice ->
+ case (case element(2,Val) of {_,Enumval3}->Enumval3;_->element(2,Val) end) of
+vm -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+doorPhone -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+disa -> ?RT_BER:encode_enumerated(2,[{tag,128,1,'EXPLICIT',32}]);
+pagingGroup -> ?RT_BER:encode_enumerated(3,[{tag,128,1,'EXPLICIT',32}]);
+psGruop -> ?RT_BER:encode_enumerated(4,[{tag,128,1,'EXPLICIT',32}]);
+externalRinger -> ?RT_BER:encode_enumerated(5,[{tag,128,1,'EXPLICIT',32}]);
+externalSensor -> ?RT_BER:encode_enumerated(6,[{tag,128,1,'EXPLICIT',32}]);
+externalPager -> ?RT_BER:encode_enumerated(7,[{tag,128,1,'EXPLICIT',32}]);
+modem -> ?RT_BER:encode_enumerated(8,[{tag,128,1,'EXPLICIT',32}]);
+hdlc -> ?RT_BER:encode_enumerated(9,[{tag,128,1,'EXPLICIT',32}]);
+pbxSystem -> ?RT_BER:encode_enumerated(10,[{tag,128,1,'EXPLICIT',32}]);
+svm -> ?RT_BER:encode_enumerated(11,[{tag,128,1,'EXPLICIT',32}]);
+Enumval4 -> exit({error,{asn1, {enumerated_not_in_range,Enumval4}}})
+end;
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeDeviceCategory'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceCategory'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceCategory'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'standardDevice'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{acd,0},{group,1},{networkInterface,2},{park,3},{routeingDevice,4},{station,5},{voiceUnit,6},{other,7},{genericInteractiveVoice,8},{listenerInteractiveVoice,9},{dtmfInteractiveVoice,10},{promptInteractiveVoice,11},{promptQueueInteractiveVoice,12},{messageInteractiveVoice,13},{conference,14}],[{tag,128,0,'EXPLICIT',32}], mandatory),
+ {{standardDevice, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeDevice'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{vm,0},{doorPhone,1},{disa,2},{pagingGroup,3},{psGruop,4},{externalRinger,5},{externalSensor,6},{externalPager,7},{modem,8},{hdlc,9},{pbxSystem,10},{svm,11}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+ {{kmeDevice, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeRequestedDevice
+%%================================
+
+'enc_KmeRequestedDevice'({'KmeRequestedDevice',Val}, TagIn) ->
+ 'enc_KmeRequestedDevice'(Val, TagIn);
+
+'enc_KmeRequestedDevice'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ device ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ category ->
+ 'enc_KmeDeviceCategory'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeRequestedDevice'(Bytes, OptOrMand) ->
+ 'dec_KmeRequestedDevice'(Bytes, OptOrMand, []).
+
+'dec_KmeRequestedDevice'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'device'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{device, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'category'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDeviceCategory'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{category, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeChangedDeviceCategory
+%%================================
+
+'enc_KmeChangedDeviceCategory'({'KmeChangedDeviceCategory',Val}, TagIn) ->
+ 'enc_KmeChangedDeviceCategory'(Val, TagIn);
+
+'enc_KmeChangedDeviceCategory'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ standardDevice ->
+ case (case element(2,Val) of {_,Enumval1}->Enumval1;_->element(2,Val) end) of
+acd -> ?RT_BER:encode_enumerated(0,[{tag,128,0,'EXPLICIT',32}]);
+groupACD -> ?RT_BER:encode_enumerated(1,[{tag,128,0,'EXPLICIT',32}]);
+groupHunt -> ?RT_BER:encode_enumerated(2,[{tag,128,0,'EXPLICIT',32}]);
+groupPick -> ?RT_BER:encode_enumerated(3,[{tag,128,0,'EXPLICIT',32}]);
+groupOther -> ?RT_BER:encode_enumerated(4,[{tag,128,0,'EXPLICIT',32}]);
+networkInterface -> ?RT_BER:encode_enumerated(5,[{tag,128,0,'EXPLICIT',32}]);
+park -> ?RT_BER:encode_enumerated(6,[{tag,128,0,'EXPLICIT',32}]);
+routeingDevice -> ?RT_BER:encode_enumerated(7,[{tag,128,0,'EXPLICIT',32}]);
+station -> ?RT_BER:encode_enumerated(8,[{tag,128,0,'EXPLICIT',32}]);
+voiceUnit -> ?RT_BER:encode_enumerated(9,[{tag,128,0,'EXPLICIT',32}]);
+other -> ?RT_BER:encode_enumerated(10,[{tag,128,0,'EXPLICIT',32}]);
+conference -> ?RT_BER:encode_enumerated(11,[{tag,128,0,'EXPLICIT',32}]);
+dtmfIV -> ?RT_BER:encode_enumerated(12,[{tag,128,0,'EXPLICIT',32}]);
+genericIV -> ?RT_BER:encode_enumerated(13,[{tag,128,0,'EXPLICIT',32}]);
+groupUser -> ?RT_BER:encode_enumerated(14,[{tag,128,0,'EXPLICIT',32}]);
+listenerIV -> ?RT_BER:encode_enumerated(15,[{tag,128,0,'EXPLICIT',32}]);
+messageIV -> ?RT_BER:encode_enumerated(16,[{tag,128,0,'EXPLICIT',32}]);
+promptIV -> ?RT_BER:encode_enumerated(17,[{tag,128,0,'EXPLICIT',32}]);
+promptQueue -> ?RT_BER:encode_enumerated(18,[{tag,128,0,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end;
+ kmeDevice ->
+ case (case element(2,Val) of {_,Enumval3}->Enumval3;_->element(2,Val) end) of
+vm -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+doorPhone -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+disa -> ?RT_BER:encode_enumerated(2,[{tag,128,1,'EXPLICIT',32}]);
+pagingGroup -> ?RT_BER:encode_enumerated(3,[{tag,128,1,'EXPLICIT',32}]);
+psGruop -> ?RT_BER:encode_enumerated(4,[{tag,128,1,'EXPLICIT',32}]);
+externalRinger -> ?RT_BER:encode_enumerated(5,[{tag,128,1,'EXPLICIT',32}]);
+externalSensor -> ?RT_BER:encode_enumerated(6,[{tag,128,1,'EXPLICIT',32}]);
+externalPager -> ?RT_BER:encode_enumerated(7,[{tag,128,1,'EXPLICIT',32}]);
+modem -> ?RT_BER:encode_enumerated(8,[{tag,128,1,'EXPLICIT',32}]);
+hdlc -> ?RT_BER:encode_enumerated(9,[{tag,128,1,'EXPLICIT',32}]);
+pbxSystem -> ?RT_BER:encode_enumerated(10,[{tag,128,1,'EXPLICIT',32}]);
+svm -> ?RT_BER:encode_enumerated(11,[{tag,128,1,'EXPLICIT',32}]);
+Enumval4 -> exit({error,{asn1, {enumerated_not_in_range,Enumval4}}})
+end;
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeChangedDeviceCategory'(Bytes, OptOrMand) ->
+ 'dec_KmeChangedDeviceCategory'(Bytes, OptOrMand, []).
+
+'dec_KmeChangedDeviceCategory'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'standardDevice'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{acd,0},{groupACD,1},{groupHunt,2},{groupPick,3},{groupOther,4},{networkInterface,5},{park,6},{routeingDevice,7},{station,8},{voiceUnit,9},{other,10},{conference,11},{dtmfIV,12},{genericIV,13},{groupUser,14},{listenerIV,15},{messageIV,16},{promptIV,17},{promptQueue,18}],[{tag,128,0,'EXPLICIT',32}], mandatory),
+ {{standardDevice, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeDevice'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{vm,0},{doorPhone,1},{disa,2},{pagingGroup,3},{psGruop,4},{externalRinger,5},{externalSensor,6},{externalPager,7},{modem,8},{hdlc,9},{pbxSystem,10},{svm,11}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+ {{kmeDevice, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeDeviceStateList
+%%================================
+
+'enc_KmeDeviceStateList'({'KmeDeviceStateList',Val}, TagIn) ->
+ 'enc_KmeDeviceStateList'(Val, TagIn);
+
+'enc_KmeDeviceStateList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeDeviceStateList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeDeviceStateList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeDeviceStateList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeDeviceStateEntry'(H, []),
+ 'enc_KmeDeviceStateList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+'dec_KmeDeviceStateList'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceStateList'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceStateList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeDeviceStateEntry'/3, [], []).
+
+
+
+
+%%================================
+%% KmeDeviceStateEntry
+%%================================
+'enc_KmeDeviceStateEntry'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,number) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(3,Val,number), 22, [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case (case ?RT_BER:cindex(4,Val,status) of {_,Enumval2}->Enumval2;_->?RT_BER:cindex(4,Val,status) end) of
+ins -> ?RT_BER:encode_enumerated(0,[]);
+ous -> ?RT_BER:encode_enumerated(1,[]);
+Enumval3 -> exit({error,{asn1, {enumerated_not_in_range,Enumval3}}})
+end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeDeviceStateEntry'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceStateEntry'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceStateEntry'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<0:2,_:1,22:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes3,{1,5},22,[], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type ENUMERATED
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = ?RT_BER:decode_enumerated(Bytes4,[],[{ins,0},{ous,1}],[], mandatory),
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeDeviceStateEntry', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+%%================================
+%% KmeDeviceState
+%%================================
+
+'enc_KmeDeviceState'({'KmeDeviceState',Val}, TagIn) ->
+ 'enc_KmeDeviceState'(Val, TagIn);
+
+'enc_KmeDeviceState'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+ins -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+ous -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeDeviceState'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceState'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceState'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{ins,0},{ous,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeGroupType
+%%================================
+
+'enc_KmeGroupType'({'KmeGroupType',Val}, TagIn) ->
+ 'enc_KmeGroupType'(Val, TagIn);
+
+'enc_KmeGroupType'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+ucd -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+ring -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+hunt -> ?RT_BER:encode_enumerated(2,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeGroupType'(Bytes, OptOrMand) ->
+ 'dec_KmeGroupType'(Bytes, OptOrMand, []).
+
+'dec_KmeGroupType'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{ucd,0},{ring,1},{hunt,2}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmePhoneProperty
+%%================================
+'enc_KmePhoneProperty'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,portType), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_integer([], ?RT_BER:cindex(3,Val,phoneCode), []),
+
+%%-------------------------------------------------
+%% attribute number 3 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = ?RT_BER:encode_integer([], ?RT_BER:cindex(4,Val,lcdRows), []),
+
+%%-------------------------------------------------
+%% attribute number 4 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = ?RT_BER:encode_integer([], ?RT_BER:cindex(5,Val,lcdColumns), []),
+
+%%-------------------------------------------------
+%% attribute number 5 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes5,EncLen5} = ?RT_BER:encode_integer([], ?RT_BER:cindex(6,Val,numberOfCoKeys), []),
+
+%%-------------------------------------------------
+%% attribute number 6 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes6,EncLen6} = ?RT_BER:encode_integer([], ?RT_BER:cindex(7,Val,numberOfSoftKeys), []),
+
+%%-------------------------------------------------
+%% attribute number 7 with type BOOLEAN
+%%-------------------------------------------------
+ {EncBytes7,EncLen7} = ?RT_BER:encode_boolean(?RT_BER:cindex(8,Val,spPhone), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4, EncBytes5, EncBytes6, EncBytes7],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4 + EncLen5 + EncLen6 + EncLen7,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmePhoneProperty'(Bytes, OptOrMand) ->
+ 'dec_KmePhoneProperty'(Bytes, OptOrMand, []).
+
+'dec_KmePhoneProperty'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_integer(Bytes3,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 with type INTEGER
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = ?RT_BER:decode_integer(Bytes4,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 4 with type INTEGER
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = ?RT_BER:decode_integer(Bytes5,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 5 with type INTEGER
+%%-------------------------------------------------
+ {Term5,Bytes7,Rb6} = ?RT_BER:decode_integer(Bytes6,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 6 with type INTEGER
+%%-------------------------------------------------
+ {Term6,Bytes8,Rb7} = ?RT_BER:decode_integer(Bytes7,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 7 with type BOOLEAN
+%%-------------------------------------------------
+ {Term7,Bytes9,Rb8} = ?RT_BER:decode_boolean(Bytes8,[], mandatory),
+
+ {Bytes10,Rb9} = ?RT_BER:restbytes2(RemBytes, Bytes9,noext),
+ {{'KmePhoneProperty', Term1, Term2, Term3, Term4, Term5, Term6, Term7}, Bytes10, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6+Rb7+Rb8+Rb9}.
+
+
+%%================================
+%% KmeDeviceExtNo
+%%================================
+'enc_KmeDeviceExtNo'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,devNumber), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,extNo) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(3,Val,extNo), 22, [])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeDeviceExtNo'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceExtNo'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceExtNo'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<0:2,_:1,22:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes3,{1,5},22,[], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeDeviceExtNo', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeDeviceName
+%%================================
+'enc_KmeDeviceName'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type IA5String
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(2,Val,extNo), 22, []),
+
+%%-------------------------------------------------
+%% attribute number 2 External KME-specific-types:KmeExtName
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeExtName'(?RT_BER:cindex(3,Val,name), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeDeviceName'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceName'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceName'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type IA5String
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_restricted_string(Bytes2,{1,5},22,[], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External KME-specific-types:KmeExtName
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeExtName'(Bytes3, mandatory, []),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeDeviceName', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeFcoKeyInfo
+%%================================
+'enc_KmeFcoKeyInfo'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type OCTET STRING
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_octet_string([], ?RT_BER:cindex(2,Val,button), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type OCTET STRING
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_octet_string([], ?RT_BER:cindex(3,Val,function), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeFcoKeyInfo'(Bytes, OptOrMand) ->
+ 'dec_KmeFcoKeyInfo'(Bytes, OptOrMand, []).
+
+'dec_KmeFcoKeyInfo'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type OCTET STRING
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_octet_string(Bytes2,[],[], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type OCTET STRING
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_octet_string(Bytes3,1,[], no_length, mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeFcoKeyInfo', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeFcoKeyList
+%%================================
+
+'enc_KmeFcoKeyList'({'KmeFcoKeyList',Val}, TagIn) ->
+ 'enc_KmeFcoKeyList'(Val, TagIn);
+
+'enc_KmeFcoKeyList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeFcoKeyList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeFcoKeyList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeFcoKeyList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeFcoKeyInfo'(H, []),
+ 'enc_KmeFcoKeyList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+'dec_KmeFcoKeyList'(Bytes, OptOrMand) ->
+ 'dec_KmeFcoKeyList'(Bytes, OptOrMand, []).
+
+'dec_KmeFcoKeyList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeFcoKeyInfo'/3, [], []).
+
+
+
+
+%%================================
+%% KmeExternalSensorList
+%%================================
+
+'enc_KmeExternalSensorList'({'KmeExternalSensorList',Val}, TagIn) ->
+ 'enc_KmeExternalSensorList'(Val, TagIn);
+
+'enc_KmeExternalSensorList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeExternalSensorList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeExternalSensorList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeExternalSensorList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeExternalSensorList_SEQOF'(H, []),
+ 'enc_KmeExternalSensorList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeExternalSensorList_SEQOF
+%%================================
+'enc_KmeExternalSensorList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type IA5String
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(2,Val,sensorNo), 22, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(3,Val,device), [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,name) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeExternalSensorList_SEQOF_name'(?RT_BER:cindex(4,Val,name), [{tag,128,2,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeExternalSensorList_SEQOF_name
+%%================================
+
+'enc_KmeExternalSensorList_SEQOF_name'({'KmeExternalSensorList_SEQOF_name',Val}, TagIn) ->
+ 'enc_KmeExternalSensorList_SEQOF_name'(Val, TagIn);
+
+'enc_KmeExternalSensorList_SEQOF_name'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeExternalSensorList_SEQOF_name'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{1,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeExternalSensorList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type IA5String
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_restricted_string(Bytes2,{1,3},22,[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes3, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 3 with type CHOICE OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<2:2,_:1,2:5,_/binary>> ->
+'dec_KmeExternalSensorList_SEQOF_name'(Bytes4, opt_or_default, [{tag,128,2,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeExternalSensorList_SEQOF', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+'dec_KmeExternalSensorList'(Bytes, OptOrMand) ->
+ 'dec_KmeExternalSensorList'(Bytes, OptOrMand, []).
+
+'dec_KmeExternalSensorList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeExternalSensorList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeTenantSpeedDial
+%%================================
+'enc_KmeTenantSpeedDial'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,tenantNo), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 External KME-specific-types:KmeSpeedDial
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeSpeedDial'(?RT_BER:cindex(3,Val,kmeSpeedDial), [{tag,128,1,'EXPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeTenantSpeedDial'(Bytes, OptOrMand) ->
+ 'dec_KmeTenantSpeedDial'(Bytes, OptOrMand, []).
+
+'dec_KmeTenantSpeedDial'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[{tag,128,0,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External KME-specific-types:KmeSpeedDial
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeSpeedDial'(Bytes3, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeTenantSpeedDial', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeDistributionMethod
+%%================================
+'enc_KmeDistributionMethod'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,group), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,type) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(3,Val,type) end) of
+ucd -> ?RT_BER:encode_enumerated(0,[]);
+ring -> ?RT_BER:encode_enumerated(1,[]);
+hunt -> ?RT_BER:encode_enumerated(2,[]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeDistributionMethod'(Bytes, OptOrMand) ->
+ 'dec_KmeDistributionMethod'(Bytes, OptOrMand, []).
+
+'dec_KmeDistributionMethod'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{ucd,0},{ring,1},{hunt,2}],[], mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeDistributionMethod', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmePDFStart
+%%================================
+'enc_KmePDFStart'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), []),
+
+ BytesSoFar = [EncBytes1],
+ LenSoFar = EncLen1,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmePDFStart'(Bytes, OptOrMand) ->
+ 'dec_KmePDFStart'(Bytes, OptOrMand, []).
+
+'dec_KmePDFStart'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+ {Bytes4,Rb3} = ?RT_BER:restbytes2(RemBytes, Bytes3,noext),
+ {{'KmePDFStart', Term1}, Bytes4, Rb1+Rb2+Rb3}.
+
+
+%%================================
+%% KmePDFStop
+%%================================
+
+'enc_KmePDFStop'({'KmePDFStop',Val}, TagIn) ->
+ 'enc_KmePDFStop'(Val, TagIn);
+
+'enc_KmePDFStop'(Val, TagIn) ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(Val, TagIn ++ []).
+
+
+'dec_KmePDFStop'(Bytes, OptOrMand) ->
+ 'dec_KmePDFStop'(Bytes, OptOrMand, []).
+
+'dec_KmePDFStop'(Bytes, OptOrMand, TagIn) ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% KmePDFStatus
+%%================================
+'enc_KmePDFStatus'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,targetDevice), []),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(3,Val,originatingDevice), []),
+
+%%-------------------------------------------------
+%% attribute number 3 with type BOOLEAN
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = ?RT_BER:encode_boolean(?RT_BER:cindex(4,Val,status), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmePDFStatus'(Bytes, OptOrMand) ->
+ 'dec_KmePDFStatus'(Bytes, OptOrMand, []).
+
+'dec_KmePDFStatus'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes3, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 3 with type BOOLEAN
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = ?RT_BER:decode_boolean(Bytes4,[], mandatory),
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmePDFStatus', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+%%================================
+%% KmePDFSrvEvt
+%%================================
+
+'enc_KmePDFSrvEvt'({'KmePDFSrvEvt',Val}, TagIn) ->
+ 'enc_KmePDFSrvEvt'(Val, TagIn);
+
+'enc_KmePDFSrvEvt'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ pDFStart ->
+ 'enc_KmePDFStart'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ pDFStop ->
+ 'enc_KmePDFStop'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmePDFSrvEvt'(Bytes, OptOrMand) ->
+ 'dec_KmePDFSrvEvt'(Bytes, OptOrMand, []).
+
+'dec_KmePDFSrvEvt'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'pDFStart'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmePDFStart'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{pDFStart, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'pDFStop'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmePDFStop'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{pDFStop, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeSvmList
+%%================================
+
+'enc_KmeSvmList'({'KmeSvmList',Val}, TagIn) ->
+ 'enc_KmeSvmList'(Val, TagIn);
+
+'enc_KmeSvmList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeSvmList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeSvmList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeSvmList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeSvmList_SEQOF'(H, []),
+ 'enc_KmeSvmList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeSvmList_SEQOF
+%%================================
+'enc_KmeSvmList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), []),
+
+%%-------------------------------------------------
+%% attribute number 2 External KME-specific-types:KmeExtName OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,name) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeExtName'(?RT_BER:cindex(3,Val,name), [])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+'dec_KmeSvmList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 External KME-specific-types:KmeExtName OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case (catch 'dec_KmeExtName'(Bytes3, opt_or_default, [])) of
+{'EXIT',{error,{asn1,{no_optional_tag,_}}}} -> { asn1_NOVALUE, Bytes3, 0 };
+Casetmp1-> Casetmp1
+end,
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeSvmList_SEQOF', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+'dec_KmeSvmList'(Bytes, OptOrMand) ->
+ 'dec_KmeSvmList'(Bytes, OptOrMand, []).
+
+'dec_KmeSvmList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeSvmList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeExtName
+%%================================
+
+'enc_KmeExtName'({'KmeExtName',Val}, TagIn) ->
+ 'enc_KmeExtName'(Val, TagIn);
+
+'enc_KmeExtName'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ single ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wide ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeExtName'(Bytes, OptOrMand) ->
+ 'dec_KmeExtName'(Bytes, OptOrMand, []).
+
+'dec_KmeExtName'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'single'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{0,20},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{single, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wide'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{0,40},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wide, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% NumberOfMsgPort
+%%================================
+'enc_NumberOfMsgPort'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,numberOfMsgPort), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_integer([], ?RT_BER:cindex(3,Val,numberOfFreePort), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_NumberOfMsgPort'(Bytes, OptOrMand) ->
+ 'dec_NumberOfMsgPort'(Bytes, OptOrMand, []).
+
+'dec_NumberOfMsgPort'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_integer(Bytes3,[],[], mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'NumberOfMsgPort', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeDndOverride
+%%================================
+
+'enc_KmeDndOverride'({'KmeDndOverride',Val}, TagIn) ->
+ 'enc_KmeDndOverride'(Val, TagIn);
+
+'enc_KmeDndOverride'(Val, TagIn) ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(Val, TagIn ++ []).
+
+
+'dec_KmeDndOverride'(Bytes, OptOrMand) ->
+ 'dec_KmeDndOverride'(Bytes, OptOrMand, []).
+
+'dec_KmeDndOverride'(Bytes, OptOrMand, TagIn) ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% KmeInteruptCall
+%%================================
+
+'enc_KmeInteruptCall'({'KmeInteruptCall',Val}, TagIn) ->
+ 'enc_KmeInteruptCall'(Val, TagIn);
+
+'enc_KmeInteruptCall'(Val, TagIn) ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(Val, TagIn ++ []).
+
+
+'dec_KmeInteruptCall'(Bytes, OptOrMand) ->
+ 'dec_KmeInteruptCall'(Bytes, OptOrMand, []).
+
+'dec_KmeInteruptCall'(Bytes, OptOrMand, TagIn) ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% KmeExternalFeatureAccess
+%%================================
+
+'enc_KmeExternalFeatureAccess'({'KmeExternalFeatureAccess',Val}, TagIn) ->
+ 'enc_KmeExternalFeatureAccess'(Val, TagIn);
+
+'enc_KmeExternalFeatureAccess'(Val, TagIn) ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(Val, TagIn ++ []).
+
+
+'dec_KmeExternalFeatureAccess'(Bytes, OptOrMand) ->
+ 'dec_KmeExternalFeatureAccess'(Bytes, OptOrMand, []).
+
+'dec_KmeExternalFeatureAccess'(Bytes, OptOrMand, TagIn) ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% KmeTempTollChange
+%%================================
+'enc_KmeTempTollChange'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-call-connection-identifiers':'enc_ConnectionID'(?RT_BER:cindex(2,Val,connection), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_integer([], ?RT_BER:cindex(3,Val,tollLevel), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeTempTollChange'(Bytes, OptOrMand) ->
+ 'dec_KmeTempTollChange'(Bytes, OptOrMand, []).
+
+'dec_KmeTempTollChange'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_integer(Bytes3,[],[], mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeTempTollChange', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeDoorOpen
+%%================================
+
+'enc_KmeDoorOpen'({'KmeDoorOpen',Val}, TagIn) ->
+ 'enc_KmeDoorOpen'(Val, TagIn);
+
+'enc_KmeDoorOpen'(Val, TagIn) ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(Val, TagIn ++ []).
+
+
+'dec_KmeDoorOpen'(Bytes, OptOrMand) ->
+ 'dec_KmeDoorOpen'(Bytes, OptOrMand, []).
+
+'dec_KmeDoorOpen'(Bytes, OptOrMand, TagIn) ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% KmeTwoWayRec
+%%================================
+'enc_KmeTwoWayRec'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-call-connection-identifiers':'enc_ConnectionID'(?RT_BER:cindex(2,Val,connection), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(3,Val,vmGroupExtNo), 22, []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeTwoWayRec'(Bytes, OptOrMand) ->
+ 'dec_KmeTwoWayRec'(Bytes, OptOrMand, []).
+
+'dec_KmeTwoWayRec'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_restricted_string(Bytes3,{1,5},22,[], no_length, mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeTwoWayRec', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeCallBackInvokeReq
+%%================================
+'enc_KmeCallBackInvokeReq'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type OCTET STRING
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_octet_string([], ?RT_BER:cindex(2,Val,callBackID), []),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(3,Val,requestingDevice), []),
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,targetDevice) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(4,Val,targetDevice), [])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeCallBackInvokeReq'(Bytes, OptOrMand) ->
+ 'dec_KmeCallBackInvokeReq'(Bytes, OptOrMand, []).
+
+'dec_KmeCallBackInvokeReq'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type OCTET STRING
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_octet_string(Bytes2,{0,4},[], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes3, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<0:2,_:1,16:5,_/binary>> ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes4, opt_or_default, []);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeCallBackInvokeReq', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+%%================================
+%% KmeCallBackInvokeRsp
+%%================================
+
+'enc_KmeCallBackInvokeRsp'({'KmeCallBackInvokeRsp',Val}, TagIn) ->
+ 'enc_KmeCallBackInvokeRsp'(Val, TagIn);
+
+'enc_KmeCallBackInvokeRsp'(Val, TagIn) ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(Val, TagIn ++ []).
+
+
+'dec_KmeCallBackInvokeRsp'(Bytes, OptOrMand) ->
+ 'dec_KmeCallBackInvokeRsp'(Bytes, OptOrMand, []).
+
+'dec_KmeCallBackInvokeRsp'(Bytes, OptOrMand, TagIn) ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% CallBackNotification
+%%================================
+'enc_CallBackNotification'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type OCTET STRING
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_octet_string([], ?RT_BER:cindex(2,Val,callBackID), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type BOOLEAN
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_boolean(?RT_BER:cindex(3,Val,prompted), []),
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(4,Val,requestingDevice), []),
+
+%%-------------------------------------------------
+%% attribute number 4 External CSTA-device-identifiers:SubjectDeviceID
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = 'CSTA-device-identifiers':'enc_SubjectDeviceID'(?RT_BER:cindex(5,Val,targetDevice), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_CallBackNotification'(Bytes, OptOrMand) ->
+ 'dec_CallBackNotification'(Bytes, OptOrMand, []).
+
+'dec_CallBackNotification'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type OCTET STRING
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_octet_string(Bytes2,{0,4},[], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type BOOLEAN
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_boolean(Bytes3,[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes4, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 4 External CSTA-device-identifiers:SubjectDeviceID
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = 'CSTA-device-identifiers':'dec_SubjectDeviceID'(Bytes5, mandatory, []),
+
+ {Bytes7,Rb6} = ?RT_BER:restbytes2(RemBytes, Bytes6,noext),
+ {{'CallBackNotification', Term1, Term2, Term3, Term4}, Bytes7, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6}.
+
+
+%%================================
+%% KmeCallBackInvoke
+%%================================
+
+'enc_KmeCallBackInvoke'({'KmeCallBackInvoke',Val}, TagIn) ->
+ 'enc_KmeCallBackInvoke'(Val, TagIn);
+
+'enc_KmeCallBackInvoke'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ request ->
+ 'enc_KmeCallBackInvokeReq'(element(2,Val), []);
+ result ->
+ 'enc_KmeCallBackInvokeRsp'(element(2,Val), []);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeCallBackInvoke'(Bytes, OptOrMand) ->
+ 'dec_KmeCallBackInvoke'(Bytes, OptOrMand, []).
+
+'dec_KmeCallBackInvoke'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'request'
+ <<0:2,_:1,16:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeCallBackInvokeReq'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'result'
+ <<1:2,_:1,11:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeCallBackInvokeRsp'(Bytes1, mandatory, []),
+ {{result, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmePcRec
+%%================================
+'enc_KmePcRec'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-call-connection-identifiers':'enc_ConnectionID'(?RT_BER:cindex(2,Val,connection), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type BOOLEAN
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_boolean(?RT_BER:cindex(3,Val,pcRecOn), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmePcRec'(Bytes, OptOrMand) ->
+ 'dec_KmePcRec'(Bytes, OptOrMand, []).
+
+'dec_KmePcRec'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type BOOLEAN
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_boolean(Bytes3,[], mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmePcRec', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeDeviceAgentStatus
+%%================================
+'enc_KmeDeviceAgentStatus'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,status) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(3,Val,status) end) of
+logout -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+login -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(4,Val,imcomingGroup), [{tag,128,2,'EXPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeDeviceAgentStatus'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceAgentStatus'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceAgentStatus'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{logout,0},{login,1}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes4, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeDeviceAgentStatus', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+%%================================
+%% KmeDeviceCallStatus
+%%================================
+
+'enc_KmeDeviceCallStatus'({'KmeDeviceCallStatus',Val}, TagIn) ->
+ 'enc_KmeDeviceCallStatus'(Val, TagIn);
+
+'enc_KmeDeviceCallStatus'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeDeviceCallStatus_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeDeviceCallStatus_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeDeviceCallStatus_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeDeviceCallStatus_SEQOF'(H, []),
+ 'enc_KmeDeviceCallStatus_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeDeviceCallStatus_SEQOF
+%%================================
+'enc_KmeDeviceCallStatus_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeDeviceCallStatus_SEQOF_status'(?RT_BER:cindex(3,Val,status), [{tag,128,1,'EXPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeDeviceCallStatus_SEQOF_status
+%%================================
+
+'enc_KmeDeviceCallStatus_SEQOF_status'({'KmeDeviceCallStatus_SEQOF_status',Val}, TagIn) ->
+ 'enc_KmeDeviceCallStatus_SEQOF_status'(Val, TagIn);
+
+'enc_KmeDeviceCallStatus_SEQOF_status'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ lineStatus ->
+ case (case element(2,Val) of {_,Enumval1}->Enumval1;_->element(2,Val) end) of
+idle -> ?RT_BER:encode_enumerated(0,[{tag,128,0,'EXPLICIT',32}]);
+ring -> ?RT_BER:encode_enumerated(1,[{tag,128,0,'EXPLICIT',32}]);
+busy -> ?RT_BER:encode_enumerated(2,[{tag,128,0,'EXPLICIT',32}]);
+hold -> ?RT_BER:encode_enumerated(3,[{tag,128,0,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end;
+ parkStatus ->
+ 'enc_KmeDeviceCallStatus_SEQOF_status_parkStatus'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+
+%%================================
+%% KmeDeviceCallStatus_SEQOF_status_parkStatus
+%%================================
+'enc_KmeDeviceCallStatus_SEQOF_status_parkStatus'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,area), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type OCTET STRING
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_octet_string([], ?RT_BER:cindex(3,Val,call), [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 3 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case (case ?RT_BER:cindex(4,Val,action) of {_,Enumval3}->Enumval3;_->?RT_BER:cindex(4,Val,action) end) of
+parkin -> ?RT_BER:encode_enumerated(0,[]);
+parkout -> ?RT_BER:encode_enumerated(1,[]);
+Enumval4 -> exit({error,{asn1, {enumerated_not_in_range,Enumval4}}})
+end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+'dec_KmeDeviceCallStatus_SEQOF_status_parkStatus'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,{0,999},[{tag,128,0,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type OCTET STRING
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_octet_string(Bytes3,[],[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 with type ENUMERATED
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = ?RT_BER:decode_enumerated(Bytes4,[],[{parkin,0},{parkout,1}],[], mandatory),
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeDeviceCallStatus_SEQOF_status_parkStatus', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+'dec_KmeDeviceCallStatus_SEQOF_status'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'lineStatus'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{idle,0},{ring,1},{busy,2},{hold,3}],[{tag,128,0,'EXPLICIT',32}], mandatory),
+ {{lineStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'parkStatus'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDeviceCallStatus_SEQOF_status_parkStatus'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{parkStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeDeviceCallStatus_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeDeviceCallStatus_SEQOF_status'(Bytes3, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeDeviceCallStatus_SEQOF', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+'dec_KmeDeviceCallStatus'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceCallStatus'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceCallStatus'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeDeviceCallStatus_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeDeviceServiceStatus
+%%================================
+'enc_KmeDeviceServiceStatus'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type CHOICE
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'enc_KmeDeviceServiceStatus_source'(?RT_BER:cindex(2,Val,source), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,status) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(3,Val,status) end) of
+ous -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+ins -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeDeviceServiceStatus_source
+%%================================
+
+'enc_KmeDeviceServiceStatus_source'({'KmeDeviceServiceStatus_source',Val}, TagIn) ->
+ 'enc_KmeDeviceServiceStatus_source'(Val, TagIn);
+
+'enc_KmeDeviceServiceStatus_source'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ device ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ cabinet ->
+ ?RT_BER:encode_integer([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeDeviceServiceStatus_source'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'device'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{device, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'cabinet'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_integer(Bytes1,[],[{tag,128,1,'EXPLICIT',32}], mandatory),
+ {{cabinet, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+'dec_KmeDeviceServiceStatus'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceServiceStatus'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceServiceStatus'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type CHOICE
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'dec_KmeDeviceServiceStatus_source'(Bytes2, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{ous,0},{ins,1}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeDeviceServiceStatus', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeLineStatus
+%%================================
+'enc_KmeLineStatus'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = case (case ?RT_BER:cindex(2,Val,segmentId) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(2,Val,segmentId) end) of
+wired1 -> ?RT_BER:encode_enumerated(0,[]);
+wired2 -> ?RT_BER:encode_enumerated(1,[]);
+wireless -> ?RT_BER:encode_enumerated(2,[]);
+trunk -> ?RT_BER:encode_enumerated(3,[]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+%%-------------------------------------------------
+%% attribute number 2 with type OCTET STRING
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_octet_string([], ?RT_BER:cindex(3,Val,lineInformation), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeLineStatus'(Bytes, OptOrMand) ->
+ 'dec_KmeLineStatus'(Bytes, OptOrMand, []).
+
+'dec_KmeLineStatus'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type ENUMERATED
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_enumerated(Bytes2,[],[{wired1,0},{wired2,1},{wireless,2},{trunk,3}],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type OCTET STRING
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_octet_string(Bytes3,{0,384},[], no_length, mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeLineStatus', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeLineStatusSegment
+%%================================
+
+'enc_KmeLineStatusSegment'({'KmeLineStatusSegment',Val}, TagIn) ->
+ 'enc_KmeLineStatusSegment'(Val, TagIn);
+
+'enc_KmeLineStatusSegment'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+wired1 -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+wired2 -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+wireless -> ?RT_BER:encode_enumerated(2,TagIn ++ []);
+trunk -> ?RT_BER:encode_enumerated(3,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeLineStatusSegment'(Bytes, OptOrMand) ->
+ 'dec_KmeLineStatusSegment'(Bytes, OptOrMand, []).
+
+'dec_KmeLineStatusSegment'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{wired1,0},{wired2,1},{wireless,2},{trunk,3}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeStartDeviceMonitor
+%%================================
+
+'enc_KmeStartDeviceMonitor'({'KmeStartDeviceMonitor',Val}, TagIn) ->
+ 'enc_KmeStartDeviceMonitor'(Val, TagIn);
+
+'enc_KmeStartDeviceMonitor'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ null ->
+ ?RT_BER:encode_null(element(2,Val), []);
+ event ->
+ case (case element(2,Val) of {_,Enumval2}->Enumval2;_->element(2,Val) end) of
+deviceCallStatus -> ?RT_BER:encode_enumerated(0,[]);
+deviceLineStatus -> ?RT_BER:encode_enumerated(1,[]);
+Enumval3 -> exit({error,{asn1, {enumerated_not_in_range,Enumval3}}})
+end;
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeStartDeviceMonitor'(Bytes, OptOrMand) ->
+ 'dec_KmeStartDeviceMonitor'(Bytes, OptOrMand, []).
+
+'dec_KmeStartDeviceMonitor'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'null'
+ <<0:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_null(Bytes1,[], mandatory),
+ {{null, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'event'
+ <<0:2,_:1,10:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{deviceCallStatus,0},{deviceLineStatus,1}],[], mandatory),
+ {{event, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeStopDeviceMonitor
+%%================================
+
+'enc_KmeStopDeviceMonitor'({'KmeStopDeviceMonitor',Val}, TagIn) ->
+ 'enc_KmeStopDeviceMonitor'(Val, TagIn);
+
+'enc_KmeStopDeviceMonitor'(Val, TagIn) ->
+?RT_BER:encode_null(Val, TagIn ++ []).
+
+
+'dec_KmeStopDeviceMonitor'(Bytes, OptOrMand) ->
+ 'dec_KmeStopDeviceMonitor'(Bytes, OptOrMand, []).
+
+'dec_KmeStopDeviceMonitor'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_null(Bytes,TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% CallMonitorEvent
+%%================================
+
+'enc_CallMonitorEvent'({'CallMonitorEvent',Val}, TagIn) ->
+ 'enc_CallMonitorEvent'(Val, TagIn);
+
+'enc_CallMonitorEvent'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+deviceCallStatus -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+deviceLineStatus -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_CallMonitorEvent'(Bytes, OptOrMand) ->
+ 'dec_CallMonitorEvent'(Bytes, OptOrMand, []).
+
+'dec_CallMonitorEvent'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{deviceCallStatus,0},{deviceLineStatus,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeBroadcastGroupList
+%%================================
+
+'enc_KmeBroadcastGroupList'({'KmeBroadcastGroupList',Val}, TagIn) ->
+ 'enc_KmeBroadcastGroupList'(Val, TagIn);
+
+'enc_KmeBroadcastGroupList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeBroadcastGroupList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeBroadcastGroupList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeBroadcastGroupList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeBroadcastGroupList_SEQOF'(H, []),
+ 'enc_KmeBroadcastGroupList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeBroadcastGroupList_SEQOF
+%%================================
+'enc_KmeBroadcastGroupList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,groupNo), []),
+
+%%-------------------------------------------------
+%% attribute number 2 External KME-specific-types:KmeExtName OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,name) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeExtName'(?RT_BER:cindex(3,Val,name), [])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+'dec_KmeBroadcastGroupList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External KME-specific-types:KmeExtName OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case (catch 'dec_KmeExtName'(Bytes3, opt_or_default, [])) of
+{'EXIT',{error,{asn1,{no_optional_tag,_}}}} -> { asn1_NOVALUE, Bytes3, 0 };
+Casetmp1-> Casetmp1
+end,
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeBroadcastGroupList_SEQOF', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+'dec_KmeBroadcastGroupList'(Bytes, OptOrMand) ->
+ 'dec_KmeBroadcastGroupList'(Bytes, OptOrMand, []).
+
+'dec_KmeBroadcastGroupList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeBroadcastGroupList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeBroadcastGrpMembers
+%%================================
+'enc_KmeBroadcastGrpMembers'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,groupNo), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type SEQUENCE OF
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeBroadcastGrpMembers_members'(?RT_BER:cindex(3,Val,members), [{tag,128,1,'IMPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeBroadcastGrpMembers_members
+%%================================
+
+'enc_KmeBroadcastGrpMembers_members'({'KmeBroadcastGrpMembers_members',Val}, TagIn) ->
+ 'enc_KmeBroadcastGrpMembers_members'(Val, TagIn);
+
+'enc_KmeBroadcastGrpMembers_members'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeBroadcastGrpMembers_members_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeBroadcastGrpMembers_members_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeBroadcastGrpMembers_members_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'CSTA-device-identifiers':'enc_DeviceID'(H, []),
+ 'enc_KmeBroadcastGrpMembers_members_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+'dec_KmeBroadcastGrpMembers_members'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'CSTA-device-identifiers':'dec_DeviceID'/3, [], []).
+
+
+
+
+'dec_KmeBroadcastGrpMembers'(Bytes, OptOrMand) ->
+ 'dec_KmeBroadcastGrpMembers'(Bytes, OptOrMand, []).
+
+'dec_KmeBroadcastGrpMembers'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[{tag,128,0,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type SEQUENCE OF
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeBroadcastGrpMembers_members'(Bytes3, mandatory, [{tag,128,1,'IMPLICIT',32}]),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeBroadcastGrpMembers', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeAlterIfSrvEvt
+%%================================
+
+'enc_KmeAlterIfSrvEvt'({'KmeAlterIfSrvEvt',Val}, TagIn) ->
+ 'enc_KmeAlterIfSrvEvt'(Val, TagIn);
+
+'enc_KmeAlterIfSrvEvt'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ alterIf ->
+ case (case element(2,Val) of {_,Enumval1}->Enumval1;_->element(2,Val) end) of
+version0 -> ?RT_BER:encode_enumerated(0,[{tag,128,0,'EXPLICIT',32}]);
+version1 -> ?RT_BER:encode_enumerated(1,[{tag,128,0,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end;
+ ifAltered ->
+ case (case element(2,Val) of {_,Enumval3}->Enumval3;_->element(2,Val) end) of
+version0 -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+version1 -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+Enumval4 -> exit({error,{asn1, {enumerated_not_in_range,Enumval4}}})
+end;
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeAlterIfSrvEvt'(Bytes, OptOrMand) ->
+ 'dec_KmeAlterIfSrvEvt'(Bytes, OptOrMand, []).
+
+'dec_KmeAlterIfSrvEvt'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'alterIf'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{version0,0},{version1,1}],[{tag,128,0,'EXPLICIT',32}], mandatory),
+ {{alterIf, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'ifAltered'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{version0,0},{version1,1}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+ {{ifAltered, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeAlterIf
+%%================================
+
+'enc_KmeAlterIf'({'KmeAlterIf',Val}, TagIn) ->
+ 'enc_KmeAlterIf'(Val, TagIn);
+
+'enc_KmeAlterIf'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+version0 -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+version1 -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeAlterIf'(Bytes, OptOrMand) ->
+ 'dec_KmeAlterIf'(Bytes, OptOrMand, []).
+
+'dec_KmeAlterIf'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{version0,0},{version1,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeIfAltered
+%%================================
+
+'enc_KmeIfAltered'({'KmeIfAltered',Val}, TagIn) ->
+ 'enc_KmeIfAltered'(Val, TagIn);
+
+'enc_KmeIfAltered'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+version0 -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+version1 -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeIfAltered'(Bytes, OptOrMand) ->
+ 'dec_KmeIfAltered'(Bytes, OptOrMand, []).
+
+'dec_KmeIfAltered'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{version0,0},{version1,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% IfVersion
+%%================================
+
+'enc_IfVersion'({'IfVersion',Val}, TagIn) ->
+ 'enc_IfVersion'(Val, TagIn);
+
+'enc_IfVersion'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+version0 -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+version1 -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_IfVersion'(Bytes, OptOrMand) ->
+ 'dec_IfVersion'(Bytes, OptOrMand, []).
+
+'dec_IfVersion'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{version0,0},{version1,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeDeviceDataList
+%%================================
+
+'enc_KmeDeviceDataList'({'KmeDeviceDataList',Val}, TagIn) ->
+ 'enc_KmeDeviceDataList'(Val, TagIn);
+
+'enc_KmeDeviceDataList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeDeviceDataList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeDeviceDataList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeDeviceDataList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeDeviceDataList_SEQOF'(H, []),
+ 'enc_KmeDeviceDataList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeDeviceDataList_SEQOF
+%%================================
+'enc_KmeDeviceDataList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeDeviceDataList_SEQOF_sysData'(?RT_BER:cindex(3,Val,sysData), [{tag,128,1,'EXPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeDeviceDataList_SEQOF_sysData
+%%================================
+
+'enc_KmeDeviceDataList_SEQOF_sysData'({'KmeDeviceDataList_SEQOF_sysData',Val}, TagIn) ->
+ 'enc_KmeDeviceDataList_SEQOF_sysData'(Val, TagIn);
+
+'enc_KmeDeviceDataList_SEQOF_sysData'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ standardInfo ->
+ 'enc_KmeDeviceDataList_SEQOF_sysData_standardInfo'(element(2,Val), []);
+ extName ->
+ 'enc_KmeExtName'(element(2,Val), [{tag,128,41,'EXPLICIT',32}]);
+ fcoKeyList ->
+ 'enc_KmeFcoKeyList'(element(2,Val), [{tag,128,44,'EXPLICIT',32}]);
+ sxdpMaster ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,45,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+
+%%================================
+%% KmeDeviceDataList_SEQOF_sysData_standardInfo
+%%================================
+'enc_KmeDeviceDataList_SEQOF_sysData_standardInfo'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External KME-specific-types:KmeWakeUpInfo OPTIONAL
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = case ?RT_BER:cindex(2,Val,wakeUp) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeWakeUpInfo'(?RT_BER:cindex(2,Val,wakeUp), [{tag,128,9,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,remoteLock) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ case (case ?RT_BER:cindex(3,Val,remoteLock) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(3,Val,remoteLock) end) of
+lock -> ?RT_BER:encode_enumerated(0,[{tag,128,10,'EXPLICIT',32}]);
+unlock -> ?RT_BER:encode_enumerated(1,[{tag,128,10,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end
+ end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,callLogLock) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ case (case ?RT_BER:cindex(4,Val,callLogLock) of {_,Enumval3}->Enumval3;_->?RT_BER:cindex(4,Val,callLogLock) end) of
+lock -> ?RT_BER:encode_enumerated(0,[{tag,128,11,'EXPLICIT',32}]);
+unlock -> ?RT_BER:encode_enumerated(1,[{tag,128,11,'EXPLICIT',32}]);
+Enumval4 -> exit({error,{asn1, {enumerated_not_in_range,Enumval4}}})
+end
+ end,
+
+%%-------------------------------------------------
+%% attribute number 4 External KME-specific-types:KmeAbsentMessage OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,absentMessage) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeAbsentMessage'(?RT_BER:cindex(5,Val,absentMessage), [{tag,128,12,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 5 External CSTA-device-feature-types:ForwardList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes5,EncLen5} = case ?RT_BER:cindex(6,Val,forwardDnd) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-feature-types':'enc_ForwardList'(?RT_BER:cindex(6,Val,forwardDnd), [{tag,128,13,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes6,EncLen6} = case ?RT_BER:cindex(7,Val,cos) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(7,Val,cos), [{tag,128,34,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 7 External KME-specific-types:KmePhoneProperty OPTIONAL
+%%-------------------------------------------------
+ {EncBytes7,EncLen7} = case ?RT_BER:cindex(8,Val,phoneProperty) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmePhoneProperty'(?RT_BER:cindex(8,Val,phoneProperty), [{tag,128,35,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 8 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {EncBytes8,EncLen8} = case ?RT_BER:cindex(9,Val,assocIncomGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_bit_string([], ?RT_BER:cindex(9,Val,assocIncomGroup), [{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}], [{tag,128,36,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 9 with type SEQUENCE OF OPTIONAL
+%%-------------------------------------------------
+ {EncBytes9,EncLen9} = case ?RT_BER:cindex(10,Val,messageWaiting) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting'(?RT_BER:cindex(10,Val,messageWaiting), [{tag,128,37,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 10 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes10,EncLen10} = case ?RT_BER:cindex(11,Val,assocExtGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(11,Val,assocExtGroup), [{tag,128,39,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4, EncBytes5, EncBytes6, EncBytes7, EncBytes8, EncBytes9, EncBytes10],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4 + EncLen5 + EncLen6 + EncLen7 + EncLen8 + EncLen9 + EncLen10,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting
+%%================================
+
+'enc_KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting'({'KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting',Val}, TagIn) ->
+ 'enc_KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting'(Val, TagIn);
+
+'enc_KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'CSTA-device-identifiers':'enc_DeviceID'(H, []),
+ 'enc_KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+'dec_KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'CSTA-device-identifiers':'dec_DeviceID'/3, [], []).
+
+
+'dec_KmeDeviceDataList_SEQOF_sysData_standardInfo'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External KME-specific-types:KmeWakeUpInfo OPTIONAL
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = case Bytes2 of
+<<2:2,_:1,9:5,_/binary>> ->
+'dec_KmeWakeUpInfo'(Bytes2, opt_or_default, [{tag,128,9,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes2, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<2:2,_:1,10:5,_/binary>> ->
+?RT_BER:decode_enumerated(Bytes3,[],[{lock,0},{unlock,1}],[{tag,128,10,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<2:2,_:1,11:5,_/binary>> ->
+?RT_BER:decode_enumerated(Bytes4,[],[{lock,0},{unlock,1}],[{tag,128,11,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 4 External KME-specific-types:KmeAbsentMessage OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<2:2,_:1,12:5,_/binary>> ->
+'dec_KmeAbsentMessage'(Bytes5, opt_or_default, [{tag,128,12,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 5 External CSTA-device-feature-types:ForwardList OPTIONAL
+%%-------------------------------------------------
+ {Term5,Bytes7,Rb6} = case Bytes6 of
+<<2:2,_:1,13:5,_/binary>> ->
+'CSTA-device-feature-types':'dec_ForwardList'(Bytes6, opt_or_default, [{tag,128,13,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes6, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term6,Bytes8,Rb7} = case Bytes7 of
+<<2:2,_:1,31:5,34,_/binary>> ->
+?RT_BER:decode_integer(Bytes7,[],[{tag,128,34,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes7, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 7 External KME-specific-types:KmePhoneProperty OPTIONAL
+%%-------------------------------------------------
+ {Term7,Bytes9,Rb8} = case Bytes8 of
+<<2:2,_:1,31:5,35,_/binary>> ->
+'dec_KmePhoneProperty'(Bytes8, opt_or_default, [{tag,128,35,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes8, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 8 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {Term8,Bytes10,Rb9} = case Bytes9 of
+<<2:2,_:1,31:5,36,_/binary>> ->
+?RT_BER:decode_bit_string(Bytes9,[],[{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}],[{tag,128,36,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes9, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 9 with type SEQUENCE OF OPTIONAL
+%%-------------------------------------------------
+ {Term9,Bytes11,Rb10} = case Bytes10 of
+<<2:2,_:1,31:5,37,_/binary>> ->
+'dec_KmeDeviceDataList_SEQOF_sysData_standardInfo_messageWaiting'(Bytes10, opt_or_default, [{tag,128,37,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes10, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 10 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term10,Bytes12,Rb11} = case Bytes11 of
+<<2:2,_:1,31:5,39,_/binary>> ->
+?RT_BER:decode_integer(Bytes11,[],[{tag,128,39,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes11, 0 }
+end,
+
+ {Bytes13,Rb12} = ?RT_BER:restbytes2(RemBytes, Bytes12,noext),
+ {{'KmeDeviceDataList_SEQOF_sysData_standardInfo', Term1, Term2, Term3, Term4, Term5, Term6, Term7, Term8, Term9, Term10}, Bytes13, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6+Rb7+Rb8+Rb9+Rb10+Rb11+Rb12}.
+'dec_KmeDeviceDataList_SEQOF_sysData'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'standardInfo'
+ <<0:2,_:1,16:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDeviceDataList_SEQOF_sysData_standardInfo'(Bytes1, mandatory, []),
+ {{standardInfo, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'extName'
+ <<2:2,_:1,31:5,41,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeExtName'(Bytes1, mandatory, [{tag,128,41,'EXPLICIT',32}]),
+ {{extName, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'fcoKeyList'
+ <<2:2,_:1,31:5,44,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeFcoKeyList'(Bytes1, mandatory, [{tag,128,44,'EXPLICIT',32}]),
+ {{fcoKeyList, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'sxdpMaster'
+ <<2:2,_:1,31:5,45,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,45,'EXPLICIT',32}]),
+ {{sxdpMaster, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeDeviceDataList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeDeviceDataList_SEQOF_sysData'(Bytes3, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeDeviceDataList_SEQOF', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+'dec_KmeDeviceDataList'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceDataList'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceDataList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeDeviceDataList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmePdnGMembers
+%%================================
+'enc_KmePdnGMembers'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,groupDevice), [{tag,128,0,'IMPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type SEQUENCE OF
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmePdnGMembers_members'(?RT_BER:cindex(3,Val,members), [{tag,128,1,'IMPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmePdnGMembers_members
+%%================================
+
+'enc_KmePdnGMembers_members'({'KmePdnGMembers_members',Val}, TagIn) ->
+ 'enc_KmePdnGMembers_members'(Val, TagIn);
+
+'enc_KmePdnGMembers_members'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmePdnGMembers_members_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmePdnGMembers_members_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmePdnGMembers_members_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'CSTA-device-identifiers':'enc_DeviceID'(H, []),
+ 'enc_KmePdnGMembers_members_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+'dec_KmePdnGMembers_members'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'CSTA-device-identifiers':'dec_DeviceID'/3, [], []).
+
+
+
+
+'dec_KmePdnGMembers'(Bytes, OptOrMand) ->
+ 'dec_KmePdnGMembers'(Bytes, OptOrMand, []).
+
+'dec_KmePdnGMembers'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, [{tag,128,0,'IMPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type SEQUENCE OF
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmePdnGMembers_members'(Bytes3, mandatory, [{tag,128,1,'IMPLICIT',32}]),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmePdnGMembers', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeHotelSrvEvt
+%%================================
+
+'enc_KmeHotelSrvEvt'({'KmeHotelSrvEvt',Val}, TagIn) ->
+ 'enc_KmeHotelSrvEvt'(Val, TagIn);
+
+'enc_KmeHotelSrvEvt'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ guestCheckIn ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,0,'IMPLICIT',32}]);
+ guestCheckOut ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,1,'IMPLICIT',32}]);
+ checkedIn ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,2,'IMPLICIT',32}]);
+ checkedOut ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,3,'IMPLICIT',32}]);
+ cleanUp ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,4,'IMPLICIT',32}]);
+ cleanUpReady ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,5,'IMPLICIT',32}]);
+ cleanUpNotReady ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,6,'IMPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeHotelSrvEvt'(Bytes, OptOrMand) ->
+ 'dec_KmeHotelSrvEvt'(Bytes, OptOrMand, []).
+
+'dec_KmeHotelSrvEvt'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'guestCheckIn'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,0,'IMPLICIT',32}]),
+ {{guestCheckIn, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'guestCheckOut'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,1,'IMPLICIT',32}]),
+ {{guestCheckOut, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'checkedIn'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,2,'IMPLICIT',32}]),
+ {{checkedIn, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'checkedOut'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,3,'IMPLICIT',32}]),
+ {{checkedOut, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'cleanUp'
+ <<2:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,4,'IMPLICIT',32}]),
+ {{cleanUp, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'cleanUpReady'
+ <<2:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,5,'IMPLICIT',32}]),
+ {{cleanUpReady, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'cleanUpNotReady'
+ <<2:2,_:1,6:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,6,'IMPLICIT',32}]),
+ {{cleanUpNotReady, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeCheckStatusList
+%%================================
+
+'enc_KmeCheckStatusList'({'KmeCheckStatusList',Val}, TagIn) ->
+ 'enc_KmeCheckStatusList'(Val, TagIn);
+
+'enc_KmeCheckStatusList'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeCheckStatusList_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeCheckStatusList_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeCheckStatusList_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'enc_KmeCheckStatusList_SEQOF'(H, []),
+ 'enc_KmeCheckStatusList_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+
+
+
+%%================================
+%% KmeCheckStatusList_SEQOF
+%%================================
+'enc_KmeCheckStatusList_SEQOF'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,extNo), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,status) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(3,Val,status) end) of
+checkIn -> ?RT_BER:encode_enumerated(0,[]);
+checkOut -> ?RT_BER:encode_enumerated(1,[]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,cleanUpStatus) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ case (case ?RT_BER:cindex(4,Val,cleanUpStatus) of {_,Enumval3}->Enumval3;_->?RT_BER:cindex(4,Val,cleanUpStatus) end) of
+ready -> ?RT_BER:encode_enumerated(0,[]);
+notReady -> ?RT_BER:encode_enumerated(1,[]);
+Enumval4 -> exit({error,{asn1, {enumerated_not_in_range,Enumval4}}})
+end
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+'dec_KmeCheckStatusList_SEQOF'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{checkIn,0},{checkOut,1}],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<0:2,_:1,10:5,_/binary>> ->
+?RT_BER:decode_enumerated(Bytes4,[],[{ready,0},{notReady,1}],[], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+ {Bytes6,Rb5} = ?RT_BER:restbytes2(RemBytes, Bytes5,noext),
+ {{'KmeCheckStatusList_SEQOF', Term1, Term2, Term3}, Bytes6, Rb1+Rb2+Rb3+Rb4+Rb5}.
+
+
+'dec_KmeCheckStatusList'(Bytes, OptOrMand) ->
+ 'dec_KmeCheckStatusList'(Bytes, OptOrMand, []).
+
+'dec_KmeCheckStatusList'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'dec_KmeCheckStatusList_SEQOF'/3, [], []).
+
+
+
+
+%%================================
+%% KmeRoomStatus
+%%================================
+
+'enc_KmeRoomStatus'({'KmeRoomStatus',Val}, TagIn) ->
+ 'enc_KmeRoomStatus'(Val, TagIn);
+
+'enc_KmeRoomStatus'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+checkIn -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+checkOut -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeRoomStatus'(Bytes, OptOrMand) ->
+ 'dec_KmeRoomStatus'(Bytes, OptOrMand, []).
+
+'dec_KmeRoomStatus'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{checkIn,0},{checkOut,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeCleanUpStatus
+%%================================
+
+'enc_KmeCleanUpStatus'({'KmeCleanUpStatus',Val}, TagIn) ->
+ 'enc_KmeCleanUpStatus'(Val, TagIn);
+
+'enc_KmeCleanUpStatus'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+ready -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+notReady -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeCleanUpStatus'(Bytes, OptOrMand) ->
+ 'dec_KmeCleanUpStatus'(Bytes, OptOrMand, []).
+
+'dec_KmeCleanUpStatus'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{ready,0},{notReady,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeGetSystemDataReq
+%%================================
+
+'enc_KmeGetSystemDataReq'({'KmeGetSystemDataReq',Val}, TagIn) ->
+ 'enc_KmeGetSystemDataReq'(Val, TagIn);
+
+'enc_KmeGetSystemDataReq'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ systemData ->
+ case (case element(2,Val) of {_,Enumval1}->Enumval1;_->element(2,Val) end) of
+sysTimeStamp -> ?RT_BER:encode_enumerated(0,[{tag,128,0,'EXPLICIT',32}]);
+devTimeStamp -> ?RT_BER:encode_enumerated(1,[{tag,128,0,'EXPLICIT',32}]);
+featureList -> ?RT_BER:encode_enumerated(2,[{tag,128,0,'EXPLICIT',32}]);
+speedDial -> ?RT_BER:encode_enumerated(3,[{tag,128,0,'EXPLICIT',32}]);
+trunkGroup -> ?RT_BER:encode_enumerated(4,[{tag,128,0,'EXPLICIT',32}]);
+extensionGroup -> ?RT_BER:encode_enumerated(5,[{tag,128,0,'EXPLICIT',32}]);
+pickupGroup -> ?RT_BER:encode_enumerated(6,[{tag,128,0,'EXPLICIT',32}]);
+pagingGroup -> ?RT_BER:encode_enumerated(7,[{tag,128,0,'EXPLICIT',32}]);
+incomingGroup -> ?RT_BER:encode_enumerated(8,[{tag,128,0,'EXPLICIT',32}]);
+dayNightMode -> ?RT_BER:encode_enumerated(9,[{tag,128,0,'EXPLICIT',32}]);
+doorPhone -> ?RT_BER:encode_enumerated(10,[{tag,128,0,'EXPLICIT',32}]);
+vmGroup -> ?RT_BER:encode_enumerated(11,[{tag,128,0,'EXPLICIT',32}]);
+manufacturerName -> ?RT_BER:encode_enumerated(12,[{tag,128,0,'EXPLICIT',32}]);
+subdomainName -> ?RT_BER:encode_enumerated(13,[{tag,128,0,'EXPLICIT',32}]);
+softwareVersion -> ?RT_BER:encode_enumerated(14,[{tag,128,0,'EXPLICIT',32}]);
+ctiVersion -> ?RT_BER:encode_enumerated(15,[{tag,128,0,'EXPLICIT',32}]);
+regionCode -> ?RT_BER:encode_enumerated(16,[{tag,128,0,'EXPLICIT',32}]);
+systemTime -> ?RT_BER:encode_enumerated(17,[{tag,128,0,'EXPLICIT',32}]);
+numberOfMsgPort -> ?RT_BER:encode_enumerated(18,[{tag,128,0,'EXPLICIT',32}]);
+psGroup -> ?RT_BER:encode_enumerated(19,[{tag,128,0,'EXPLICIT',32}]);
+whoAmI -> ?RT_BER:encode_enumerated(20,[{tag,128,0,'EXPLICIT',32}]);
+broadcastGroup -> ?RT_BER:encode_enumerated(21,[{tag,128,0,'EXPLICIT',32}]);
+pbxType -> ?RT_BER:encode_enumerated(22,[{tag,128,0,'EXPLICIT',32}]);
+externalSensor -> ?RT_BER:encode_enumerated(23,[{tag,128,0,'EXPLICIT',32}]);
+svm -> ?RT_BER:encode_enumerated(24,[{tag,128,0,'EXPLICIT',32}]);
+pdn -> ?RT_BER:encode_enumerated(25,[{tag,128,0,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end;
+ deviceData ->
+ 'enc_KmeGetSystemDataReq_deviceData'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ trkExtGMember ->
+ 'enc_KmeGetSystemDataReq_trkExtGMember'(element(2,Val), [{tag,128,2,'IMPLICIT',32}]);
+ incomGMember ->
+ 'enc_KmeGetSystemDataReq_incomGMember'(element(2,Val), [{tag,128,3,'IMPLICIT',32}]);
+ deviceList ->
+ 'enc_KmeRequestedDevice'(element(2,Val), [{tag,128,4,'EXPLICIT',32}]);
+ vmGMember ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,5,'EXPLICIT',32}]);
+ speedDial ->
+ 'enc_KmeSpeedDialRequest'(element(2,Val), [{tag,128,6,'EXPLICIT',32}]);
+ broadcastGMembers ->
+ ?RT_BER:encode_integer([], element(2,Val), [{tag,128,7,'EXPLICIT',32}]);
+ guestCheckStatus ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,8,'IMPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+
+%%================================
+%% KmeGetSystemDataReq_deviceData
+%%================================
+'enc_KmeGetSystemDataReq_deviceData'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeGetSystemDataReq_deviceData_sysData'(?RT_BER:cindex(3,Val,sysData), [{tag,128,1,'EXPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeGetSystemDataReq_deviceData_sysData
+%%================================
+
+'enc_KmeGetSystemDataReq_deviceData_sysData'({'KmeGetSystemDataReq_deviceData_sysData',Val}, TagIn) ->
+ 'enc_KmeGetSystemDataReq_deviceData_sysData'(Val, TagIn);
+
+'enc_KmeGetSystemDataReq_deviceData_sysData'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ standardInfo ->
+ ?RT_BER:encode_bit_string([], element(2,Val), [{wakeUp,0},{remoteStatationLock,1},{callLogLock,2},{absentMessage,3},{forwardDnd,4},{cos,5},{phoneProperty,6},{assocIncomGroup,7},{messageWating,8},{assocExtGroup,9}], []);
+ extName ->
+ ?RT_BER:encode_null(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ fcoKey ->
+ ?RT_BER:encode_null(element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ sxdpMaster ->
+ ?RT_BER:encode_null(element(2,Val), [{tag,128,3,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeGetSystemDataReq_deviceData_sysData'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'standardInfo'
+ <<0:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_bit_string(Bytes1,[],[{wakeUp,0},{remoteStatationLock,1},{callLogLock,2},{absentMessage,3},{forwardDnd,4},{cos,5},{phoneProperty,6},{assocIncomGroup,7},{messageWating,8},{assocExtGroup,9}],[], no_length, mandatory),
+ {{standardInfo, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'extName'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_null(Bytes1,[{tag,128,1,'EXPLICIT',32}], mandatory),
+ {{extName, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'fcoKey'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_null(Bytes1,[{tag,128,2,'EXPLICIT',32}], mandatory),
+ {{fcoKey, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'sxdpMaster'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_null(Bytes1,[{tag,128,3,'EXPLICIT',32}], mandatory),
+ {{sxdpMaster, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeGetSystemDataReq_deviceData'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeGetSystemDataReq_deviceData_sysData'(Bytes3, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeGetSystemDataReq_deviceData', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+
+%%================================
+%% KmeGetSystemDataReq_trkExtGMember
+%%================================
+'enc_KmeGetSystemDataReq_trkExtGMember'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,groupNo), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,groupType) of {_,Enumval2}->Enumval2;_->?RT_BER:cindex(3,Val,groupType) end) of
+trunkGMembers -> ?RT_BER:encode_enumerated(0,[]);
+extGMembers -> ?RT_BER:encode_enumerated(1,[]);
+Enumval3 -> exit({error,{asn1, {enumerated_not_in_range,Enumval3}}})
+end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+'dec_KmeGetSystemDataReq_trkExtGMember'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{trunkGMembers,0},{extGMembers,1}],[], mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeGetSystemDataReq_trkExtGMember', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+
+%%================================
+%% KmeGetSystemDataReq_incomGMember
+%%================================
+'enc_KmeGetSystemDataReq_incomGMember'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,groupNo), []),
+
+ BytesSoFar = [EncBytes1],
+ LenSoFar = EncLen1,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+'dec_KmeGetSystemDataReq_incomGMember'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+ {Bytes4,Rb3} = ?RT_BER:restbytes2(RemBytes, Bytes3,noext),
+ {{'KmeGetSystemDataReq_incomGMember', Term1}, Bytes4, Rb1+Rb2+Rb3}.
+
+
+'dec_KmeGetSystemDataReq'(Bytes, OptOrMand) ->
+ 'dec_KmeGetSystemDataReq'(Bytes, OptOrMand, []).
+
+'dec_KmeGetSystemDataReq'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'systemData'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{sysTimeStamp,0},{devTimeStamp,1},{featureList,2},{speedDial,3},{trunkGroup,4},{extensionGroup,5},{pickupGroup,6},{pagingGroup,7},{incomingGroup,8},{dayNightMode,9},{doorPhone,10},{vmGroup,11},{manufacturerName,12},{subdomainName,13},{softwareVersion,14},{ctiVersion,15},{regionCode,16},{systemTime,17},{numberOfMsgPort,18},{psGroup,19},{whoAmI,20},{broadcastGroup,21},{pbxType,22},{externalSensor,23},{svm,24},{pdn,25}],[{tag,128,0,'EXPLICIT',32}], mandatory),
+ {{systemData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'deviceData'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq_deviceData'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{deviceData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'trkExtGMember'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq_trkExtGMember'(Bytes1, mandatory, [{tag,128,2,'IMPLICIT',32}]),
+ {{trkExtGMember, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'incomGMember'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq_incomGMember'(Bytes1, mandatory, [{tag,128,3,'IMPLICIT',32}]),
+ {{incomGMember, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'deviceList'
+ <<2:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeRequestedDevice'(Bytes1, mandatory, [{tag,128,4,'EXPLICIT',32}]),
+ {{deviceList, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'vmGMember'
+ <<2:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,5,'EXPLICIT',32}]),
+ {{vmGMember, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'speedDial'
+ <<2:2,_:1,6:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSpeedDialRequest'(Bytes1, mandatory, [{tag,128,6,'EXPLICIT',32}]),
+ {{speedDial, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'broadcastGMembers'
+ <<2:2,_:1,7:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_integer(Bytes1,[],[{tag,128,7,'EXPLICIT',32}], mandatory),
+ {{broadcastGMembers, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'guestCheckStatus'
+ <<2:2,_:1,8:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,8,'IMPLICIT',32}]),
+ {{guestCheckStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeGetSystemDataRsp
+%%================================
+'enc_KmeGetSystemDataRsp'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type GeneralizedTime OPTIONAL
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = case ?RT_BER:cindex(2,Val,timeStamp) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_generalized_time([], ?RT_BER:cindex(2,Val,timeStamp), [{tag,128,0,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 2 External KME-specific-types:KmeFeatureList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,featureList) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeFeatureList'(?RT_BER:cindex(3,Val,featureList), [{tag,128,1,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 3 External KME-specific-types:KmeSpeedDial OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,speedDial) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeSpeedDial'(?RT_BER:cindex(4,Val,speedDial), [{tag,128,2,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 4 External KME-specific-types:KmeExtTrkGroupList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,trunkGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeExtTrkGroupList'(?RT_BER:cindex(5,Val,trunkGroup), [{tag,128,3,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 5 External KME-specific-types:KmeExtTrkGroupList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes5,EncLen5} = case ?RT_BER:cindex(6,Val,extGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeExtTrkGroupList'(?RT_BER:cindex(6,Val,extGroup), [{tag,128,4,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 6 External KME-specific-types:KmePckPagGroupList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes6,EncLen6} = case ?RT_BER:cindex(7,Val,pickGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmePckPagGroupList'(?RT_BER:cindex(7,Val,pickGroup), [{tag,128,5,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 7 External KME-specific-types:KmePckPagGroupList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes7,EncLen7} = case ?RT_BER:cindex(8,Val,pagingGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmePckPagGroupList'(?RT_BER:cindex(8,Val,pagingGroup), [{tag,128,6,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 8 External KME-specific-types:KmeIncomingGroupList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes8,EncLen8} = case ?RT_BER:cindex(9,Val,incomingGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeIncomingGroupList'(?RT_BER:cindex(9,Val,incomingGroup), [{tag,128,7,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 9 External KME-specific-types:KmeDayNightMode OPTIONAL
+%%-------------------------------------------------
+ {EncBytes9,EncLen9} = case ?RT_BER:cindex(10,Val,dayNightMode) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeDayNightMode'(?RT_BER:cindex(10,Val,dayNightMode), [{tag,128,8,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 10 External KME-specific-types:KmeWakeUpInfo OPTIONAL
+%%-------------------------------------------------
+ {EncBytes10,EncLen10} = case ?RT_BER:cindex(11,Val,wakeUp) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeWakeUpInfo'(?RT_BER:cindex(11,Val,wakeUp), [{tag,128,9,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 11 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {EncBytes11,EncLen11} = case ?RT_BER:cindex(12,Val,remoteLock) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ case (case ?RT_BER:cindex(12,Val,remoteLock) of {_,Enumval2}->Enumval2;_->?RT_BER:cindex(12,Val,remoteLock) end) of
+lock -> ?RT_BER:encode_enumerated(0,[{tag,128,10,'EXPLICIT',32}]);
+unlock -> ?RT_BER:encode_enumerated(1,[{tag,128,10,'EXPLICIT',32}]);
+Enumval3 -> exit({error,{asn1, {enumerated_not_in_range,Enumval3}}})
+end
+ end,
+
+%%-------------------------------------------------
+%% attribute number 12 External KME-specific-types:KmeAbsentMessage OPTIONAL
+%%-------------------------------------------------
+ {EncBytes12,EncLen12} = case ?RT_BER:cindex(13,Val,callLogLock) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeAbsentMessage'(?RT_BER:cindex(13,Val,callLogLock), [{tag,128,12,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 13 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {EncBytes13,EncLen13} = case ?RT_BER:cindex(14,Val,forwardDnd) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ case (case ?RT_BER:cindex(14,Val,forwardDnd) of {_,Enumval4}->Enumval4;_->?RT_BER:cindex(14,Val,forwardDnd) end) of
+lock -> ?RT_BER:encode_enumerated(0,[{tag,128,11,'EXPLICIT',32}]);
+unlock -> ?RT_BER:encode_enumerated(1,[{tag,128,11,'EXPLICIT',32}]);
+Enumval5 -> exit({error,{asn1, {enumerated_not_in_range,Enumval5}}})
+end
+ end,
+
+%%-------------------------------------------------
+%% attribute number 14 External CSTA-device-feature-types:ForwardList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes14,EncLen14} = case ?RT_BER:cindex(15,Val,absentMessage) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-feature-types':'enc_ForwardList'(?RT_BER:cindex(15,Val,absentMessage), [{tag,128,13,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 15 External KME-specific-types:KmeTrkMembers OPTIONAL
+%%-------------------------------------------------
+ {EncBytes15,EncLen15} = case ?RT_BER:cindex(16,Val,trkGMembers) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeTrkMembers'(?RT_BER:cindex(16,Val,trkGMembers), [{tag,128,14,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 16 External KME-specific-types:KmeExtMembers OPTIONAL
+%%-------------------------------------------------
+ {EncBytes16,EncLen16} = case ?RT_BER:cindex(17,Val,extGMembers) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeExtMembers'(?RT_BER:cindex(17,Val,extGMembers), [{tag,128,15,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 17 External KME-specific-types:KmeIcmGrpMembers OPTIONAL
+%%-------------------------------------------------
+ {EncBytes17,EncLen17} = case ?RT_BER:cindex(18,Val,incomGMembers) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeIcmGrpMembers'(?RT_BER:cindex(18,Val,incomGMembers), [{tag,128,16,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 18 External KME-specific-types:KmeDoorPhone OPTIONAL
+%%-------------------------------------------------
+ {EncBytes18,EncLen18} = case ?RT_BER:cindex(19,Val,doorPhone) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeDoorPhone'(?RT_BER:cindex(19,Val,doorPhone), [{tag,128,17,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 19 External KME-specific-types:KmeVmGroupList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes19,EncLen19} = case ?RT_BER:cindex(20,Val,vmGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeVmGroupList'(?RT_BER:cindex(20,Val,vmGroup), [{tag,128,18,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 20 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes20,EncLen20} = case ?RT_BER:cindex(21,Val,manufacturerName) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(21,Val,manufacturerName), 22, [{tag,128,19,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 21 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes21,EncLen21} = case ?RT_BER:cindex(22,Val,subdomainName) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(22,Val,subdomainName), 22, [{tag,128,20,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 22 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes22,EncLen22} = case ?RT_BER:cindex(23,Val,softwareVersion) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(23,Val,softwareVersion), 22, [{tag,128,21,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 23 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes23,EncLen23} = case ?RT_BER:cindex(24,Val,ctiVersion) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(24,Val,ctiVersion), 22, [{tag,128,22,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 24 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes24,EncLen24} = case ?RT_BER:cindex(25,Val,regionCode) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(25,Val,regionCode), 22, [{tag,128,23,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 25 with type GeneralizedTime OPTIONAL
+%%-------------------------------------------------
+ {EncBytes25,EncLen25} = case ?RT_BER:cindex(26,Val,systemTime) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_generalized_time([], ?RT_BER:cindex(26,Val,systemTime), [{tag,128,24,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 26 External KME-specific-types:NumberOfMsgPort OPTIONAL
+%%-------------------------------------------------
+ {EncBytes26,EncLen26} = case ?RT_BER:cindex(27,Val,numberOfMsgPort) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_NumberOfMsgPort'(?RT_BER:cindex(27,Val,numberOfMsgPort), [{tag,128,25,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 27 External KME-specific-types:KmePsGroupList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes27,EncLen27} = case ?RT_BER:cindex(28,Val,psGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmePsGroupList'(?RT_BER:cindex(28,Val,psGroup), [{tag,128,26,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 28 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes28,EncLen28} = case ?RT_BER:cindex(29,Val,youAre) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(29,Val,youAre), [{tag,128,27,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 29 External KME-specific-types:KmeSvmList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes29,EncLen29} = case ?RT_BER:cindex(30,Val,svm) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeSvmList'(?RT_BER:cindex(30,Val,svm), [{tag,128,28,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 30 External KME-specific-types:KmePdnGMembers OPTIONAL
+%%-------------------------------------------------
+ {EncBytes30,EncLen30} = case ?RT_BER:cindex(31,Val,pdn) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmePdnGMembers'(?RT_BER:cindex(31,Val,pdn), [{tag,128,29,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 31 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes31,EncLen31} = case ?RT_BER:cindex(32,Val,cos) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(32,Val,cos), [{tag,128,34,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 32 External KME-specific-types:KmePhoneProperty OPTIONAL
+%%-------------------------------------------------
+ {EncBytes32,EncLen32} = case ?RT_BER:cindex(33,Val,phoneProperty) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmePhoneProperty'(?RT_BER:cindex(33,Val,phoneProperty), [{tag,128,35,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 33 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {EncBytes33,EncLen33} = case ?RT_BER:cindex(34,Val,assocIncomGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_bit_string([], ?RT_BER:cindex(34,Val,assocIncomGroup), [{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}], [{tag,128,36,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 34 with type SEQUENCE OF OPTIONAL
+%%-------------------------------------------------
+ {EncBytes34,EncLen34} = case ?RT_BER:cindex(35,Val,messageWaiting) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeGetSystemDataRsp_messageWaiting'(?RT_BER:cindex(35,Val,messageWaiting), [{tag,128,37,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 35 External KME-specific-types:KmeDeviceStateList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes35,EncLen35} = case ?RT_BER:cindex(36,Val,deviceList) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeDeviceStateList'(?RT_BER:cindex(36,Val,deviceList), [{tag,128,38,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 36 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes36,EncLen36} = case ?RT_BER:cindex(37,Val,assocExtGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(37,Val,assocExtGroup), [{tag,128,39,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 37 External KME-specific-types:KmeIcmGrpMembers OPTIONAL
+%%-------------------------------------------------
+ {EncBytes37,EncLen37} = case ?RT_BER:cindex(38,Val,vmGMembers) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeIcmGrpMembers'(?RT_BER:cindex(38,Val,vmGMembers), [{tag,128,40,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 38 External KME-specific-types:KmeExtName OPTIONAL
+%%-------------------------------------------------
+ {EncBytes38,EncLen38} = case ?RT_BER:cindex(39,Val,extName) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeExtName'(?RT_BER:cindex(39,Val,extName), [{tag,128,41,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 39 External KME-specific-types:KmeBroadcastGroupList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes39,EncLen39} = case ?RT_BER:cindex(40,Val,broadcastGroup) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeBroadcastGroupList'(?RT_BER:cindex(40,Val,broadcastGroup), [{tag,128,42,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 40 External KME-specific-types:KmeBroadcastGrpMembers OPTIONAL
+%%-------------------------------------------------
+ {EncBytes40,EncLen40} = case ?RT_BER:cindex(41,Val,broadcastGMembers) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeBroadcastGrpMembers'(?RT_BER:cindex(41,Val,broadcastGMembers), [{tag,128,43,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 41 External KME-specific-types:KmeFcoKeyList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes41,EncLen41} = case ?RT_BER:cindex(42,Val,fcoKeyList) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeFcoKeyList'(?RT_BER:cindex(42,Val,fcoKeyList), [{tag,128,44,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 42 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes42,EncLen42} = case ?RT_BER:cindex(43,Val,sxdpMaster) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(43,Val,sxdpMaster), [{tag,128,45,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 43 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes43,EncLen43} = case ?RT_BER:cindex(44,Val,pbxType) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(44,Val,pbxType), [{tag,128,46,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 44 External KME-specific-types:KmeExternalSensorList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes44,EncLen44} = case ?RT_BER:cindex(45,Val,externalSensor) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeExternalSensorList'(?RT_BER:cindex(45,Val,externalSensor), [{tag,128,47,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 45 External KME-specific-types:KmeDeviceDataList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes45,EncLen45} = case ?RT_BER:cindex(46,Val,deviceDataList) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeDeviceDataList'(?RT_BER:cindex(46,Val,deviceDataList), [{tag,128,48,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 46 External KME-specific-types:KmeCheckStatusList OPTIONAL
+%%-------------------------------------------------
+ {EncBytes46,EncLen46} = case ?RT_BER:cindex(47,Val,guestCheckStatus) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeCheckStatusList'(?RT_BER:cindex(47,Val,guestCheckStatus), [{tag,128,49,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4, EncBytes5, EncBytes6, EncBytes7, EncBytes8, EncBytes9, EncBytes10, EncBytes11, EncBytes12, EncBytes13, EncBytes14, EncBytes15, EncBytes16, EncBytes17, EncBytes18, EncBytes19, EncBytes20, EncBytes21, EncBytes22, EncBytes23, EncBytes24, EncBytes25, EncBytes26, EncBytes27, EncBytes28, EncBytes29, EncBytes30, EncBytes31, EncBytes32, EncBytes33, EncBytes34, EncBytes35, EncBytes36, EncBytes37, EncBytes38, EncBytes39, EncBytes40, EncBytes41, EncBytes42, EncBytes43, EncBytes44, EncBytes45, EncBytes46],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4 + EncLen5 + EncLen6 + EncLen7 + EncLen8 + EncLen9 + EncLen10 + EncLen11 + EncLen12 + EncLen13 + EncLen14 + EncLen15 + EncLen16 + EncLen17 + EncLen18 + EncLen19 + EncLen20 + EncLen21 + EncLen22 + EncLen23 + EncLen24 + EncLen25 + EncLen26 + EncLen27 + EncLen28 + EncLen29 + EncLen30 + EncLen31 + EncLen32 + EncLen33 + EncLen34 + EncLen35 + EncLen36 + EncLen37 + EncLen38 + EncLen39 + EncLen40 + EncLen41 + EncLen42 + EncLen43 + EncLen44 + EncLen45 + EncLen46,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeGetSystemDataRsp_messageWaiting
+%%================================
+
+'enc_KmeGetSystemDataRsp_messageWaiting'({'KmeGetSystemDataRsp_messageWaiting',Val}, TagIn) ->
+ 'enc_KmeGetSystemDataRsp_messageWaiting'(Val, TagIn);
+
+'enc_KmeGetSystemDataRsp_messageWaiting'(Val, TagIn) ->
+ {EncBytes,EncLen} = 'enc_KmeGetSystemDataRsp_messageWaiting_components'(Val,[],0),
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], EncBytes, EncLen).
+
+'enc_KmeGetSystemDataRsp_messageWaiting_components'([], AccBytes, AccLen) ->
+ {lists:reverse(AccBytes),AccLen};
+
+'enc_KmeGetSystemDataRsp_messageWaiting_components'([H|T],AccBytes, AccLen) ->
+ {EncBytes,EncLen} = 'CSTA-device-identifiers':'enc_DeviceID'(H, []),
+ 'enc_KmeGetSystemDataRsp_messageWaiting_components'(T,[EncBytes|AccBytes], AccLen + EncLen).
+
+'dec_KmeGetSystemDataRsp_messageWaiting'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+ ?RT_BER:decode_components(Rb1, Len, Bytes1, fun 'CSTA-device-identifiers':'dec_DeviceID'/3, [], []).
+
+
+
+
+'dec_KmeGetSystemDataRsp'(Bytes, OptOrMand) ->
+ 'dec_KmeGetSystemDataRsp'(Bytes, OptOrMand, []).
+
+'dec_KmeGetSystemDataRsp'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type GeneralizedTime OPTIONAL
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = case Bytes2 of
+<<2:2,_:1,0:5,_/binary>> ->
+?RT_BER:decode_generalized_time(Bytes2,[],[{tag,128,0,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes2, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 2 External KME-specific-types:KmeFeatureList OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<2:2,_:1,1:5,_/binary>> ->
+'dec_KmeFeatureList'(Bytes3, opt_or_default, [{tag,128,1,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 External KME-specific-types:KmeSpeedDial OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<2:2,_:1,2:5,_/binary>> ->
+'dec_KmeSpeedDial'(Bytes4, opt_or_default, [{tag,128,2,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 4 External KME-specific-types:KmeExtTrkGroupList OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<2:2,_:1,3:5,_/binary>> ->
+'dec_KmeExtTrkGroupList'(Bytes5, opt_or_default, [{tag,128,3,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 5 External KME-specific-types:KmeExtTrkGroupList OPTIONAL
+%%-------------------------------------------------
+ {Term5,Bytes7,Rb6} = case Bytes6 of
+<<2:2,_:1,4:5,_/binary>> ->
+'dec_KmeExtTrkGroupList'(Bytes6, opt_or_default, [{tag,128,4,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes6, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 6 External KME-specific-types:KmePckPagGroupList OPTIONAL
+%%-------------------------------------------------
+ {Term6,Bytes8,Rb7} = case Bytes7 of
+<<2:2,_:1,5:5,_/binary>> ->
+'dec_KmePckPagGroupList'(Bytes7, opt_or_default, [{tag,128,5,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes7, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 7 External KME-specific-types:KmePckPagGroupList OPTIONAL
+%%-------------------------------------------------
+ {Term7,Bytes9,Rb8} = case Bytes8 of
+<<2:2,_:1,6:5,_/binary>> ->
+'dec_KmePckPagGroupList'(Bytes8, opt_or_default, [{tag,128,6,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes8, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 8 External KME-specific-types:KmeIncomingGroupList OPTIONAL
+%%-------------------------------------------------
+ {Term8,Bytes10,Rb9} = case Bytes9 of
+<<2:2,_:1,7:5,_/binary>> ->
+'dec_KmeIncomingGroupList'(Bytes9, opt_or_default, [{tag,128,7,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes9, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 9 External KME-specific-types:KmeDayNightMode OPTIONAL
+%%-------------------------------------------------
+ {Term9,Bytes11,Rb10} = case Bytes10 of
+<<2:2,_:1,8:5,_/binary>> ->
+'dec_KmeDayNightMode'(Bytes10, opt_or_default, [{tag,128,8,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes10, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 10 External KME-specific-types:KmeWakeUpInfo OPTIONAL
+%%-------------------------------------------------
+ {Term10,Bytes12,Rb11} = case Bytes11 of
+<<2:2,_:1,9:5,_/binary>> ->
+'dec_KmeWakeUpInfo'(Bytes11, opt_or_default, [{tag,128,9,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes11, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 11 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {Term11,Bytes13,Rb12} = case Bytes12 of
+<<2:2,_:1,10:5,_/binary>> ->
+?RT_BER:decode_enumerated(Bytes12,[],[{lock,0},{unlock,1}],[{tag,128,10,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes12, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 12 External KME-specific-types:KmeAbsentMessage OPTIONAL
+%%-------------------------------------------------
+ {Term12,Bytes14,Rb13} = case Bytes13 of
+<<2:2,_:1,12:5,_/binary>> ->
+'dec_KmeAbsentMessage'(Bytes13, opt_or_default, [{tag,128,12,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes13, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 13 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {Term13,Bytes15,Rb14} = case Bytes14 of
+<<2:2,_:1,11:5,_/binary>> ->
+?RT_BER:decode_enumerated(Bytes14,[],[{lock,0},{unlock,1}],[{tag,128,11,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes14, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 14 External CSTA-device-feature-types:ForwardList OPTIONAL
+%%-------------------------------------------------
+ {Term14,Bytes16,Rb15} = case Bytes15 of
+<<2:2,_:1,13:5,_/binary>> ->
+'CSTA-device-feature-types':'dec_ForwardList'(Bytes15, opt_or_default, [{tag,128,13,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes15, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 15 External KME-specific-types:KmeTrkMembers OPTIONAL
+%%-------------------------------------------------
+ {Term15,Bytes17,Rb16} = case Bytes16 of
+<<2:2,_:1,14:5,_/binary>> ->
+'dec_KmeTrkMembers'(Bytes16, opt_or_default, [{tag,128,14,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes16, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 16 External KME-specific-types:KmeExtMembers OPTIONAL
+%%-------------------------------------------------
+ {Term16,Bytes18,Rb17} = case Bytes17 of
+<<2:2,_:1,15:5,_/binary>> ->
+'dec_KmeExtMembers'(Bytes17, opt_or_default, [{tag,128,15,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes17, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 17 External KME-specific-types:KmeIcmGrpMembers OPTIONAL
+%%-------------------------------------------------
+ {Term17,Bytes19,Rb18} = case Bytes18 of
+<<2:2,_:1,16:5,_/binary>> ->
+'dec_KmeIcmGrpMembers'(Bytes18, opt_or_default, [{tag,128,16,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes18, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 18 External KME-specific-types:KmeDoorPhone OPTIONAL
+%%-------------------------------------------------
+ {Term18,Bytes20,Rb19} = case Bytes19 of
+<<2:2,_:1,17:5,_/binary>> ->
+'dec_KmeDoorPhone'(Bytes19, opt_or_default, [{tag,128,17,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes19, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 19 External KME-specific-types:KmeVmGroupList OPTIONAL
+%%-------------------------------------------------
+ {Term19,Bytes21,Rb20} = case Bytes20 of
+<<2:2,_:1,18:5,_/binary>> ->
+'dec_KmeVmGroupList'(Bytes20, opt_or_default, [{tag,128,18,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes20, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 20 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term20,Bytes22,Rb21} = case Bytes21 of
+<<2:2,_:1,19:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes21,{0,64},22,[{tag,128,19,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes21, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 21 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term21,Bytes23,Rb22} = case Bytes22 of
+<<2:2,_:1,20:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes22,{0,20},22,[{tag,128,20,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes22, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 22 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term22,Bytes24,Rb23} = case Bytes23 of
+<<2:2,_:1,21:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes23,{0,32},22,[{tag,128,21,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes23, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 23 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term23,Bytes25,Rb24} = case Bytes24 of
+<<2:2,_:1,22:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes24,{0,32},22,[{tag,128,22,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes24, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 24 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term24,Bytes26,Rb25} = case Bytes25 of
+<<2:2,_:1,23:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes25,{0,32},22,[{tag,128,23,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes25, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 25 with type GeneralizedTime OPTIONAL
+%%-------------------------------------------------
+ {Term25,Bytes27,Rb26} = case Bytes26 of
+<<2:2,_:1,24:5,_/binary>> ->
+?RT_BER:decode_generalized_time(Bytes26,[],[{tag,128,24,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes26, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 26 External KME-specific-types:NumberOfMsgPort OPTIONAL
+%%-------------------------------------------------
+ {Term26,Bytes28,Rb27} = case Bytes27 of
+<<2:2,_:1,25:5,_/binary>> ->
+'dec_NumberOfMsgPort'(Bytes27, opt_or_default, [{tag,128,25,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes27, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 27 External KME-specific-types:KmePsGroupList OPTIONAL
+%%-------------------------------------------------
+ {Term27,Bytes29,Rb28} = case Bytes28 of
+<<2:2,_:1,26:5,_/binary>> ->
+'dec_KmePsGroupList'(Bytes28, opt_or_default, [{tag,128,26,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes28, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 28 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {Term28,Bytes30,Rb29} = case Bytes29 of
+<<2:2,_:1,27:5,_/binary>> ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes29, opt_or_default, [{tag,128,27,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes29, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 29 External KME-specific-types:KmeSvmList OPTIONAL
+%%-------------------------------------------------
+ {Term29,Bytes31,Rb30} = case Bytes30 of
+<<2:2,_:1,28:5,_/binary>> ->
+'dec_KmeSvmList'(Bytes30, opt_or_default, [{tag,128,28,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes30, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 30 External KME-specific-types:KmePdnGMembers OPTIONAL
+%%-------------------------------------------------
+ {Term30,Bytes32,Rb31} = case Bytes31 of
+<<2:2,_:1,29:5,_/binary>> ->
+'dec_KmePdnGMembers'(Bytes31, opt_or_default, [{tag,128,29,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes31, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 31 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term31,Bytes33,Rb32} = case Bytes32 of
+<<2:2,_:1,31:5,34,_/binary>> ->
+?RT_BER:decode_integer(Bytes32,[],[{tag,128,34,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes32, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 32 External KME-specific-types:KmePhoneProperty OPTIONAL
+%%-------------------------------------------------
+ {Term32,Bytes34,Rb33} = case Bytes33 of
+<<2:2,_:1,31:5,35,_/binary>> ->
+'dec_KmePhoneProperty'(Bytes33, opt_or_default, [{tag,128,35,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes33, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 33 with type BIT STRING OPTIONAL
+%%-------------------------------------------------
+ {Term33,Bytes35,Rb34} = case Bytes34 of
+<<2:2,_:1,31:5,36,_/binary>> ->
+?RT_BER:decode_bit_string(Bytes34,[],[{one,0},{two,1},{three,2},{four,3},{five,4},{six,5},{seven,6},{eight,7},{nine,8},{ten,9},{eleven,10},{twelve,11},{thirteen,12},{fourteen,13},{fifteen,14},{sixteen,15},{seventeen,16},{eighteen,17},{nineteen,18},{twenty,19},{twentyOne,20},{twentyTwo,21},{twentyThree,22},{twentyFour,23},{twentyFive,24},{twentySix,25},{twentySeven,26},{twentyEight,27},{twentyNine,28},{thirty,29},{thirtyOne,30},{thirtyTwo,31},{thirtyThree,32},{thirtyFour,33},{thirtyFive,34},{thirtySix,35},{thirtySeven,36},{thirtyEight,37},{thirtyNine,38},{fourty,39},{fourtyOne,40},{fourtyTwo,41},{fourtyThree,42},{fourtyFour,43},{fourtyFive,44},{fourtySix,45},{fourtySeven,46},{fourtyEight,47},{fourtyNine,48},{fifty,49},{fiftyOne,50},{fiftyTwo,51},{fiftyThree,52},{fiftyFour,53},{fiftyFive,54},{fiftySix,55},{fiftySeven,56},{fiftyEight,57},{fiftyNine,58},{sixty,59},{sixtyOne,60},{sixtyTwo,61},{sixtyThree,62},{sixtyFour,63},{sixtyFive,64},{sixtySix,65},{sixtySeven,66},{sixtyEight,67},{sixtyNine,68},{seventy,69},{seventyOne,70},{seventyTwo,71},{seventyThree,72},{seventyFour,73},{seventyFive,74},{seventySix,75},{seventySeven,76},{seventyEight,77},{seventyNine,78},{eighty,79},{eightyOne,80},{eightyTwo,81},{eightyThree,82},{eightyFour,83},{eightyFive,84},{eightySix,85},{eightySeven,86},{eightyEight,87},{eightyNine,88},{ninety,89},{ninetyOne,90},{ninetyTwo,91},{ninetyThree,92},{ninetyFour,93},{ninetyFive,94},{ninetySix,95},{ninetySeven,96},{ninetyEight,97},{ninetyNine,98},{oneHundred,99},{oneHundredOne,100},{oneHundredTwo,101},{oneHundredThree,102},{oneHundredFour,103},{oneHundredFive,104},{oneHundredSix,105},{oneHundredSeven,106},{oneHundredEitht,107},{oneHundredNine,108},{oneHundredTen,109},{oneHundredEleven,110},{oneHundredTwelve,111},{oneHundredThirteen,112},{oneHundredFourteen,113},{oneHundredFifteen,114},{oneHundredSixteen,115},{oneHundredSeventeen,116},{oneHundredEithteen,117},{oneHundredNineteen,118},{oneHundredTwenty,119},{oneHundredTwentyOne,120},{oneHundredTwentyTwo,121},{oneHundredTwentyThree,122},{oneHundredTwentyFour,123},{oneHundredTwentyFive,124},{oneHundredTwentySix,125},{oneHundredTwentySeven,126},{oneHundredTwentyEight,127}],[{tag,128,36,'EXPLICIT',32}], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes34, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 34 with type SEQUENCE OF OPTIONAL
+%%-------------------------------------------------
+ {Term34,Bytes36,Rb35} = case Bytes35 of
+<<2:2,_:1,31:5,37,_/binary>> ->
+'dec_KmeGetSystemDataRsp_messageWaiting'(Bytes35, opt_or_default, [{tag,128,37,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes35, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 35 External KME-specific-types:KmeDeviceStateList OPTIONAL
+%%-------------------------------------------------
+ {Term35,Bytes37,Rb36} = case Bytes36 of
+<<2:2,_:1,31:5,38,_/binary>> ->
+'dec_KmeDeviceStateList'(Bytes36, opt_or_default, [{tag,128,38,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes36, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 36 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term36,Bytes38,Rb37} = case Bytes37 of
+<<2:2,_:1,31:5,39,_/binary>> ->
+?RT_BER:decode_integer(Bytes37,[],[{tag,128,39,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes37, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 37 External KME-specific-types:KmeIcmGrpMembers OPTIONAL
+%%-------------------------------------------------
+ {Term37,Bytes39,Rb38} = case Bytes38 of
+<<2:2,_:1,31:5,40,_/binary>> ->
+'dec_KmeIcmGrpMembers'(Bytes38, opt_or_default, [{tag,128,40,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes38, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 38 External KME-specific-types:KmeExtName OPTIONAL
+%%-------------------------------------------------
+ {Term38,Bytes40,Rb39} = case Bytes39 of
+<<2:2,_:1,31:5,41,_/binary>> ->
+'dec_KmeExtName'(Bytes39, opt_or_default, [{tag,128,41,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes39, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 39 External KME-specific-types:KmeBroadcastGroupList OPTIONAL
+%%-------------------------------------------------
+ {Term39,Bytes41,Rb40} = case Bytes40 of
+<<2:2,_:1,31:5,42,_/binary>> ->
+'dec_KmeBroadcastGroupList'(Bytes40, opt_or_default, [{tag,128,42,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes40, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 40 External KME-specific-types:KmeBroadcastGrpMembers OPTIONAL
+%%-------------------------------------------------
+ {Term40,Bytes42,Rb41} = case Bytes41 of
+<<2:2,_:1,31:5,43,_/binary>> ->
+'dec_KmeBroadcastGrpMembers'(Bytes41, opt_or_default, [{tag,128,43,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes41, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 41 External KME-specific-types:KmeFcoKeyList OPTIONAL
+%%-------------------------------------------------
+ {Term41,Bytes43,Rb42} = case Bytes42 of
+<<2:2,_:1,31:5,44,_/binary>> ->
+'dec_KmeFcoKeyList'(Bytes42, opt_or_default, [{tag,128,44,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes42, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 42 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {Term42,Bytes44,Rb43} = case Bytes43 of
+<<2:2,_:1,31:5,45,_/binary>> ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes43, opt_or_default, [{tag,128,45,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes43, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 43 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term43,Bytes45,Rb44} = case Bytes44 of
+<<2:2,_:1,31:5,46,_/binary>> ->
+?RT_BER:decode_integer(Bytes44,[],[{tag,128,46,'EXPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes44, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 44 External KME-specific-types:KmeExternalSensorList OPTIONAL
+%%-------------------------------------------------
+ {Term44,Bytes46,Rb45} = case Bytes45 of
+<<2:2,_:1,31:5,47,_/binary>> ->
+'dec_KmeExternalSensorList'(Bytes45, opt_or_default, [{tag,128,47,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes45, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 45 External KME-specific-types:KmeDeviceDataList OPTIONAL
+%%-------------------------------------------------
+ {Term45,Bytes47,Rb46} = case Bytes46 of
+<<2:2,_:1,31:5,48,_/binary>> ->
+'dec_KmeDeviceDataList'(Bytes46, opt_or_default, [{tag,128,48,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes46, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 46 External KME-specific-types:KmeCheckStatusList OPTIONAL
+%%-------------------------------------------------
+ {Term46,Bytes48,Rb47} = case Bytes47 of
+<<2:2,_:1,31:5,49,_/binary>> ->
+'dec_KmeCheckStatusList'(Bytes47, opt_or_default, [{tag,128,49,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes47, 0 }
+end,
+
+ {Bytes49,Rb48} = ?RT_BER:restbytes2(RemBytes, Bytes48,noext),
+ {{'KmeGetSystemDataRsp', Term1, Term2, Term3, Term4, Term5, Term6, Term7, Term8, Term9, Term10, Term11, Term12, Term13, Term14, Term15, Term16, Term17, Term18, Term19, Term20, Term21, Term22, Term23, Term24, Term25, Term26, Term27, Term28, Term29, Term30, Term31, Term32, Term33, Term34, Term35, Term36, Term37, Term38, Term39, Term40, Term41, Term42, Term43, Term44, Term45, Term46}, Bytes49, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6+Rb7+Rb8+Rb9+Rb10+Rb11+Rb12+Rb13+Rb14+Rb15+Rb16+Rb17+Rb18+Rb19+Rb20+Rb21+Rb22+Rb23+Rb24+Rb25+Rb26+Rb27+Rb28+Rb29+Rb30+Rb31+Rb32+Rb33+Rb34+Rb35+Rb36+Rb37+Rb38+Rb39+Rb40+Rb41+Rb42+Rb43+Rb44+Rb45+Rb46+Rb47+Rb48}.
+
+
+%%================================
+%% KmeGetSystemData
+%%================================
+
+'enc_KmeGetSystemData'({'KmeGetSystemData',Val}, TagIn) ->
+ 'enc_KmeGetSystemData'(Val, TagIn);
+
+'enc_KmeGetSystemData'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ request ->
+ 'enc_KmeGetSystemDataReq'(element(2,Val), []);
+ result ->
+ 'enc_KmeGetSystemDataRsp'(element(2,Val), []);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeGetSystemData'(Bytes, OptOrMand) ->
+ 'dec_KmeGetSystemData'(Bytes, OptOrMand, []).
+
+'dec_KmeGetSystemData'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'request'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ <<2:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ <<2:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ <<2:2,_:1,6:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ <<2:2,_:1,7:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ <<2:2,_:1,8:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataReq'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'result'
+ <<0:2,_:1,16:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataRsp'(Bytes1, mandatory, []),
+ {{result, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeSetSystemData
+%%================================
+
+'enc_KmeSetSystemData'({'KmeSetSystemData',Val}, TagIn) ->
+ 'enc_KmeSetSystemData'(Val, TagIn);
+
+'enc_KmeSetSystemData'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ systemData ->
+ 'enc_KmeSetSystemData_systemData'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ deviceData ->
+ 'enc_KmeSetSystemData_deviceData'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ acdQueue ->
+ 'enc_KmeSetSystemData_acdQueue'(element(2,Val), [{tag,128,3,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+
+%%================================
+%% KmeSetSystemData_systemData
+%%================================
+
+'enc_KmeSetSystemData_systemData'({'KmeSetSystemData_systemData',Val}, TagIn) ->
+ 'enc_KmeSetSystemData_systemData'(Val, TagIn);
+
+'enc_KmeSetSystemData_systemData'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ speedDial ->
+ 'enc_KmeSpeedDial'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ dayNightMode ->
+ 'enc_KmeDayNightMode'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ time ->
+ ?RT_BER:encode_generalized_time([], element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ extNo ->
+ 'enc_KmeChangeExtNo'(element(2,Val), [{tag,128,3,'EXPLICIT',32}]);
+ name ->
+ 'enc_KmeChangeName'(element(2,Val), [{tag,128,4,'EXPLICIT',32}]);
+ subdomainName ->
+ ?RT_BER:encode_restricted_string([], element(2,Val), 22, [{tag,128,5,'EXPLICIT',32}]);
+ tenantSpeedDial ->
+ 'enc_KmeTenantSpeedDial'(element(2,Val), [{tag,128,6,'EXPLICIT',32}]);
+ distributionMethod ->
+ 'enc_KmeDistributionMethod'(element(2,Val), [{tag,128,7,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeSetSystemData_systemData'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'speedDial'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSpeedDial'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{speedDial, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'dayNightMode'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDayNightMode'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{dayNightMode, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'time'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_generalized_time(Bytes1,[],[{tag,128,2,'EXPLICIT',32}], no_length, mandatory),
+ {{time, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'extNo'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeChangeExtNo'(Bytes1, mandatory, [{tag,128,3,'EXPLICIT',32}]),
+ {{extNo, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'name'
+ <<2:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeChangeName'(Bytes1, mandatory, [{tag,128,4,'EXPLICIT',32}]),
+ {{name, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'subdomainName'
+ <<2:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_restricted_string(Bytes1,{0,20},22,[{tag,128,5,'EXPLICIT',32}], no_length, mandatory),
+ {{subdomainName, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'tenantSpeedDial'
+ <<2:2,_:1,6:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeTenantSpeedDial'(Bytes1, mandatory, [{tag,128,6,'EXPLICIT',32}]),
+ {{tenantSpeedDial, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'distributionMethod'
+ <<2:2,_:1,7:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDistributionMethod'(Bytes1, mandatory, [{tag,128,7,'EXPLICIT',32}]),
+ {{distributionMethod, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+
+%%================================
+%% KmeSetSystemData_deviceData
+%%================================
+'enc_KmeSetSystemData_deviceData'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeSetSystemData_deviceData_sysData'(?RT_BER:cindex(3,Val,sysData), [{tag,128,2,'EXPLICIT',32}]),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeSetSystemData_deviceData_sysData
+%%================================
+
+'enc_KmeSetSystemData_deviceData_sysData'({'KmeSetSystemData_deviceData_sysData',Val}, TagIn) ->
+ 'enc_KmeSetSystemData_deviceData_sysData'(Val, TagIn);
+
+'enc_KmeSetSystemData_deviceData_sysData'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ wakeUp ->
+ 'enc_KmeWakeUpInfo'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ remoteLock ->
+ case (case element(2,Val) of {_,Enumval1}->Enumval1;_->element(2,Val) end) of
+lock -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+unlock -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end;
+ forwardDnd ->
+ 'enc_KmeSetForwardInfo'(element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ absentMessage ->
+ 'enc_KmeAbsentMessage'(element(2,Val), [{tag,128,3,'EXPLICIT',32}]);
+ passwordClear ->
+ ?RT_BER:encode_null(element(2,Val), [{tag,128,4,'EXPLICIT',32}]);
+ extNumber ->
+ ?RT_BER:encode_restricted_string([], element(2,Val), 22, [{tag,128,5,'EXPLICIT',32}]);
+ extName ->
+ 'enc_KmeExtName'(element(2,Val), [{tag,128,6,'EXPLICIT',32}]);
+ cos ->
+ ?RT_BER:encode_integer([], element(2,Val), [{tag,128,7,'EXPLICIT',32}]);
+ joinGroup ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,8,'EXPLICIT',32}]);
+ leaveGroup ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,9,'EXPLICIT',32}]);
+ inService ->
+ ?RT_BER:encode_boolean(element(2,Val), [{tag,128,10,'EXPLICIT',32}]);
+ fcoKey ->
+ 'enc_KmeFcoKeyList'(element(2,Val), [{tag,128,11,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeSetSystemData_deviceData_sysData'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'wakeUp'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeWakeUpInfo'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{wakeUp, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'remoteLock'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{lock,0},{unlock,1}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+ {{remoteLock, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'forwardDnd'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSetForwardInfo'(Bytes1, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+ {{forwardDnd, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'absentMessage'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeAbsentMessage'(Bytes1, mandatory, [{tag,128,3,'EXPLICIT',32}]),
+ {{absentMessage, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'passwordClear'
+ <<2:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_null(Bytes1,[{tag,128,4,'EXPLICIT',32}], mandatory),
+ {{passwordClear, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'extNumber'
+ <<2:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_restricted_string(Bytes1,{1,5},22,[{tag,128,5,'EXPLICIT',32}], no_length, mandatory),
+ {{extNumber, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'extName'
+ <<2:2,_:1,6:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeExtName'(Bytes1, mandatory, [{tag,128,6,'EXPLICIT',32}]),
+ {{extName, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'cos'
+ <<2:2,_:1,7:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_integer(Bytes1,[],[{tag,128,7,'EXPLICIT',32}], mandatory),
+ {{cos, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'joinGroup'
+ <<2:2,_:1,8:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,8,'EXPLICIT',32}]),
+ {{joinGroup, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'leaveGroup'
+ <<2:2,_:1,9:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,9,'EXPLICIT',32}]),
+ {{leaveGroup, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'inService'
+ <<2:2,_:1,10:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_boolean(Bytes1,[{tag,128,10,'EXPLICIT',32}], mandatory),
+ {{inService, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'fcoKey'
+ <<2:2,_:1,11:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeFcoKeyList'(Bytes1, mandatory, [{tag,128,11,'EXPLICIT',32}]),
+ {{fcoKey, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeSetSystemData_deviceData'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeSetSystemData_deviceData_sysData'(Bytes3, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeSetSystemData_deviceData', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+
+%%================================
+%% KmeSetSystemData_acdQueue
+%%================================
+'enc_KmeSetSystemData_acdQueue'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeSetSystemData_acdQueue_attribute'(?RT_BER:cindex(3,Val,attribute), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeSetSystemData_acdQueue_attribute
+%%================================
+
+'enc_KmeSetSystemData_acdQueue_attribute'({'KmeSetSystemData_acdQueue_attribute',Val}, TagIn) ->
+ 'enc_KmeSetSystemData_acdQueue_attribute'(Val, TagIn);
+
+'enc_KmeSetSystemData_acdQueue_attribute'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ groupType ->
+ case (case element(2,Val) of {_,Enumval1}->Enumval1;_->element(2,Val) end) of
+ucd -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+ring -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+hunt -> ?RT_BER:encode_enumerated(2,[{tag,128,1,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end;
+ acdMode ->
+ ?RT_BER:encode_boolean(element(2,Val), []);
+ ctiWaitTime ->
+ ?RT_BER:encode_integer([], element(2,Val), []);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeSetSystemData_acdQueue_attribute'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'groupType'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{ucd,0},{ring,1},{hunt,2}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+ {{groupType, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'acdMode'
+ <<0:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_boolean(Bytes1,[], mandatory),
+ {{acdMode, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'ctiWaitTime'
+ <<0:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_integer(Bytes1,[],[], mandatory),
+ {{ctiWaitTime, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeSetSystemData_acdQueue'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeSetSystemData_acdQueue_attribute'(Bytes3, mandatory, []),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeSetSystemData_acdQueue', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+'dec_KmeSetSystemData'(Bytes, OptOrMand) ->
+ 'dec_KmeSetSystemData'(Bytes, OptOrMand, []).
+
+'dec_KmeSetSystemData'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'systemData'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSetSystemData_systemData'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{systemData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'deviceData'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSetSystemData_deviceData'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{deviceData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'acdQueue'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSetSystemData_acdQueue'(Bytes1, mandatory, [{tag,128,3,'EXPLICIT',32}]),
+ {{acdQueue, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeSystemDataChanged
+%%================================
+
+'enc_KmeSystemDataChanged'({'KmeSystemDataChanged',Val}, TagIn) ->
+ 'enc_KmeSystemDataChanged'(Val, TagIn);
+
+'enc_KmeSystemDataChanged'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ systemData ->
+ case (case element(2,Val) of {_,Enumval1}->Enumval1;_->element(2,Val) end) of
+featureList -> ?RT_BER:encode_enumerated(1,[{tag,128,0,'EXPLICIT',32}]);
+speedDial -> ?RT_BER:encode_enumerated(2,[{tag,128,0,'EXPLICIT',32}]);
+trunkGroup -> ?RT_BER:encode_enumerated(3,[{tag,128,0,'EXPLICIT',32}]);
+extGroup -> ?RT_BER:encode_enumerated(4,[{tag,128,0,'EXPLICIT',32}]);
+pickGroup -> ?RT_BER:encode_enumerated(5,[{tag,128,0,'EXPLICIT',32}]);
+pagingGroup -> ?RT_BER:encode_enumerated(6,[{tag,128,0,'EXPLICIT',32}]);
+incomingGroup -> ?RT_BER:encode_enumerated(7,[{tag,128,0,'EXPLICIT',32}]);
+dayNightMode -> ?RT_BER:encode_enumerated(8,[{tag,128,0,'EXPLICIT',32}]);
+doorPhone -> ?RT_BER:encode_enumerated(9,[{tag,128,0,'EXPLICIT',32}]);
+vmGroup -> ?RT_BER:encode_enumerated(10,[{tag,128,0,'EXPLICIT',32}]);
+systemTime -> ?RT_BER:encode_enumerated(11,[{tag,128,0,'EXPLICIT',32}]);
+psGroup -> ?RT_BER:encode_enumerated(12,[{tag,128,0,'EXPLICIT',32}]);
+trunkGMembers -> ?RT_BER:encode_enumerated(13,[{tag,128,0,'EXPLICIT',32}]);
+incomingGMembers -> ?RT_BER:encode_enumerated(14,[{tag,128,0,'EXPLICIT',32}]);
+psGMembers -> ?RT_BER:encode_enumerated(15,[{tag,128,0,'EXPLICIT',32}]);
+vmGMembers -> ?RT_BER:encode_enumerated(16,[{tag,128,0,'EXPLICIT',32}]);
+broadcastGroup -> ?RT_BER:encode_enumerated(17,[{tag,128,0,'EXPLICIT',32}]);
+broadcastGMembers -> ?RT_BER:encode_enumerated(18,[{tag,128,0,'EXPLICIT',32}]);
+subdomainName -> ?RT_BER:encode_enumerated(19,[{tag,128,0,'EXPLICIT',32}]);
+externalSensor -> ?RT_BER:encode_enumerated(20,[{tag,128,0,'EXPLICIT',32}]);
+svm -> ?RT_BER:encode_enumerated(21,[{tag,128,0,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end;
+ deviceData ->
+ 'enc_KmeSystemDataChanged_deviceData'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ deviceBasicInfo ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ reconfiguration ->
+ ?RT_BER:encode_null(element(2,Val), [{tag,128,3,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+
+%%================================
+%% KmeSystemDataChanged_deviceData
+%%================================
+'enc_KmeSystemDataChanged_deviceData'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,sysData) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(3,Val,sysData) end) of
+wakeUp -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+remoteStatationLock -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+callLogLock -> ?RT_BER:encode_enumerated(2,[{tag,128,1,'EXPLICIT',32}]);
+absentMessage -> ?RT_BER:encode_enumerated(3,[{tag,128,1,'EXPLICIT',32}]);
+forwardDnd -> ?RT_BER:encode_enumerated(4,[{tag,128,1,'EXPLICIT',32}]);
+cos -> ?RT_BER:encode_enumerated(5,[{tag,128,1,'EXPLICIT',32}]);
+extName -> ?RT_BER:encode_enumerated(6,[{tag,128,1,'EXPLICIT',32}]);
+assocExtGroup -> ?RT_BER:encode_enumerated(7,[{tag,128,1,'EXPLICIT',32}]);
+fcoKey -> ?RT_BER:encode_enumerated(8,[{tag,128,1,'EXPLICIT',32}]);
+sxdpMaster -> ?RT_BER:encode_enumerated(9,[{tag,128,1,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+'dec_KmeSystemDataChanged_deviceData'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{wakeUp,0},{remoteStatationLock,1},{callLogLock,2},{absentMessage,3},{forwardDnd,4},{cos,5},{extName,6},{assocExtGroup,7},{fcoKey,8},{sxdpMaster,9}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeSystemDataChanged_deviceData', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+'dec_KmeSystemDataChanged'(Bytes, OptOrMand) ->
+ 'dec_KmeSystemDataChanged'(Bytes, OptOrMand, []).
+
+'dec_KmeSystemDataChanged'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'systemData'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{featureList,1},{speedDial,2},{trunkGroup,3},{extGroup,4},{pickGroup,5},{pagingGroup,6},{incomingGroup,7},{dayNightMode,8},{doorPhone,9},{vmGroup,10},{systemTime,11},{psGroup,12},{trunkGMembers,13},{incomingGMembers,14},{psGMembers,15},{vmGMembers,16},{broadcastGroup,17},{broadcastGMembers,18},{subdomainName,19},{externalSensor,20},{svm,21}],[{tag,128,0,'EXPLICIT',32}], mandatory),
+ {{systemData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'deviceData'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSystemDataChanged_deviceData'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{deviceData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'deviceBasicInfo'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+ {{deviceBasicInfo, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'reconfiguration'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_null(Bytes1,[{tag,128,3,'EXPLICIT',32}], mandatory),
+ {{reconfiguration, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeSystemDataLinkedReply
+%%================================
+'enc_KmeSystemDataLinkedReply'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type OCTET STRING
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_octet_string([], ?RT_BER:cindex(2,Val,crossRefID), [{tag,128,0,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_integer([], ?RT_BER:cindex(3,Val,segmentID), [{tag,128,1,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 3 with type BOOLEAN
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = ?RT_BER:encode_boolean(?RT_BER:cindex(4,Val,lastSegment), [{tag,128,2,'EXPLICIT',32}]),
+
+%%-------------------------------------------------
+%% attribute number 4 External KME-specific-types:KmeGetSystemDataRsp OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,sysData) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'enc_KmeGetSystemDataRsp'(?RT_BER:cindex(5,Val,sysData), [{tag,128,3,'EXPLICIT',32}])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeSystemDataLinkedReply'(Bytes, OptOrMand) ->
+ 'dec_KmeSystemDataLinkedReply'(Bytes, OptOrMand, []).
+
+'dec_KmeSystemDataLinkedReply'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type OCTET STRING
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_octet_string(Bytes2,[],[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_integer(Bytes3,[],[{tag,128,1,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 with type BOOLEAN
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = ?RT_BER:decode_boolean(Bytes4,[{tag,128,2,'EXPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 4 External KME-specific-types:KmeGetSystemDataRsp OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<2:2,_:1,3:5,_/binary>> ->
+'dec_KmeGetSystemDataRsp'(Bytes5, opt_or_default, [{tag,128,3,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+ {Bytes7,Rb6} = ?RT_BER:restbytes2(RemBytes, Bytes6,noext),
+ {{'KmeSystemDataLinkedReply', Term1, Term2, Term3, Term4}, Bytes7, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6}.
+
+
+%%================================
+%% KmeGetSystemDataPosAck
+%%================================
+
+'enc_KmeGetSystemDataPosAck'({'KmeGetSystemDataPosAck',Val}, TagIn) ->
+ 'enc_KmeGetSystemDataPosAck'(Val, TagIn);
+
+'enc_KmeGetSystemDataPosAck'(Val, TagIn) ->
+?RT_BER:encode_octet_string([], Val, TagIn ++ []).
+
+
+'dec_KmeGetSystemDataPosAck'(Bytes, OptOrMand) ->
+ 'dec_KmeGetSystemDataPosAck'(Bytes, OptOrMand, []).
+
+'dec_KmeGetSystemDataPosAck'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_octet_string(Bytes,[],TagIn++[], no_length, OptOrMand).
+
+
+
+%%================================
+%% KmeSystemCrossRefID
+%%================================
+
+'enc_KmeSystemCrossRefID'({'KmeSystemCrossRefID',Val}, TagIn) ->
+ 'enc_KmeSystemCrossRefID'(Val, TagIn);
+
+'enc_KmeSystemCrossRefID'(Val, TagIn) ->
+?RT_BER:encode_octet_string([], Val, TagIn ++ []).
+
+
+'dec_KmeSystemCrossRefID'(Bytes, OptOrMand) ->
+ 'dec_KmeSystemCrossRefID'(Bytes, OptOrMand, []).
+
+'dec_KmeSystemCrossRefID'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_octet_string(Bytes,4,TagIn++[], no_length, OptOrMand).
+
+
+
+%%================================
+%% KmeLockSystemData
+%%================================
+
+'enc_KmeLockSystemData'({'KmeLockSystemData',Val}, TagIn) ->
+ 'enc_KmeLockSystemData'(Val, TagIn);
+
+'enc_KmeLockSystemData'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ request ->
+ 'enc_KmeLockSystemData_request'(element(2,Val), []);
+ lockResult ->
+ ?RT_BER:encode_octet_string([], element(2,Val), []);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+
+%%================================
+%% KmeLockSystemData_request
+%%================================
+'enc_KmeLockSystemData_request'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type BOOLEAN
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_boolean(?RT_BER:cindex(2,Val,systemDataLock), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'enc_KmeLockSystemData_request_id'(?RT_BER:cindex(3,Val,id), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+
+%%================================
+%% KmeLockSystemData_request_id
+%%================================
+
+'enc_KmeLockSystemData_request_id'({'KmeLockSystemData_request_id',Val}, TagIn) ->
+ 'enc_KmeLockSystemData_request_id'(Val, TagIn);
+
+'enc_KmeLockSystemData_request_id'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ lock ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), []);
+ unlock ->
+ ?RT_BER:encode_octet_string([], element(2,Val), []);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+'dec_KmeLockSystemData_request_id'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'lock'
+ <<0:2,_:1,16:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, []),
+ {{lock, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'unlock'
+ <<0:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,4,[], no_length, mandatory),
+ {{unlock, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+'dec_KmeLockSystemData_request'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type BOOLEAN
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_boolean(Bytes2,[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 with type CHOICE
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'dec_KmeLockSystemData_request_id'(Bytes3, mandatory, []),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeLockSystemData_request', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+'dec_KmeLockSystemData'(Bytes, OptOrMand) ->
+ 'dec_KmeLockSystemData'(Bytes, OptOrMand, []).
+
+'dec_KmeLockSystemData'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'request'
+ <<0:2,_:1,16:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeLockSystemData_request'(Bytes1, mandatory, []),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'lockResult'
+ <<0:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,4,[], no_length, mandatory),
+ {{lockResult, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeSystemDataStatus
+%%================================
+'enc_KmeSystemDataStatus'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type BOOLEAN
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_boolean(?RT_BER:cindex(2,Val,systemDataLock), []),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,lockingDevice) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(3,Val,lockingDevice), [])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeSystemDataStatus'(Bytes, OptOrMand) ->
+ 'dec_KmeSystemDataStatus'(Bytes, OptOrMand, []).
+
+'dec_KmeSystemDataStatus'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type BOOLEAN
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_boolean(Bytes2,[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<0:2,_:1,16:5,_/binary>> ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes3, opt_or_default, []);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeSystemDataStatus', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeSystemDataRevision
+%%================================
+
+'enc_KmeSystemDataRevision'({'KmeSystemDataRevision',Val}, TagIn) ->
+ 'enc_KmeSystemDataRevision'(Val, TagIn);
+
+'enc_KmeSystemDataRevision'(Val, TagIn) ->
+?RT_BER:encode_octet_string([], Val, TagIn ++ []).
+
+
+'dec_KmeSystemDataRevision'(Bytes, OptOrMand) ->
+ 'dec_KmeSystemDataRevision'(Bytes, OptOrMand, []).
+
+'dec_KmeSystemDataRevision'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_octet_string(Bytes,{0,128},TagIn++[], no_length, OptOrMand).
+
+
+
+%%================================
+%% KmeGetSystemDataRevision
+%%================================
+
+'enc_KmeGetSystemDataRevision'({'KmeGetSystemDataRevision',Val}, TagIn) ->
+ 'enc_KmeGetSystemDataRevision'(Val, TagIn);
+
+'enc_KmeGetSystemDataRevision'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ request ->
+ case (case element(2,Val) of {_,Enumval1}->Enumval1;_->element(2,Val) end) of
+systemDataRevision -> ?RT_BER:encode_enumerated(0,[]);
+speedDialRevision -> ?RT_BER:encode_enumerated(1,[]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end;
+ result ->
+ ?RT_BER:encode_octet_string([], element(2,Val), []);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeGetSystemDataRevision'(Bytes, OptOrMand) ->
+ 'dec_KmeGetSystemDataRevision'(Bytes, OptOrMand, []).
+
+'dec_KmeGetSystemDataRevision'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'request'
+ <<0:2,_:1,10:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{systemDataRevision,0},{speedDialRevision,1}],[], mandatory),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'result'
+ <<0:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{0,128},[], no_length, mandatory),
+ {{result, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeRevisionType
+%%================================
+
+'enc_KmeRevisionType'({'KmeRevisionType',Val}, TagIn) ->
+ 'enc_KmeRevisionType'(Val, TagIn);
+
+'enc_KmeRevisionType'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+systemDataRevision -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+speedDialRevision -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeRevisionType'(Bytes, OptOrMand) ->
+ 'dec_KmeRevisionType'(Bytes, OptOrMand, []).
+
+'dec_KmeRevisionType'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{systemDataRevision,0},{speedDialRevision,1}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% ProgrammingEventOn
+%%================================
+
+'enc_ProgrammingEventOn'({'ProgrammingEventOn',Val}, TagIn) ->
+ 'enc_ProgrammingEventOn'(Val, TagIn);
+
+'enc_ProgrammingEventOn'(Val, TagIn) ->
+?RT_BER:encode_boolean(Val, TagIn ++ []).
+
+
+'dec_ProgrammingEventOn'(Bytes, OptOrMand) ->
+ 'dec_ProgrammingEventOn'(Bytes, OptOrMand, []).
+
+'dec_ProgrammingEventOn'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_boolean(Bytes,TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeSetProgrammingEventOn
+%%================================
+
+'enc_KmeSetProgrammingEventOn'({'KmeSetProgrammingEventOn',Val}, TagIn) ->
+ 'enc_KmeSetProgrammingEventOn'(Val, TagIn);
+
+'enc_KmeSetProgrammingEventOn'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ request ->
+ ?RT_BER:encode_boolean(element(2,Val), []);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeSetProgrammingEventOn'(Bytes, OptOrMand) ->
+ 'dec_KmeSetProgrammingEventOn'(Bytes, OptOrMand, []).
+
+'dec_KmeSetProgrammingEventOn'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'request'
+ <<0:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_boolean(Bytes1,[], mandatory),
+ {{request, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeLocalAlerm
+%%================================
+
+'enc_KmeLocalAlerm'({'KmeLocalAlerm',Val}, TagIn) ->
+ 'enc_KmeLocalAlerm'(Val, TagIn);
+
+'enc_KmeLocalAlerm'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ singleMessage ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ wideMessage ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeLocalAlerm'(Bytes, OptOrMand) ->
+ 'dec_KmeLocalAlerm'(Bytes, OptOrMand, []).
+
+'dec_KmeLocalAlerm'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'singleMessage'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{0,24},[{tag,128,0,'EXPLICIT',32}], no_length, mandatory),
+ {{singleMessage, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wideMessage'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{0,48},[{tag,128,1,'EXPLICIT',32}], no_length, mandatory),
+ {{wideMessage, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeTrunkId
+%%================================
+
+'enc_KmeTrunkId'({'KmeTrunkId',Val}, TagIn) ->
+ 'enc_KmeTrunkId'(Val, TagIn);
+
+'enc_KmeTrunkId'(Val, TagIn) ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(Val, TagIn ++ []).
+
+
+'dec_KmeTrunkId'(Bytes, OptOrMand) ->
+ 'dec_KmeTrunkId'(Bytes, OptOrMand, []).
+
+'dec_KmeTrunkId'(Bytes, OptOrMand, TagIn) ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% KmeOtherDevice
+%%================================
+
+'enc_KmeOtherDevice'({'KmeOtherDevice',Val}, TagIn) ->
+ 'enc_KmeOtherDevice'(Val, TagIn);
+
+'enc_KmeOtherDevice'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+vm -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+doorPhone -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+disa -> ?RT_BER:encode_enumerated(2,TagIn ++ []);
+pagingGroup -> ?RT_BER:encode_enumerated(3,TagIn ++ []);
+psGruop -> ?RT_BER:encode_enumerated(4,TagIn ++ []);
+externalRinger -> ?RT_BER:encode_enumerated(5,TagIn ++ []);
+externalSensor -> ?RT_BER:encode_enumerated(6,TagIn ++ []);
+externalPager -> ?RT_BER:encode_enumerated(7,TagIn ++ []);
+modem -> ?RT_BER:encode_enumerated(8,TagIn ++ []);
+hdlc -> ?RT_BER:encode_enumerated(9,TagIn ++ []);
+pbxSystem -> ?RT_BER:encode_enumerated(10,TagIn ++ []);
+svm -> ?RT_BER:encode_enumerated(11,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeOtherDevice'(Bytes, OptOrMand) ->
+ 'dec_KmeOtherDevice'(Bytes, OptOrMand, []).
+
+'dec_KmeOtherDevice'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{vm,0},{doorPhone,1},{disa,2},{pagingGroup,3},{psGruop,4},{externalRinger,5},{externalSensor,6},{externalPager,7},{modem,8},{hdlc,9},{pbxSystem,10},{svm,11}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeCdrConditionCode
+%%================================
+
+'enc_KmeCdrConditionCode'({'KmeCdrConditionCode',Val}, TagIn) ->
+ 'enc_KmeCdrConditionCode'(Val, TagIn);
+
+'enc_KmeCdrConditionCode'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+cl -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+tr -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+fw -> ?RT_BER:encode_enumerated(2,TagIn ++ []);
+d0 -> ?RT_BER:encode_enumerated(3,TagIn ++ []);
+rm -> ?RT_BER:encode_enumerated(4,TagIn ++ []);
+na -> ?RT_BER:encode_enumerated(5,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeCdrConditionCode'(Bytes, OptOrMand) ->
+ 'dec_KmeCdrConditionCode'(Bytes, OptOrMand, []).
+
+'dec_KmeCdrConditionCode'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{cl,0},{tr,1},{fw,2},{d0,3},{rm,4},{na,5}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeFeatureNumber
+%%================================
+
+'enc_KmeFeatureNumber'({'KmeFeatureNumber',Val}, TagIn) ->
+ 'enc_KmeFeatureNumber'(Val, TagIn);
+
+'enc_KmeFeatureNumber'(Val, TagIn) ->
+?RT_BER:encode_integer([], Val, TagIn ++ []).
+
+
+'dec_KmeFeatureNumber'(Bytes, OptOrMand) ->
+ 'dec_KmeFeatureNumber'(Bytes, OptOrMand, []).
+
+'dec_KmeFeatureNumber'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_integer(Bytes,[],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeProprietaryChars
+%%================================
+
+'enc_KmeProprietaryChars'({'KmeProprietaryChars',Val}, TagIn) ->
+ 'enc_KmeProprietaryChars'(Val, TagIn);
+
+'enc_KmeProprietaryChars'(Val, TagIn) ->
+?RT_BER:encode_octet_string([], Val, TagIn ++ []).
+
+
+'dec_KmeProprietaryChars'(Bytes, OptOrMand) ->
+ 'dec_KmeProprietaryChars'(Bytes, OptOrMand, []).
+
+'dec_KmeProprietaryChars'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_octet_string(Bytes,{0,144},TagIn++[], no_length, OptOrMand).
+
+
+
+%%================================
+%% KmeHoldType
+%%================================
+
+'enc_KmeHoldType'({'KmeHoldType',Val}, TagIn) ->
+ 'enc_KmeHoldType'(Val, TagIn);
+
+'enc_KmeHoldType'(Val, TagIn) ->
+case (case Val of {_,Enumval1}->Enumval1;_->Val end) of
+consultation -> ?RT_BER:encode_enumerated(0,TagIn ++ []);
+normal -> ?RT_BER:encode_enumerated(1,TagIn ++ []);
+exclusive -> ?RT_BER:encode_enumerated(2,TagIn ++ []);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end.
+
+
+'dec_KmeHoldType'(Bytes, OptOrMand) ->
+ 'dec_KmeHoldType'(Bytes, OptOrMand, []).
+
+'dec_KmeHoldType'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_enumerated(Bytes,[],[{consultation,0},{normal,1},{exclusive,2}],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeForcedAlerting
+%%================================
+
+'enc_KmeForcedAlerting'({'KmeForcedAlerting',Val}, TagIn) ->
+ 'enc_KmeForcedAlerting'(Val, TagIn);
+
+'enc_KmeForcedAlerting'(Val, TagIn) ->
+?RT_BER:encode_bit_string([], Val, [{fwdDnd,0},{timer,1}], TagIn ++ []).
+
+
+'dec_KmeForcedAlerting'(Bytes, OptOrMand) ->
+ 'dec_KmeForcedAlerting'(Bytes, OptOrMand, []).
+
+'dec_KmeForcedAlerting'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_bit_string(Bytes,[],[{fwdDnd,0},{timer,1}],TagIn++[], no_length, OptOrMand).
+
+
+
+%%================================
+%% KmeDigitsReport
+%%================================
+'enc_KmeDigitsReport'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-call-connection-identifiers':'enc_ConnectionID'(?RT_BER:cindex(2,Val,connection), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(3,Val,digits), 22, []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeDigitsReport'(Bytes, OptOrMand) ->
+ 'dec_KmeDigitsReport'(Bytes, OptOrMand, []).
+
+'dec_KmeDigitsReport'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_restricted_string(Bytes3,{0,64},22,[], no_length, mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeDigitsReport', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeOgmStatus
+%%================================
+'enc_KmeOgmStatus'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-call-connection-identifiers':'enc_ConnectionID'(?RT_BER:cindex(2,Val,connection), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,state) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(3,Val,state) end) of
+started -> ?RT_BER:encode_enumerated(0,[]);
+ended -> ?RT_BER:encode_enumerated(1,[]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = ?RT_BER:encode_integer([], ?RT_BER:cindex(4,Val,ogmId), []),
+
+%%-------------------------------------------------
+%% attribute number 4 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(5,Val,ogmPortNumber), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeOgmStatus'(Bytes, OptOrMand) ->
+ 'dec_KmeOgmStatus'(Bytes, OptOrMand, []).
+
+'dec_KmeOgmStatus'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{started,0},{ended,1}],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 with type INTEGER
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = ?RT_BER:decode_integer(Bytes4,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 4 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes5, mandatory, []),
+
+ {Bytes7,Rb6} = ?RT_BER:restbytes2(RemBytes, Bytes6,noext),
+ {{'KmeOgmStatus', Term1, Term2, Term3, Term4}, Bytes7, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6}.
+
+
+%%================================
+%% KmeWakeupResult
+%%================================
+'enc_KmeWakeupResult'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,device), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case (case ?RT_BER:cindex(3,Val,state) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(3,Val,state) end) of
+answered -> ?RT_BER:encode_enumerated(0,[]);
+noAnswer -> ?RT_BER:encode_enumerated(1,[]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 External KME-specific-types:KmeWakeUpTime
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = 'enc_KmeWakeUpTime'(?RT_BER:cindex(4,Val,wakeupTime), []),
+
+%%-------------------------------------------------
+%% attribute number 4 with type GeneralizedTime
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = ?RT_BER:encode_generalized_time([], ?RT_BER:cindex(5,Val,invokeTime), []),
+
+%%-------------------------------------------------
+%% attribute number 5 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes5,EncLen5} = case ?RT_BER:cindex(6,Val,restOfRetry) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(6,Val,restOfRetry), [])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4, EncBytes5],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4 + EncLen5,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeWakeupResult'(Bytes, OptOrMand) ->
+ 'dec_KmeWakeupResult'(Bytes, OptOrMand, []).
+
+'dec_KmeWakeupResult'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type ENUMERATED
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_enumerated(Bytes3,[],[{answered,0},{noAnswer,1}],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 3 External KME-specific-types:KmeWakeUpTime
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = 'dec_KmeWakeUpTime'(Bytes4, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 4 with type GeneralizedTime
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = ?RT_BER:decode_generalized_time(Bytes5,[],[], no_length, mandatory),
+
+%%-------------------------------------------------
+%% attribute number 5 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term5,Bytes7,Rb6} = case Bytes6 of
+<<0:2,_:1,2:5,_/binary>> ->
+?RT_BER:decode_integer(Bytes6,[],[], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes6, 0 }
+end,
+
+ {Bytes8,Rb7} = ?RT_BER:restbytes2(RemBytes, Bytes7,noext),
+ {{'KmeWakeupResult', Term1, Term2, Term3, Term4, Term5}, Bytes8, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6+Rb7}.
+
+
+%%================================
+%% KmeUnconferenced
+%%================================
+'enc_KmeUnconferenced'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(2,Val,unconferencingDevice), []),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = 'CSTA-call-connection-identifiers':'enc_ConnectionID'(?RT_BER:cindex(3,Val,primaryCall), []),
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-call-connection-identifiers:ConnectionID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,secodaryCall) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(?RT_BER:cindex(4,Val,secodaryCall), [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 4 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,primaryNID) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(5,Val,primaryNID), [{tag,128,1,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 5 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes5,EncLen5} = case ?RT_BER:cindex(6,Val,secondaryNID) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(6,Val,secondaryNID), [{tag,128,2,'EXPLICIT',32}])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type ENUMERATED
+%%-------------------------------------------------
+ {EncBytes6,EncLen6} = case (case ?RT_BER:cindex(7,Val,primaryConnectionInfo) of {_,Enumval1}->Enumval1;_->?RT_BER:cindex(7,Val,primaryConnectionInfo) end) of
+null -> ?RT_BER:encode_enumerated(0,[{tag,64,14,'IMPLICIT',32}]);
+initiated -> ?RT_BER:encode_enumerated(1,[{tag,64,14,'IMPLICIT',32}]);
+alerting -> ?RT_BER:encode_enumerated(2,[{tag,64,14,'IMPLICIT',32}]);
+connected -> ?RT_BER:encode_enumerated(3,[{tag,64,14,'IMPLICIT',32}]);
+hold -> ?RT_BER:encode_enumerated(4,[{tag,64,14,'IMPLICIT',32}]);
+queued -> ?RT_BER:encode_enumerated(5,[{tag,64,14,'IMPLICIT',32}]);
+fail -> ?RT_BER:encode_enumerated(6,[{tag,64,14,'IMPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end,
+
+%%-------------------------------------------------
+%% attribute number 7 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {EncBytes7,EncLen7} = case ?RT_BER:cindex(8,Val,secondaryConnectionInfo) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ case (case ?RT_BER:cindex(8,Val,secondaryConnectionInfo) of {_,Enumval3}->Enumval3;_->?RT_BER:cindex(8,Val,secondaryConnectionInfo) end) of
+null -> ?RT_BER:encode_enumerated(0,[{tag,64,14,'IMPLICIT',32}]);
+initiated -> ?RT_BER:encode_enumerated(1,[{tag,64,14,'IMPLICIT',32}]);
+alerting -> ?RT_BER:encode_enumerated(2,[{tag,64,14,'IMPLICIT',32}]);
+connected -> ?RT_BER:encode_enumerated(3,[{tag,64,14,'IMPLICIT',32}]);
+hold -> ?RT_BER:encode_enumerated(4,[{tag,64,14,'IMPLICIT',32}]);
+queued -> ?RT_BER:encode_enumerated(5,[{tag,64,14,'IMPLICIT',32}]);
+fail -> ?RT_BER:encode_enumerated(6,[{tag,64,14,'IMPLICIT',32}]);
+Enumval4 -> exit({error,{asn1, {enumerated_not_in_range,Enumval4}}})
+end
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4, EncBytes5, EncBytes6, EncBytes7],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4 + EncLen5 + EncLen6 + EncLen7,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeUnconferenced'(Bytes, OptOrMand) ->
+ 'dec_KmeUnconferenced'(Bytes, OptOrMand, []).
+
+'dec_KmeUnconferenced'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-device-identifiers:DeviceID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = 'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes3, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-call-connection-identifiers:ConnectionID OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<1:2,_:1,11:5,_/binary>> ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes4, opt_or_default, []);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 4 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<2:2,_:1,1:5,_/binary>> ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes5, opt_or_default, [{tag,128,1,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 5 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {Term5,Bytes7,Rb6} = case Bytes6 of
+<<2:2,_:1,2:5,_/binary>> ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes6, opt_or_default, [{tag,128,2,'EXPLICIT',32}]);
+_ ->
+{ asn1_NOVALUE, Bytes6, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type ENUMERATED
+%%-------------------------------------------------
+ {Term6,Bytes8,Rb7} = ?RT_BER:decode_enumerated(Bytes7,[],[{null,0},{initiated,1},{alerting,2},{connected,3},{hold,4},{queued,5},{fail,6}],[{tag,64,14,'IMPLICIT',32}], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 7 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {Term7,Bytes9,Rb8} = case Bytes8 of
+<<1:2,_:1,14:5,_/binary>> ->
+?RT_BER:decode_enumerated(Bytes8,[],[{null,0},{initiated,1},{alerting,2},{connected,3},{hold,4},{queued,5},{fail,6}],[{tag,64,14,'IMPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes8, 0 }
+end,
+
+ {Bytes10,Rb9} = ?RT_BER:restbytes2(RemBytes, Bytes9,noext),
+ {{'KmeUnconferenced', Term1, Term2, Term3, Term4, Term5, Term6, Term7}, Bytes10, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6+Rb7+Rb8+Rb9}.
+
+
+%%================================
+%% KmeTamEnded
+%%================================
+
+'enc_KmeTamEnded'({'KmeTamEnded',Val}, TagIn) ->
+ 'enc_KmeTamEnded'(Val, TagIn);
+
+'enc_KmeTamEnded'(Val, TagIn) ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(Val, TagIn ++ []).
+
+
+'dec_KmeTamEnded'(Bytes, OptOrMand) ->
+ 'dec_KmeTamEnded'(Bytes, OptOrMand, []).
+
+'dec_KmeTamEnded'(Bytes, OptOrMand, TagIn) ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% KmePcRecEnded
+%%================================
+
+'enc_KmePcRecEnded'({'KmePcRecEnded',Val}, TagIn) ->
+ 'enc_KmePcRecEnded'(Val, TagIn);
+
+'enc_KmePcRecEnded'(Val, TagIn) ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(Val, TagIn ++ []).
+
+
+'dec_KmePcRecEnded'(Bytes, OptOrMand) ->
+ 'dec_KmePcRecEnded'(Bytes, OptOrMand, []).
+
+'dec_KmePcRecEnded'(Bytes, OptOrMand, TagIn) ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% KmeSwitchChannel
+%%================================
+
+'enc_KmeSwitchChannel'({'KmeSwitchChannel',Val}, TagIn) ->
+ 'enc_KmeSwitchChannel'(Val, TagIn);
+
+'enc_KmeSwitchChannel'(Val, TagIn) ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(Val, TagIn ++ []).
+
+
+'dec_KmeSwitchChannel'(Bytes, OptOrMand) ->
+ 'dec_KmeSwitchChannel'(Bytes, OptOrMand, []).
+
+'dec_KmeSwitchChannel'(Bytes, OptOrMand, TagIn) ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% KmeFreeOgmPort
+%%================================
+
+'enc_KmeFreeOgmPort'({'KmeFreeOgmPort',Val}, TagIn) ->
+ 'enc_KmeFreeOgmPort'(Val, TagIn);
+
+'enc_KmeFreeOgmPort'(Val, TagIn) ->
+?RT_BER:encode_integer([], Val, TagIn ++ []).
+
+
+'dec_KmeFreeOgmPort'(Bytes, OptOrMand) ->
+ 'dec_KmeFreeOgmPort'(Bytes, OptOrMand, []).
+
+'dec_KmeFreeOgmPort'(Bytes, OptOrMand, TagIn) ->
+?RT_BER:decode_integer(Bytes,[],TagIn++[], OptOrMand).
+
+
+
+%%================================
+%% KmeCallControlSrvEvt
+%%================================
+
+'enc_KmeCallControlSrvEvt'({'KmeCallControlSrvEvt',Val}, TagIn) ->
+ 'enc_KmeCallControlSrvEvt'(Val, TagIn);
+
+'enc_KmeCallControlSrvEvt'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ dndOverride ->
+ 'enc_KmeDndOverride'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ interuptCall ->
+ 'enc_KmeInteruptCall'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ eFA ->
+ 'enc_KmeExternalFeatureAccess'(element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ tempTollChange ->
+ 'enc_KmeTempTollChange'(element(2,Val), [{tag,128,3,'EXPLICIT',32}]);
+ doorOpen ->
+ 'enc_KmeDoorOpen'(element(2,Val), [{tag,128,4,'EXPLICIT',32}]);
+ twoWayRec ->
+ 'enc_KmeTwoWayRec'(element(2,Val), [{tag,128,5,'EXPLICIT',32}]);
+ callBackInvoke ->
+ 'enc_KmeCallBackInvoke'(element(2,Val), [{tag,128,6,'EXPLICIT',32}]);
+ pcRec ->
+ 'enc_KmePcRec'(element(2,Val), [{tag,128,7,'EXPLICIT',32}]);
+ switchChannel ->
+ 'enc_KmeSwitchChannel'(element(2,Val), [{tag,128,8,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeCallControlSrvEvt'(Bytes, OptOrMand) ->
+ 'dec_KmeCallControlSrvEvt'(Bytes, OptOrMand, []).
+
+'dec_KmeCallControlSrvEvt'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'dndOverride'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDndOverride'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{dndOverride, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'interuptCall'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeInteruptCall'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{interuptCall, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'eFA'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeExternalFeatureAccess'(Bytes1, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+ {{eFA, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'tempTollChange'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeTempTollChange'(Bytes1, mandatory, [{tag,128,3,'EXPLICIT',32}]),
+ {{tempTollChange, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'doorOpen'
+ <<2:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDoorOpen'(Bytes1, mandatory, [{tag,128,4,'EXPLICIT',32}]),
+ {{doorOpen, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'twoWayRec'
+ <<2:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeTwoWayRec'(Bytes1, mandatory, [{tag,128,5,'EXPLICIT',32}]),
+ {{twoWayRec, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'callBackInvoke'
+ <<2:2,_:1,6:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeCallBackInvoke'(Bytes1, mandatory, [{tag,128,6,'EXPLICIT',32}]),
+ {{callBackInvoke, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'pcRec'
+ <<2:2,_:1,7:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmePcRec'(Bytes1, mandatory, [{tag,128,7,'EXPLICIT',32}]),
+ {{pcRec, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'switchChannel'
+ <<2:2,_:1,8:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSwitchChannel'(Bytes1, mandatory, [{tag,128,8,'EXPLICIT',32}]),
+ {{switchChannel, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeDeviceStatus
+%%================================
+
+'enc_KmeDeviceStatus'({'KmeDeviceStatus',Val}, TagIn) ->
+ 'enc_KmeDeviceStatus'(Val, TagIn);
+
+'enc_KmeDeviceStatus'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ agentStatus ->
+ 'enc_KmeDeviceAgentStatus'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ callStatus ->
+ 'enc_KmeDeviceCallStatus'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ serviceStatus ->
+ 'enc_KmeDeviceServiceStatus'(element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ lineStatus ->
+ 'enc_KmeLineStatus'(element(2,Val), [{tag,128,3,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeDeviceStatus'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceStatus'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceStatus'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'agentStatus'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDeviceAgentStatus'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{agentStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'callStatus'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDeviceCallStatus'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{callStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'serviceStatus'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDeviceServiceStatus'(Bytes1, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+ {{serviceStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'lineStatus'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeLineStatus'(Bytes1, mandatory, [{tag,128,3,'EXPLICIT',32}]),
+ {{lineStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeDeviceMonitor
+%%================================
+
+'enc_KmeDeviceMonitor'({'KmeDeviceMonitor',Val}, TagIn) ->
+ 'enc_KmeDeviceMonitor'(Val, TagIn);
+
+'enc_KmeDeviceMonitor'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ startDeviceMonitor ->
+ 'enc_KmeStartDeviceMonitor'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ stopDeviceMonitor ->
+ ?RT_BER:encode_null(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeDeviceMonitor'(Bytes, OptOrMand) ->
+ 'dec_KmeDeviceMonitor'(Bytes, OptOrMand, []).
+
+'dec_KmeDeviceMonitor'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'startDeviceMonitor'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeStartDeviceMonitor'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{startDeviceMonitor, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'stopDeviceMonitor'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_null(Bytes1,[{tag,128,1,'EXPLICIT',32}], mandatory),
+ {{stopDeviceMonitor, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeSystemData
+%%================================
+
+'enc_KmeSystemData'({'KmeSystemData',Val}, TagIn) ->
+ 'enc_KmeSystemData'(Val, TagIn);
+
+'enc_KmeSystemData'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ getSystemData ->
+ 'enc_KmeGetSystemData'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ setSystemData ->
+ 'enc_KmeSetSystemData'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ systemDataChanged ->
+ 'enc_KmeSystemDataChanged'(element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ systemDataLinkedReply ->
+ 'enc_KmeSystemDataLinkedReply'(element(2,Val), [{tag,128,3,'EXPLICIT',32}]);
+ getSystemDataPosAck ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,4,'EXPLICIT',32}]);
+ lockSystemData ->
+ 'enc_KmeLockSystemData'(element(2,Val), [{tag,128,5,'EXPLICIT',32}]);
+ systemDataStatus ->
+ 'enc_KmeSystemDataStatus'(element(2,Val), [{tag,128,6,'EXPLICIT',32}]);
+ dataRevisionRecord ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,7,'EXPLICIT',32}]);
+ getDataRevisionRecord ->
+ 'enc_KmeGetSystemDataRevision'(element(2,Val), [{tag,128,8,'EXPLICIT',32}]);
+ setprogrammingEventOn ->
+ 'enc_KmeSetProgrammingEventOn'(element(2,Val), [{tag,128,9,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeSystemData'(Bytes, OptOrMand) ->
+ 'dec_KmeSystemData'(Bytes, OptOrMand, []).
+
+'dec_KmeSystemData'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'getSystemData'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemData'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{getSystemData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'setSystemData'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSetSystemData'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{setSystemData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'systemDataChanged'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSystemDataChanged'(Bytes1, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+ {{systemDataChanged, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'systemDataLinkedReply'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSystemDataLinkedReply'(Bytes1, mandatory, [{tag,128,3,'EXPLICIT',32}]),
+ {{systemDataLinkedReply, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'getSystemDataPosAck'
+ <<2:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,[],[{tag,128,4,'EXPLICIT',32}], no_length, mandatory),
+ {{getSystemDataPosAck, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'lockSystemData'
+ <<2:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeLockSystemData'(Bytes1, mandatory, [{tag,128,5,'EXPLICIT',32}]),
+ {{lockSystemData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'systemDataStatus'
+ <<2:2,_:1,6:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSystemDataStatus'(Bytes1, mandatory, [{tag,128,6,'EXPLICIT',32}]),
+ {{systemDataStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'dataRevisionRecord'
+ <<2:2,_:1,7:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{0,128},[{tag,128,7,'EXPLICIT',32}], no_length, mandatory),
+ {{dataRevisionRecord, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'getDataRevisionRecord'
+ <<2:2,_:1,8:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGetSystemDataRevision'(Bytes1, mandatory, [{tag,128,8,'EXPLICIT',32}]),
+ {{getDataRevisionRecord, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'setprogrammingEventOn'
+ <<2:2,_:1,9:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSetProgrammingEventOn'(Bytes1, mandatory, [{tag,128,9,'EXPLICIT',32}]),
+ {{setprogrammingEventOn, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeAdditionalData
+%%================================
+
+'enc_KmeAdditionalData'({'KmeAdditionalData',Val}, TagIn) ->
+ 'enc_KmeAdditionalData'(Val, TagIn);
+
+'enc_KmeAdditionalData'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ fowardType ->
+ case (case element(2,Val) of {_,Enumval1}->Enumval1;_->element(2,Val) end) of
+forwardImmediate -> ?RT_BER:encode_enumerated(0,[{tag,128,1,'EXPLICIT',32}]);
+forwardBusy -> ?RT_BER:encode_enumerated(1,[{tag,128,1,'EXPLICIT',32}]);
+forwardNoAns -> ?RT_BER:encode_enumerated(2,[{tag,128,1,'EXPLICIT',32}]);
+forwardBusyInt -> ?RT_BER:encode_enumerated(3,[{tag,128,1,'EXPLICIT',32}]);
+forwardBusyExt -> ?RT_BER:encode_enumerated(4,[{tag,128,1,'EXPLICIT',32}]);
+forwardNoAnsInt -> ?RT_BER:encode_enumerated(5,[{tag,128,1,'EXPLICIT',32}]);
+forwardNoAnsExt -> ?RT_BER:encode_enumerated(6,[{tag,128,1,'EXPLICIT',32}]);
+forwardImmInt -> ?RT_BER:encode_enumerated(7,[{tag,128,1,'EXPLICIT',32}]);
+forwardImmExt -> ?RT_BER:encode_enumerated(8,[{tag,128,1,'EXPLICIT',32}]);
+forwardDND -> ?RT_BER:encode_enumerated(9,[{tag,128,1,'EXPLICIT',32}]);
+forwardDNDInt -> ?RT_BER:encode_enumerated(10,[{tag,128,1,'EXPLICIT',32}]);
+forwardDNDExt -> ?RT_BER:encode_enumerated(11,[{tag,128,1,'EXPLICIT',32}]);
+forwardBusyNoAnswer -> ?RT_BER:encode_enumerated(12,[{tag,128,1,'EXPLICIT',32}]);
+forwardBusyNoAnswerInt -> ?RT_BER:encode_enumerated(13,[{tag,128,1,'EXPLICIT',32}]);
+forwardBusyNoAnswerExt -> ?RT_BER:encode_enumerated(14,[{tag,128,1,'EXPLICIT',32}]);
+Enumval2 -> exit({error,{asn1, {enumerated_not_in_range,Enumval2}}})
+end;
+ trunkId ->
+ 'enc_KmeTrunkId'(element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ otherDevice ->
+ case (case element(2,Val) of {_,Enumval3}->Enumval3;_->element(2,Val) end) of
+vm -> ?RT_BER:encode_enumerated(0,[{tag,128,3,'EXPLICIT',32}]);
+doorPhone -> ?RT_BER:encode_enumerated(1,[{tag,128,3,'EXPLICIT',32}]);
+disa -> ?RT_BER:encode_enumerated(2,[{tag,128,3,'EXPLICIT',32}]);
+pagingGroup -> ?RT_BER:encode_enumerated(3,[{tag,128,3,'EXPLICIT',32}]);
+psGruop -> ?RT_BER:encode_enumerated(4,[{tag,128,3,'EXPLICIT',32}]);
+externalRinger -> ?RT_BER:encode_enumerated(5,[{tag,128,3,'EXPLICIT',32}]);
+externalSensor -> ?RT_BER:encode_enumerated(6,[{tag,128,3,'EXPLICIT',32}]);
+externalPager -> ?RT_BER:encode_enumerated(7,[{tag,128,3,'EXPLICIT',32}]);
+modem -> ?RT_BER:encode_enumerated(8,[{tag,128,3,'EXPLICIT',32}]);
+hdlc -> ?RT_BER:encode_enumerated(9,[{tag,128,3,'EXPLICIT',32}]);
+pbxSystem -> ?RT_BER:encode_enumerated(10,[{tag,128,3,'EXPLICIT',32}]);
+svm -> ?RT_BER:encode_enumerated(11,[{tag,128,3,'EXPLICIT',32}]);
+Enumval4 -> exit({error,{asn1, {enumerated_not_in_range,Enumval4}}})
+end;
+ vmRecExtNo ->
+ ?RT_BER:encode_restricted_string([], element(2,Val), 22, [{tag,128,4,'EXPLICIT',32}]);
+ deviceCategory ->
+ 'enc_KmeChangedDeviceCategory'(element(2,Val), [{tag,128,5,'EXPLICIT',32}]);
+ device ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,6,'EXPLICIT',32}]);
+ featureNumber ->
+ ?RT_BER:encode_integer([], element(2,Val), [{tag,128,7,'EXPLICIT',32}]);
+ proprietaryContents ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,8,'EXPLICIT',32}]);
+ holdType ->
+ case (case element(2,Val) of {_,Enumval8}->Enumval8;_->element(2,Val) end) of
+consultation -> ?RT_BER:encode_enumerated(0,[{tag,128,9,'EXPLICIT',32}]);
+normal -> ?RT_BER:encode_enumerated(1,[{tag,128,9,'EXPLICIT',32}]);
+exclusive -> ?RT_BER:encode_enumerated(2,[{tag,128,9,'EXPLICIT',32}]);
+Enumval9 -> exit({error,{asn1, {enumerated_not_in_range,Enumval9}}})
+end;
+ conditionCode ->
+ case (case element(2,Val) of {_,Enumval10}->Enumval10;_->element(2,Val) end) of
+cl -> ?RT_BER:encode_enumerated(0,[{tag,128,10,'EXPLICIT',32}]);
+tr -> ?RT_BER:encode_enumerated(1,[{tag,128,10,'EXPLICIT',32}]);
+fw -> ?RT_BER:encode_enumerated(2,[{tag,128,10,'EXPLICIT',32}]);
+d0 -> ?RT_BER:encode_enumerated(3,[{tag,128,10,'EXPLICIT',32}]);
+rm -> ?RT_BER:encode_enumerated(4,[{tag,128,10,'EXPLICIT',32}]);
+na -> ?RT_BER:encode_enumerated(5,[{tag,128,10,'EXPLICIT',32}]);
+Enumval11 -> exit({error,{asn1, {enumerated_not_in_range,Enumval11}}})
+end;
+ lockDisplay ->
+ ?RT_BER:encode_boolean(element(2,Val), [{tag,128,11,'EXPLICIT',32}]);
+ forcedAlerting ->
+ ?RT_BER:encode_bit_string([], element(2,Val), [{fwdDnd,0},{timer,1}], [{tag,128,12,'EXPLICIT',32}]);
+ callID ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,13,'EXPLICIT',32}]);
+ ogmContinuation ->
+ ?RT_BER:encode_boolean(element(2,Val), [{tag,128,14,'EXPLICIT',32}]);
+ broadcastGroupNo ->
+ ?RT_BER:encode_integer([], element(2,Val), [{tag,128,15,'EXPLICIT',32}]);
+ ringPattern ->
+ ?RT_BER:encode_integer([], element(2,Val), [{tag,128,16,'EXPLICIT',32}]);
+ didNo ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(element(2,Val), [{tag,128,17,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeAdditionalData'(Bytes, OptOrMand) ->
+ 'dec_KmeAdditionalData'(Bytes, OptOrMand, []).
+
+'dec_KmeAdditionalData'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'fowardType'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{forwardImmediate,0},{forwardBusy,1},{forwardNoAns,2},{forwardBusyInt,3},{forwardBusyExt,4},{forwardNoAnsInt,5},{forwardNoAnsExt,6},{forwardImmInt,7},{forwardImmExt,8},{forwardDND,9},{forwardDNDInt,10},{forwardDNDExt,11},{forwardBusyNoAnswer,12},{forwardBusyNoAnswerInt,13},{forwardBusyNoAnswerExt,14}],[{tag,128,1,'EXPLICIT',32}], mandatory),
+ {{fowardType, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'trunkId'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeTrunkId'(Bytes1, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+ {{trunkId, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'otherDevice'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{vm,0},{doorPhone,1},{disa,2},{pagingGroup,3},{psGruop,4},{externalRinger,5},{externalSensor,6},{externalPager,7},{modem,8},{hdlc,9},{pbxSystem,10},{svm,11}],[{tag,128,3,'EXPLICIT',32}], mandatory),
+ {{otherDevice, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'vmRecExtNo'
+ <<2:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_restricted_string(Bytes1,{1,5},22,[{tag,128,4,'EXPLICIT',32}], no_length, mandatory),
+ {{vmRecExtNo, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'deviceCategory'
+ <<2:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeChangedDeviceCategory'(Bytes1, mandatory, [{tag,128,5,'EXPLICIT',32}]),
+ {{deviceCategory, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'device'
+ <<2:2,_:1,6:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,6,'EXPLICIT',32}]),
+ {{device, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'featureNumber'
+ <<2:2,_:1,7:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_integer(Bytes1,[],[{tag,128,7,'EXPLICIT',32}], mandatory),
+ {{featureNumber, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'proprietaryContents'
+ <<2:2,_:1,8:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{0,144},[{tag,128,8,'EXPLICIT',32}], no_length, mandatory),
+ {{proprietaryContents, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'holdType'
+ <<2:2,_:1,9:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{consultation,0},{normal,1},{exclusive,2}],[{tag,128,9,'EXPLICIT',32}], mandatory),
+ {{holdType, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'conditionCode'
+ <<2:2,_:1,10:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_enumerated(Bytes1,[],[{cl,0},{tr,1},{fw,2},{d0,3},{rm,4},{na,5}],[{tag,128,10,'EXPLICIT',32}], mandatory),
+ {{conditionCode, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'lockDisplay'
+ <<2:2,_:1,11:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_boolean(Bytes1,[{tag,128,11,'EXPLICIT',32}], mandatory),
+ {{lockDisplay, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'forcedAlerting'
+ <<2:2,_:1,12:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_bit_string(Bytes1,[],[{fwdDnd,0},{timer,1}],[{tag,128,12,'EXPLICIT',32}], no_length, mandatory),
+ {{forcedAlerting, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'callID'
+ <<2:2,_:1,13:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,[],[{tag,128,13,'EXPLICIT',32}], no_length, mandatory),
+ {{callID, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'ogmContinuation'
+ <<2:2,_:1,14:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_boolean(Bytes1,[{tag,128,14,'EXPLICIT',32}], mandatory),
+ {{ogmContinuation, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'broadcastGroupNo'
+ <<2:2,_:1,15:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_integer(Bytes1,[],[{tag,128,15,'EXPLICIT',32}], mandatory),
+ {{broadcastGroupNo, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'ringPattern'
+ <<2:2,_:1,16:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_integer(Bytes1,[],[{tag,128,16,'EXPLICIT',32}], mandatory),
+ {{ringPattern, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'didNo'
+ <<2:2,_:1,17:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'CSTA-device-identifiers':'dec_DeviceID'(Bytes1, mandatory, [{tag,128,17,'EXPLICIT',32}]),
+ {{didNo, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmePrivateEvent
+%%================================
+
+'enc_KmePrivateEvent'({'KmePrivateEvent',Val}, TagIn) ->
+ 'enc_KmePrivateEvent'(Val, TagIn);
+
+'enc_KmePrivateEvent'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ digitsReport ->
+ 'enc_KmeDigitsReport'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ ogmStatus ->
+ 'enc_KmeOgmStatus'(element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ wakeupResult ->
+ 'enc_KmeWakeupResult'(element(2,Val), [{tag,128,3,'EXPLICIT',32}]);
+ unconferenced ->
+ 'enc_KmeUnconferenced'(element(2,Val), [{tag,128,4,'EXPLICIT',32}]);
+ tamEnded ->
+ 'enc_KmeTamEnded'(element(2,Val), [{tag,128,5,'EXPLICIT',32}]);
+ pcRecEnded ->
+ 'enc_KmePcRecEnded'(element(2,Val), [{tag,128,6,'EXPLICIT',32}]);
+ callbackNotification ->
+ 'enc_CallBackNotification'(element(2,Val), [{tag,128,7,'EXPLICIT',32}]);
+ freeOgmPort ->
+ ?RT_BER:encode_integer([], element(2,Val), [{tag,128,8,'EXPLICIT',32}]);
+ pDFStatus ->
+ 'enc_KmePDFStatus'(element(2,Val), [{tag,128,9,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmePrivateEvent'(Bytes, OptOrMand) ->
+ 'dec_KmePrivateEvent'(Bytes, OptOrMand, []).
+
+'dec_KmePrivateEvent'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'digitsReport'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDigitsReport'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{digitsReport, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'ogmStatus'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeOgmStatus'(Bytes1, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+ {{ogmStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'wakeupResult'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeWakeupResult'(Bytes1, mandatory, [{tag,128,3,'EXPLICIT',32}]),
+ {{wakeupResult, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'unconferenced'
+ <<2:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeUnconferenced'(Bytes1, mandatory, [{tag,128,4,'EXPLICIT',32}]),
+ {{unconferenced, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'tamEnded'
+ <<2:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeTamEnded'(Bytes1, mandatory, [{tag,128,5,'EXPLICIT',32}]),
+ {{tamEnded, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'pcRecEnded'
+ <<2:2,_:1,6:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmePcRecEnded'(Bytes1, mandatory, [{tag,128,6,'EXPLICIT',32}]),
+ {{pcRecEnded, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'callbackNotification'
+ <<2:2,_:1,7:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_CallBackNotification'(Bytes1, mandatory, [{tag,128,7,'EXPLICIT',32}]),
+ {{callbackNotification, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'freeOgmPort'
+ <<2:2,_:1,8:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_integer(Bytes1,[],[{tag,128,8,'EXPLICIT',32}], mandatory),
+ {{freeOgmPort, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'pDFStatus'
+ <<2:2,_:1,9:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmePDFStatus'(Bytes1, mandatory, [{tag,128,9,'EXPLICIT',32}]),
+ {{pDFStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeResourceControl
+%%================================
+
+'enc_KmeResourceControl'({'KmeResourceControl',Val}, TagIn) ->
+ 'enc_KmeResourceControl'(Val, TagIn);
+
+'enc_KmeResourceControl'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ ogmStart ->
+ 'enc_KmeOgmStart'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ ogmStop ->
+ 'enc_KmeOgmStop'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeResourceControl'(Bytes, OptOrMand) ->
+ 'dec_KmeResourceControl'(Bytes, OptOrMand, []).
+
+'dec_KmeResourceControl'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'ogmStart'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeOgmStart'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{ogmStart, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'ogmStop'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeOgmStop'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{ogmStop, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeOgmStart
+%%================================
+'enc_KmeOgmStart'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = 'CSTA-call-connection-identifiers':'enc_ConnectionID'(?RT_BER:cindex(2,Val,connection), []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = ?RT_BER:encode_integer([], ?RT_BER:cindex(3,Val,ogmId), []),
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeOgmStart'(Bytes, OptOrMand) ->
+ 'dec_KmeOgmStart'(Bytes, OptOrMand, []).
+
+'dec_KmeOgmStart'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 External CSTA-call-connection-identifiers:ConnectionID
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = 'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes2, mandatory, []),
+
+%%-------------------------------------------------
+%% attribute number 2 with type INTEGER
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = ?RT_BER:decode_integer(Bytes3,[],[], mandatory),
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeOgmStart', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeOgmStop
+%%================================
+
+'enc_KmeOgmStop'({'KmeOgmStop',Val}, TagIn) ->
+ 'enc_KmeOgmStop'(Val, TagIn);
+
+'enc_KmeOgmStop'(Val, TagIn) ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(Val, TagIn ++ []).
+
+
+'dec_KmeOgmStop'(Bytes, OptOrMand) ->
+ 'dec_KmeOgmStop'(Bytes, OptOrMand, []).
+
+'dec_KmeOgmStop'(Bytes, OptOrMand, TagIn) ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes, OptOrMand, TagIn++[]).
+
+
+
+%%================================
+%% KmeGenericSrvEvt
+%%================================
+
+'enc_KmeGenericSrvEvt'({'KmeGenericSrvEvt',Val}, TagIn) ->
+ 'enc_KmeGenericSrvEvt'(Val, TagIn);
+
+'enc_KmeGenericSrvEvt'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ serviceRequest ->
+ 'enc_KmeGenericServiceReq'(element(2,Val), [{tag,128,0,'EXPLICIT',32}]);
+ serviceResult ->
+ 'enc_KmeGenericServiceRsp'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ event ->
+ 'enc_KmeGenericEvent'(element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KmeGenericSrvEvt'(Bytes, OptOrMand) ->
+ 'dec_KmeGenericSrvEvt'(Bytes, OptOrMand, []).
+
+'dec_KmeGenericSrvEvt'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'serviceRequest'
+ <<2:2,_:1,0:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGenericServiceReq'(Bytes1, mandatory, [{tag,128,0,'EXPLICIT',32}]),
+ {{serviceRequest, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'serviceResult'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGenericServiceRsp'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{serviceResult, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'event'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGenericEvent'(Bytes1, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+ {{event, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.
+
+
+%%================================
+%% KmeGenericServiceReq
+%%================================
+'enc_KmeGenericServiceReq'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,serviceNo), []),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,device) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(3,Val,device), [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-call-connection-identifiers:ConnectionID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,connection) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(?RT_BER:cindex(4,Val,connection), [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 4 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,number) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(5,Val,number), [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 5 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes5,EncLen5} = case ?RT_BER:cindex(6,Val,string) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(6,Val,string), 22, [])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4, EncBytes5],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4 + EncLen5,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeGenericServiceReq'(Bytes, OptOrMand) ->
+ 'dec_KmeGenericServiceReq'(Bytes, OptOrMand, []).
+
+'dec_KmeGenericServiceReq'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<0:2,_:1,16:5,_/binary>> ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes3, opt_or_default, []);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-call-connection-identifiers:ConnectionID OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<1:2,_:1,11:5,_/binary>> ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes4, opt_or_default, []);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 4 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<0:2,_:1,2:5,_/binary>> ->
+?RT_BER:decode_integer(Bytes5,[],[], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 5 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term5,Bytes7,Rb6} = case Bytes6 of
+<<0:2,_:1,22:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes6,{0,128},22,[], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes6, 0 }
+end,
+
+ {Bytes8,Rb7} = ?RT_BER:restbytes2(RemBytes, Bytes7,noext),
+ {{'KmeGenericServiceReq', Term1, Term2, Term3, Term4, Term5}, Bytes8, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6+Rb7}.
+
+
+%%================================
+%% KmeGenericServiceRsp
+%%================================
+'enc_KmeGenericServiceRsp'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = case ?RT_BER:cindex(2,Val,number) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,number), [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,string) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(3,Val,string), 22, [])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2],
+ LenSoFar = EncLen1 + EncLen2,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeGenericServiceRsp'(Bytes, OptOrMand) ->
+ 'dec_KmeGenericServiceRsp'(Bytes, OptOrMand, []).
+
+'dec_KmeGenericServiceRsp'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = case Bytes2 of
+<<0:2,_:1,2:5,_/binary>> ->
+?RT_BER:decode_integer(Bytes2,[],[], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes2, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 2 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<0:2,_:1,22:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes3,{0,128},22,[], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+ {Bytes5,Rb4} = ?RT_BER:restbytes2(RemBytes, Bytes4,noext),
+ {{'KmeGenericServiceRsp', Term1, Term2}, Bytes5, Rb1+Rb2+Rb3+Rb4}.
+
+
+%%================================
+%% KmeGenericEvent
+%%================================
+'enc_KmeGenericEvent'(Val, TagIn) ->
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {EncBytes1,EncLen1} = ?RT_BER:encode_integer([], ?RT_BER:cindex(2,Val,eventNo), []),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes2,EncLen2} = case ?RT_BER:cindex(3,Val,device) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-device-identifiers':'enc_DeviceID'(?RT_BER:cindex(3,Val,device), [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-call-connection-identifiers:ConnectionID OPTIONAL
+%%-------------------------------------------------
+ {EncBytes3,EncLen3} = case ?RT_BER:cindex(4,Val,connection) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ 'CSTA-call-connection-identifiers':'enc_ConnectionID'(?RT_BER:cindex(4,Val,connection), [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 4 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {EncBytes4,EncLen4} = case ?RT_BER:cindex(5,Val,state) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ case (case ?RT_BER:cindex(5,Val,state) of {_,Enumval2}->Enumval2;_->?RT_BER:cindex(5,Val,state) end) of
+null -> ?RT_BER:encode_enumerated(0,[{tag,64,14,'IMPLICIT',32}]);
+initiated -> ?RT_BER:encode_enumerated(1,[{tag,64,14,'IMPLICIT',32}]);
+alerting -> ?RT_BER:encode_enumerated(2,[{tag,64,14,'IMPLICIT',32}]);
+connected -> ?RT_BER:encode_enumerated(3,[{tag,64,14,'IMPLICIT',32}]);
+hold -> ?RT_BER:encode_enumerated(4,[{tag,64,14,'IMPLICIT',32}]);
+queued -> ?RT_BER:encode_enumerated(5,[{tag,64,14,'IMPLICIT',32}]);
+fail -> ?RT_BER:encode_enumerated(6,[{tag,64,14,'IMPLICIT',32}]);
+Enumval3 -> exit({error,{asn1, {enumerated_not_in_range,Enumval3}}})
+end
+ end,
+
+%%-------------------------------------------------
+%% attribute number 5 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {EncBytes5,EncLen5} = case ?RT_BER:cindex(6,Val,cause) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_integer([], ?RT_BER:cindex(6,Val,cause), [])
+ end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {EncBytes6,EncLen6} = case ?RT_BER:cindex(7,Val,message) of
+ asn1_NOVALUE -> {<<>>,0};
+ _ ->
+ ?RT_BER:encode_restricted_string([], ?RT_BER:cindex(7,Val,message), 22, [])
+ end,
+
+ BytesSoFar = [EncBytes1, EncBytes2, EncBytes3, EncBytes4, EncBytes5, EncBytes6],
+ LenSoFar = EncLen1 + EncLen2 + EncLen3 + EncLen4 + EncLen5 + EncLen6,
+ ?RT_BER:encode_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], BytesSoFar, LenSoFar).
+
+
+'dec_KmeGenericEvent'(Bytes, OptOrMand) ->
+ 'dec_KmeGenericEvent'(Bytes, OptOrMand, []).
+
+'dec_KmeGenericEvent'(Bytes, OptOrMand, TagIn) ->
+ %%-------------------------------------------------
+ %% decode tag and length
+ %%-------------------------------------------------
+ {{_,Len},Bytes1,Rb1} = ?RT_BER:check_tags(TagIn ++ [{tag,0,16,'IMPLICIT',32}], Bytes, OptOrMand),
+{Bytes2,RemBytes} = ?RT_BER:split_list(Bytes1,Len),
+
+%%-------------------------------------------------
+%% attribute number 1 with type INTEGER
+%%-------------------------------------------------
+ {Term1,Bytes3,Rb2} = ?RT_BER:decode_integer(Bytes2,[],[], mandatory),
+
+%%-------------------------------------------------
+%% attribute number 2 External CSTA-device-identifiers:DeviceID OPTIONAL
+%%-------------------------------------------------
+ {Term2,Bytes4,Rb3} = case Bytes3 of
+<<0:2,_:1,16:5,_/binary>> ->
+'CSTA-device-identifiers':'dec_DeviceID'(Bytes3, opt_or_default, []);
+_ ->
+{ asn1_NOVALUE, Bytes3, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 3 External CSTA-call-connection-identifiers:ConnectionID OPTIONAL
+%%-------------------------------------------------
+ {Term3,Bytes5,Rb4} = case Bytes4 of
+<<1:2,_:1,11:5,_/binary>> ->
+'CSTA-call-connection-identifiers':'dec_ConnectionID'(Bytes4, opt_or_default, []);
+_ ->
+{ asn1_NOVALUE, Bytes4, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 4 with type ENUMERATED OPTIONAL
+%%-------------------------------------------------
+ {Term4,Bytes6,Rb5} = case Bytes5 of
+<<1:2,_:1,14:5,_/binary>> ->
+?RT_BER:decode_enumerated(Bytes5,[],[{null,0},{initiated,1},{alerting,2},{connected,3},{hold,4},{queued,5},{fail,6}],[{tag,64,14,'IMPLICIT',32}], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes5, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 5 with type INTEGER OPTIONAL
+%%-------------------------------------------------
+ {Term5,Bytes7,Rb6} = case Bytes6 of
+<<0:2,_:1,2:5,_/binary>> ->
+?RT_BER:decode_integer(Bytes6,[],[], mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes6, 0 }
+end,
+
+%%-------------------------------------------------
+%% attribute number 6 with type IA5String OPTIONAL
+%%-------------------------------------------------
+ {Term6,Bytes8,Rb7} = case Bytes7 of
+<<0:2,_:1,22:5,_/binary>> ->
+?RT_BER:decode_restricted_string(Bytes7,{1,128},22,[], no_length, mandatory);
+_ ->
+{ asn1_NOVALUE, Bytes7, 0 }
+end,
+
+ {Bytes9,Rb8} = ?RT_BER:restbytes2(RemBytes, Bytes8,noext),
+ {{'KmeGenericEvent', Term1, Term2, Term3, Term4, Term5, Term6}, Bytes9, Rb1+Rb2+Rb3+Rb4+Rb5+Rb6+Rb7+Rb8}.
+
+
+%%================================
+%% KMESpecificPrivateData
+%%================================
+
+'enc_KMESpecificPrivateData'({'KMESpecificPrivateData',Val}, TagIn) ->
+ 'enc_KMESpecificPrivateData'(Val, TagIn);
+
+'enc_KMESpecificPrivateData'(Val, TagIn) ->
+ {EncBytes,EncLen} = case element(1,Val) of
+ kmeCallControl ->
+ 'enc_KmeCallControlSrvEvt'(element(2,Val), [{tag,128,1,'EXPLICIT',32}]);
+ kmeDeviceStatus ->
+ 'enc_KmeDeviceStatus'(element(2,Val), [{tag,128,2,'EXPLICIT',32}]);
+ kmeDeviceMonitor ->
+ 'enc_KmeDeviceMonitor'(element(2,Val), [{tag,128,3,'EXPLICIT',32}]);
+ kmeSystemData ->
+ 'enc_KmeSystemData'(element(2,Val), [{tag,128,4,'EXPLICIT',32}]);
+ kmeLocalAlerm ->
+ 'enc_KmeLocalAlerm'(element(2,Val), [{tag,128,5,'EXPLICIT',32}]);
+ kmeAdditionalData ->
+ 'enc_KmeAdditionalData'(element(2,Val), [{tag,128,6,'EXPLICIT',32}]);
+ kmePrivateEvent ->
+ 'enc_KmePrivateEvent'(element(2,Val), [{tag,128,7,'EXPLICIT',32}]);
+ kmeResourceControl ->
+ 'enc_KmeResourceControl'(element(2,Val), [{tag,128,8,'EXPLICIT',32}]);
+ kmeGeneric ->
+ 'enc_KmeGenericSrvEvt'(element(2,Val), [{tag,128,9,'EXPLICIT',32}]);
+ kmeExtendedDataAccess ->
+ ?RT_BER:encode_octet_string([], element(2,Val), [{tag,128,10,'EXPLICIT',32}]);
+ kmePDFControl ->
+ 'enc_KmePDFSrvEvt'(element(2,Val), [{tag,128,11,'EXPLICIT',32}]);
+ kmeAlterIf ->
+ 'enc_KmeAlterIfSrvEvt'(element(2,Val), [{tag,128,12,'EXPLICIT',32}]);
+ kmeHotelControl ->
+ 'enc_KmeHotelSrvEvt'(element(2,Val), [{tag,128,13,'EXPLICIT',32}]);
+ Else ->
+ exit({error,{asn1,{invalid_choice_type,Else}}})
+ end,
+
+?RT_BER:encode_tags(TagIn ++[], EncBytes, EncLen).
+
+
+
+
+'dec_KMESpecificPrivateData'(Bytes, OptOrMand) ->
+ 'dec_KMESpecificPrivateData'(Bytes, OptOrMand, []).
+
+'dec_KMESpecificPrivateData'(Bytes, OptOrMand, TagIn) ->
+ {{_,Len},Bytes1, RbExp} = ?RT_BER:check_tags(TagIn++[], Bytes, OptOrMand),
+ IndefEndBytes = fun(indefinite,<<0,0,R/binary>>)-> R; (_,B)-> B end,
+ IndefEndRb = fun(indefinite,<<0,0,_R/binary>>)-> 2; (_,_)-> 0 end,
+ case Bytes1 of
+
+%% 'kmeCallControl'
+ <<2:2,_:1,1:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeCallControlSrvEvt'(Bytes1, mandatory, [{tag,128,1,'EXPLICIT',32}]),
+ {{kmeCallControl, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeDeviceStatus'
+ <<2:2,_:1,2:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDeviceStatus'(Bytes1, mandatory, [{tag,128,2,'EXPLICIT',32}]),
+ {{kmeDeviceStatus, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeDeviceMonitor'
+ <<2:2,_:1,3:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeDeviceMonitor'(Bytes1, mandatory, [{tag,128,3,'EXPLICIT',32}]),
+ {{kmeDeviceMonitor, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeSystemData'
+ <<2:2,_:1,4:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeSystemData'(Bytes1, mandatory, [{tag,128,4,'EXPLICIT',32}]),
+ {{kmeSystemData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeLocalAlerm'
+ <<2:2,_:1,5:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeLocalAlerm'(Bytes1, mandatory, [{tag,128,5,'EXPLICIT',32}]),
+ {{kmeLocalAlerm, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeAdditionalData'
+ <<2:2,_:1,6:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeAdditionalData'(Bytes1, mandatory, [{tag,128,6,'EXPLICIT',32}]),
+ {{kmeAdditionalData, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmePrivateEvent'
+ <<2:2,_:1,7:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmePrivateEvent'(Bytes1, mandatory, [{tag,128,7,'EXPLICIT',32}]),
+ {{kmePrivateEvent, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeResourceControl'
+ <<2:2,_:1,8:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeResourceControl'(Bytes1, mandatory, [{tag,128,8,'EXPLICIT',32}]),
+ {{kmeResourceControl, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeGeneric'
+ <<2:2,_:1,9:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeGenericSrvEvt'(Bytes1, mandatory, [{tag,128,9,'EXPLICIT',32}]),
+ {{kmeGeneric, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeExtendedDataAccess'
+ <<2:2,_:1,10:5,_/binary>> ->
+ {Dec, Rest, RbCho} = ?RT_BER:decode_octet_string(Bytes1,{0,200},[{tag,128,10,'EXPLICIT',32}], no_length, mandatory),
+ {{kmeExtendedDataAccess, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmePDFControl'
+ <<2:2,_:1,11:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmePDFSrvEvt'(Bytes1, mandatory, [{tag,128,11,'EXPLICIT',32}]),
+ {{kmePDFControl, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeAlterIf'
+ <<2:2,_:1,12:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeAlterIfSrvEvt'(Bytes1, mandatory, [{tag,128,12,'EXPLICIT',32}]),
+ {{kmeAlterIf, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+
+%% 'kmeHotelControl'
+ <<2:2,_:1,13:5,_/binary>> ->
+ {Dec, Rest, RbCho} = 'dec_KmeHotelSrvEvt'(Bytes1, mandatory, [{tag,128,13,'EXPLICIT',32}]),
+ {{kmeHotelControl, Dec}, IndefEndBytes(Len,Rest), RbExp + RbCho + IndefEndRb(Len,Rest)};
+
+ Else ->
+ case OptOrMand of
+ mandatory ->exit({error,{asn1,{invalid_choice_tag,Else}}});
+ _ ->exit({error,{asn1,{no_optional_tag,Else}}})
+ end
+ end.