Dear Dialog,
I would like to know what reason why DA14580 disconnected while being interrogated. Any condition or trigger for this case occurring?
我的代码是基于sample128的,它在大多数情况下都运行良好。但有时会出现这样的问题——我的应用程序无法连接DA14580,而浅蓝色工具会报告“被询问时外设断开”。同时,广告效果也很好——通过传感器检测广告数据的动态变化。
If this case occurs, DA14580 never be connected all the time. The only way to let it work is "power-down reset". After reset, it works well. The problem does rarely happen, and not easy to be reproduced.
Is it caused by calling disconnecting function? I didn't find it from my code, may be somewhere or timing issue? So far, I can't find any clue for it. Please help!
谢谢!
关键词:
Hello Alex Luo,
在我看来,这可能是硬件问题/xtal校准问题。我也遇到过类似的问题。你用自己的硬件吗?
Thanks Vesa,
Yes, I used my own hardware. The issue does rarely happen which is fetal issue for my application.
我们用我们的应用程序跟踪连接,看起来连接后DA14580立即断开。我在app\u connection\u func()中添加了一个LED指示灯,发现LED指示灯亮起表示app_环境conidx==GAP\u INVILAD\u CONIDX当问题发生时,但我不确定每次审问都进行到这一点。所以,我想知道是不是时机不对?如果是这样的话,为什么会出现这个问题,在掉电复位之前永远不会建立连接?!
By the way, I used RC oscillator for 32.768KHz, not Xtal. I also used to functions for timer: app_sample128_timer_handler() (I set timer for 200ms, 500ms and 2s for applications), and app_rtc_timer_handler() (for 1s fixed timer). I'm not sure if there is any conflict or with other timers in stack.
顺便说一句,代码在大多数情况下都运行得很好,但有时会出现这个问题——我没有找到问题所在。希望你能给我更多的线索。
谢谢,
你好,亚历克斯,
Read the section 7. carefully
如果没有精确校准,您可能会遇到奇怪的行为
谢谢!
Hello Vesa,
Thanks for your sharing your experience and I try to do it. Due to variation of the xtal and components, do you think to trim each of boards or using one trimming to cover all of those boards for production? (reaching 5ppm?)
你能跟我说说你遇到的问题吗?广告效果很好,在重置之前从未建立连接?如果是这样,问题是通过修剪Xtal来解决的?
你认为固件有问题吗?
Thanks a lot,
嗨,亚历克斯,
I guess one trim should cover all boards, however, there might be some variation.
For me, wrong calibration caused the advertising to "disappear" sometimes and the device function incorrectly in general. It was impossible to operate it. The problem was fixed my trimming the xtal and also changing the HW design a little. If the frequency is not correct, then the generated RF signal is in the wrong frequency zone.
When you are calibrating the xtal, you may also notice some drifting.
Can't say if there is anything wrong with the firmware.
Tanks Vesa,
我会尽量听从你的建议,同时从f/w中挖掘更多。有趣的是,所有的问题都发生在更新广告数据时(需要app\u adv\u stop和app\u adv\u start…)
谢谢,
Alex
Hello,
you may want to double check that you don't access wrong memory addresses, and that your adv packet is valid. Try printing it out in hex.
你好,维萨,
似乎很难找到问题的根源。这个问题可能不会发生后,运行数百次,我想知道是什么触发它。奇怪的是,问题发生后,连接就再也没有恢复,广告效果也很好。我不知道在调用app\u adv\u stop然后很近距离地调用app\u adv\u start()之后是否有任何冲突--我可以找到有关它的更多信息。您有使用add\u adv\u stop()和add\u adv\u start()的经验吗?我在app\u rtc\u timer\u handler()中更新了广告数据之后使用了这些工具,我创建了app\u rtc\timer\u handler(),以供rtc使用(1秒/步)。希望你能在那里找到一些东西,让我知道。
谢谢,
我也有同样的问题,我用5V supply,when i change it to 3.3v,everything is fine!hope this help!
Hello cuijinfei,
DA14580 working voltage up to 3.6V, the chip can't work properly at 5V. So, using 3.3V is right.
Hi Dialog,
我遇到了同样的问题,亚历克斯。DA14580保持advertising but cannot be connected any more. Once the problem happens, it'll be always there and the only recovery operation is to restart the chip.
I got the air log when met the problem when using iPhone. But the problem also exists with Android. From the log, disconnection occurs after LLCP Version Exchange and no response from DA14580. The problem is not easy to reproduce but exists.
Could Dialog help to list some protential reasons? This's an urgent bug for me, can anyone give a favor? Thank u very much.
致以最诚挚的问候
Angie
嗨,安吉尔森林,
是设备本身断开连接,然后您无法重新连接吗?Is your connection using any security, maybe something goes wrong there. When you issue the connection request can you tell of the da gets the connection request (in debug mode). Can you use a sniffer in order to see whats in the air ?
Thanks MT_dialog
嗨,MT\u dialog,
1. Question: Is the device disconnected by its own and then you can't reconnect ?
Answer: I am not sure the disconnection is caused by the device or host. But the connection cannot be established again until reset the DA14580.
2. Q: Is your connection using any security?
A:是的。我们的产品包括HID和ANCS型材。
//IO功能
cfm->data.pairing_feat.iocap = GAP_IO_CAP_NO_INPUT_NO_OUTPUT;
// Authentication requirements
cfm->data.pairing_feat.auth = GAP_AUTH_REQ_NO_MITM_BOND;
//Security requirements
// The HID Device shall use LE Security Mode 1 and either Security Level 2 or 3.
//这里我们使用模式1,级别2
cfm->data.u专长.sec_req=GAP_SEC1_NOAUTH_PAIR_ENC;
三。问:你能用嗅探器来观察空气中的东西吗?
A: I used a sniffer. According the capture, disconnection always appears after LLCP Version Exchange. The master sent LLCP_Version(Opcode: LL_VERSION_IND) everytime with 6 tries, but no response from DA14580. Then after around 350ms, the sniffer showed our device turns back to "connectable state".
Have u met this before? Is that caused by security settings? Thank you.
BR
天使森林
嗨,安吉尔森林,
不,据我所知不存在这样的问题,如果设备可以建立第一个连接,但不能重新连接,则必须是第二个连接中的密钥交换过程,可能密钥没有正确存储或公开。在重新连接期间使用不同的处理程序,您可以查看键盘参考设计,以查看正确的HID连接。
Thanks MT_dialog