KAATcpKaaSync Class Reference
Inherits from | KAAMqttFrame : NSObject |
---|---|
Declared in | KAATcpKaaSync.h |
Overview
KaaSync message class.
The KAASYNC message is used as intermediate class for decoding messages
SyncRequest,SyncResponse,BootstrapResolve,BootstrapResponse.
Variable header
Protocol Name
byte 1 Length MSB (0)
byte 2 Length LSB (6)
byte 3 K
byte 4 a
byte 5 a
byte 6 t
byte 7 c
byte 8 p
Protocol version
byte 9 Version (1)
Message ID (2 bytes)
byte 10 ID MSB
byte 11 ID LSB
Flags
byte 12
Request/Response (bit 0)
1 - request, 0 - response
Zipped (bit 1)
1 - zepped, 0 - unzipped
Encrypted(bit 2)
1 - encrypted, 0 - unencrypted
Unused(bit 3)
bit4-bit7 - KAASYNC subcomand messageIdid
KAASYNC subcomand id table
Mnemonic | Enumeration | Description |
UNUSED | 0 | reserved value |
SYNC | 1 | Sync request/response |
BOOTSTRAP | 2 | Bootstrap resolve/response |
– initRequest:zipped:encypted:
Default constructor.
- (instancetype)initRequest:(BOOL)isRequest zipped:(BOOL)isZipped encypted:(BOOL)isEncrypted
Parameters
isRequest |
boolean ‘true’ is request, else response |
---|---|
isZipped |
boolean if message is Zipped |
isEcrypted |
boolean if message is Encrypted |
Discussion
Default constructor.
Declared In
KAATcpKaaSync.h