GSM48: Be able to parse a GSM IMSI Detach message
This commit is contained in:
parent
46231d5a0e
commit
ded50cff4d
17
GSM48.st
17
GSM48.st
|
@ -498,6 +498,7 @@ GSM48MSG subclass: GSM48MMMessage [
|
|||
GSM48MMMessage class >> msgAuReq [ ^ 16r12 ]
|
||||
GSM48MMMessage class >> msgAuRes [ ^ 16r14 ]
|
||||
GSM48MMMessage class >> msgCMReq [ ^ 16r24 ]
|
||||
GSM48MMMessage class >> msgIMSIDetach [ ^ 16r01 ]
|
||||
]
|
||||
|
||||
GSM48MMMessage subclass: LocationUpdatingRequest [
|
||||
|
@ -639,6 +640,21 @@ GSM48MMMessage subclass: CMServiceRequest [
|
|||
|
||||
]
|
||||
|
||||
GSM48MMMessage subclass: IMSIDetachIndication [
|
||||
<category: 'osmo-message'>
|
||||
|
||||
Mandantory := nil.
|
||||
IMSIDetachIndication class >> messageType [ ^ self msgIMSIDetach ]
|
||||
IMSIDetachIndication class >> Mandantory [
|
||||
^ Mandantory ifNil: [ Mandantory := OrderedCollection new ].
|
||||
]
|
||||
|
||||
IMSIDetachIndication class >> initialize [
|
||||
self addMandantory: 'cm1' with: GSM48Classmark1.
|
||||
self addMandantory: 'mi' with: GSM48MIdentity.
|
||||
]
|
||||
]
|
||||
|
||||
Eval [
|
||||
LocationUpdatingRequest initialize.
|
||||
LocationUpdatingReject initialize.
|
||||
|
@ -648,4 +664,5 @@ Eval [
|
|||
IdentityRequest initialize.
|
||||
IdentityResponse initialize.
|
||||
CMServiceRequest initialize.
|
||||
IMSIDetachIndication initialize.
|
||||
]
|
||||
|
|
5
Tests.st
5
Tests.st
|
@ -311,5 +311,10 @@ TestCase subclass: TestMessages [
|
|||
inp := #(1 205 4 5 2 2 4 2 66 254 15 33 0 31 87 5 8 0 114 244 128 16 3 156 64 23 16 5 36 17 3 51 25 129 8 41 32 1 153 118 6 1 152 33 1 0) asByteArray.
|
||||
msg := MSGParser parse: inp.
|
||||
self assert: msg toMessage asByteArray = inp.
|
||||
|
||||
"IMSI Detach Ind"
|
||||
inp := #(1 255 4 5 2 2 4 2 66 254 15 29 0 27 87 5 8 0 114 244 128 16 3 156 64 23 12 5 1 51 8 41 65 112 6 16 9 71 34 33 1 0 ) asByteArray.
|
||||
msg := MSGParser parse: inp.
|
||||
self assert: msg toMessage asByteArray = inp.
|
||||
]
|
||||
]
|
||||
|
|
Reference in New Issue