Add all BENNC message types with unit tests

This commit is contained in:
Jack Hadrill
2022-02-06 20:34:13 +00:00
parent 7d1a0991e4
commit e758de7ef4
28 changed files with 708 additions and 12539 deletions

View File

@@ -1,6 +1,12 @@
export const MAX_DATA_LENGTH = 1000
export enum ByteLength {
UInt16 = 2,
UInt32 = 4
export const DEFAULT_KEY = Buffer.alloc(16)
export enum MessageTypes {
Subscribe = 0x0000,
Basic = 0x0001,
UserDataRequest = 0x0002,
UserDataResponse = 0x0003,
Keepalive = 0x0005,
Unsubscribe = 0xFFFF
}