如何通过 IoT Agent for JSON 将实际(硬件)物联网设备连接到 FIWARE Orion Context
是否有任何教程或指南可以通过JSON的IoT代理遵循并连接硬件IoT设备?所有教程在虚拟配置设备上都可以正常工作,但是没有关于如何进行和连接实际设备的引用。
我已经尝试了教程( https://github.com/fiware/tutorials.iots.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-s.iot-coment- Agent-json )成功,但我不知道如何连接,让我们说一个实际的智能灯。
Is there any tutorial or guide to follow and connect a hardware IoT Device via the IoT Agent for JSON? All the tutorial are working just fine with the virtual provisioned devices but there is no reference on how to proceed and connect an actual device.
I have tried the tutorial (https://github.com/FIWARE/tutorials.IoT-Agent-JSON) with success but I do not know how to connect lets say an actual smart lamp.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
本教程应用程序创建能够通过 HTTP 或 MQTT 发送有效负载的虚拟设备。
任何真实设备也需要遵循这些步骤,例如查看 Arduino 文档 您可以对设备进行编程,使其在选定的 MQTT 主题上发出信号。
相同的技术可用于致动。要么让设备侦听 HTTP:
要么订阅给定的 MQTT 主题:
当然,此示例适用于 JSON 或 Ultralight 有效负载,其他协议需要连接到适当的中间件(例如连接到 OPC-UA 的 OPC-UA 设备) UA 服务器),但是一般来说,您的设备将能够下载适当的通信库,并且您需要使用设备本身上找到的语言对设置进行编码并测量速率和/或驱动响应 - Arduino 文档正在使用 C++ 例子。
The tutorial app creates dummy devices which are capable of sending a payload over HTTP or MQTT
Any real device would also need to follow these steps, so for example looking in the Arduino Documentation you can program a device to emit on a chosen MQTT topic.
The same technique can be used for actuation. Either get the device to listen on HTTP:
Or subscribe to a given MQTT topic:
Of course this example is for JSON or Ultralight payloads, other protocols would need to connect to the appropriate middleware (e.g. an OPC-UA device connecting to an OPC-UA server), however in general your device will be able to download an appropriate comms library and you'll need to code up the set-up and measure rate and/or actuation response using the language found on the device itself - the Arduino docs are using C++ for example.