/*---------------声明-------------------------------*/
///主要服务声明
ATT\u DECL\u Primary\u service=0x2800,
///次要服务声明
ATT\u DECL\u Secondary\u service,
///Include Declaration如果您看到文件“ATT.h”,您可以找到此内容
我想使用ATT\u DECL\u INCLUDE
我尝试声明INCLUDE服务属性。
//---------------------------------------------------------------------
const struct attm\u desc sample128\u ATT\u db[sample128\u IDX\u NB]=
{
//服务取消
[SAMPLE128\u IDX\u SVC]={ATT\u DECL\u PRIMARY\u SERVICE,PERM(RD,ENABLE),sizeof(SAMPLE128\u SVC),
sizeof(SAMPLE128\u SVC),(uint8\u t*)&;SAMPLE128\u SVC},
//DISS服务声明
[SAMPLE128\u IDX\u INCL\u DISS\u SVC]={ATT DECL\u INCLUDE,PERM(RD,ENABLE),sizeof(struct ATT\u INCL\u desc),0,NULL},
…
状态=attm\U svc\U create\U db(&;sample128_环境样品128\U shdl、(uint8\u t*)和cfg\u标志、SAMPLE128\u IDX\u NB和SAMPLE128_环境附件[0]、dest_id和sample128_att_db[0]);
…
//--------------------------------------------------------------------------------------------------------------------
但是我不知道如何填充DB“struct att\u incl\u desc”
我可以看到使用include service属性的示例吗?
(示例中需要信息)
1。当
send msg REQ\u DB\u CREATE时,
2。其中
func req \u db \u create \u hendler
3。how
get diss\u service\u start\u handle
get diss\u service\u end\u handle
//--------------------------------
///include service entry element
struct att\u incl\u desc
{
///include service的start handle值
uint16\u start\u hdl;
///包含服务的结束句柄值
uint16\u t end\u hdl;
///属性值UUID
uint16\u t UUID;
};
//------------------------------------------
谢谢。