esp8266关闭加密通信获得更多可用RAM-Arduino中文社区 - Powered by Discuz!

Arduino中文社区

 找回密码
 立即注册

QQ登录

只需一步,快速开始

查看: 4874|回复: 11

[使用文档] esp8266关闭加密通信获得更多可用RAM

[复制链接]
发表于 2020-8-31 17:35 | 显示全部楼层 |阅读模式


blinker默认使用加密方式进行远程通信,但通信加密会消耗大量的RAM,如果您对通信安全性无要求,可以添加宏BLINKER_WITHOUT_SSL用以获得更多可用RAM

  1. #define BLINKER_WIFI  
  2. #define BLINKER_WITHOUT_SSL
  3. #include <Blinker.h>  
  4.   
  5. void setup() {  
  6.     Blinker.begin(auth, ssid, pswd);  
  7. }
复制代码



BLINKER_WITHOUT_SSL目前仅可用于ESP8266,其他设备的RAM足以进行加密通信。最新的blinker lib已经支持关闭加密通信功能,如果您的esp8266项目可用ram不够,可通过这个功能关闭加密通信。
发表于 2020-8-31 19:32 | 显示全部楼层
感谢奈何,技术贴
发表于 2021-2-6 19:53 | 显示全部楼层
你好,我发现一旦取消SSL加密那么在blinker手机端就没办法看到设备在线了。

点评

看调试信息  详情 回复 发表于 2021-2-6 21:51
发表于 2021-2-6 19:54 | 显示全部楼层
但是只要删除 BLINKER_WITHOUT_SSL 就可以显示在线。这有什么关系吗?
 楼主| 发表于 2021-2-6 21:51 | 显示全部楼层
3137234383 发表于 2021-2-6 19:53
你好,我发现一旦取消SSL加密那么在blinker手机端就没办法看到设备在线了。

看调试信息
发表于 2021-2-7 14:18 | 显示全部楼层

14:15:06.173 ->  __       __                __
14:15:06.173 -> /\ \     /\ \    __        /\ \              v0.3.4
14:15:06.173 -> \ \ \___ \ \ \  /\_\    ___\ \ \/'\      __   _ __   
14:15:06.173 ->  \ \ '__`\\ \ \ \/\ \ /' _ `\ \ , <    /'__`\/\`'__\
14:15:06.173 ->   \ \ \L\ \\ \ \_\ \ \/\ \/\ \ \ \\`\ /\  __/\ \ \./
14:15:06.173 ->    \ \_,__/ \ \__\\ \_\ \_\ \_\ \_\ \_\ \____\\ \_\  
14:15:06.173 ->     \/___/   \/__/ \/_/\/_/\/_/\/_/\/_/\/____/ \/_/  
14:15:06.206 ->     To better use blinker with your IoT project!
14:15:06.206 ->     Download latest blinker library here!
14:15:06.206 ->     => https://github.com/blinker-iot/blinker-library
14:15:06.206 ->
14:15:06.206 -> [490] Connecting to B-LINK
14:15:06.274 -> [555] ESP8266_MQTT initialized...
14:15:06.274 -> [555]
14:15:06.274 -> ===========================================================
14:15:06.274 -> ================== Blinker Timer loaded! ==================
14:15:06.274 -> Warning!EEPROM address 1536-2431 is used for Blinker Timer!
14:15:06.274 -> ============= DON'T USE THESE EEPROM ADDRESS! =============
14:15:06.274 -> ===========================================================
14:15:06.274 ->
14:15:07.263 -> [1554] ERROR: null
14:15:08.801 -> [3087] WiFi Connected.
14:15:08.801 -> [3087] IP Address:
14:15:08.801 -> [3087] 192.168.0.105
14:15:08.941 -> [3226] Freeheap: 33296
14:15:08.941 -> [3228] mDNS responder started
14:15:08.941 -> [3229] webSocket_MQTT server started
14:15:08.941 -> [3229] ws://F669137E4OO3|securemode=3,signmethod=hmacsha1|.local:81
14:15:22.030 -> [16324] ERROR: device not found
14:15:22.133 -> [16416] ERROR: device not found
14:15:22.235 -> [16519] Connecting to MQTT...
14:15:22.339 -> [16636] MQTT Connected!
14:15:22.339 -> [16636] Freeheap: 33456
14:15:22.339 -> [16636] =======================================================
14:15:22.339 -> [16636] =========== Blinker Auto Control mode init! ===========
14:15:22.372 -> [16641] Warning!EEPROM address 0-1279 is used for Auto Control!
14:15:22.372 -> [16646] =========== DON'T USE THESE EEPROM ADDRESS! ===========
14:15:22.372 -> [16652] =======================================================
14:15:52.359 -> [46648] MQTT Ping!
14:16:10.183 -> [64473] ERROR: null
14:16:22.881 -> [77189] MQTT Ping!
14:16:35.343 -> [89619] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:16:39.534 -> [93810] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:16:43.706 -> [98001] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:16:47.908 -> [102190] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:16:52.074 -> [106381] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:16:53.429 -> [107736] MQTT Ping!
14:16:56.282 -> [110577] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:00.488 -> [114767] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:04.663 -> [118958] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:06.819 -> [121115] ERROR: device not found
14:17:08.870 -> [123154] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:13.055 -> [127343] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:17.225 -> [131534] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:21.428 -> [135724] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:23.994 -> [138287] MQTT Ping!
14:17:25.640 -> [139925] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:29.801 -> [144112] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:34.009 -> [148296] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:38.192 -> [152497] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:42.401 -> [156686] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:46.572 -> [160880] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:50.776 -> [165068] ERROR: SERVER NOT ALIVE OR MSG LIMIT
14:17:54.542 -> [168832] MQTT Ping!
14:17:55.262 -> [169551] ERROR: SERVER NOT ALIVE OR MSG LIMIT
发表于 2021-2-7 14:19 | 显示全部楼层
3137234383 发表于 2021-2-7 14:18
14:15:06.173 ->  __       __                __
14:15:06.173 -> /\ \     /\ \    __        /\ \     ...

库太老了,请按文档操作,按文档来就是安装的新库
发表于 2021-2-7 14:19 | 显示全部楼层

已经设备已经连上了wif,但是手机app端口一直显示离线。只有把这句话删除app端才显示在线。
发表于 2021-2-7 14:20 | 显示全部楼层
3137234383 发表于 2021-2-7 14:19
已经设备已经连上了wif,但是手机app端口一直显示离线。只有把这句话删除app端才显示在线。 ...

库太老了,不知道你哪里下的,按官方文档操作即可
发表于 2021-2-7 14:23 | 显示全部楼层
coloz 发表于 2021-2-7 14:20
库太老了,不知道你哪里下的,按官方文档操作即可

好的,谢谢你,我试试看
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

小黑屋|Archiver|手机版|Arduino中文社区

GMT+8, 2024-11-28 15:43 , Processed in 0.085925 second(s), 19 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表