|
panid目前要改两个地方
1 消息要发送到那个panid网络
- void BPhero_UWB_Message_Init(void)
- {
- //set frame type (0-2), SEC (3), Pending (4), ACK (5), PanIDcomp(6)
- msg_f_send.frameCtrl[0] = 0x1 /*frame type 0x1 == data*/ | 0x40 /*PID comp*/|0x20/* ACK request*/;
- //source/dest addressing modes and frame version
- //msg_f.frameCtrl[0] = 0x41;
- msg_f_send.frameCtrl[1] = 0x8 /*dest extended address (16bits)*/ | 0x80 /*src extended address (16bits)*/;
- msg_f_send.panID[0] = 0xF0;
- msg_f_send.panID[1] = 0xF0;
复制代码 2 自身接工作panid(接收那个panid网络信息)- void BPhero_UWB_Init(void)//dwm1000 init related
- {
- ……
- dwt_setpanid(0xF0F0);
- }
复制代码 两个同时改,你再试试
后面代码会更新下,定义一个宏,两个地方引用这个宏,就不会出现问题了
|
|