IHeartbeatParser

Interface for parsing heartbeat protobuf messages in KMM Bridges platform-specific protobuf implementations to common KMM code

Inheritors

Functions

Link copied to clipboard
abstract fun appendRssiToHeartbeat(data: ByteArray, rssi: Int): ByteArray

Returns heartbeat protobuf bytes with bridge RSSI set. RSSI is not sent by the device; the bridge adds it before forwarding to the server.

Link copied to clipboard
abstract fun getDevId(heartbeatData: HeartbeatData): UInt

Get the device ID from parsed heartbeat data

Link copied to clipboard

Get the firmware version from parsed heartbeat data

Link copied to clipboard
abstract fun getLastOOBServerTimestamp(heartbeatData: HeartbeatData): Long?

Get the last OOB server timestamp

Link copied to clipboard
abstract fun getMfrId(heartbeatData: HeartbeatData): UInt?

Get the manufacturer ID from parsed heartbeat data

Link copied to clipboard
abstract fun getRssi(heartbeatData: HeartbeatData): Int?

Get the RSSI value from parsed heartbeat data

Link copied to clipboard
abstract fun getSigBmp(heartbeatData: HeartbeatData): UInt

Get the signal bitmap from parsed heartbeat data

Link copied to clipboard
abstract fun getTimestamp(heartbeatData: HeartbeatData): UInt?

Get the timestamp from parsed heartbeat data

Link copied to clipboard
abstract fun parseHeartbeat(data: ByteArray): HeartbeatData?

Parse heartbeat data from byte array