1

我正在尝试使用 Orion 上下文代理在干舷中显示 DHT11 传感器(温度和湿度)。该实体具有以下方面:

<contextElement>
<entityId type="Sala" isPattern="false">
<id>Sala1</id>
</entityId>
<contextAttributeList>
<contextAttribute>
<name>date</name>
<type>string</type>
<contextValue>2016-03-15 11:14:22</contextValue>
</contextAttribute>
<contextAttribute>
<name>humidity</name>
<type>float</type>
<contextValue>35</contextValue>
</contextAttribute>
<contextAttribute>
<name>temperature</name>
<type>float</type>
<contextValue>19</contextValue>
</contextAttribute>
</contextAttributeList>
</contextElement>

ORION SERVER 正在侦听,但我无法从干舷仪表板数据源配置中访问类型为“Sala”的实体:

FIWARE 数据集配置

在此处输入图像描述

它失败并显示 404 - 未找到上下文元素。我可以使用这个文本小部件看到它:

在此处输入图像描述

查看 JS 代码。我看到它在变量 cbhost 之后添加了一个“/NGSI10/contextElement”路径...

...
url = "http://"+currentSettings.cbhost+"/NGSI10/queryContext";
...

我尝试使用此路径和 REST 客户端进行查询,但无法使其工作。我必须重新配置我的 orion 服务器吗?

我只是不知道如何使它工作..

有任何想法吗?

提前致谢。

——丹尼尔

4

1 回答 1

0

这是 Orion 在单租户模式下运行(即未-multiservice启用)时的已知问题。请在 FreeBoard 上使用以下配置:

  • Fiware-Service: ' ' (即一个空格)
  • Fiware-ServicePath: '/'

但是,您可以克隆以下板,已配置为以这种方式与您的 Orion 一起使用:

https://freeboard.io/board/q7Oe0e

(旁注:XML 在 Orion 中已弃用,事实上,下一个 Orion 版本 -1.0.0- 将不支持它。我建议停止使用它,转而使用 JSON)。

于 2016-03-17T17:32:47.710 回答