Image
Image

l63t89

+ 关注

粉丝 1     |     主题 101     |     回帖 1077

STM32-MQTT
2023-10-10 12:35
  • ST MCU
  • 31
  • 1030
  发布/订阅  
  ......  
  客户端-Windows 下载安装MQTTX 添加连接  
  订阅消息 命令格式: mosquitto_sub -h hostname -p port-number -u username -P password -t message-topic ...  
  发布消息 命令格式: mosquitto_pub -h hostname -p port-number -u username -P password -t message-topic ...  
  客户端-Ubuntu 安装mosquitto客户端 sudo apt-get install mosquitto-clients  
  服务器防火墙开通1883端口  
  启动mosquitto mosquitto -c /etc/mosquitto/mosquitto.conf -d -c 指定配置文件 -d 在后台运行mosquitto ...  
  编辑配置文件 vim /etc/mosquitto/mosquitto.conf 添加以下内容 listener 1883 allow_anonymous true ...  
  服务器环境搭建 安装mosquitto sudo apt-add-repository ppa:mosquitto-dev/mosquitto-ppa sudo apt-get up ...  
  测试 服务器: Ubuntu Server 20.04 LTS 64bit Broker: Eclipse Mosquitto Client: mosquitto_pub/mosquitto ...  
  Notes 移植源码内需包含MQTTPacket.h. 详细移植方案参考eclipse/paho.mqtt.embedded-c/MQTTClient-C里的内 ...  
  发布消息 bool mqtt_publish(unsigned char *buf, unsigned int buflen, char *topicName, MQTTMessage *me ...  
  发布消息bool mqtt_publish(unsigned char *buf, unsigned int buflen, char *topicName, MQTTMessage *mes ...  
  登录MQTT服务器  
  数据接收接口 int transport_getdata(unsigned char *buf, unsigned int count) { tcp_recv(buf, count ...  
  简易移植方案 数据发送接口 bool transport_sendPacketBuffer(unsigned char *buf, unsigned int buflen) { ...  
  通信过程 底层模块建立TCP链接 登录MQTT服务器 采集数据并构造Message 发布消息 ...  
  步骤 下载源码 将MQTTPacket内的全部内容添加到Keil工程中 根据MQTTClient-C的内容编写移植代码 编译下载 ...  
什么时候咱们也有个电子竞赛啥的?有多方认证那种。
2023-12-20 19:23
  • 小华半导体
  • 10
  • 1630
  咱们啥时候也有个电子竞赛,能多方认证那种带证书的? 光是礼品其实没啥动力,感觉来证书的话会有很强的动 ...  
2
3
近期访客