diff --git a/include/bluetooth/mesh/access.h b/include/bluetooth/mesh/access.h index c07abdd59a..c93a897097 100644 --- a/include/bluetooth/mesh/access.h +++ b/include/bluetooth/mesh/access.h @@ -55,6 +55,15 @@ extern "C" { #define BT_MESH_IS_DEV_KEY(key) (key == BT_MESH_KEY_DEV_LOCAL || \ key == BT_MESH_KEY_DEV_REMOTE) +/** Maximum payload size of an access message (in octets). */ +#define BT_MESH_APP_SEG_SDU_MAX 12 +/** Maximum possible payload size of an outgoing access message (in octets). */ +#define BT_MESH_TX_SDU_MAX (CONFIG_BT_MESH_TX_SEG_MAX * \ + BT_MESH_APP_SEG_SDU_MAX) +/** Maximum possible payload size of an incoming access message (in octets). */ +#define BT_MESH_RX_SDU_MAX (CONFIG_BT_MESH_RX_SEG_MAX * \ + BT_MESH_APP_SEG_SDU_MAX) + /** Helper to define a mesh element within an array. * * In case the element has no SIG or Vendor models the helper diff --git a/subsys/bluetooth/mesh/transport.h b/subsys/bluetooth/mesh/transport.h index a258f0834b..b40b639112 100644 --- a/subsys/bluetooth/mesh/transport.h +++ b/subsys/bluetooth/mesh/transport.h @@ -10,9 +10,6 @@ #define BT_MESH_SDU_UNSEG_MAX 11 #define BT_MESH_CTL_SEG_SDU_MAX 8 -#define BT_MESH_APP_SEG_SDU_MAX 12 -#define BT_MESH_TX_SDU_MAX (CONFIG_BT_MESH_TX_SEG_MAX * BT_MESH_APP_SEG_SDU_MAX) -#define BT_MESH_RX_SDU_MAX (CONFIG_BT_MESH_RX_SEG_MAX * BT_MESH_APP_SEG_SDU_MAX) #define BT_MESH_RX_CTL_MAX (CONFIG_BT_MESH_RX_SEG_MAX * BT_MESH_CTL_SEG_SDU_MAX) #define TRANS_SEQ_ZERO_MASK ((uint16_t)BIT_MASK(13))