资料介绍
描述
先决条件
这个项目建立在这个项目中开发的云基础设施之上。
1-您必须遵循以下步骤:
2-您必须安装 Git。如果没有安装 Git,可以在这里下载。
搭建 MQTT-SN 透明网关
1- 打开终端并运行以下命令来设置网关:
> git clone -b experiment https://github.com/eclipse/paho.mqtt-sn.embedded-c
> cd paho.mqtt-sn.embedded-c/MQTTSNGateway
> make SENSORNET=udp6
> make install
> make clean
2-打开gateway.conf
文件并以这种方式编辑内容:
#**************************************************************************
# Copyright (c) 2016-2019, Tomoaki Yamaguchi
#
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Eclipse Public License v1.0
# and Eclipse Distribution License v1.0 which accompany this distribution.
#
# The Eclipse Public License is available at
# http://www.eclipse.org/legal/epl-v10.html
# and the Eclipse Distribution License is available at
# http://www.eclipse.org/org/documents/edl-v10.php.
#***************************************************************************
#
# config file of MQTT-SN Gateway
#
#BrokerName=mqtt.eclipse.org
#BrokerPortNo=1883
#BrokerSecurePortNo=8883
BrokerName=localhost
BrokerPortNo=1884
#BrokerSecurePortNo=8883
#
# When AggregatingGateway=YES or ClientAuthentication=YES,
# All clients must be specified by the ClientList File
#
ClientAuthentication=NO
AggregatingGateway=NO
QoS-1=NO
Forwarder=NO
#ClientsList=/path/to/your_clients.conf
PredefinedTopic=NO
#PredefinedTopicList=/path/to/your_predefinedTopic.conf
#RootCAfile=/etc/ssl/certs/ca-certificates.crt
#RootCApath=/etc/ssl/certs/
#CertsFile=/path/to/certKey.pem
#PrivateKey=/path/to/privateKey.pem
GatewayID=1
GatewayName=PahoGateway-01
KeepAlive=900
#LoginID=your_ID
#Password=your_Password
# UDP
GatewayPortNo=10000
MulticastIP=225.1.1.1
MulticastPortNo=1883
# UDP6
#GatewayUDP6Bind=FFFF:FFFE::1
GatewayUDP6Bind=fec0:affe::1/64
#GatewayUDP6Port=10000
GatewayUDP6Port=1885
GatewayUDP6Broadcast=FF02::1
GatewayUDP6If=wpan0
# XBee
Baudrate=38400
SerialDevice=/dev/ttyUSB0
ApiMode=2
# LOG
ShearedMemory=NO;
基本上,您必须配置 MQTT 部分(我们将与之交互的代理,在我的情况下它是一个localhost
并在1884
端口中运行)。
另一件重要的事情是您必须绑定 upd6 地址(fec0:affe::1/64
与您在 RIOT-OSREADME
文件中看到的用于 MQTT-SN 连接的地址相同)和端口(1885
是允许您从 RIOT 接收消息的端口实例)。
3- 要执行网关,请从安装 Paho 的目录打开终端并运行以下命令:
> ./MQTT-SNGateway
将 Mosquitto MQTT 代理桥接到 AWS IoT
1- 安装 Mosquitto 代理。你可以在这里下载。
2- 现在,您需要配置网桥,以便 Mosquitto 代理可以创建到 AWS IoT 的连接。为此,您必须创建一个新mosquitto_bridge.conf
文件并在其中写入以下行:
# =================================================================
# Bridges to AWS IOT
# =================================================================
# AWS IoT endpoint
connection awsiot
address a6as4ru7uhh5u-ats.iot.us-east-1.amazonaws.com:8883
# Specifying which topics are bridged
# topic awsiot_to_localgateway in 1
# topic localgateway_to_awsiot out 1
# topic both_directions both 1
topic sensor/values both 1
# Setting protocol version explicitly
bridge_protocol_version mqttv311
bridge_insecure false
# Bridge connection name and MQTT client Id,
# enabling the connection automatically when the broker starts.
cleansession true
clientid bridgeawsiot
start_type automatic
notifications false
log_type all
# =================================================================
# Certificate based SSL/TLS support
# -----------------------------------------------------------------
#Path to the rootCA
bridge_cafile ./AWS-certs/rootCA.pem
# Path to the PEM encoded client certificate
bridge_certfile ./AWS-certs/fc278d0e63-certificate.pem.crt
# Path to the PEM encoded client private key
bridge_keyfile ./AWS-certs/fc278d0e63-private.pem.key
用您自己的端点替换此部分很重要:
在这里你必须插入你的证书的路径:
请记住,您已在此步骤中下载并保存了证书:
3- 要在端口上运行 Mosquitto 代理1884
,请从配置文件的根目录打开终端,然后执行以下命令:
> sudo mosquitto -c ./mosquitto_bridge.conf –p 1884
防暴应用
初步要求
您必须已安装:
-
吉特。
- 使用LoRaWAN和TTN在IoT实验室测试RIOT-OS设备 0次下载
- 使用RIOT/Google IoT/MQTT的环境站 0次下载
- 基于AWS的人群感知应用程序 0次下载
- 使用RIOT-OS的基于AWS的IoT虚拟环境站 0次下载
- 通过AWS IoT控制连接到Intel Galileo Gen 2的事物 0次下载
- 使用RIOT OS控制外部LED 0次下载
- 使用ESP32以简单且不安全的方式连接到AWS IoT 0次下载
- 如何使用MQTT将嵌入式系统连接到AWS IoT Core 0次下载
- 用于PIC IoT和AVR IoT的AWS应用程序 0次下载
- 基于RIOT OS的LoRa信号的被动数据包嗅探应用程序 0次下载
- RIOT-OS实时多线程IoT操作系统 0次下载
- 适用于嵌入式C的AWS IoT设备开发工具包 5次下载
- RIOT-OS入门 Windows系统下在STM32上运行RIOT OS 0次下载
- 调整AVR-IoT WG的用途以连接到AWS 10次下载
- 第4节《鸿蒙OS应用程序开发》 15次下载
- SEW-MOVIPRO启动应用程序配置程序 275次阅读
- 如何找到连接到服务器的客户端计算机的IP地址 931次阅读
- Neon--AWS Aurora Postgres的无服务器开源替代品 309次阅读
- 连接到您最喜欢的数据库集 296次阅读
- 基于RTOS的应用程序的五个最佳实践技巧 543次阅读
- PreEmptiveProtection:全面的移动应用程序保护 319次阅读
- RTOS应用程序设计的五个实战技巧 771次阅读
- 怎么使用uboot引导应用程序? 994次阅读
- DPU编译应用程序的不同方法 1328次阅读
- 浅谈RAM 执行应用程序 2759次阅读
- IoT系统架构和网络类别 3257次阅读
- LPWAN在物联网有什么独特的优势 893次阅读
- 应用程序安全怎样来提供保障 1033次阅读
- PCB最小颈口长度连接到0603的焊盘布置规则资料概述 3956次阅读
- 两种开发 RFID 应用程序的方法分析 719次阅读
下载排行
本周
- 1山景DSP芯片AP8248A2数据手册
- 1.06 MB | 532次下载 | 免费
- 2RK3399完整板原理图(支持平板,盒子VR)
- 3.28 MB | 339次下载 | 免费
- 3TC358743XBG评估板参考手册
- 1.36 MB | 330次下载 | 免费
- 4DFM软件使用教程
- 0.84 MB | 295次下载 | 免费
- 5元宇宙深度解析—未来的未来-风口还是泡沫
- 6.40 MB | 227次下载 | 免费
- 6迪文DGUS开发指南
- 31.67 MB | 194次下载 | 免费
- 7元宇宙底层硬件系列报告
- 13.42 MB | 182次下载 | 免费
- 8FP5207XR-G1中文应用手册
- 1.09 MB | 178次下载 | 免费
本月
- 1OrCAD10.5下载OrCAD10.5中文版软件
- 0.00 MB | 234315次下载 | 免费
- 2555集成电路应用800例(新编版)
- 0.00 MB | 33566次下载 | 免费
- 3接口电路图大全
- 未知 | 30323次下载 | 免费
- 4开关电源设计实例指南
- 未知 | 21549次下载 | 免费
- 5电气工程师手册免费下载(新编第二版pdf电子书)
- 0.00 MB | 15349次下载 | 免费
- 6数字电路基础pdf(下载)
- 未知 | 13750次下载 | 免费
- 7电子制作实例集锦 下载
- 未知 | 8113次下载 | 免费
- 8《LED驱动电路设计》 温德尔著
- 0.00 MB | 6656次下载 | 免费
总榜
- 1matlab软件下载入口
- 未知 | 935054次下载 | 免费
- 2protel99se软件下载(可英文版转中文版)
- 78.1 MB | 537798次下载 | 免费
- 3MATLAB 7.1 下载 (含软件介绍)
- 未知 | 420027次下载 | 免费
- 4OrCAD10.5下载OrCAD10.5中文版软件
- 0.00 MB | 234315次下载 | 免费
- 5Altium DXP2002下载入口
- 未知 | 233046次下载 | 免费
- 6电路仿真软件multisim 10.0免费下载
- 340992 | 191187次下载 | 免费
- 7十天学会AVR单片机与C语言视频教程 下载
- 158M | 183279次下载 | 免费
- 8proe5.0野火版下载(中文版免费下载)
- 未知 | 138040次下载 | 免费
评论
查看更多