完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
嗨,
我的设备是蓝牙LE外设,它基于通过SPI连接的BlueNRG-2和STM32。 我想在SCAN_RSP中向中央设备提供一些测量数据。测量每1秒进行一次,在此期间我通过以下方式更新scan_rsp数据: hci_le_set_scan_response_data() 我传递给上面函数的数据有以下格式: 0:22 - AD_Len 1:0xFF - AD_Type = MANUFACT_SPEC.2-23:custom_data [22] - AD_Data - 我的测量 在我的中央设备中,我只收到大约30%的正确SCAN_RSP,其他则有空数据: 11662 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -53 dBm :: [24]:16 ff 01 10 99 1c 70 00 15 00 80 03 80 fe c0 c0 00 00 6c 01 00 17 01 00 14757 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 19177 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [24]:16 ff 01 10 bb 93 71 00 15 00 80 03 40 ff 40 c1 00 00 6c 01 00 17 01 00 22272 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 24485 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]:16 ff 01 10 dd 0a 73 00 15 00 40 03 00 ff 80 c0 00 00 6c 01 00 17 01 00 27532 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 29742 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]:16 ff 01 10 ff 81 74 00 15 00 80 03 80 ff 40 c1 00 00 6c 01 00 17 01 00 34999 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]:16 ff 01 10 11 f9 75 00 15 00 40 03 c0 fe 00 c1 00 00 6c 01 00 17 01 00 38047 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 40254 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [0]: 41363 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -52 dBm :: [24]:16 ff 01 10 33 70 77 00 15 00 80 03 00 ff 00 c1 00 00 6c 01 00 17 01 00 44410 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 46620 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -54 dBm :: [0]: 47725 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]:16 ff 01 10 55 e7 78 00 15 00 80 03 40 ff c0 c0 00 00 6c 01 00 17 01 00 50771 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -59 dBm :: [0]: 54086 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -51 dBm :: [24]:16 ff 01 10 77 5e 7a 00 15 00 40 03 40 ff c0 c0 00 00 6c 01 00 17 01 00 57131 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -61 dBm :: [0]: 59342 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]:16 ff 01 10 99 d5 7b 00 15 00 40 03 c0 fe 40 c0 00 00 6c 01 00 17 01 00 62389 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 64600 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [0]: 65705 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]:16 ff 01 10 bb 4c 7d 00 15 00 c0 03 40 ff 80 c1 00 00 6c 01 00 17 01 00 68802 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 71012 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]:16 ff 01 10 dd c3 7e 00 15 00 80 03 80 ff 00 c1 00 00 6c 01 00 17 01 00 74109 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -61 dBm :: [0]: 76319 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -56 dBm :: [0]: 77425 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]:16 ff 01 10 1f 3b 80 00 15 00 40 03 40 ff 40 c1 00 00 6c 01 00 16 01 00 80519 0> SCAN_RSP,xx:xx:xx:xx:xx:xx RSSI -61 dBm :: [0]: 为什么某些SCAN_RSP的数据为空? 亲切的问候, 彼得· #scan_rsp #bluenrg-2 以上来自于谷歌翻译 以下为原文 Hi, My device is Bluetooth LE peripheral that is based on BlueNRG-2 and STM32 connected via SPI. I would like to present some measurement data in SCAN_RSP to central devices.The measurement is performed every 1 second and in this period I update scan_rsp data by: hci_le_set_scan_response_data() The data that I pass to above function has following format: 0: 22 - AD_Len 1: 0xFF - AD_Type = MANUFACT_SPEC.2-23: custom_data[22] - AD_Data - my measurements In my central device I receive only about 30% of correct SCAN_RSP, other have empty data: 11662 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -53 dBm :: [24]: 16 ff 01 10 99 1c 70 00 15 00 80 03 80 fe c0 c0 00 00 6c 01 00 17 01 00 14757 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 19177 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [24]: 16 ff 01 10 bb 93 71 00 15 00 80 03 40 ff 40 c1 00 00 6c 01 00 17 01 00 22272 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 24485 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]: 16 ff 01 10 dd 0a 73 00 15 00 40 03 00 ff 80 c0 00 00 6c 01 00 17 01 00 27532 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 29742 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]: 16 ff 01 10 ff 81 74 00 15 00 80 03 80 ff 40 c1 00 00 6c 01 00 17 01 00 34999 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]: 16 ff 01 10 11 f9 75 00 15 00 40 03 c0 fe 00 c1 00 00 6c 01 00 17 01 00 38047 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 40254 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [0]: 41363 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -52 dBm :: [24]: 16 ff 01 10 33 70 77 00 15 00 80 03 00 ff 00 c1 00 00 6c 01 00 17 01 00 44410 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 46620 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -54 dBm :: [0]: 47725 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]: 16 ff 01 10 55 e7 78 00 15 00 80 03 40 ff c0 c0 00 00 6c 01 00 17 01 00 50771 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -59 dBm :: [0]: 54086 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -51 dBm :: [24]: 16 ff 01 10 77 5e 7a 00 15 00 40 03 40 ff c0 c0 00 00 6c 01 00 17 01 00 57131 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -61 dBm :: [0]: 59342 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]: 16 ff 01 10 99 d5 7b 00 15 00 40 03 c0 fe 40 c0 00 00 6c 01 00 17 01 00 62389 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 64600 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [0]: 65705 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]: 16 ff 01 10 bb 4c 7d 00 15 00 c0 03 40 ff 80 c1 00 00 6c 01 00 17 01 00 68802 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -60 dBm :: [0]: 71012 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]: 16 ff 01 10 dd c3 7e 00 15 00 80 03 80 ff 00 c1 00 00 6c 01 00 17 01 00 74109 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -61 dBm :: [0]: 76319 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -56 dBm :: [0]: 77425 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -55 dBm :: [24]: 16 ff 01 10 1f 3b 80 00 15 00 40 03 40 ff 40 c1 00 00 6c 01 00 16 01 00 80519 0> SCAN_RSP, xx:xx:xx:xx:xx:xx RSSI -61 dBm :: [0]: Why data are empty for some SCAN_RSP? Kind regards, Piotr #scan_rsp #bluenrg-2 |
|
相关推荐
1个回答
|
|
我的错。
我忽略了每次连接后我调用SetDiscoverable将SCAN-RSP数据设置为null.Regards, 彼得· 以上来自于谷歌翻译 以下为原文 My mistake. I overlooked that after each connection I call SetDiscoverable where was setting SCAN-RSP data to null.Regards, Piotr |
|
|
|
只有小组成员才能发言,加入小组>>
请教:在使用UDE STK时,单片机使用SPC560D30L1,在配置文件怎么设置或选择?里面只有SPC560D40的选项
2747 浏览 1 评论
3244 浏览 1 评论
请问是否有通过UART连接的两个微处理器之间实现双向值交换的方法?
1813 浏览 1 评论
3655 浏览 6 评论
6044 浏览 21 评论
1342浏览 4评论
204浏览 3评论
对H747I-DISCO写程序时将CN2的st-link复用为usart1,再次烧录时无法检测到stlink怎么解决?
359浏览 2评论
STM32G474RE芯片只是串口发个数据就发烫严重是怎么回事?
451浏览 2评论
STM32处理增量式编码器Z信号如何判断中断是正转的还是反向转的?
277浏览 2评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-12-29 09:32 , Processed in 1.137313 second(s), Total 76, Slave 60 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号