feat: Add Status Message module support (#4163)

Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com>
This commit is contained in:
James Rich 2026-01-25 08:15:47 -06:00 committed by GitHub
parent df592d4d86
commit 355d2260e8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
15 changed files with 1195 additions and 9 deletions

View file

@ -90,10 +90,11 @@ data class DataPacket(
/** If this is a text message, return the string, otherwise null */
val text: String?
get() =
if (dataType == Portnums.PortNum.TEXT_MESSAGE_APP_VALUE) {
bytes?.decodeToString()
} else {
null
when (dataType) {
Portnums.PortNum.TEXT_MESSAGE_APP_VALUE -> bytes?.decodeToString()
// Portnums.PortNum.NODE_STATUS_APP_VALUE ->
// MeshProtos.StatusMessage.parseFrom(bytes).status
else -> null
}
val alert: String?