P25 Opcodes for Login & Logout

Status
Not open for further replies.

Gilligan

Member
Database Admin
Joined
Dec 19, 2002
Messages
2,136
Reaction score
9
Location
Hagerstown, MD
I see that login opcodes are 2C and AC prefix and that logout opcodes are 2F and AF. I am curious as to why there are two of these for login/logout and not just one like the other opcodes. If I am writing software to decode them, should I differentiate between them or just decode them as if they are the same? Thanks!

Examples:

Here are two separate units logging in with 2C and AC:
2C
00 02 77 27 FB 17 27 FB 17 F9 DE -- 2620183 - Unit Registration
AC
00 02 77 27 FC 23 27 FC 23 73 66 -- 2620451 - Unit Registration

Here is the same unit logging out with 2F and then AF:
2F
00 00 BE E0 02 77 27 FB 15 02 A5 -- 2620181 - De-Registration
AF
00 00 BE E0 02 77 27 FB 15 E6 91 -- 2620181 - De-Registration

Why two opcodes for each function?
 

Jay911

Silent Key (April 15th, 2023)
Feed Provider
Joined
Feb 15, 2002
Messages
9,378
Reaction score
380
Location
Bragg Creek, Alberta
The ones beginning with "A" indicate that the TSBK being sent is the last block. The opcode is actually only the last six bits of the first hex pair, not all eight. The first bit indicates whether this is the "last block" or not - as told to me by Rick Parrish (Unitrunker), some systems send TSBKs in blocks of 3 or so - and the 2nd bit indicates whether the opcode is in Protected (encrypted) mode or not.

Get the binary representation of the two-digit hex value and take only the rightmost six bits. Or, check to see if the decimal value of the two-digit hex value is >127, and if it is, subtract dec 128.
 
Status
Not open for further replies.
Top