Include and qualify Meshtext in RAK4631 Full Companion

Port Meshtext settings to verified atomic nRF52 storage and use the existing radio RNG and hardware entropy. Keep the ExtraFS boundary, GPS, contacts, channel count and 8 KiB stack unchanged; omit unused library data to fit the image. Require linked codec and Companion transport evidence and build the real RAK Full profile in CI. Add configuration and storage-failure regression coverage.
This commit is contained in:
mikecarper committed 2026-10-12 22:39:00 -07:00
1 parent 7e5eabe81c
commit 65820d0dd2
13 files changed
+515 -9

No files matched your search

+8
View File
@@ -265,6 +265,11 @@ bool modemConfig(Region region, Preset preset, RadioProfileParams& params, uint3
return true;
}
// Keep the nRF52 codec entry points visible under LTO so release qualification
// can verify executable send/receive code instead of assuming a feature flag.
#if defined(NRF52_PLATFORM) && defined(__GNUC__)
__attribute__((noinline))
#endif
size_t encodeText(uint32_t from, uint32_t id, uint8_t hop_limit, const char* channel_name,
const uint8_t* key, size_t key_len, const char* text, size_t text_len,
uint8_t out[MaxFrameSize]) {
@@ -317,6 +322,9 @@ size_t encodeNodeInfo(uint32_t from, uint32_t id, uint8_t hop_limit, const char*
return finishFrame(from, id, hop_limit, channel_name, key, key_len, out, count);
}
#if defined(NRF52_PLATFORM) && defined(__GNUC__)
__attribute__((noinline))
#endif
bool decodeText(const uint8_t* raw, size_t length, const char* channel_name,
const uint8_t* key, size_t key_len, uint32_t local_node, DecodedText& decoded) {
if (raw == nullptr || key == nullptr || (key_len != 16 && key_len != 32)
+7 -3
View File
@@ -7,15 +7,19 @@
#include <sdkconfig.h>
#endif
// Channel chat is an optional Companion transport, never a bridge. Start with
// the roomy ESP32-S3 Full/SX1262 family; other builds retain every existing
// feature and do not acquire the codec or its bounded raw-frame queue. A new
// Channel chat is an optional Companion transport, never a bridge. Qualified
// families are ESP32-S3 Full/SX1262 and RAK4631 Full; other builds retain their
// features and do not acquire the codec or its bounded raw-frame queue. A new
// family must qualify its modem implementation, flash and runtime RAM first.
#ifndef MESH_ENABLE_MESHTEXT_CHAT
#if defined(ESP32_PLATFORM) && defined(CONFIG_IDF_TARGET_ESP32S3) \
&& defined(COMPANION_RADIO_FULL) && defined(USE_SX1262) \
&& !(defined(MESH_PRIMARY_ESPNOW) && MESH_PRIMARY_ESPNOW)
#define MESH_ENABLE_MESHTEXT_CHAT 1
#elif defined(NRF52_PLATFORM) && defined(RAK_4631) \
&& defined(COMPANION_RADIO_FULL) && defined(USE_SX1262) \
&& !(defined(MESH_PRIMARY_ESPNOW) && MESH_PRIMARY_ESPNOW)
#define MESH_ENABLE_MESHTEXT_CHAT 1
#else
#define MESH_ENABLE_MESHTEXT_CHAT 0
#endif