你好,
我已经用Keil IDE写了一个应用程序,通过通知订阅节点来传输RFID读取器。读者是我的硬件系统的一部分。在客户要求通知他的读者时,在客户通知之后启动硬件处理。
那是工作的,但它阻止了任何其他活动。
现在,我需要一个提示/简单的例子,我如何完成以下内容:
可以指示另一种相同的节点,以将此作为中继。这是网格的替代品,也需要适合小RAM。所以我想构建一棵树,其中root附近的节点有一个以某种方式优先,但允许转发源头和读取结果信息。DA14531对网格没有支持,这与我完全没问题。我只需要使用相同的连接服务多个GATT服务频道。并且,我需要支持3个或更多连接,其中我用一个节点监督网络,它使用GATT服务来指导连接。没有自动化,我想控制关于连接并接受结果的优先级。
I guess, I need to be able, to use another GATT channel/service, to place my parameters and start activity there, while my main activity continues.
我已经观察到的是,在启动我的主循环后,在启动RFID后,没有其他GATT服务则再工作。
I tried it with an LED switch on or off. It is working fine, until I start my notification abonnement. When it is started, the LED switching GATT service is not reachable anymore.
我注意到,服务的广告也停止了 - 校长中很好。但我认为它是一个指示,任何其他活动都是不可能的。我的连接数量设置为1.但是这是Showstopper,还是还有更多?
同样的连接用于两个服务,但我的RFID循环消耗任何东西。如何暂停它,以提供进一步的GATT服务?
为什么我的第一个通知服务占据整个系统?(代码有轮询性质,RFID前端的中断目前不可用)
作为第一步,我希望能够使用我的LED交换服务,而RFID阅读器正在运行。
感谢您的帮助和提示!
Joachim
P.S.背景:PC或Raspberry等任何节点似乎限制了连接数。有人想过,这是在7个连接的范围内。我需要连接大约100个设备。流量将足够小,从伴侣中传递通知。
Hi Joachimm,
Thanks for your question online and for your interest in our BLE products.
Let me check it, and I’ll get back to you.
DA14531充当中央或外围设备?
In the meanwhile, please take a look atDA14585/DA14586 - DA14531 Multiperipheral ExampleSW示例。
此示例演示了单个外设如何连接到多个中心。DA14531能够支持最多3.此外,它还展示了如何根据不同的连接保持不同的特征值。
谢谢,PM_DIALOG.
你好,
That is in fact an interesting example, and it shows the expected difficulty with the SDKs ROM functions overloaded. My first answer is:
My device could act in a peripheral role, advertising all services and one (fully capable) device, like a Raspberry PI, can then write the connection parameters for the entire orchestra to all devices, so any will build and keep up to 3 connections. One upwards, 2 downwards. Data received from downwards are forwarded to upwards.
这是解释我的想法吗?两个向下的设备连接到向上设备。
Did you see my difficulty with the single-thread behaviour for my device? I need a way to return control to the library code, so it will serve more than one GATT service, my somehow polling code, which currently runs forever and exclusive.
非常感谢,
Joachim
嗨Joachim,
>>can then write the connection parameters for the entire orchestra to all devices, so any will build and keep up to 3 connections.
Regarding this statement, could you please clarify it? So, a single peripheral will be connected to 3 Centrals at the same time. So, the peripheral should update the connection parameters to all of the 3 connected Central?
谢谢,PM_DIALOG.
嗨Joachim,
>>can then write the connection parameters for the entire orchestra to all devices, so any will build and keep up to 3 connections.
Regarding this statement, could you please clarify it? So, a single peripheral will be connected to 3 Centrals at the same time. So, the peripheral should update the connection parameters to all of the 3 connected Central?
谢谢,PM_DIALOG.
你好,
你误解了,我的目的是,3 concurrent connections at each device. 2 as central, in order to forward information from below ordered peripherals and 1 in the role of a peripheral to the next upper level. Result is a tree structure, where I have the basic functionality of a 'mesh' - where the higher levels send their messages faster to the final central.
As I found out, the limit seems near 7 concurrent connections at the most upper level. That means, I can build a binary tree.
该树结构的设置需要默认设备,刚刚组织网络。
任何DA14531都需要支持两个外设和上部节点。
配置(在蓝牙MAC地址方面)将由专用应用程序设置,并且将保存在非易失性存储器中。
Is this a bit more clear?
Thanks for your support,
Joachim
Hi joachimkr,
是否有可能共享您的应用程序的高级框图,以便我们可以更好地理解它?
谢谢,PM_DIALOG.
你好,
是的当然。DA14531不支持网格,因此我搜索绕线。我可以和一个设备树一起生活,其中一些是在中央,有些是叶子。叶子发送他们的活动,重量更改到上一个级别。在那里,它被转发到下一个等等。最后,消费旁边的设备(非DA14531)设备旁边发送来自较低级别的任何东西 - 它是自身的值变化。我的避难所实施需要在网络设置中配置配置。管理设备将此设置中的连接数据和角色发送到任何设备。他们将其存储在非易失性记忆中。这是可以接受的,因为它通常只是一次完成。 Does this make sense ?
问候,
Joachim
Hi joachimkr,
Apologies for the delay. The DA14531 is able to support up to 3 connections. However, it’s not possible to act both as Peripheral and as Central at the same time. You could perform role switching.
谢谢,PM_DIALOG.
你好,
Thanks for your advice for role switch. I might find out, what that implies.
At the moment, my plan is, to provide GATT services, which allow the leaf nodes, to deliver events/values to two services, left and right, where values are accepted and another service, where a parent node (both have the same roles) can register to be notified.
结果是二叉树,其中根节点发送/在所有子树单元的许可中发送通知。
Each unit acts as forwarder and may generate own values by notification.
Bandwith不是问题。我也可以将数据压缩为每个通知的20个字节。
这棵树的设置可能需要切换,但我假设(告诉我,如果我错了)所有树单位都可以保持在外围模式,除了连接建立。我想要一个解决方案,在设置相位中分发树单位的MAC,并触发树单位以存储这些永久性。我有一个闪光灯设备。
btw. TI had an application note, with similar ideas. But I didn't understand the setup phase and want my own detailed, somehow manual setup.
Best regards,
Joachim