@@ -542,8 +542,31 @@ static uint8_t health_tests[] = {
542
542
BT_MESH_HEALTH_TEST_INFO (COMPANY_ID_NORDIC_SEMI , 3 , 0x01 , 0x02 , 0x03 ),
543
543
};
544
544
545
+ static uint8_t zero_metadata [100 ];
546
+
545
547
static struct bt_mesh_models_metadata_entry health_srv_meta [] = {
546
548
BT_MESH_HEALTH_TEST_INFO_METADATA (health_tests ),
549
+ {
550
+ .len = ARRAY_SIZE (zero_metadata ),
551
+ .id = 0xABCD ,
552
+ .data = zero_metadata ,
553
+ },
554
+ BT_MESH_MODELS_METADATA_END ,
555
+ };
556
+
557
+ static uint8_t health_tests_alt [] = {
558
+ BT_MESH_HEALTH_TEST_INFO (COMPANY_ID_LF , 6 , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 ,
559
+ 0x66 ),
560
+ BT_MESH_HEALTH_TEST_INFO (COMPANY_ID_NORDIC_SEMI , 3 , 0x11 , 0x22 , 0x33 ),
561
+ };
562
+
563
+ static struct bt_mesh_models_metadata_entry health_srv_meta_alt [] = {
564
+ BT_MESH_HEALTH_TEST_INFO_METADATA (health_tests_alt ),
565
+ {
566
+ .len = ARRAY_SIZE (zero_metadata ),
567
+ .id = 0xFEED ,
568
+ .data = zero_metadata ,
569
+ },
547
570
BT_MESH_MODELS_METADATA_END ,
548
571
};
549
572
#endif
@@ -1709,6 +1732,13 @@ static uint8_t change_prepare(const void *cmd, uint16_t cmd_len,
1709
1732
return BTP_STATUS_FAILED ;
1710
1733
}
1711
1734
1735
+ #if CONFIG_BT_MESH_LARGE_COMP_DATA_SRV
1736
+ err = bt_mesh_models_metadata_change_prepare ();
1737
+ if (err < 0 ) {
1738
+ return BTP_STATUS_FAILED ;
1739
+ }
1740
+ #endif
1741
+
1712
1742
return BTP_STATUS_SUCCESS ;
1713
1743
}
1714
1744
@@ -5026,6 +5056,9 @@ uint8_t tester_init_mesh(void)
5026
5056
if (default_comp ) {
5027
5057
err = bt_mesh_init (& prov , & comp );
5028
5058
} else {
5059
+ #ifdef CONFIG_BT_MESH_LARGE_COMP_DATA_SRV
5060
+ health_srv .metadata = health_srv_meta_alt ;
5061
+ #endif
5029
5062
err = bt_mesh_init (& prov , & comp_alt );
5030
5063
}
5031
5064
0 commit comments