如何在 XBee PRO 系列 2 上设置频道?
我有 3 个 XBees。 2x PRO 和一个标准,所有系列 2。 我已将一个 PRO 和一个标准配置为通道 0 和 PAN 234 上的路由器/端点(这是选择“XBP24-B”/“XB24-B”“ZNET2.5 ROUTER/END”时的默认通道和 PAN ID) DEVICE AT”配置文件(两者的版本都是 1247)。
但是,我使用“ZNET 2.5 COORDINATOR AT”配置文件设置的一个 PRO 具有 E 通道(尽管如果我继续使用相同的配置文件刷新设备,则此值会从 12 更改) -F)。
显然,如果协调器没有相同的通道,则任何操作都不起作用,但我看不到任何手动设置通道的方法..?
X-CTU 中的 CH 设置是只读的,我可以查看任何其他 UI 元素来更改频道:
我什至已经进入终端并键入(括号中的单词是终端返回的内容):
+++(OK) 附加 (E) ATCH0(错误) ATCH 0(错误) ATCH00(错误) ATCH 00(错误) 注意 E(错误) ATCHE(错误)
我用谷歌搜索了又谷歌没有结果。非常令人沮丧,有人可以帮忙吗?! 我之前让它们工作只是侥幸,因为我不断刷新硬件直到通道号匹配,但这显然是荒谬的!
I've got three XBees. 2x PROs and a standard, all series 2s.
I've configured one PRO and one standard to be router/endpoints on channel 0 and PAN 234 (this is the default channel and PAN ID when selecting the "XBP24-B"/"XB24-B" "ZNET2.5 ROUTER/END DEVICE AT" profile (version 1247 for both).
However the one PRO I've set with the "ZNET 2.5 COORDINATOR AT" profile has a channel of E (though if I keep flashing the device with the same profile, this changes from 12-F).
Obviously if the coordinator doesn't have the same channel, nothing will work, but I can't see any way of setting the channel manually..?
The CH setting in X-CTU is read only, and I can see any other UI element to change the channel:
I've even been into the terminal and typed (words in brackets are what the terminal returns):
+++ (OK)
ATCH (E)
ATCH0 (ERROR)
ATCH 0 (ERROR)
ATCH00 (ERROR)
ATCH 00 (ERROR)
ATCH E (ERROR)
ATCHE (ERROR)
I've Googled and Googled to no avail. incredibly frustrating, can anyone help?!
I've had them working previous as a matter of fluke as I kept flashing the hardware until the channel numbers match up, but this is obviously ridiculous!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
XBee ZB(S2、S2B、S2C)系列模块的通道选择工作方式与 XBee 802.15.4 (S1) 模块不同。 ZB 的信道选择是自动的(与 802.15.4 模块的手动选择相反)。
通常,您永远不需要使用 ZB 操作通道选择参数。如果可以的话,模块会相互查找并相互关联。
如果您的模块似乎无法找到彼此,通常会归结为协调器 (NJ) 上的 PAN 设置 (ID)、安全设置 (LK) 或网络加入权限设置不匹配。
除了 Digi 的 XBee ZB OEM 手册之外,网络上没有太多信息。作为参考,使用 ZB 进行通道选择的工作方式如下:
此过程旨在选择噪声最少的信道,无论是微波炉、WiFi 网络还是任何其他可能在 2.4GHz 频率上传输的东西乐队。
任何加入网络的路由器或终端设备都会首先咨询其 SC 参数,然后它们将尝试搜索可以加入的与其 PAN 和安全参数相匹配的网络。他们将加入并保持加入他们能加入的第一个网络,但有一些小的例外(例如,请参阅 JV 和 NW 参数)。
如果要强制选择通道,则必须设置 SC 参数以仅启用单个通道。 SC 参数是一个位掩码1。掩码中设置的每一位将启用一个额外的通道。该参数的棘手之处在于第一位(位 0)不是通道 0,而是通道 11 (0x0B)。为了便于使用,如果您想将 XBee ZB 锁定到单个通道,则此处的值如下:
Channel selection with the XBee ZB (S2, S2B, S2C) series of modules works differently than with the XBee 802.15.4 (S1) modules. Channel selection is automatic with ZB (as opposed to it being manual with the 802.15.4 modules).
You normally never need to manipulate the channel selection parameters with ZB. Modules find each other and associate with each other if they can.
If your modules just can't seem to find each other it usually comes down to a mismatch in the PAN settings (ID), security settings (LK), or network joining permission settings on the coordinator (NJ).
Not a lot of information exists on the web outside of the Digi's XBee ZB OEM manual. For reference sake, channel selection with ZB works like this:
This procedure aims to pick a channel with the least amount of noise on it be it from microwave ovens, WiFi networks, or anything else that might be transmitting on the 2.4GHz frequency band.
Any router or end devices joining a network with consult their SC parameters first, then they will try and search for networks they can join which match their PAN and security parameters. They will join and stay joined to the first network they can--with some minor exceptions (see the JV and NW parameters, for example).
If you want to force a channel selection you must set the SC parameter to enable only a single channel. The SC parameter is a bitmask1. Each bit set in the mask will enable one additional channel. What's tricky about this parameter is that the first bit (bit 0) is not channel 0, it's channel 11 (0x0B). For ease of use, if you wanted to lock an XBee ZB to a single channel here would be the values:
我不确定你上面说的是否正确。来自http://ftp1.digi.com/support/documentation/90000976_C.pdf(不过,您应该查看适合您的硬件的正确版本),看起来协调器的目的是自动确定通道:
实际上,我从未使用过 Digi XBee 无线电(只是他们的一些其他无线电),所以我对协调器了解不多。我认为他们的用户界面通常会公开所有有效命令,因此尝试手动发送它们可能不起作用(正如您所发现的)。
您可以在Digi 论坛上找到更多专家。
I'm not sure if what you say above is right. From http://ftp1.digi.com/support/documentation/90000976_C.pdf (you should look at the correct version for your hardware, though), it looks like the purpose of a coordinator is to automatically determine the channel:
I've actually never used the Digi XBee radios (just some of their other radios), so I don't know much about coordinators. I think that their user interface typically does expose all of the valid commands, so it probably won't work to try sending them manually (as you discovered).
You may find more experts on the Digi forums.
唔。奇怪,再次检查设置并最终让它与 2 路通信一起工作?! :S
其他所有内容均保留为默认值。
配置路由器/终端设备时,让协调器保持开机状态,以便您可以检查它们是否正确配对。
正如我所说,我以前使用过这个配置,但它不起作用,所以我不知道这次是什么让它发挥作用,但它起作用了?!
Hmm. strange, keep going over the settings again and finally got it working with 2-way comms?! :S
Everything else was left as default.
Leave coordinator powered on when configuring router/end devices so you can check they pair correctly.
As I said, I've used this configuration before and it just didn't work, so I don't know what kicked it into life this time, but it worked?!
需要考虑的一件事是 ZigBee 通道从 11 扩展到 26,零不是一个有效的选项。
既然是这种情况,您可以尝试命令 ATCH11 吗?
如果该命令成功,那么 ATCH 命令可能需要 11 到 26 之间的十进制输入?
One thing to take into account is that ZigBee channels extend from 11 to 26, zero is not a valid option.
Since that's the case, are you able to try the command ATCH11 ?
If that command succeeds, then perhaps the ATCH command wants a decimal input between 11 and 26?